使用面向对象的 PHP 设计 ERP 系统需要遵循哪些步骤?
我被指派为一家小型企业使用面向对象的 PHP 设计 ERP 系统。我已经为此设计了数据库。
以前我设计过一些Web应用程序,但从未使用过面向对象编程。
我有以下疑问。
我知道项目的文档很重要,但不知道执行此操作的程序。
不确定要遵循哪种架构,如 MVC 或 3 层等。
UML 在项目中的重要性以及如何设计它数据库或类和对象。
如何将数据库映射到类和对象。
我已经为该项目设计了数据库,但不确定如何进一步进行。
I have been assigned to design an ERP system for a small enterprise with Object oriented PHP.I have already designed the database for that.
Previously I have designed some web applications but never used Object oriented programming.
I have the following doubts.
I know that the documentation of a project matters a lot, but do not know the procedure to do that.
Not sure which architecture to follow like MVC or 3-tier etc.
Significance of UML in the project and how to design it from the database or the classes and objects.
How to map the database to classes and objects.
I have already designed the database for the project ,but not sure how to proceed further.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
您已经创建了数据库,但尚未记录该项目?我的朋友,你正处于一个痛苦的世界。
项目文档,包括最终用户可读的功能规范和完整的管理签字,是至关重要的。 (即使您遵循敏捷流程并且没有大的预先设计规范!)虽然 ERP 系统的每个组件都非常简单,但用户的工作流程将至关重要在编写任何代码之前理解。如果任何组件无法获得用户的认可和管理人员的认可,您的项目将会被终止,并且/或者在推出后会彻底失败。
当前的用户工作流程很可能是临时的或文档记录不足......或更糟糕的是,没有流程,只是人们独立工作,不了解数据/资金的整体流程/库存/组织其他部分的任何内容。虽然从人员中提取工作流程不是您的责任,但您有责任确保创建工作流程并且您的应用程序遵循它。如果您喜欢使用 UML,那么这就是它的亮点。请记住,UML 只是工具箱中的一个工具,还有很多其他方法来表示整个流程中的用户交互。
我根据个人经验给你这个建议。我是一名全职 PHP 开发人员,我的主要项目是我雇主自行开发的基于 PHP 的 ERP/CMS/CRM 系统。在编码之前未能理解流程会导致工具质量不佳。如果无法确保编码之前有一个流程,就会导致工具质量不佳。未能获得用户和管理层的支持会导致用户满意度不佳,这会损害您的声誉和项目。
您已将此标记为 PHP 问题。 采用现代 PHP 框架的 MVC 将会是明智的。我有点喜欢 Zend Framework,但其他许多人都非常喜欢 CodeIgniter、Symfony、Yii、Kohana 和 Lithium。评估一些,并至少做出一个选择。许多现代框架都是松耦合的,并且可以很好地协同工作。我知道 ZF 和 Symfony 可以成为很好的搭档。
至于数据库表到类和对象的映射,请始终牢记 MVC 中的“M”——模型。模型负责包含业务逻辑和相关数据。您的模型应该是负责使用数据库的部分。我提到的框架包括许多工具,可以使用各种方法和模式轻松构建有用的、正确的、可扩展的模型。再次评估您可用的框架选项以及他们更喜欢如何构建模型,以找到适合您的解决方案。
You've already created the database, but you haven't documented the project? My friend, you are in for a world of pain.
Documentation for the project, including an end-user-readable functional specification with complete managerial sign-off is critical. (Even if you're following an Agile process and there's no Big Design Up Front specification!) While each component of an ERP system is pretty straight-forward, the workflows of the users are going to be critical to understand before writing any code. Failure to get user buy-in and managerial sign-off for any component is going to kill your project and/or make it an utter failure after rollout.
It's very possible that the current user workflow is either ad-hoc or poorly documented... or worse, there is no process and it's just people working independently with no understanding of the overall flow of data/money/inventory/whatever throughout the rest of the organization. While it's not your responsibility to extract a workflow out of people, it is going to be your responsibility to ensure that workflow is created and that your application follows it. If you're the type to use UML, here's where it may shine. Just remember that UML is just a tool in the toolbox, and there are lots of other ways to represent user interaction throughout a process.
I give you this advice from personal experience. I'm a full time PHP developer, and my primary project is my employer's home-grown PHP-based ERP/CMS/CRM system. Failing to understand process before coding results in poor tools. Failing to ensure there is a process before coding results in poor tools. Failing to get both user and managerial buy-in results in poor user satisfaction, and that will hurt both your reputation and the project.
You've tagged this as a PHP question. MVC with a modern PHP framework is going to be wise. I kind of like Zend Framework, but many others swear by CodeIgniter, Symfony, Yii, Kohana and Lithium. Evaluate a few, and make at least one choice. Many modern frameworks are loosely-coupled and can work well together. I understand that ZF and Symfony can make a good pair.
As for the mapping of database tables to classes and objects, always keep in mind the "M" in MVC -- the Models. Models are responsible for containing business logic and the related data. Your Models should be the parts responsible for working with the database. The frameworks I've mentioned include many tools that make it easy to build useful, correct, extensible models using a variety of methods and patterns. Again, evaluate your available framework options and how they prefer building their Models to find a solution that will work well for you.