Commit 0b5ef6eb by Sxy

fix: 统计优化

parent a24075a3
......@@ -119,6 +119,15 @@ class StatisticsCtl extends CtlBase {
}
}
async getNeedProductType(pobj, qobj, req) {
try {
const rs = await this.service.getNeedProductType(pobj);
return system.getResult(rs);
} catch (err) {
return system.getResult(null, err.message)
}
}
}
module.exports = StatisticsCtl;
......@@ -11,7 +11,7 @@ class StatisticsService {
const data = await ToQiFuTong.getStatisticsByUappId({
start: pobj.start,
end: pobj.end,
type_code: pobj.type_code,
type_name: pobj.type_code,
status: pobj.status
});
const dates = ToQiFuTong.getAllDate(pobj.start, pobj.end);
......@@ -102,7 +102,7 @@ class StatisticsService {
return ToQiFuTong.getNeedFunnelStatistics({
start: pobj.start,
end: pobj.end,
type_code: pobj.type_code,
type_name: pobj.type_code,
uapp_id: pobj.uapp_id
});
}
......@@ -111,7 +111,7 @@ class StatisticsService {
const data = await ToQiFuTong.getStatisticsByArea({
start: pobj.start,
end: pobj.end,
type_code: pobj.type_code,
type_name: pobj.type_code,
uapp_id: pobj.uapp_id
});
let result = {};
......@@ -154,7 +154,7 @@ class StatisticsService {
endNow: pobj.endNow,
startLast: pobj.startLast,
endLast: pobj.endLast,
type_code: pobj.type_code,
type_name: pobj.type_code,
uapp_id: pobj.uapp_id
});
return {
......@@ -200,6 +200,7 @@ class StatisticsService {
end: pobj.end,
uapp_id: pobj.uapp_id,
type_code: pobj.type_code,
type_name: pobj.type_code,
pageIndex: pobj.pageNum || 1,
pageSize: pobj.pageSize || 10,
listType: pobj.listType,
......@@ -212,5 +213,9 @@ class StatisticsService {
const data = await ToQiFuTong.importTxNeeds(pobj);
return data;
}
async getNeedProductType(pobj) {
const data = await ToQiFuTong.getNeedProductType(pobj);
return data;
}
}
module.exports = StatisticsService;
\ No newline at end of file
......@@ -98,6 +98,14 @@ class BaseClient {
});
return data;
}
async getNeedProductType() {
const data = await this.pushQiFuTong('/web/action/opNeed/springBoard', {
"actionType": "getNeedProductType",
"actionBody": {
}
});
return data;
}
async getStatisticsByUappId(pobj) {
const data = await this.pushQiFuTong('/web/action/opNeed/springBoard', {
"actionType": "getStatisticsByUappId",
......
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