Commit 20bdcd85 by 兰国旗

laolan

parent c7bd2282
...@@ -37,36 +37,6 @@ class Mediaaggregation extends APIBase { ...@@ -37,36 +37,6 @@ class Mediaaggregation extends APIBase {
case "addbrowsingrecord"://添加页面访问记录 case "addbrowsingrecord"://添加页面访问记录
opResult = this.needinfoSve.addbrowsingrecord(pobj); opResult = this.needinfoSve.addbrowsingrecord(pobj);
break; break;
default:
opResult = system.getResult(null, "action_type参数错误");
break;
}
return opResult;
}
/**
* 接口跳转-POST请求
* action_process 执行的流程
* action_type 执行的类型
* action_body 执行的参数
*/
async mediAaggregationApi(pobj, qobj, req) {
if (!pobj.actionType) {
return system.getResult(null, "actionType参数不能为空");
}
var result = await this.mediAaggregationAction(pobj, pobj.actionType, req);
return result;
}
async mediAaggregationAction(pobj, action_type, req) {
var opResult = null;
var self = this;
pobj.xctx = req.xctx;
switch (action_type) {
case "test"://测试
opResult = system.getResultSuccess("测试接口");
break;
case "productList"://服务列表 case "productList"://服务列表
opResult = await this.mediaaggregationSve.productList(pobj); opResult = await this.mediaaggregationSve.productList(pobj);
break; break;
...@@ -74,7 +44,7 @@ class Mediaaggregation extends APIBase { ...@@ -74,7 +44,7 @@ class Mediaaggregation extends APIBase {
opResult = await this.mediaaggregationSve.rotationChartList(pobj); opResult = await this.mediaaggregationSve.rotationChartList(pobj);
break; break;
case "needProductList"://留资表单产品 case "needProductList"://留资表单产品
opResult =await this.mediaaggregationSve.needProductList(pobj); opResult = await this.mediaaggregationSve.needProductList(pobj);
break; break;
case "popularRecommendationList"://热门推荐列表 case "popularRecommendationList"://热门推荐列表
opResult = await this.mediaaggregationSve.popularRecommendationList(pobj); opResult = await this.mediaaggregationSve.popularRecommendationList(pobj);
...@@ -89,10 +59,11 @@ class Mediaaggregation extends APIBase { ...@@ -89,10 +59,11 @@ class Mediaaggregation extends APIBase {
opResult = await this.mediaaggregationSve.productDetail(pobj); opResult = await this.mediaaggregationSve.productDetail(pobj);
break; break;
case "bottomMenuConfig"://吸底菜单 case "bottomMenuConfig"://吸底菜单
opResult =await this.mediaaggregationSve.bottomMenuConfig(pobj); opResult = await this.mediaaggregationSve.bottomMenuConfig(pobj);
break; break;
default: default:
opResult = system.getResult(null, "action_type参数错误"); opResult = system.getResult(null, "action_type参数错误");
break;
} }
return opResult; return opResult;
} }
......
...@@ -67,7 +67,7 @@ class MediaaggregationSve { ...@@ -67,7 +67,7 @@ class MediaaggregationSve {
} }
//产品详情 //产品详情
async productDetail(pobj) { async productDetail(pobj) {
if (!pobj || !pobj.actionBody || !pobj.actionBody.product_type_code) { if (!pobj || !pobj.actionBody || !pobj.actionBody.product_type_code || !pobj.actionBody.company_id) {
return system.getResultFail(-100, "参数错误"); return system.getResultFail(-100, "参数错误");
} }
......
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