|
...
|
...
|
@@ -57,7 +57,7 @@ class CustomTemplateLogic extends BaseLogic |
|
|
|
* @time :2023/6/29 16:21
|
|
|
|
*/
|
|
|
|
public function customTemplateSave(){
|
|
|
|
try {
|
|
|
|
// try {
|
|
|
|
$this->param['url'] = str_replace_url($this->param['url']);
|
|
|
|
if(isset($this->param['id']) && !empty($this->param['id'])){
|
|
|
|
$id = $this->editCustomRoute($this->param['id'],$this->param['url']);
|
|
...
|
...
|
@@ -68,9 +68,9 @@ class CustomTemplateLogic extends BaseLogic |
|
|
|
}
|
|
|
|
$route = RouteMap::setRoute($this->param['url'], RouteMap::SOURCE_PAGE, $id, $this->user['project_id']);
|
|
|
|
$this->model->edit(['url'=>$route],['id'=>$id]);
|
|
|
|
}catch (\Exception $e){
|
|
|
|
$this->fail('error');
|
|
|
|
}
|
|
|
|
// }catch (\Exception $e){
|
|
|
|
// $this->fail('error');
|
|
|
|
// }
|
|
|
|
//TODO::通知网站更新
|
|
|
|
$data = ['project_id'=>$this->user['project_id'], 'type'=>RouteMap::SOURCE_PAGE, 'route'=>$route];
|
|
|
|
$this->updateNotify($data);
|
...
|
...
|
|