版权说明:本文档由用户提供并上传,收益归属内容提供方,若内容存在侵权,请进行举报或认领
文档简介
1、Design and implementation of the MVCpattern personal financial managementsystem based onPaper Introduction: MVC model has become a classic of software architecture, which uses a divide and conqueridea to make the application of the mandatory input, processing and output separately, the system is div
2、ided into three major categories: model (Model ), view (View) and the controller (Controller). Personal financial management system to record details of everyday life in the balance of payments program, and be able to analyze charts, financial planning, unified management of various assets, data sea
3、rch, and export data to an Excel spreadsheet.Keywords: MVC pattern, financial management systems1, MVC design pattern Introduction to MVC (Model-View-Controller) proposed by Trygve Reenskaug, was first used in SmallTalk-80 environment, constitute the basis of many interactive interface system. Paper
4、 format. MVC model has become a classic of software architecture, which uses a divide and conquer mentality, forcibly enter theapplication, processing and output separately, the system is divided into three major categories: model (Model), view (View) and the controller (Controller).s re1.1 Views Vi
5、ews are users see and interact with the interface, the model data, logic and status information presented to the user in a specific format. It displays information obtained from the model, for the same information can have several different display form or view. MVC design pattern for dealing with a
6、 limited view on the view data acquisition and processing, as well as the user and not included in the view of the business process handling.View output data and only as a way to allow the user to manipulate.1.2 Models is where all the business logic code fragments1 . It indicates that the data and
7、business rules, encapsulates the core data computing problems, logical and functional relationship management application domain behavior and data, has the largest number of processing tasks. It is independent of the specific expression of the interface and I / O operations, the data returned by the
8、 model is neutral, that is independent of the model and the data format, such a model can provide data for a plurality of views.1.3 Controller The controller is handling user interaction with the software, so that the model and the view to coordinate efforts to ensure that the user interface compone
9、nts corresponding to the contact between the model. It accepts user input, the feedback input to the model, thus achieving control of the computational model. Meanwhile, update and modify the model will also be used to notify the view through the controller to maintain consistency with the model of
10、each view.Processing 1.4MVC First, the controlle r accepts the user s request, and to decide which models should be called to deal with. Then, the model with the business logic to handle user requests and return data. Finally, the controller model with the corresponding view formatted data returned
11、and presented to the user through the presentation layer. Model, view, the relationship among the controller and each main function (see Figure 1).Figure 1 MVC components and features two types of relationships, personal financial management system design and implementation of personal financial man
12、agement system to record details of everyday life in the balance of payments program, and be able to analyze charts, financialplanning, unified management of various assets for data search, and export data to Excel spreadsheet. Personal financial management system design using the MVC pattern, the u
13、se of the database is SQL Server 2000, the .NET platform implementation of the system, which involves JQuery, AJAX, ADO.NET technology.In Visual Studio 2008, and by creatinga ASP.NET MVC WEB APLICATION, the system will automatically generate an MVC framework, which includes Views, Controllers and Mo
14、dels, began to realize the system on this basis.2.1 Database Design Database Accout personal financial management system contains three data tables:(1) The user table (Users) by user number, user name, real name, password, gender, occupation components.(2) a statement of accounts (Accounts)accounts
15、by type,user, expenditure / income, amount, project name, date of composition. Paper format.(3) the type of accounts table (AccountsTypes) from the accounts of type number, account type names.2.2 Build VisualStudio.NET view layer provides data in the View Designer toolbox, Web Forms, Components, HTM
16、L, and other controls, while also providing user control. Through the above various controls, such as the development of the Windows interface can be the same way in WYSIWYG visual design. In ASP.NET development environment designed to achieve the aspx page view.The user interface consists of the fo
17、llowing main pages:(1) Home display information: About.aspx, Index.aspx.(2) Registration and login screen: Register.aspx, Logon.aspx, Error.aspx.(3) After you log into the main interface: TitleContent.aspx, mainContent.aspx.(4) accounting, edit, delete accounts interface information: AccountEdit.asp
18、x, AccountDel.aspx, AccountUpdate.aspx so on.(5) View account information interface: AccountView.aspx like.(6) user interface to change the password: ChangePassword.aspx.Design and implementation of the model layer of 2.3 (1) database connection model: definition and use ADO.NET technology database
19、connection, close the database methods.(2) The type of business model: this system IdbADO.cs and DbADO.cs business models are abstract database of common operations: query, add, delete, modify the interface and implementation class interface. All operations in the future as long as the class that im
20、plements the interface or inherit it. interface ICriteria.cs abstract complex query, class Order.cs, Criteria.cs complex query. interface IUserService, IAccountService, IAccountTypeService abstract service model layer to the control layer (Controller) provided by the class UserService, AccountServic
21、e, AccountTypeService achieve these three interfaces.(3) physical layer model: Create a physical layer for each data table, a data field as a property, each property has its own get and set methods. There User.cs, Account.cs, AccountType.cs, EntityFactory.cs four physical layer model in this system,
22、 which is used to generate EntityFactory.cs class entities.2.4 Building Controller ASP.NET code separation mechanism allows the code with the Model View Controller code and can be easily separated.Each aspx file correspondsto a back-end code files through the back-end code to implement Controller fu
23、nctions. Paper format.The system controller: AccountController, HomeController, testController, UserController more. These controllers are based on the user s request to determine which call action,the use of which models and views to complete the appropriate action. User requests are: login, entry,
24、 query, accounts list, edit, save, analyze, and delete.These requestsare entered by the view layer, the control layer is passed to the model for processing.Design will be business logic of the system, and database connectivity and interactive public operations encapsulated in a separate class, with
25、a special class to handle the business logic and data logic, thereby increasing the reusability of the code.3, the conclusion of this article on the .NET platform as the design and implementation of the MVC pattern standard personal financial management system, effectively safeguarding the complexity of the system, and personal financial manageme
温馨提示
- 1. 本站所有资源如无特殊说明,都需要本地电脑安装OFFICE2007和PDF阅读器。图纸软件为CAD,CAXA,PROE,UG,SolidWorks等.压缩文件请下载最新的WinRAR软件解压。
- 2. 本站的文档不包含任何第三方提供的附件图纸等,如果需要附件,请联系上传者。文件的所有权益归上传用户所有。
- 3. 本站RAR压缩包中若带图纸,网页内容里面会有图纸预览,若没有图纸预览就没有图纸。
- 4. 未经权益所有人同意不得将文件中的内容挪作商业或盈利用途。
- 5. 人人文库网仅提供信息存储空间,仅对用户上传内容的表现方式做保护处理,对用户上传分享的文档内容本身不做任何修改或编辑,并不能对任何下载内容负责。
- 6. 下载文件中如有侵权或不适当内容,请与我们联系,我们立即纠正。
- 7. 本站不保证下载资源的准确性、安全性和完整性, 同时也不承担用户因使用这些下载资源对自己和他人造成任何形式的伤害或损失。
最新文档
- 照片滤镜调色课程设计
- 二手车交易平台营业员销售总结
- 春游课程设计
- 家具设计师工作总结
- 风险防控方案计划
- 法律服务行业风险防范方案
- 化工行业卫生防护要点
- 物流运输行业咨询服务经验总结
- 药店卫生管理措施
- 金融领域的投资顾问职责
- 2024-2030年中国汽车水泵市场未来发展趋势及前景调研分析报告
- 绿城营销策划管理标准化手册
- 2025小学创意特色寒假素养作业设计真绝了【高清可打印】
- 2025年上半年河南安阳市睢阳区“减县补乡”乡镇事业单位选拔130人重点基础提升(共500题)附带答案详解
- 2025学年学期学校卫生工作计划
- 10.1.2事件的关系和运算(教学课件)高一数学(人教A版2019必修第二册)
- 2024-2030年中国天然靛蓝行业市场规模预测及发展可行性分析报告
- DB37T 4548-2022 二氧化碳驱油封存项目碳减排量核算技术规范
- 《公路养护安全培训》课件
- 2024国家开放大学基础写作形考任务2试题及答案
- 2023-2024学年江苏省苏州市高一(上)期末地理试卷
评论
0/150
提交评论