Support MySQL and SQLite databases, quickly build project prototypes, generate front and rear crud code snippets directly, and customize code templates to reduce duplication of effort as needed.
The reason I wrote this was because I recently found myself frustrated that I was doing repetitive things, such as repeating the simplest crud methods, writing forms, writing foreground stylesheets, and so on.
September 27, 2014 23:53:38 Update: Upgrade to version 0.3, the change is large, abandoned the form of single file, but more rich, support the direct generation of files, quickly build a project prototype
Thinkphphelper
==============
Support MySQL and SQLite databases, quickly build project prototypes, generate front and rear crud code snippets directly, and customize code templates to reduce duplication of effort as needed.
> The reason for writing this is because I've recently been frustrated that I've been doing repetitive things, like repeating the simplest crud methods, writing forms, writing foreground stylesheets, and so on.
thinkphp's support for background operations has been very strong, and the recent very popular bootstrap framework has made the foreground style easier to follow a standard, so I decided to start writing a code generator that belongs to me.
> I want it to be simple enough to get a good look at it, and it's nice to be able to reliably generate crud code for both MySQL and SQLite databases, as well as to generate some view code that conforms to the bootstrap framework.
thinkphphelper was born to thank you for your support. In this version I gave up the form of a single file in order to achieve more ideas. You can see now that the interface is more beautiful and the functionality is more powerful. The biggest highlight of this version is the support for directly generated files, in addition to the database, you only need to write 3 or so lines of code to quickly build a prototype system. I suggest that you can modify the templates in the template folder according to your needs to make them more consistent with your project needs.
In the test I used a SQLite database, copy the database files into the project directory, such as the use of MySQL database can omit this step.
Copy the TPH folder to the project directory.
Modify the project configuration file, primarily the configuration database information.
Visit TPH, you should see the above interface
Click "Generate Module Options" To select a good target module, tick the name of the table you need to generate, click Generate. After success, you will be prompted to generate a path. This step is primarily to generate a layout file.
Click on "Generate CRUD code", note Select the same data table as the previous step, click Generate file.
Modify the index method under the index controller content is: $this->show ();
Visit your project again with fun.
Note that it is important to prepare your database and database tables before use, and to configure your module, but smart you must know how it is used, right?
Support Thinkphp3.2.2
↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓
Project address: Https://github.com/zhuanqianfish/ThinkphpHelper
Detailed instructions for use address: Http://zhuanqianfish.github.io/ThinkphpHelper
↑↑↑↑↑↑↑↑↑↑↑↑↑↑↑↑↑↑↑↑↑↑↑↑↑↑↑↑↑↑↑↑↑↑↑↑↑↑↑↑↑↑↑↑↑↑↑↑↑↑↑↑↑↑↑↑↑↑↑↑↑↑↑↑↑↑↑
thinkphphelper follows the Apache2 Open source Agreement and is available for free use.
Thinkphp code generation tool Thinkphphelper