Commit d42a59c7 by 任晓松

update

parent 01601afe
...@@ -1206,7 +1206,7 @@ class OrderInfoService extends ServiceBase { ...@@ -1206,7 +1206,7 @@ class OrderInfoService extends ServiceBase {
} }
/** /**
* 需求统计(产品维度) * 订单统计(产品维度)
* @param pobj * @param pobj
* @returns {Promise<void>} * @returns {Promise<void>}
*/ */
...@@ -1233,7 +1233,7 @@ class OrderInfoService extends ServiceBase { ...@@ -1233,7 +1233,7 @@ class OrderInfoService extends ServiceBase {
} }
/** /**
* 需求统计(产品维度) * 订单统计(产品维度)
* @param pobj * @param pobj
* @returns {Promise<void>} * @returns {Promise<void>}
*/ */
...@@ -1333,6 +1333,11 @@ class OrderInfoService extends ServiceBase { ...@@ -1333,6 +1333,11 @@ class OrderInfoService extends ServiceBase {
totalSql += ` and a.uapp_id = :uapp_id`; totalSql += ` and a.uapp_id = :uapp_id`;
whereParams.uapp_id = ab.uapp_id; whereParams.uapp_id = ab.uapp_id;
} }
if(ab.status){
listSql += ` and a.orderStatus = :status`;
totalSql += ` and a.orderStatus = :status`;
whereParams.status = ab.status;
}
if(ab.type_code){ if(ab.type_code){
listSql += ` and b.itemCode = :type_code`; listSql += ` and b.itemCode = :type_code`;
totalSql += ` and b.itemCode = :type_code`; totalSql += ` and b.itemCode = :type_code`;
......
...@@ -183,6 +183,7 @@ class NeedinfoService extends ServiceBase { ...@@ -183,6 +183,7 @@ class NeedinfoService extends ServiceBase {
if (ac.start&&ac.end){ if (ac.start&&ac.end){
sql += ` AND created_at >= :start and created_at <= :end`; sql += ` AND created_at >= :start and created_at <= :end`;
sql2 += ` AND created_at >= :start and created_at <= :end`; sql2 += ` AND created_at >= :start and created_at <= :end`;
sql3 += ` AND created_at >= :start and created_at <= :end`;
whereParams.start = ac.start; whereParams.start = ac.start;
whereParams.end = ac.end; whereParams.end = ac.end;
} }
...@@ -360,6 +361,13 @@ class NeedinfoService extends ServiceBase { ...@@ -360,6 +361,13 @@ class NeedinfoService extends ServiceBase {
needToOrderTotalSql += ` and b.typeName = :type_name`; needToOrderTotalSql += ` and b.typeName = :type_name`;
whereParams.typeName = actionBody.type_name; whereParams.typeName = actionBody.type_name;
} }
if(actionBody.status){
needSql += ` and a.status = :status`;
needTotalSql += ` and a.status = :status`;
needToOrderSql += ` and b.status = :status`;
needToOrderTotalSql += ` and b.status = :status`;
whereParams.status = actionBody.status;
}
if(actionBody.fuzzy_code){ if(actionBody.fuzzy_code){
needSql += ` and ( a.needNo like :fuzzy_code or a.channelNeedNo like :fuzzy_code or a.publishMobile like :fuzzy_code)`; needSql += ` and ( a.needNo like :fuzzy_code or a.channelNeedNo like :fuzzy_code or a.publishMobile like :fuzzy_code)`;
needTotalSql += ` and ( a.needNo like :fuzzy_code or a.channelNeedNo like :fuzzy_code or a.publishMobile like :fuzzy_code)`; needTotalSql += ` and ( a.needNo like :fuzzy_code or a.channelNeedNo like :fuzzy_code or a.publishMobile like :fuzzy_code)`;
......
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