jufubao-admin-library 1.0.0-beta1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/LICENSE +21 -0
- package/README.md +90 -0
- package/library/gulpfile.js/const.js +51 -0
- package/library/gulpfile.js/index.js +237 -0
- package/library/gulpfile.js/util.js +114 -0
- package/library/viewModules/config.js +75 -0
- package/library/viewModules/viewStat/router/supplierStat.js +33 -0
- package/library/viewModules/viewStat/schemas/supplier.stat.js +70 -0
- package/library/viewModules/viewStat/schemas.js +18 -0
- package/library/viewModules/viewStat/viewsStat/index/components/stat-all.vue +233 -0
- package/library/viewModules/viewStat/viewsStat/index/components/stat-product.vue +129 -0
- package/library/viewModules/viewStat/viewsStat/index/components/stat-supplier.vue +124 -0
- package/library/viewModules/viewStat/viewsStat/index/components/table-category.vue +309 -0
- package/library/viewModules/viewStat/viewsStat/index/components/table-product.vue +316 -0
- package/library/viewModules/viewStat/viewsStat/index/components/table-supplier.vue +276 -0
- package/library/viewModules/viewStat/viewsStat/index/index.vue +117 -0
- package/library/viewModules/viewTask/router/tasks.js +34 -0
- package/library/viewModules/viewTask/schemas/tasks.js +52 -0
- package/library/viewModules/viewTask/viewTask/list.vue +195 -0
- package/library/viewModules/viewsEnterpriseBuy/router/enterprise_buy.js +91 -0
- package/library/viewModules/viewsEnterpriseBuy/schemas/enterprise_buy.js +420 -0
- package/library/viewModules/viewsEnterpriseBuy/viewsEnterpriseBuy/compontents/OrderInfoButton.vue +550 -0
- package/library/viewModules/viewsEnterpriseBuy/viewsEnterpriseBuy/compontents/cardList.vue +119 -0
- package/library/viewModules/viewsEnterpriseBuy/viewsEnterpriseBuy/compontents/expressCopy.vue +259 -0
- package/library/viewModules/viewsEnterpriseBuy/viewsEnterpriseBuy/compontents/operateHistory.vue +164 -0
- package/library/viewModules/viewsEnterpriseBuy/viewsEnterpriseBuy/compontents/send_list.vue +395 -0
- package/library/viewModules/viewsEnterpriseBuy/viewsEnterpriseBuy/compontents/storeList.vue +100 -0
- package/library/viewModules/viewsEnterpriseBuy/viewsEnterpriseBuy/compontents/workHistory.vue +163 -0
- package/library/viewModules/viewsEnterpriseBuy/viewsEnterpriseBuy/detail.vue +503 -0
- package/library/viewModules/viewsEnterpriseBuy/viewsEnterpriseBuy/list.vue +635 -0
- package/library/viewModules/viewsEnterpriseBuy/viewsEnterpriseBuy/order_detail.vue +860 -0
- package/library/viewModules/viewsEnterpriseBuy/viewsEnterpriseBuy/set_create.vue +219 -0
- package/library/viewModules/viewsEnterpriseBuy/viewsEnterpriseBuy/set_list.vue +237 -0
- package/library/viewModules/viewsEnterpriseBuy/viewsEnterpriseBuy/table-card.vue +180 -0
- package/library/viewModules/viewsFinance/router/balance.js +75 -0
- package/library/viewModules/viewsFinance/router/finance.js +30 -0
- package/library/viewModules/viewsFinance/schemas/trade.record.js +153 -0
- package/library/viewModules/viewsFinance/schemas/wallet.js +116 -0
- package/library/viewModules/viewsFinance/viewsFinance/balance/components/listChannel.vue +220 -0
- package/library/viewModules/viewsFinance/viewsFinance/balance/components/listOpenapi.vue +260 -0
- package/library/viewModules/viewsFinance/viewsFinance/balance/components/listPartner.vue +217 -0
- package/library/viewModules/viewsFinance/viewsFinance/balance/components/listSupplier.vue +229 -0
- package/library/viewModules/viewsFinance/viewsFinance/balance/detail_channel.vue +401 -0
- package/library/viewModules/viewsFinance/viewsFinance/balance/detail_openapi.vue +364 -0
- package/library/viewModules/viewsFinance/viewsFinance/balance/detail_partner.vue +633 -0
- package/library/viewModules/viewsFinance/viewsFinance/balance/detail_supplier.vue +417 -0
- package/library/viewModules/viewsFinance/viewsFinance/balance/list.vue +75 -0
- package/library/viewModules/viewsFinance/viewsFinance/index.vue +191 -0
- package/library/viewModules/viewsLimit/router/buyLimit/buyLimit.js +31 -0
- package/library/viewModules/viewsLimit/schemas/buyLimit.js +22 -0
- package/library/viewModules/viewsLimit/viewsLimit/index.vue +211 -0
- package/package.json +114 -0
|
@@ -0,0 +1,364 @@
|
|
|
1
|
+
<template>
|
|
2
|
+
<div class="app-container">
|
|
3
|
+
<el-card class="app-container__search">
|
|
4
|
+
<div slot="header" class="flex list_header">
|
|
5
|
+
<div>openAPI明细对账</div>
|
|
6
|
+
<div class="flex total_wrap">
|
|
7
|
+
<p class="amount_wrap">
|
|
8
|
+
<span class="amount_label">接口余额:</span>{{divide(totalData.channel_amount)}}元
|
|
9
|
+
<span class="amount_label">平台余额:</span>{{divide(totalData.total_amount)}}元
|
|
10
|
+
</p>
|
|
11
|
+
</div>
|
|
12
|
+
</div>
|
|
13
|
+
<xd-search
|
|
14
|
+
dateFilter
|
|
15
|
+
timeType
|
|
16
|
+
v-if="searchForm.length > 0"
|
|
17
|
+
v-model="searchParams"
|
|
18
|
+
:list="searchForm"
|
|
19
|
+
@onSearch="handleSearch"
|
|
20
|
+
@onDone="getList"
|
|
21
|
+
>
|
|
22
|
+
</xd-search>
|
|
23
|
+
</el-card>
|
|
24
|
+
<el-card class="app-container__list">
|
|
25
|
+
<div class="app-container__list-pagination">
|
|
26
|
+
<div></div>
|
|
27
|
+
<div class="table-stat">
|
|
28
|
+
<p>
|
|
29
|
+
总充值:<span class="_mo">{{divide(totalData.total_recharge_amount)}}元</span>
|
|
30
|
+
提现总额:<span class="_mo">{{divide(totalData.total_withdrawal_amount)}}元</span>
|
|
31
|
+
矫正金额:<span class="_mo">{{divide(totalData.correct_amount)}}元</span>
|
|
32
|
+
总收入:<span class="_mo">{{divide(totalData.total_income_amount)}}元</span>
|
|
33
|
+
总消费:<span class="_mo">{{divide(totalData.total_consume_amount)}}元</span>
|
|
34
|
+
总退款:<span class="_mo">{{divide(totalData.total_refund_amount)}}元</span>
|
|
35
|
+
结余:<span class="_mo">{{divide(totalData.cash_amount)}}元</span>
|
|
36
|
+
实际结算:<span class="_mo">{{ divide(totalData.settlement_amount) }}元</span>
|
|
37
|
+
</p>
|
|
38
|
+
<el-button type="primary" @click="doExport">导出</el-button>
|
|
39
|
+
</div>
|
|
40
|
+
</div>
|
|
41
|
+
<div class="app-container__list-table">
|
|
42
|
+
<xd-table
|
|
43
|
+
:headers="headers"
|
|
44
|
+
:list="tables"
|
|
45
|
+
is-border
|
|
46
|
+
>
|
|
47
|
+
<template slot="address" slot-scope="scope">
|
|
48
|
+
<p style="text-align: left;">姓名:{{ scope.row.receipt_username }}</p>
|
|
49
|
+
<p style="text-align: left;">收货地址:{{ scope.row.receipt_address_detail }}</p>
|
|
50
|
+
</template>
|
|
51
|
+
<template slot="products" slot-scope="scope">
|
|
52
|
+
<div class="table-product" v-for="(prod, i) in scope.row.product_list" :key="i">
|
|
53
|
+
<div class="table-product__img">
|
|
54
|
+
<img :src="prod.product_thumb" alt="">
|
|
55
|
+
</div>
|
|
56
|
+
<div class="table-product__name">
|
|
57
|
+
<p>{{ prod.product_name}}</p>
|
|
58
|
+
</div>
|
|
59
|
+
<div class="table-product__id">
|
|
60
|
+
<p>{{ prod.product_id}}</p>
|
|
61
|
+
</div>
|
|
62
|
+
</div>
|
|
63
|
+
</template>
|
|
64
|
+
<template slot="num" slot-scope="scope">
|
|
65
|
+
<div v-for="(prod, i) in scope.row.product_list" :key="i">
|
|
66
|
+
<div>
|
|
67
|
+
金额: <span>{{ divide(prod.dist_price)}}</span>
|
|
68
|
+
</div>
|
|
69
|
+
<div>
|
|
70
|
+
数量: <span>{{ prod.product_num}}</span>
|
|
71
|
+
</div>
|
|
72
|
+
</div>
|
|
73
|
+
</template>
|
|
74
|
+
</xd-table>
|
|
75
|
+
</div>
|
|
76
|
+
<div class="app-container__list-pagination">
|
|
77
|
+
<xd-pagination
|
|
78
|
+
:page="page_token"
|
|
79
|
+
:total="total"
|
|
80
|
+
:limit.sync="page_size"
|
|
81
|
+
:autoScroll="false"
|
|
82
|
+
@onPagination="handlePagination"
|
|
83
|
+
></xd-pagination>
|
|
84
|
+
</div>
|
|
85
|
+
</el-card>
|
|
86
|
+
<xd-dialog @onConfirm="handleExport" :show.sync="showExport" width="350px" title="导出文件名称">
|
|
87
|
+
<el-input maxlength="20" v-model="exportName" placeholder=""></el-input>
|
|
88
|
+
</xd-dialog>
|
|
89
|
+
</div>
|
|
90
|
+
</template>
|
|
91
|
+
|
|
92
|
+
|
|
93
|
+
<script>
|
|
94
|
+
import XdSearch from "@/components/XdSearch";
|
|
95
|
+
import XdPagination from "@/components/XdPagination.vue";
|
|
96
|
+
import XdTable from "@/components/XdTable";
|
|
97
|
+
import { mapActions } from "vuex"
|
|
98
|
+
import { getOptions } from "@/utils/options"
|
|
99
|
+
import XdDialog from "@/components/XdDialog"
|
|
100
|
+
import { baseJsDateToTime } from "@/utils/xd.base.js"
|
|
101
|
+
import checkPermission from "@/utils/permission"
|
|
102
|
+
import roleTRecord from "@/constant/modules/tradeRecord.js"
|
|
103
|
+
import roleWallet from "@/constant/modules/wallet.js"
|
|
104
|
+
|
|
105
|
+
export default {
|
|
106
|
+
name: "PageChannelDetail",
|
|
107
|
+
components: {
|
|
108
|
+
XdPagination, //翻译插件
|
|
109
|
+
XdSearch, //搜查插件
|
|
110
|
+
XdTable,
|
|
111
|
+
XdDialog
|
|
112
|
+
},
|
|
113
|
+
data() {
|
|
114
|
+
return {
|
|
115
|
+
roleWallet,
|
|
116
|
+
|
|
117
|
+
//分页参数
|
|
118
|
+
page_token: 1, //当前页面数量
|
|
119
|
+
hasNextPage: true, //是否有下一页
|
|
120
|
+
page_size: 20, //搜索参数
|
|
121
|
+
searchForm: [], //搜索区域模块表单
|
|
122
|
+
searchParams: null, //搜索参数
|
|
123
|
+
totalData: {},
|
|
124
|
+
total: 0,
|
|
125
|
+
|
|
126
|
+
//列表对象
|
|
127
|
+
tables: [],
|
|
128
|
+
headers: [
|
|
129
|
+
{ "type": "normal", "prop": "main_order_id", "align": "center", "width": 200, "label": "主单号" },
|
|
130
|
+
{ "type": "normal", "prop": "sub_order_id", "align": "center", "minWidth": 200, "label": "拆单号" },
|
|
131
|
+
{ "type": "normal", "prop": "address", "align": "center", "minWidth": 200, "label": "收货信息" },
|
|
132
|
+
{ "type": "normal", "prop": "products", "align": "center", "minWidth": 300, "label": "商品图片/名称/ID" },
|
|
133
|
+
{ "type": "normal", "prop": "num", "align": "center", "minWidth": 300, "label": "金额&数量" },
|
|
134
|
+
{ "type": "price", "prop": "amount", "align": "center", "width": 100, "label": "总价", "unit": "元"},
|
|
135
|
+
{ "type": "normal", "prop": "created_time", "align": "center", "minWidth": 200, "label": "下单时间" },
|
|
136
|
+
{ "type": "normal", "prop": "receipt_send_time", "align": "center", "minWidth": 200, "label": "发货时间" },
|
|
137
|
+
{ "type": "normal", "prop": "order_partner_name", "align": "center", "minWidth": 200, "label": "加盟商" },
|
|
138
|
+
{ "type": "normal", "prop": "operate_type_name", "align": "center", "minWidth": 200, "label": "资金方向" },
|
|
139
|
+
{ "type": "normal", "prop": "invoice_name", "align": "center", "minWidth": 200, "label": "发票名称" },
|
|
140
|
+
{ "type": "normal", "prop": "comment", "align": "center", "minWidth": 200, "label": "备注" },
|
|
141
|
+
],
|
|
142
|
+
showExport: false,
|
|
143
|
+
exportName: 'openAPI明细对账'
|
|
144
|
+
}
|
|
145
|
+
},
|
|
146
|
+
computed: {
|
|
147
|
+
channel_code(){
|
|
148
|
+
return this.$route.query.channel_code;
|
|
149
|
+
},
|
|
150
|
+
open_user_id(){
|
|
151
|
+
return this.$route.params.id;
|
|
152
|
+
},
|
|
153
|
+
open_user_name(){
|
|
154
|
+
return this.$route.query.open_user_name;
|
|
155
|
+
},
|
|
156
|
+
wallet_type(){
|
|
157
|
+
return this.$route.query.wallet_type;
|
|
158
|
+
},
|
|
159
|
+
wallet_nnid(){
|
|
160
|
+
return this.$route.query.wallet_nnid;
|
|
161
|
+
},
|
|
162
|
+
},
|
|
163
|
+
created() {
|
|
164
|
+
this.initSearchForm();
|
|
165
|
+
},
|
|
166
|
+
methods: {
|
|
167
|
+
...mapActions("tradeRecord", ["countOpenApi", "listOpenApi"]),
|
|
168
|
+
//相除
|
|
169
|
+
divide(price) {
|
|
170
|
+
return this.$xdHelper.divisionFloatNumber(price, 100);
|
|
171
|
+
},
|
|
172
|
+
getParams(){
|
|
173
|
+
return {
|
|
174
|
+
...this.searchParams,
|
|
175
|
+
channel_code: this.channel_code,
|
|
176
|
+
open_user_id: this.open_user_id,
|
|
177
|
+
wallet_type: this.wallet_type,
|
|
178
|
+
}
|
|
179
|
+
},
|
|
180
|
+
doExport(){
|
|
181
|
+
this.exportName= 'openAPI明细对账'
|
|
182
|
+
this.showExport = true
|
|
183
|
+
},
|
|
184
|
+
handleExport() {
|
|
185
|
+
if(!this.exportName) {
|
|
186
|
+
this.$message.error('请输入导出名称');
|
|
187
|
+
return
|
|
188
|
+
}
|
|
189
|
+
let other = this.getParams();
|
|
190
|
+
let params = {
|
|
191
|
+
...other,
|
|
192
|
+
export: true,
|
|
193
|
+
file_ext: "xlsx",
|
|
194
|
+
file_name: this.exportName,
|
|
195
|
+
export_data_tag: "ExportSupplierTradeRecordList"
|
|
196
|
+
};
|
|
197
|
+
let loading = this.$loading({});
|
|
198
|
+
this.listOpenApi(params).then(res => {
|
|
199
|
+
loading.close();
|
|
200
|
+
this.showExport=false;
|
|
201
|
+
this.$alert('导出任务已经开始执行,请去任务管理查看下载状态', '提示', {
|
|
202
|
+
confirmButtonText: '确定',
|
|
203
|
+
});
|
|
204
|
+
}).catch(err => {
|
|
205
|
+
this.$message.error(err.msg);
|
|
206
|
+
loading.close();
|
|
207
|
+
})
|
|
208
|
+
},
|
|
209
|
+
/**
|
|
210
|
+
* @description 获取数据列表
|
|
211
|
+
*/
|
|
212
|
+
getList() {
|
|
213
|
+
//请求数据
|
|
214
|
+
let other = this.getParams();
|
|
215
|
+
let params = {
|
|
216
|
+
...other,
|
|
217
|
+
page_token: this.page_token,
|
|
218
|
+
page_size: this.page_size
|
|
219
|
+
};
|
|
220
|
+
console.log(params)
|
|
221
|
+
let loading = this.$loading({});
|
|
222
|
+
Promise.all([
|
|
223
|
+
this.listOpenApi(params),
|
|
224
|
+
this.countOpenApi(params)
|
|
225
|
+
]).then(([res, res1]) => {
|
|
226
|
+
loading.close();
|
|
227
|
+
this.tables = res.data.list.map(item => {
|
|
228
|
+
item['created_time'] = baseJsDateToTime(item['created_time']);
|
|
229
|
+
item['receipt_send_time'] = item['receipt_send_time']?baseJsDateToTime(item['receipt_send_time']): ''
|
|
230
|
+
item['product_list'] = item['product_list'].map(prod => {
|
|
231
|
+
prod['product_thumb'] = this.getImageFullPath(prod['product_thumb'])
|
|
232
|
+
return prod;
|
|
233
|
+
})
|
|
234
|
+
return item;
|
|
235
|
+
});
|
|
236
|
+
this.total = res.data.total_size;
|
|
237
|
+
this.totalData = res1.data;
|
|
238
|
+
})
|
|
239
|
+
.catch(err => {
|
|
240
|
+
loading.close();
|
|
241
|
+
})
|
|
242
|
+
},
|
|
243
|
+
|
|
244
|
+
/**
|
|
245
|
+
* @description 点击搜索进行搜索操作
|
|
246
|
+
* @param action 动作
|
|
247
|
+
* @param form 搜索请求参数
|
|
248
|
+
*/
|
|
249
|
+
handleSearch({ action, form }) {
|
|
250
|
+
this.page_token = 1;
|
|
251
|
+
this.getList();
|
|
252
|
+
},
|
|
253
|
+
/**
|
|
254
|
+
* @description 初始化搜索模块
|
|
255
|
+
*/
|
|
256
|
+
initSearchForm() {
|
|
257
|
+
this.searchForm = [
|
|
258
|
+
{
|
|
259
|
+
label: "渠道",
|
|
260
|
+
ele: "el-input",
|
|
261
|
+
valueKey: "open_user_name",
|
|
262
|
+
value: this.open_user_name,
|
|
263
|
+
placeholder: "请输入名称",
|
|
264
|
+
disabled: true,
|
|
265
|
+
},
|
|
266
|
+
{
|
|
267
|
+
label: "主单号",
|
|
268
|
+
ele: "el-input",
|
|
269
|
+
valueKey: "main_order_id",
|
|
270
|
+
value: "",
|
|
271
|
+
placeholder: "请输入主单号",
|
|
272
|
+
},
|
|
273
|
+
{
|
|
274
|
+
label: "资金方向",
|
|
275
|
+
ele: "xd-select-list",
|
|
276
|
+
valueKey: "operate_type",
|
|
277
|
+
value: "",
|
|
278
|
+
placeholder: "请输入渠道ID",
|
|
279
|
+
list: [
|
|
280
|
+
{ label: "全部", value: "" },
|
|
281
|
+
{ label: "支出", value: "R" },
|
|
282
|
+
{ label: "收入", value: "A" },
|
|
283
|
+
]
|
|
284
|
+
},
|
|
285
|
+
{
|
|
286
|
+
label: '时间:', //label
|
|
287
|
+
ele: 'xd-date', //package 名称
|
|
288
|
+
valueKey: ['start_time', 'end_time'], //form[valueKey]
|
|
289
|
+
value: [], //v-model
|
|
290
|
+
format: 'yyyy-MM-dd HH:mm:ss', //时间显示格式
|
|
291
|
+
formatValue: 'timestamp', //输出时间格式
|
|
292
|
+
placeholder: ['开始时间', '结束时间'],
|
|
293
|
+
},
|
|
294
|
+
];
|
|
295
|
+
},
|
|
296
|
+
/**
|
|
297
|
+
* @description 翻页处理方法
|
|
298
|
+
* @param page {Number} 访问页面页码数
|
|
299
|
+
*/
|
|
300
|
+
handlePagination(page) {
|
|
301
|
+
this.page_token = page;
|
|
302
|
+
this.getList();
|
|
303
|
+
}, //todo
|
|
304
|
+
}
|
|
305
|
+
}
|
|
306
|
+
</script>
|
|
307
|
+
|
|
308
|
+
<style scoped lang="scss">
|
|
309
|
+
.list_header{
|
|
310
|
+
.total_wrap{
|
|
311
|
+
font-size: 13px;
|
|
312
|
+
margin-left: 30px;
|
|
313
|
+
}
|
|
314
|
+
.amount_wrap{
|
|
315
|
+
margin-right: 20px;
|
|
316
|
+
.amount_label{
|
|
317
|
+
font-size: 14px;
|
|
318
|
+
font-weight: 500;
|
|
319
|
+
}
|
|
320
|
+
}
|
|
321
|
+
}
|
|
322
|
+
.table-stat{
|
|
323
|
+
display: flex;
|
|
324
|
+
justify-content: space-between;
|
|
325
|
+
align-items: center;
|
|
326
|
+
p{
|
|
327
|
+
margin: 0;
|
|
328
|
+
font-weight: 500;
|
|
329
|
+
font-size: 14px;
|
|
330
|
+
._mo{
|
|
331
|
+
font-weight: 400;
|
|
332
|
+
margin-right: 20px;
|
|
333
|
+
font-size: 12px;
|
|
334
|
+
}
|
|
335
|
+
}
|
|
336
|
+
}
|
|
337
|
+
.flex{
|
|
338
|
+
display: flex;
|
|
339
|
+
align-items: center;
|
|
340
|
+
}
|
|
341
|
+
.table-product{
|
|
342
|
+
display: flex;
|
|
343
|
+
align-items: center;
|
|
344
|
+
.table-product__img{
|
|
345
|
+
width: 50px;
|
|
346
|
+
height: 50px;
|
|
347
|
+
img{
|
|
348
|
+
width: 100%;
|
|
349
|
+
height: 100%;
|
|
350
|
+
}
|
|
351
|
+
}
|
|
352
|
+
.table-product__id,
|
|
353
|
+
.table-product__name{
|
|
354
|
+
width: 100px;
|
|
355
|
+
p{
|
|
356
|
+
width: 100%;
|
|
357
|
+
overflow: hidden;
|
|
358
|
+
text-overflow: ellipsis;
|
|
359
|
+
white-space: nowrap;
|
|
360
|
+
}
|
|
361
|
+
}
|
|
362
|
+
}
|
|
363
|
+
</style>
|
|
364
|
+
|