Zblog_ Eloquent_ ORM

  • ID : Zblog_ Eloquent_ ORM
  • edition : 1.0.4
  • author : XiaoFeng ( Author website )  Contact author
  • Official website : H ttps://Www.SongHaiFeng.Com
  • system requirements : Z-BlogPHP 1.7.2 Tenet
  • Update date : 2022-05-17 10:55:30   Update in March
  • amount of downloads : forty-eight
  • Rating : The average score of two votes is 10 / 10
  • PHP version : 7.3 and higher
  • size : 7.84MB

Get apps

It is provided for developers to use. It is useless for ordinary users to download unless the plug-in or theme is required.


I believe that there are friends who use laravel and know how comfortable ORM is to use it. Now it's coming!!!


Need to prepare:

php >= 7.3

Configure composer

Familiar with namespace and autoloading


It can be used after installation. Examples are as follows:

1. Create a new composer under any directory in the theme or plug-in JSON file, write the following code:

{

  "autoload": {

    "psr-4": {

      "ModelsDemo\\": "./ModelsDemo",

      "ObserverDemo\\": "./ObserverDemo"

    }

  }

}

Note: in order to avoid conflicts between the name of the theme or the name of the plug-in, you need to automatically load the folder with the name of the plug-in


2. Execute composer dump autoload to configure automatic loading


3. Include in the theme or plug-in Autoload is introduced into PHP PHP, such as:

include_ once dirname(__FILE__) . DIRECTORY_ SEPARATOR.'/ vendor/autoload. php';


Please refer to Larravel ORM documentation , does not support facade class. For transaction related, please refer to the methods of models / basemodel in the plug-in. Other operations remain unchanged.

Code cloud address: https://gitee.com/SongHaiFeng/Zblog-Eloquent-ORM


#Updated on May 17, 2022

Adjust a problem of last update

The default database link is used to adjust the system table by default


#Updated on April 16, 2022

Add the custompaginate method for paging


#Updated on November 24, 2021

Code conversion table support

Support configuration of multiple databases


#Updated on May 11, 2021

Add pagination support. Examples are as follows:

 $post = \Models\Post::query()->paginate(10, ['*'], 'p', GetVars('p', 'GET', 1));
 echo \Base\Pagination::paginate($post);

Here, it returns the paged HTML structure conforming to bootstrap. If NULL is returned, there will be no paging.

In addition, the pagename of the pagenate method is page by default, and the default paging parameter of zblog is also page, so you need to specify that the paging parameter is p and must be P.

Hello visitor, the real name system has been opened on the relevant website of Z-blog. Please log in after Bind your phone Thank you for your support.


Welcome to: Xiaofeng blog



Zblog Application Center - application purchase and use agreement


1. Before you purchase an app, you must first confirm whether the app meets your needs. Digital products do not support trial. According to Article 25 of the law on the protection of consumers' rights and interests, the app is a digital product downloaded online. Once it is downloaded and installed after purchase, it cannot be refunded.
2. The application you purchased in the application center, Only the license right of the application, the ownership of the application still belongs to the application provider.
3. An application can only be used for a single account without the consent of the website and the application provider, No second release, gift, resale, lease, piracy, etc Otherwise we will Permanently close user account And reserve the right to continue to investigate the relevant responsibilities.
4 The website containing the app has been reselled, given, leased, etc., please use a new account to purchase the app or remove the app Otherwise, it will be regarded as a violation of the usage agreement and the right to use the account will be permanently cancelled.
5. Unless otherwise specified, the purchased applications only include the relevant right to use and free update services, and the application center and application provider will not provide additional after-sales installation services.
6. The user shall bear all risks in using the application, including system damage, data loss and any other risks.
seven Users are not allowed to use the app in any way to engage in acts in violation of laws and regulations and social public order and good customs. Users must be fully responsible for the consequences of their improper use, and neither the website nor the application provider shall bear any responsibility.
8. The website and application provider reserves the right to change, limit, freeze or terminate your use of certain content without informing you and without assuming responsibility for you.


Purchase guide


First, please Registered account number , and then Sign in Application Center.
2. Click "buy app" directly and follow the guide.


Download guide


1. The buyer logs in his / her Z-blog website, enters the background, and clicks "Application Center" menu in the left menu bar.
2. On the home page of "Application Center", log in with the registered account of application center.
3. Enter "my application warehouse", you can see the successfully purchased applications, and click "download" to download and install.


Other precautions


1. If you can't access the application center through your own website background, please purchase carefully, because this may lead to the application not being downloaded and installed smoothly.
2. If the paid app cannot be downloaded normally, please check the Z-blog and application update in the background of your website. If you have updated to the latest version and still can't download, please contact us in time.
3. When applying the update, it is possible to override the local settings. Please make a backup before updating.