Thinkphp code generation tool forThinkphp3.2.2

Source: Internet
Author: User
Provides various official and user-released code examples and code reference. You are welcome to exchange and learn how to support MySQL and sqlite databases, quickly build a project prototype, and directly generate the front and back-end CRUD code snippets, you can also customize code templates as needed to reduce repetitive work.

The reason for writing this is that I have recently been frustrated and found that many times I am doing repetitive things, such as repeating the simplest CRUD method, writing forms, and writing foreground style sheets.

Updated at 23:53:38 on April 9, September 27, 2014: Updated to version 0.3. This change was big and gave up the form of a single file. However, it has more functions. It supports generating files directly and quickly building a project prototype.

ThinkphpHelper
====================
Supports MySQL and sqlite databases to quickly build a project prototype and directly generate the front and back-end CRUD code snippets. You can also customize code templates as needed to reduce repetitive work.

The reason for writing this is that I have recently been frustrated and found that many times I am doing repetitive things, such as repeating the simplest CRUD method, writing forms, and writing foreground style sheets.

Thinkphp's support for background operations is very powerful, and the recently popular Bootstrap framework makes the foreground style easy to follow a standard, so I decided to write a code generator of my own.

I hope it is easy enough for anyone to understand at a Glance. It is good for MySql and Sqlite databases to generate CRUD code stably, it would be better to generate some View code that complies with the Bootstrap framework.

Thanks for your support for thinkphelper. In this version, I gave up the form of a single file to implement more ideas. Now you can see that the interface is more beautiful and more powerful. The biggest highlight of this version is the support for direct file generation. In addition to the database, you only need to write up to five lines of code to quickly build a prototype system. I suggest you modify the Template in the Template folder as needed to better meet your project requirements.

1. Configure your database and copy the TPH folder to your project directory.
2. modify your portal file and add the MODULE you want to generate, such as: define ('Bind _ module', 'test'); access your portal file, let Thinkphp automatically generate the directory structure under your module (note that only modules under the project root directory are supported currently)
3. visit http: // 127.0.0.1/[here is your project name]/index. php/TPH. Now you should be able to see the thinkphelper operation interface.
4. in "generate module options", select your target module, tick the table name corresponding to the Controller you want to generate, and click the "generate" button below, this step is used to generate a layout file. It also modifies the config file in the Module Directory to enable the layout options.
5. In "generate CRUD code", select the target module you want to generate, select the data table you want to generate, and click the blue button "generate file directly"
6. select another data table to be generated and generate the corresponding file.
7. Modify the index method of the IndexController. class. php file in your module and change its content to: $ this-> display ();
8. Access your project, have fun

Note: before using it, you must prepare your database and data tables in the database and configure your modules. However, you must be smart enough to know how to use it, right?

Supports Thinkphp3.2.2

Please refer to the following link for more information: when there are too many threads, there are too many threads, too many threads.

Project address: https://github.com/zhuanqianfish/ThinkphpHelper

Detailed instructions for use address (to be updated): http://zhuanqianfish.github.io/ThinkphpHelper

Video tutorial here: http://pan.baidu.com/s/1i39oOjr

Please refer to the following link for more information: when there are too many threads, there are too many threads, too many threads.

Thinkphelper follows The Apache2 open source Protocol and is available for free.

AD: truly free, domain name + VM + enterprise mailbox = 0 RMB

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.