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.
Files changed (52) hide show
  1. package/LICENSE +21 -0
  2. package/README.md +90 -0
  3. package/library/gulpfile.js/const.js +51 -0
  4. package/library/gulpfile.js/index.js +237 -0
  5. package/library/gulpfile.js/util.js +114 -0
  6. package/library/viewModules/config.js +75 -0
  7. package/library/viewModules/viewStat/router/supplierStat.js +33 -0
  8. package/library/viewModules/viewStat/schemas/supplier.stat.js +70 -0
  9. package/library/viewModules/viewStat/schemas.js +18 -0
  10. package/library/viewModules/viewStat/viewsStat/index/components/stat-all.vue +233 -0
  11. package/library/viewModules/viewStat/viewsStat/index/components/stat-product.vue +129 -0
  12. package/library/viewModules/viewStat/viewsStat/index/components/stat-supplier.vue +124 -0
  13. package/library/viewModules/viewStat/viewsStat/index/components/table-category.vue +309 -0
  14. package/library/viewModules/viewStat/viewsStat/index/components/table-product.vue +316 -0
  15. package/library/viewModules/viewStat/viewsStat/index/components/table-supplier.vue +276 -0
  16. package/library/viewModules/viewStat/viewsStat/index/index.vue +117 -0
  17. package/library/viewModules/viewTask/router/tasks.js +34 -0
  18. package/library/viewModules/viewTask/schemas/tasks.js +52 -0
  19. package/library/viewModules/viewTask/viewTask/list.vue +195 -0
  20. package/library/viewModules/viewsEnterpriseBuy/router/enterprise_buy.js +91 -0
  21. package/library/viewModules/viewsEnterpriseBuy/schemas/enterprise_buy.js +420 -0
  22. package/library/viewModules/viewsEnterpriseBuy/viewsEnterpriseBuy/compontents/OrderInfoButton.vue +550 -0
  23. package/library/viewModules/viewsEnterpriseBuy/viewsEnterpriseBuy/compontents/cardList.vue +119 -0
  24. package/library/viewModules/viewsEnterpriseBuy/viewsEnterpriseBuy/compontents/expressCopy.vue +259 -0
  25. package/library/viewModules/viewsEnterpriseBuy/viewsEnterpriseBuy/compontents/operateHistory.vue +164 -0
  26. package/library/viewModules/viewsEnterpriseBuy/viewsEnterpriseBuy/compontents/send_list.vue +395 -0
  27. package/library/viewModules/viewsEnterpriseBuy/viewsEnterpriseBuy/compontents/storeList.vue +100 -0
  28. package/library/viewModules/viewsEnterpriseBuy/viewsEnterpriseBuy/compontents/workHistory.vue +163 -0
  29. package/library/viewModules/viewsEnterpriseBuy/viewsEnterpriseBuy/detail.vue +503 -0
  30. package/library/viewModules/viewsEnterpriseBuy/viewsEnterpriseBuy/list.vue +635 -0
  31. package/library/viewModules/viewsEnterpriseBuy/viewsEnterpriseBuy/order_detail.vue +860 -0
  32. package/library/viewModules/viewsEnterpriseBuy/viewsEnterpriseBuy/set_create.vue +219 -0
  33. package/library/viewModules/viewsEnterpriseBuy/viewsEnterpriseBuy/set_list.vue +237 -0
  34. package/library/viewModules/viewsEnterpriseBuy/viewsEnterpriseBuy/table-card.vue +180 -0
  35. package/library/viewModules/viewsFinance/router/balance.js +75 -0
  36. package/library/viewModules/viewsFinance/router/finance.js +30 -0
  37. package/library/viewModules/viewsFinance/schemas/trade.record.js +153 -0
  38. package/library/viewModules/viewsFinance/schemas/wallet.js +116 -0
  39. package/library/viewModules/viewsFinance/viewsFinance/balance/components/listChannel.vue +220 -0
  40. package/library/viewModules/viewsFinance/viewsFinance/balance/components/listOpenapi.vue +260 -0
  41. package/library/viewModules/viewsFinance/viewsFinance/balance/components/listPartner.vue +217 -0
  42. package/library/viewModules/viewsFinance/viewsFinance/balance/components/listSupplier.vue +229 -0
  43. package/library/viewModules/viewsFinance/viewsFinance/balance/detail_channel.vue +401 -0
  44. package/library/viewModules/viewsFinance/viewsFinance/balance/detail_openapi.vue +364 -0
  45. package/library/viewModules/viewsFinance/viewsFinance/balance/detail_partner.vue +633 -0
  46. package/library/viewModules/viewsFinance/viewsFinance/balance/detail_supplier.vue +417 -0
  47. package/library/viewModules/viewsFinance/viewsFinance/balance/list.vue +75 -0
  48. package/library/viewModules/viewsFinance/viewsFinance/index.vue +191 -0
  49. package/library/viewModules/viewsLimit/router/buyLimit/buyLimit.js +31 -0
  50. package/library/viewModules/viewsLimit/schemas/buyLimit.js +22 -0
  51. package/library/viewModules/viewsLimit/viewsLimit/index.vue +211 -0
  52. package/package.json +114 -0
@@ -0,0 +1,31 @@
1
+ import Layout from '@/layout'
2
+ import roles from '@/constant/permissions' //引用权限值
3
+ const buyLimit = roles.buyLimit;
4
+
5
+ const buyLimitRouter = {
6
+ path: '/buy-limit',
7
+ component: Layout,
8
+ sort: 105,
9
+ name: '触发限购记录',
10
+ redirect: '/buy-limit/buy-limit',
11
+ meta: {
12
+ title: '触发限购记录',
13
+ icon: 'el-icon-document',
14
+ iconSize: 20,
15
+ },
16
+ children: [
17
+ {
18
+ path: 'buy-limit',
19
+ name: 'PageLimitIndex',
20
+ component: () => import('@/viewsLimit/index'),
21
+ meta: {
22
+ title: '触发限购记录',
23
+ icon: 'el-icon-document',
24
+ },
25
+ roles: [buyLimit.getLimitLogs]
26
+ },
27
+
28
+ ]
29
+ }
30
+
31
+ export default buyLimitRouter
@@ -0,0 +1,22 @@
1
+ 'use strict';
2
+ module.exports = {
3
+ "name": "buyLimit",
4
+ "title": "加盟商余额",
5
+ "vuex": true,
6
+ "model": [
7
+ {
8
+ "title": "限购风控记录",
9
+ "mapFn": "getLimitLogs",
10
+ "path": "/@@@@/v1/buylimit-triggered-log/query",
11
+ "isRule": false,
12
+ "params": {
13
+ "product_id": ["商品ID", "string|number", "可选"],
14
+ "product_name": ["商品名称", "string|number", "可选"],
15
+ "user_id": ["用户ID", "string", "可选"],
16
+ "user_phone": ["钱包唯一标识", "string", "必填"],
17
+ },
18
+ "disabled": true,
19
+ "role": "@@@@.BUY_LIMIT_LOGS_QUERY"
20
+ }
21
+ ]
22
+ }
@@ -0,0 +1,211 @@
1
+ <template>
2
+ <div class="app-container">
3
+ <el-card class="app-container__search">
4
+ <xd-search
5
+ time-type
6
+ date-filter
7
+ v-if="searchForm.length > 0"
8
+ v-model="searchParams"
9
+ :list="searchForm"
10
+ @onSearch="handleSearch"
11
+ @onDone="getList"
12
+ >
13
+ </xd-search>
14
+ </el-card>
15
+ <el-card class="app-container__list">
16
+ <div class="app-container__list-table">
17
+ <xd-table
18
+ :headers="headers"
19
+ :list="tables"
20
+ is-border
21
+ >
22
+ <template slot="product_info" slot-scope="scope">
23
+ <div>{{scope.row.product_id}}</div>
24
+ <div>{{scope.row.product_name}}</div>
25
+ </template>
26
+ <template slot="rule_desc" slot-scope="scope">
27
+ <div v-html="scope.row.rule_desc"></div>
28
+ </template>
29
+ </xd-table>
30
+ </div>
31
+ <div class="app-container__list-pagination">
32
+ <xd-pagination
33
+ :page="page_token"
34
+ :total="total"
35
+ :limit.sync="page_size"
36
+ :autoScroll="false"
37
+ @onPagination="handlePagination"
38
+ ></xd-pagination>
39
+ </div>
40
+ </el-card>
41
+ </div>
42
+ </template>
43
+
44
+
45
+ <script>
46
+ import XdSearch from "@/components/XdSearch";
47
+ import XdPagination from "@/components/XdPagination.vue";
48
+ import XdTable from "@/components/XdTable";
49
+ import { mapActions } from "vuex"
50
+ import { getOptions } from "@/utils/options"
51
+ import { baseJsDateToTime } from "@/utils/xd.base.js"
52
+
53
+ export default {
54
+ name: "PageListPartner",
55
+ components: {
56
+ XdPagination, //翻译插件
57
+ XdSearch, //搜查插件
58
+ XdTable
59
+ },
60
+ data() {
61
+ return {
62
+
63
+ //分页参数
64
+ page_token: 1, //当前页面数量
65
+ hasNextPage: true, //是否有下一页
66
+ page_size: 20, //搜索参数
67
+ searchForm: [], //搜索区域模块表单
68
+ searchParams: null, //搜索参数
69
+ total: 0,
70
+ categoryList: [],
71
+
72
+ //列表对象
73
+ tables: [],
74
+ headers: [
75
+ { "type": "normal", "prop": "list_id", "align": "center", "label": "ID" },
76
+ { "type": "normal", "prop": "user_id", "align": "center", "label": "用户ID" },
77
+ { "type": "normal", "prop": "user_phone", "align": "center", "label": "手机号" },
78
+ { "type": "normal", "prop": "product_info", "align": "center", "label": "商品ID&商品名称" },
79
+ { "type": "normal", "prop": "site_name", "align": "center", "label": "站点" },
80
+ { "type": "normal", "prop": "business_name", "align": "center", "label": "业务线" },
81
+ { "type": "normal", "prop": "rule_desc", "align": "left", "label": "触发限购内容" },
82
+ { "type": "normal", "prop": "day_triggered_count", "align": "center", "label": "日/次" },
83
+ { "type": "normal", "prop": "updated_time", "align": "center", "minWidth": 200, "label": "触发时间" },
84
+ ],
85
+ }
86
+ },
87
+ created() {
88
+ getOptions({
89
+ server: 'partner',
90
+ fn: 'business-line',
91
+ path: 'p1',
92
+ }).then(res=>{
93
+ this.initSearchForm(res);
94
+ }).catch(error=>{
95
+ this.$xdLog.catch(error)
96
+ });
97
+
98
+ this.getList();
99
+ },
100
+ methods: {
101
+ ...mapActions("buyLimit", ["getLimitLogs"]),
102
+
103
+ //相除
104
+ divide(price) {
105
+ return this.$xdHelper.divisionFloatNumber(price, 100);
106
+ },
107
+ /**
108
+ * @description 获取数据列表
109
+ */
110
+ getList() {
111
+ //请求数据
112
+ let params = {
113
+ ...this.searchParams,
114
+ page_token: this.page_token,
115
+ page_size: this.page_size
116
+ };
117
+ console.log(params)
118
+ let loading = this.$loading({});
119
+ this.getLimitLogs(params).then(res => {
120
+ loading.close();
121
+ this.tables = res.data.list.map(item => {
122
+ item['updated_time'] = item['updated_time'] ? baseJsDateToTime(item['updated_time']) : "";
123
+ item['day_triggered_count'] = `${item.day_triggered_count}次`
124
+ return item;
125
+ });
126
+ this.total = res.data.total;
127
+ }).catch(err => {
128
+ loading.close();
129
+ })
130
+ },
131
+
132
+
133
+ /**
134
+ * @description 点击搜索进行搜索操作
135
+ * @param action 动作
136
+ * @param form 搜索请求参数
137
+ */
138
+ handleSearch({ action, form }) {
139
+ this.page_token = 1;
140
+ this.getList();
141
+ },
142
+ /**
143
+ * @description 初始化搜索模块
144
+ */
145
+ initSearchForm(res) {
146
+ this.searchForm = [
147
+ {
148
+ label: "商品ID",
149
+ ele: "el-input",
150
+ valueKey: "product_id",
151
+ value: "",
152
+ placeholder: "请输入商品ID"
153
+ },
154
+ {
155
+ label: "商品名称",
156
+ ele: "el-input",
157
+ valueKey: "product_name",
158
+ value: "",
159
+ placeholder: "请输入商品名称"
160
+ },
161
+ {
162
+ label: "用户ID",
163
+ ele: "el-input",
164
+ valueKey: "user_id",
165
+ value: "",
166
+ placeholder: "请输入分类ID"
167
+ },
168
+ {
169
+ label: "手机号",
170
+ ele: "el-input",
171
+ valueKey: "user_phone",
172
+ value: "",
173
+ placeholder: "请输入用户手机号"
174
+ },
175
+ {
176
+ label: '业务线:', //label
177
+ ele: 'xd-select-list', //package 名称
178
+ valueKey: 'business_code', //form[valueKey]
179
+ value: [], //v-model
180
+ placeholder: '请选择业务线',
181
+ multiple: false, //多选
182
+ list: res['data']['list']
183
+ },
184
+ {
185
+ label: '触发时间:', //label
186
+ ele: 'xd-date', //package 名称
187
+ valueKey: ['start_time', 'end_time'], //form[valueKey]
188
+ value: [], //v-model
189
+ format: 'yyyy/MM/dd HH:mm:ss',//时间显示格式
190
+ formatValue: 'timestamp', //输出时间格式
191
+ placeholder: ['开始时间', '结束时间'],
192
+ },
193
+
194
+ ];
195
+ },
196
+ /**
197
+ * @description 翻页处理方法
198
+ * @param page {Number} 访问页面页码数
199
+ */
200
+ handlePagination(page) {
201
+ this.page_token = page;
202
+ this.getList();
203
+ }, //todo
204
+ }
205
+ }
206
+ </script>
207
+
208
+ <style scoped lang="scss">
209
+
210
+ </style>
211
+
package/package.json ADDED
@@ -0,0 +1,114 @@
1
+ {
2
+ "name": "jufubao-admin-library",
3
+ "version": "1.0.0-beta1",
4
+ "description": "A vue admin template with Element UI & axios & iconfont & permission control & lint",
5
+ "author": "goashiyong <gaoshiyong1272@vip.163.com>",
6
+ "scripts": {
7
+ "serve": "cross-env type=test cover=true service=serve npm run entry",
8
+ "serve.domain": "cross-env type=test cover=true service=serve domain=http://sandbox-editx.jufubao.cn npm run entry",
9
+ "dev": "cross-env type=dev cover=true service=build npm run entry",
10
+ "test": "cross-env type=test cover=true service=build npm run entry",
11
+ "build": "cross-env type=build cover=true service=build npm run entry",
12
+ "update": " node ./update.command.js false",
13
+ "update.local": " node ./update.command.js true",
14
+ "entry": "node ./build/commands/entry.init.js",
15
+ "app": "node ./build/commands/appcss.js",
16
+ "coder": "node ./build/commands/coder.js",
17
+ "coder:check": "node ./build/commands/coder.check.js",
18
+ "coder:page": "node ./build/commands/coder.page.js",
19
+ "coder:router": "node ./build/commands/coder.router.js",
20
+ "oss": "cross-env bucket=xxxx region=oss-cn-beijing name=xxx node ./build/commands/oss.js",
21
+ "oss.dev": "cross-env bucket=xxxx region=oss-cn-qingdao name=xxx(开发) node ./build/commands/oss.js",
22
+ "oss.test": "cross-env bucket=xxxx region=oss-cn-qingdao name=xxx(测试) node ./build/commands/oss.js",
23
+ "gao": "cross-env status=test node ./build/commands/copy.init.js"
24
+ },
25
+ "dependencies": {
26
+ "alife-logger": "1.8.30",
27
+ "axios": "0.18.1",
28
+ "core-js": "3.6.5",
29
+ "echarts": "^4.2.1",
30
+ "element-ui": "2.13.2",
31
+ "gxd-file-preview": "1.2.1",
32
+ "gxd-helper": "2.0.21",
33
+ "gxd-vue-library": "1.1.65",
34
+ "js-base64": "^3.4.5",
35
+ "js-cookie": "2.2.0",
36
+ "md5": "^2.3.0",
37
+ "md5.js": "^1.3.5",
38
+ "moment": "^2.27.0",
39
+ "normalize.css": "7.0.0",
40
+ "nprogress": "0.2.0",
41
+ "path-to-regexp": "2.4.0",
42
+ "qs": "^6.9.6",
43
+ "screenfull": "^5.1.0",
44
+ "vue": "2.6.10",
45
+ "vue-clipboard2": "^0.3.1",
46
+ "vue-router": "3.0.6",
47
+ "vuex": "3.1.0",
48
+ "color": "4.2.3",
49
+ "downloadjs": "^1.4.7",
50
+ "js-beautify": "^1.14.0",
51
+ "vue-codemirror": "4.0.6",
52
+ "qrcode": "1.5.3",
53
+ "jsbarcode": "^3.11.5",
54
+ "html2canvas": "1.4.1"
55
+ },
56
+ "devDependencies": {
57
+ "babel-polyfill": "^6.26.0",
58
+ "@vue/cli-plugin-babel": "4.4.4",
59
+ "@vue/cli-plugin-eslint": "4.4.4",
60
+ "@vue/cli-plugin-unit-jest": "4.4.4",
61
+ "@vue/cli-service": "4.4.4",
62
+ "@vue/test-utils": "1.0.0-beta.29",
63
+ "autoprefixer": "9.5.1",
64
+ "babel-eslint": "10.1.0",
65
+ "babel-jest": "23.6.0",
66
+ "babel-plugin-dynamic-import-node": "2.3.3",
67
+ "chalk": "2.4.2",
68
+ "connect": "3.6.6",
69
+ "eslint": "6.7.2",
70
+ "eslint-plugin-vue": "6.2.2",
71
+ "html-webpack-plugin": "3.2.0",
72
+ "mockjs": "1.0.1-beta3",
73
+ "runjs": "4.3.2",
74
+ "sass": "1.26.8",
75
+ "sass-loader": "8.0.2",
76
+ "script-ext-html-webpack-plugin": "2.1.3",
77
+ "serve-static": "1.13.2",
78
+ "svg-sprite-loader": "4.1.3",
79
+ "svgo": "1.2.2",
80
+ "vue-template-compiler": "2.6.10",
81
+ "less": "^3.12.2",
82
+ "less-loader": "^7.0.1",
83
+ "mini-css-extract-plugin": "^0.8.2",
84
+ "sass-resources-loader": "^2.1.1",
85
+ "uglifyjs-webpack-plugin": "^1.1.1",
86
+ "require-context": "^1.1.0",
87
+ "mini-types": "*",
88
+ "miniprogram-api-typings": "*",
89
+ "cross-env": "^7.0.2",
90
+ "progress": "^2.0.3",
91
+ "ali-oss": "^6.16.0",
92
+ "ejs": "^3.1.6",
93
+ "js-beautify": "^1.14.0",
94
+ "art-template": "^4.13.2",
95
+ "copy-dir": "^1.3.0",
96
+ "md5": "^2.3.0",
97
+ "webpack": "4.46.0",
98
+ "compressing": "1.10.0",
99
+ "gulp": "^4.0.2",
100
+ "gulp-rename": "^2.0.0",
101
+ "gulp-replace": "^1.1.4",
102
+ "require-from-string": "^2.0.2",
103
+ "through2": "^4.0.2"
104
+ },
105
+ "browserslist": [
106
+ "> 1%",
107
+ "last 2 versions"
108
+ ],
109
+ "engines": {
110
+ "node": ">=8.9",
111
+ "npm": ">= 3.0.0"
112
+ },
113
+ "license": "MIT"
114
+ }