Commit d4f5496b by 庄冰

ctl

parent c942cfb0
......@@ -32,25 +32,25 @@ class Template extends APIBase {
case "test"://测试
opResult = system.getResultSuccess("测试接口");
break;
case "createTemplate"://创建模板
opResult = await this.templateinfoSve.createTemplate(pobj);
break;
// case "createTemplate"://创建模板
// opResult = await this.templateinfoSve.createTemplate(pobj);
// break;
case "editTemplateContent"://修改模板内容
opResult = await this.templateinfoSve.editTemplateContent(pobj);
break;
case "updateSwitchStatus"://修改模板启用状态
opResult = await this.templateinfoSve.updateSwitchStatus(pobj);
break;
case "findAndCountAll"://模板列表查询
pobj.actionBody.company_id = pobj.company_id;
opResult = await this.templateinfoSve.findAndCountAll(pobj.actionBody);
break;
// case "updateSwitchStatus"://修改模板启用状态
// opResult = await this.templateinfoSve.updateSwitchStatus(pobj);
// break;
// case "findAndCountAll"://模板列表查询
// pobj.actionBody.company_id = pobj.company_id;
// opResult = await this.templateinfoSve.findAndCountAll(pobj.actionBody);
// break;
case "findOneByCode"://模板查询
opResult = await this.templateinfoSve.findOneByCode(pobj);
break;
case "editTemplateTdk"://编辑模板TDK
opResult = await this.templateinfoSve.editTemplateTdk(pobj);
break;
// case "editTemplateTdk"://编辑模板TDK
// opResult = await this.templateinfoSve.editTemplateTdk(pobj);
// break;
case "getTemplateAndLinkInfo"://根据链接参数获取模板链接信息
opResult = await this.templatelinkSve.getTemplateAndLinkInfo(pobj);
break;
......
......@@ -30,22 +30,22 @@ class Templatelink extends APIBase {
case "test"://测试
opResult = system.getResultSuccess("测试接口");
break;
case "createTemplateLink"://创建模板链接
opResult = await this.templatelinkSve.createTemplateLink(pobj);
break;
case "editTemplateLink"://修改模板链接
opResult = await this.templatelinkSve.editTemplateLink(pobj);
break;
case "updateLaunchStatus"://修改投放状态
opResult = await this.templatelinkSve.updateLaunchStatus(pobj);
break;
case "findAndCountAll"://链接列表查询
pobj.actionBody.company_id = pobj.company_id;
opResult = await this.templatelinkSve.findAndCountAll(pobj.actionBody);
break;
case "findOneByCode"://获取模板链接详情数据
opResult = await this.templatelinkSve.findOneByCode(pobj);
break;
// case "createTemplateLink"://创建模板链接
// opResult = await this.templatelinkSve.createTemplateLink(pobj);
// break;
// case "editTemplateLink"://修改模板链接
// opResult = await this.templatelinkSve.editTemplateLink(pobj);
// break;
// case "updateLaunchStatus"://修改投放状态
// opResult = await this.templatelinkSve.updateLaunchStatus(pobj);
// break;
// case "findAndCountAll"://链接列表查询
// pobj.actionBody.company_id = pobj.company_id;
// opResult = await this.templatelinkSve.findAndCountAll(pobj.actionBody);
// break;
// case "findOneByCode"://获取模板链接详情数据
// opResult = await this.templatelinkSve.findOneByCode(pobj);
// break;
default:
opResult = system.getResult(null, "action_type参数错误");
break;
......
......@@ -24,6 +24,10 @@ class CtlBase {
const up = await this.service.delete(pobj);
return system.getResult(up);
}
async bulkDelete(ids) {
var en = await this.service.bulkDelete(ids);
return en;
}
async findAndCountAll(pobj, qobj, req) {
//设置查询条件
pobj.search.company_id = pobj.company_id;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment