39 lines
810 B
PHP
39 lines
810 B
PHP
|
|
<?php
|
||
|
|
|
||
|
|
namespace App\Http\Controllers\core;
|
||
|
|
|
||
|
|
use App\BaseApp\BaseController;
|
||
|
|
use App\Service\core\CodeGenerationService;
|
||
|
|
use App\Service\LoginService;
|
||
|
|
use Illuminate\Http\JsonResponse;
|
||
|
|
|
||
|
|
class codeGenerationController extends BaseController
|
||
|
|
{
|
||
|
|
//
|
||
|
|
|
||
|
|
public function __construct()
|
||
|
|
{
|
||
|
|
parent::__construct();
|
||
|
|
$this->service = CodeGenerationService::getInstance();
|
||
|
|
}
|
||
|
|
|
||
|
|
public function generation()
|
||
|
|
{
|
||
|
|
$this->insertField = [
|
||
|
|
'class_name',
|
||
|
|
'class_comment',
|
||
|
|
'sort',
|
||
|
|
'icon',
|
||
|
|
'pid',
|
||
|
|
'field',
|
||
|
|
];
|
||
|
|
|
||
|
|
$params = $this->checkRequiredFields(request()->post());
|
||
|
|
return $this->service->generate($params);
|
||
|
|
// return jok(
|
||
|
|
// $this->service->generate([])
|
||
|
|
// );
|
||
|
|
}
|
||
|
|
|
||
|
|
}
|