|
...
|
...
|
@@ -92,7 +92,17 @@ class Project5CateController extends BaseController |
|
|
|
if($projectInfo === false){
|
|
|
|
$this->response('当前项目不存在或数据未同步',Code::SYSTEM_ERROR);
|
|
|
|
}
|
|
|
|
$url = $projectInfo['website'].'wp-admin/admin-ajax.php?action=get_products_category';
|
|
|
|
$data = http_post($url);
|
|
|
|
$project5CateModel = new Project5Cate();
|
|
|
|
$projectInfo['website'] = 'https://devmark.globalso.com/';
|
|
|
|
$action = $project5CateModel->saveCateTypeAction($this->param['type']);
|
|
|
|
$url = $projectInfo['website'].'wp-admin/admin-ajax.php?action='.$action;
|
|
|
|
if(empty($action)){
|
|
|
|
$this->response('未知请求',Code::SYSTEM_ERROR);
|
|
|
|
}
|
|
|
|
$data = http_post($url,json_encode(['name'=>$this->param['name'],'parent'=>$this->param['parent']],true));
|
|
|
|
if($data && $data['status'] == 200){
|
|
|
|
$this->response('success', );
|
|
|
|
}
|
|
|
|
$this->response('请求失败',Code::SYSTEM_ERROR);
|
|
|
|
}
|
|
|
|
} |
...
|
...
|
|