From 21e0660b32f926c182b5ca5181ac4c2c65596bf9 Mon Sep 17 00:00:00 2001 From: "liujw155@outlook.com" Date: Wed, 31 Aug 2022 18:00:30 +0800 Subject: [PATCH] add income api --- src/pages/turnover/turnover.vue | 189 +++++++++++++-------- src/static/images/icon/triangle_c33.png | Bin 0 -> 339 bytes .../income/pages/details_record/details_record.vue | 5 +- src/subpackage/income/pages/search/search.vue | 65 ++++++- 4 files changed, 175 insertions(+), 84 deletions(-) create mode 100644 src/static/images/icon/triangle_c33.png diff --git a/src/pages/turnover/turnover.vue b/src/pages/turnover/turnover.vue index afdd859..b09eb70 100644 --- a/src/pages/turnover/turnover.vue +++ b/src/pages/turnover/turnover.vue @@ -5,7 +5,6 @@ 门店统计 - @@ -31,10 +30,30 @@ ¥{{totalData.count_type_actual_income_amount || '0'}} - - 线上 ¥{{totalData.online_actual_income_amount || '0'}} - 线下 ¥{{totalData.offline_actual_income_amount || '0'}} + + + + 线上 + + + ¥{{totalData.online_actual_income_amount || '0'}} + + + + 线下 + + + ¥{{totalData.offline_actual_income_amount || '0'}} + + + + 联营 + + + ¥{{totalData.joint_actual_income_amount || '0'}} + + @@ -57,36 +76,32 @@ 总收入 ¥{{botData.count_type_actual_income_amount || 0}} - - - - - 线上 ¥{{ botData.online_actual_income_amount || '0' }} - - - 收款{{ botData.online_income_num || '0' }}笔 - ( ¥{{ botData.online_income_amount || '0' }} ) - - - 退款{{ botData.online_refund_num || '0' }}笔 - ( ¥ {{ botData.online_refund_amount || '0' }} ) + + 查看收款明细 + + + + + 线上 ¥{{ botData.online_actual_income_amount || '0' }} + + 收款{{ botData.online_income_num || '0' }}笔(¥{{ botData.online_income_amount || '0' }}) + 退款{{ botData.online_refund_num || '0' }}笔(¥{{ botData.online_refund_amount || '0' }} - - - - 线下 ¥{{ botData.offline_actual_income_amount || '0' }} - - - 收款{{ botData.offline_income_num || '0' }}笔 - ( ¥{{botData.offline_income_amount || '0'}} ) + + 线下 ¥{{ botData.offline_actual_income_amount || '0' }} + + 收款{{ botData.offline_income_num || '0' }}笔(¥{{ botData.offline_income_amount || '0' }}) + 退款{{ botData.offline_refund_num || '0' }}笔(¥{{ botData.offline_refund_amount || '0' }} - - 退款{{ botData.offline_refund_num || '0' }}笔 - ( ¥{{ botData.offline_refund_amount || '0' }} ) + + + 联营 ¥{{ botData.joint_actual_income_amount || '0' }} + + 收款{{ botData.joint_income_num || '0' }}笔(¥{{ botData.joint_income_amount || '0' }}) + 退款{{ botData.joint_refund_num || '0' }}笔(¥{{ botData.joint_refund_amount || '0' }} - @@ -387,7 +402,9 @@ export default { background-color: #fff; } .turnover-container{ - + padding-bottom: 40upx; + padding-bottom: calc( 40upx + constant(safe-area-inset-bottom)); /* 兼容 iOS < 11.2 */ + padding-bottom: calc( 40upx + env(safe-area-inset-bottom)); /* 兼容 iOS >= 11.2 */ } .tc-tab{ height: 134upx; @@ -445,7 +462,6 @@ export default { } .tts-money{ padding-top: 48upx; - >view{ margin-bottom: 34upx; text-align: center; @@ -481,21 +497,39 @@ export default { } } } - .tts-preview{ - padding-bottom: 70upx; + .tts-preview-ls{ + padding-top: 50upx; + padding-bottom: 36upx; @include centerFlex(space-between); - >view{ - width: 50%; - padding: 0 24upx; - line-height: 40upx; - text-align: center; - font-size: 28upx; - font-weight: 500; - color: #1a1a1a; - white-space: nowrap; - text-overflow: ellipsis; - overflow: hidden; - + .tpl-item{ + padding: 0 10upx; + flex-shrink: 0; + flex-grow: 1; + width: 33.33%; + .ti-name{ + @include centerFlex(center); + margin-bottom: 6upx; + line-height: 34upx; + font-weight: 500; + font-size: 24upx; + color: #1A1A1A; + >image{ + margin-left: 10upx; + flex-shrink: 0; + width: 28upx; + height: 28upx; + } + } + .ti-price{ + text-align: center; + line-height: 34upx; + font-size: 24upx; + font-weight: 500; + color: #1A1A1A; + @include textHide(1); + } + + } } } @@ -577,37 +611,46 @@ export default { } @include textHide(1); } - .td-detail{ - padding: 0 24upx; - width: 100%; - @include centerFlex(center); - >view{ - max-width: 50%; - flex-shrink: 0; - .td-first{ + .td-check-btn{ + padding-bottom: 12upx; + width: 642upx; + line-height: 40upx; + font-size: 28upx; + border-bottom: 2upx solid #D8D8D8; + color: #9C9C9F; + @include centerFlex(flex-end); + >image{ + margin-left: 6upx; + width: 22upx; + height: 22upx; + } + + } + .td-income-info{ + padding: 40upx 0 0; + width: 642upx; + .tii-line{ + margin-bottom: 50upx; + .tl-tit{ margin-bottom: 24upx; - color: #1A1A1A; - font-weight: 500; + line-height: 40upx; font-size: 28upx; - } - &:first-child{ - margin-right: 24upx; - } - &+view{ - margin-left: 24upx; - } - >view{ - font-size: 24upx; - color: #9C9C9F; + font-weight: 500; + color: #1A1A1A; @include textHide(1); - >text{ - - } - .orange{ - color: #F6843E; - } - .margin{ - margin-right: 12upx; + } + .tl-detail{ + @include centerFlex(space-between); + flex-wrap: nowrap; + .td-item{ + width: 50%; + flex-grow: 0; + flex-shrink: 0; + font-size: 24upx; + color: #9C9C9F; + >text{ + color: #F6843E; + } } } } diff --git a/src/static/images/icon/triangle_c33.png b/src/static/images/icon/triangle_c33.png new file mode 100644 index 0000000000000000000000000000000000000000..26bf1e8d4d47401c96c9b92e5ba37b4afc5897ad GIT binary patch literal 339 zcmeAS@N?(olHy`uVBq!ia0vp^Iv~u!3?wz9Rv7~+*8raoS0F7fFE1q}B`GN>E-o$$ z20$(Z0D02V(lDMBkPQSfGBOYmAOpw+vej;9bO8+#D+%%oX5e`7L!8&>(zZ^OyN6d+ zXGPjgEDrMUvybKjs#xyn;uvCa`t4;)zQYDQE`dQ;p4C48+b?DIu70}G%wugI95|Fc z|NZpZk{0Np`aRTD(=YRM)5hhB#c#ItEE1RHE*Xz^>X|AD?*K;yNC9N`jkb z_VUe-PKt?!HQhgBer#fyYpcleg$X%{FU>Bst^T}CJm&76)fz|sHXP5*d+zam^Kw(2 zIX1DbFKXwN{bReWD50OIn78-X^oN_SO&99dJimLg{5ke5ANUjQzcbGRI+?-K)z4*} HQ$iB}F8g>S literal 0 HcmV?d00001 diff --git a/src/subpackage/income/pages/details_record/details_record.vue b/src/subpackage/income/pages/details_record/details_record.vue index db3a864..dd7c473 100644 --- a/src/subpackage/income/pages/details_record/details_record.vue +++ b/src/subpackage/income/pages/details_record/details_record.vue @@ -42,8 +42,8 @@ @@ -376,6 +376,7 @@ >input{ flex-grow: 1; height: 100%; + font-weight: 400; font-size: 28upx; color: #1a1a1a; } diff --git a/src/subpackage/income/pages/search/search.vue b/src/subpackage/income/pages/search/search.vue index 5bc82cd..80638dd 100644 --- a/src/subpackage/income/pages/search/search.vue +++ b/src/subpackage/income/pages/search/search.vue @@ -2,20 +2,38 @@ - - - + + + + + + + - + - @@ -32,12 +50,36 @@ export default { data(){ return { incomeLs: [], + isFocus: false, + searchKey: '', + page: 1, + } }, onLoad(){ - this.getRecordLs({}); + }, + onReachBottom(){ + let { searchKey, page } = this; + this.getRecordLs({ + page: ++page, + key: searchKey, + }) }, methods: { + searchConfirm(e){ + console.warn(e); + this.page = 1; + this.incomeLs = []; + this.getRecordLs({ + key: e.detail.value || '' + }) + }, + iptFocus(){ + this.isFocus = true; + }, + iptBlur(){ + this.isFocus = false; + }, getRecordLs({ brand_id = '', stadium_id = '', // 空字符全部 -1品牌收款 其他门店id @@ -47,7 +89,7 @@ export default { income_type = '', // 收款类型 online 线上收款 offline线下收款 joint联营 page = 1, page_size = 20, - order_no= '', + key= '', }){ util.showLoad(); server.get({ @@ -61,7 +103,7 @@ export default { scene, type, income_type, - order_no + key }, failMsg: '加载失败!', }) @@ -99,10 +141,15 @@ export default { font-size: 28upx; color: #1a1a1a; } - >image{ + >view{ flex-shrink: 0; width: 30upx; height: 30upx; + font-size: 0; + >image{ + width: 100%; + height: 100%; + } } .if-search-icon{ margin-right: 24upx;