1. Go to this page and download the library: Download alphazento/zento library. Choose the download type require.
2. Extract the ZIP file and open the index.php.
3. Add this code to the index.php.
<?php
require_once('vendor/autoload.php');
/* Start to develop here. Best regards https://php-download.com/ */
alphazento / zento example snippets
class TestModel extends \Illuminate\Database\Eloquent\Model {
use \Zento\Kernel\Booster\Database\Eloquent\DynamicAttribute\DynamicAttributeAbility;
}
DanamicAttributeFactory::createRelationShipORM(TestModel::class,
'new_column', ['char', 32], true);
DanamicAttributeFactory::createRelationShipORM(TestModel::class,
'new_column1', ['char', 32], false);
TestModel::listDynamicAttributes(); //list all dynamic Attributes
$collection = TestModel::where('id', 1)->withDynamicSingleAttribute('new_column')->withDynamicOptionAttribute('new_column1')->first();
'config_extend' => [
'extra_repository' => \Zento\Kernel\Booster\Config\ConfigInDB\ConfigRepository::class,
'grouping_provider' => null //config can be different by grouping
]
php artisan package:enable Zento/Kernel
php artisan package:enable Zento/ThemeManager
php artisan package:enable Zento/UrlRewriter
shell
/mypackages/{VendorName/{PackageName# tree
.
|-- Console
| `-- Commands //put your console command class files here
|
|-- Http
| |-- Controllers //put your Controllers class files here
| `-- Middleware //put your middleware class files here
|
|-- Model //put your Model class files here
|
|-- Providers //put your ServiceProvider class files here
| `-- Facades
|
|-- Services //put your real service class files here
|
|-- Events //Put event class and listener class here
| |-- Listeners
|
|-- database //database migration management here
| |-- 0.0.1 //version number
| |-- 01_create_sample_table1.php
| |-- 0.0.2 //version number
| |-- 01_create_sample_table2.php
|
|-- resources //everything about frontend,please put here
| |-- public
| | |-- css
| | |-- font
| | |-- images
| | `-- js
| `-- views //your views. Please use it by: view('VendorName.'), with your VendorName_PackageName prefix.
|
|-- composer.json //Config extra/laravel/zento setting here
|
`-- routes.php.example //Please change it as "routes.php" if you want to use routes.
Loading please wait ...
Before you can download the PHP files, the dependencies should be resolved. This can take some minutes. Please be patient.