Commit 6a47f145 by 宋毅

tj

parent 751354e6
......@@ -28,6 +28,9 @@ class ProductAPI extends APIBase {
case "addOrder"://创建订单
opResult = await this.utilsOrderSve.addOrder(pobj, pobj.actionBody);
break;
case "getIcbcOrderDetails"://获取工商详情
opResult = await this.utilsOrderSve.addOrder(pobj, pobj.actionBody);
break;
default:
opResult = system.getResult(null, "action_type参数错误");
break;
......
......@@ -17,9 +17,9 @@ class UtilsOrderService extends AppServiceBase {
if (!price_list) {
return system.getResult(null, "产品价格列表信息有误,10080");
}
var product_price = price_list.filter(f => f.id == actionBody.id);
var product_price = price_list.filter(f => f.pay_code == actionBody.pay_code);
if (!product_price || product_price.length == 0) {
return system.getResult(null, "产品定价id信息有误,10110");
return system.getResult(null, "支付价格pay_code信息有误,10110");
}
var totalSum = Number(product_price[0].price) * Number(actionBody.quantity);
if (Number(actionBody.totalSum) < totalSum) {
......@@ -37,8 +37,8 @@ class UtilsOrderService extends AppServiceBase {
if (!actionBody.channelItemCode) {
return system.getResult(null, "产品编码有误,10010");
}
if (!actionBody.id || Number(actionBody.id) <= 0) {
return system.getResult(null, "定价ID有误,10030");
if (!actionBody.pay_code || Number(actionBody.pay_code) <= 0) {
return system.getResult(null, "支付价格pay_code有误,10030");
}
if (!actionBody.quantity || Number(actionBody.quantity) <= 0) {
return system.getResult(null, "订单数量有误,10050");
......
......@@ -161,7 +161,7 @@
``` javascript
{
"channelItemCode":"fzsbzc",// Y 产品的渠道编码
"id":2,// Y 定价id
"pay_code": "zzsbzc-1", // Y 支付价格code
"quantity":1,// Y 购买数量
"totalSum":699,// Y 订单总金额
"payTotalSum":699, // Y 订单付款总金额
......
......@@ -26,7 +26,7 @@
"status": 0,
"msg": "success",
"data": [
{
{
"uapp_id": 26,//平台id--显示不用
"path_code": "/sbfu/sbzc/",//产品路径编码--显示不用
"path_name": "/商标服务/商标注册/",//产品路径名称--显示不用
......@@ -41,7 +41,7 @@
"icon_url": null,//产品的icon
"productType_id": 2,//产品类型id--显示用不到
"sort": 1,//排序
"id": 1, //定价id
"pay_code": "zzsbzc-1", //支付价格code
"service_charge": 30,//服务费
"public_expense": 270,//官费
"price": 300,//价格
......@@ -92,7 +92,7 @@
"icon_url": null,//产品的icon
"productType_id": 2,//产品类型id--显示用不到
"sort": 1,//排序
"id": 1, //定价id
"pay_code": "zzsbzc-1", //支付价格code
"service_charge": 30,//服务费
"public_expense": 270,//官费
"price": 300,//价格
......@@ -128,7 +128,7 @@
"status": 0,
"msg": "success",
"data": {
"id": 1,
"id": 1,//产品Id
"uapp_id": 26,
"path_code": "/sbfu/sbzc/",
"path_name": "/商标服务/商标注册/",
......@@ -144,7 +144,7 @@
"productType_id": 2,
"price_list": [
{
"id": 1,//定价id
"pay_code": "zzsbzc-1", //支付价格code
"price": 300,
"supply_price": 270,
"service_charge": 30,
......@@ -158,7 +158,7 @@
"max_qty": null
},
{
"id": 4,//定价id
"pay_code": "zzsbzc-2", //支付价格code
"price": 580,
"supply_price": 540,
"service_charge": 40,
......
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