jufubao-base 1.0.221 → 1.0.222-beta2

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 (35) hide show
  1. package/package.json +1 -1
  2. package/src/components/JfbBaseAfterOrderList/Attr.js +13 -0
  3. package/src/components/JfbBaseAfterOrderList/JfbBaseAfterOrderList.vue +33 -1
  4. package/src/components/JfbBaseAfterSales/Api.js +58 -0
  5. package/src/components/JfbBaseAfterSales/Attr.js +25 -0
  6. package/src/components/JfbBaseAfterSales/JfbBaseAfterSales.vue +505 -0
  7. package/src/components/JfbBaseAfterSales/JfbBaseAfterSalesLess.less +79 -0
  8. package/src/components/JfbBaseAfterSales/JfbBaseAfterSalesMixin.js +30 -0
  9. package/src/components/JfbBaseAfterSales/Mock.js +13 -0
  10. package/src/components/JfbBaseAfterSales/refundOrderInfo.vue +96 -0
  11. package/src/components/JfbBaseAfterSalesDetail/Api.js +41 -0
  12. package/src/components/JfbBaseAfterSalesDetail/Attr.js +14 -0
  13. package/src/components/JfbBaseAfterSalesDetail/JfbBaseAfterSalesDetail.vue +518 -0
  14. package/src/components/JfbBaseAfterSalesDetail/JfbBaseAfterSalesDetailLess.less +79 -0
  15. package/src/components/JfbBaseAfterSalesDetail/JfbBaseAfterSalesDetailMixin.js +30 -0
  16. package/src/components/JfbBaseAfterSalesDetail/Mock.js +13 -0
  17. package/src/components/JfbBaseAfterSalesDetail/secProd.vue +54 -0
  18. package/src/components/JfbBaseAfterSalesFast/Api.js +30 -0
  19. package/src/components/JfbBaseAfterSalesFast/Attr.js +32 -0
  20. package/src/components/JfbBaseAfterSalesFast/JfbBaseAfterSalesFast.vue +273 -0
  21. package/src/components/JfbBaseAfterSalesFast/JfbBaseAfterSalesFastLess.less +79 -0
  22. package/src/components/JfbBaseAfterSalesFast/JfbBaseAfterSalesFastMixin.js +30 -0
  23. package/src/components/JfbBaseAfterSalesFast/Mock.js +13 -0
  24. package/src/components/JfbBaseAfterSalesList/Api.js +18 -0
  25. package/src/components/JfbBaseAfterSalesList/Attr.js +48 -0
  26. package/src/components/JfbBaseAfterSalesList/JfbBaseAfterSalesList.vue +454 -0
  27. package/src/components/JfbBaseAfterSalesList/JfbBaseAfterSalesListLess.less +79 -0
  28. package/src/components/JfbBaseAfterSalesList/JfbBaseAfterSalesListMixin.js +30 -0
  29. package/src/components/JfbBaseAfterSalesList/Mock.js +5 -0
  30. package/src/components/JfbBaseOrderDetail/Attr.js +12 -0
  31. package/src/components/JfbBaseOrderDetail/JfbBaseOrderDetail.vue +4 -0
  32. package/src/components/JfbBaseOrderList/Attr.js +36 -0
  33. package/src/components/JfbBaseOrderList/JfbBaseOrderList.vue +30 -0
  34. package/src/components/JfbBaseOrderList/Mock.js +1 -1
  35. package/src/components/JfbBaseOrderList/XdTfkOrderItem.vue +17 -5
@@ -0,0 +1,30 @@
1
+ 'use strict';
2
+ /**
3
+ * @description 接口配置,
4
+ * 在设置方法名字当时候,别忘记加上【模块名字】:After
5
+ * @type {*[]}
6
+ */
7
+ module.exports = [
8
+ {
9
+ mapFnName: "getAfterSalesTypeList",
10
+ path: "/aftersale/v1/service-order/after-sales-type-list",
11
+ title: "售后类型列表",
12
+ isRule: false,
13
+ params: {},
14
+ isConsole: true,
15
+ disabled: true,
16
+ },
17
+ {
18
+ mapFnName: "createAfterServiceOrderQuick",
19
+ path: "/aftersale/v1/service-order/quick-refund",
20
+ title: "快速退款",
21
+ isRule: false,
22
+ data: {
23
+ main_order_id: ['主订单号', 'String', true],
24
+ after_sale_type: ['售后类型', 'String', true],
25
+ db_from: ['来源', 'String', true],
26
+ },
27
+ isConsole: true,
28
+ disabled: true,
29
+ }
30
+ ];
@@ -0,0 +1,32 @@
1
+ 'use strict';
2
+
3
+ /**
4
+ * @description 当表单组件中有联动操作时候,使用方法进行返回
5
+ */
6
+ export default {
7
+ style: [],
8
+ content: (data) => {
9
+ return [
10
+ {
11
+ label: "温馨提示:",
12
+ ele: "xd-tinymce",
13
+ valueKey: "warmTips",
14
+ groupKey: "content",
15
+ value: data['warmTips'] || '',
16
+ },
17
+ {
18
+ label: '售后详情页面路径:',
19
+ ele: 'xd-select-pages-path',
20
+ valueKey: 'refundStepPath',
21
+ groupKey:'advanced',
22
+ placeholder: '请选择售后详情页面路径',
23
+ value: data['refundStepPath'] || null,
24
+ setting: {
25
+ router: XdBus.getParentApi('getPagesTree'),
26
+ },
27
+ inline: false,
28
+ },
29
+ ].filter(i=>i)
30
+ },
31
+ advanced: [],
32
+ };
@@ -0,0 +1,273 @@
1
+ <template>
2
+ <view
3
+ class="jfb-base-after-sales-fast"
4
+ @click="handleEditxSelect"
5
+ :class="{ editx : isEditx && active }"
6
+ >
7
+ <!--#ifdef H5-->
8
+ <view
9
+ class="jfb-base-after-sales-fast__edit"
10
+ :class="{ editx : isEditx && active }"
11
+ v-if="isEditx && active"
12
+ >
13
+ <view class="jfb-base-after-sales-fast__edit-icon" @click="delEdit">删除</view>
14
+ </view>
15
+ <!-- #endif -->
16
+ <view class="jfb-base-after-sales-fast__body" :style="{
17
+ minHeight: layoutInfo.bodyMinHeightRpx + 'rpx',
18
+ '--main-color': mainColor
19
+ }">
20
+ <view class="list_section section_inline">
21
+ <view class="sec_label">
22
+ <view class="label_require">*</view>
23
+ <view>申请原因</view>
24
+ </view>
25
+ <view class="sec_content" @click="toChoseReason">
26
+ <view>包装破损</view>
27
+ <xd-font-icon icon="iconxiangyou_xian" :size="28" style="margin-left: 8rpx;"></xd-font-icon>
28
+ </view>
29
+ </view>
30
+ <view class="refund_warm_tip">
31
+ <view class="tip_title">温馨提示</view>
32
+ <xd-content-xss :html="warmTips"></xd-content-xss>
33
+ </view>
34
+ <view class="bottom_fixed">
35
+ <xd-button type="primary" @click="handleApplyRefund">提交申请</xd-button>
36
+ </view>
37
+ <xd-down-drawer :show.sync="reasonShow" :isClose="false">
38
+ <view class="refund_reason_head">申请原因</view>
39
+ <view class="refund_reason_body" style="min-height: 50vh;max-height: 75vh;">
40
+ <view class="reason_cont">
41
+ <view class="reason_item" v-for="item in afterSalesTypes" :key="item.id">
42
+ <view>{{ item.type_name }}</view>
43
+ <xd-radio :value="temp_type === item.id" @change="selectApplyReason(item.id)"></xd-radio>
44
+ </view>
45
+ </view>
46
+ <view class="reason_foot">
47
+ <xd-button type="primary" @click="handleChoseReason">确定</xd-button>
48
+ </view>
49
+ </view>
50
+ </xd-down-drawer>
51
+ </view>
52
+ </view>
53
+ </template>
54
+
55
+ <script>
56
+ import XdFontIcon from "@/components/XdFontIcon/XdFontIcon";
57
+ import XdContentXss from "@/components/XdContentXss/XdContentXss"
58
+ import XdButton from "@/components/XdButton/XdButton";
59
+ import XdDownDrawer from "@/components/XdDownDrawer/XdDownDrawer"
60
+ import XdRadio from "@/components/XdRadio/XdRadio"
61
+ import { jfbRootExec } from "@/utils/xd.event";
62
+ import JfbBaseAfterSalesFastMixin from "./JfbBaseAfterSalesFastMixin";
63
+ import { getContainerPropsValue } from "@/utils/xd.base";
64
+ import componentsMixins from "@/mixins/componentsMixins";
65
+ import extsMixins from "@/mixins/extsMixins";
66
+ export default {
67
+ name: "JfbBaseAfterSalesFast",
68
+ components: {
69
+ XdFontIcon,
70
+ XdContentXss,
71
+ XdButton,
72
+ XdDownDrawer,
73
+ XdRadio
74
+ },
75
+ mixins: [
76
+ componentsMixins, extsMixins, JfbBaseAfterSalesFastMixin
77
+ ],
78
+ data() {
79
+ return {
80
+ reasonShow: false,
81
+ // content: `1.遇订单拆分,京券将换成同价值京豆返还;<br/>2.本单支付券退还以实际使用规则为准;<br/>3.订单一旦取消,无法恢复;<br/>4.微信搜一搜订单返现金额会从退款中扣除`,
82
+ order_id: "",
83
+ //todo
84
+ warmTips: "",
85
+ after_sale_type: "",
86
+ temp_type: "",
87
+ afterSalesTypes: [],
88
+
89
+ refundStepPath: "",
90
+ }
91
+ },
92
+ watch: {
93
+ container(value, oldValue) {
94
+ if (JSON.stringify(value) === JSON.stringify(oldValue)) return;
95
+ if (this.$configProject['isPreview']) this.init(value)
96
+ },
97
+ },
98
+ created() {
99
+ this.init(this.container);
100
+
101
+ //todo
102
+ },
103
+ methods: {
104
+ onJfbLoad(options) {
105
+ this.order_id = options.order_id;
106
+ },
107
+ /**
108
+ * @description 监听事件变化
109
+ * @param container {object} 业务组件对象自己
110
+ */
111
+ init(container) {
112
+ this.warmTips = getContainerPropsValue(container, 'content.warmTips', "");
113
+ this.refundStepPath = getContainerPropsValue(container, 'content.refundStepPath', {value: ""}).value;
114
+ },
115
+ p_getAfterSalesTypeList(){
116
+ jfbRootExec("getAfterSalesTypeList", {
117
+ vm: this,
118
+ data: {}
119
+ }).then(res => {
120
+ this.afterSalesTypes = res.list;
121
+ })
122
+ },
123
+ selectApplyReason(id){
124
+ this.temp_type = id;
125
+ },
126
+ handleApplyRefund(){
127
+ jfbRootExec("createAfterServiceOrderQuick", {
128
+ vm: this,
129
+ data: {
130
+ main_order_id: this.order_id,
131
+ after_sale_type: this.after_sale_type,
132
+ }
133
+ }).then(res => {
134
+ this.$xdUniHelper.navigateTo({
135
+ url: `${this.refundStepPath}?service_order_id=${res.service_order_id}`,
136
+ });
137
+ })
138
+ },
139
+ toChoseReason(){
140
+ this.reasonShow = true;
141
+ },
142
+ handleChoseReason(){
143
+ this.reasonShow = false;
144
+ this.after_sale_type = this.temp_type;
145
+ },
146
+ onJfbScroll(options) {
147
+ // console.log('event.onJfbScroll', options)
148
+ },
149
+ onJfbReachBottom(options) {
150
+ console.log('event.onJfbReachBottom', options)
151
+ },
152
+ onJfbShow(options) {
153
+ console.log('event.onJfbShow', options)
154
+ },
155
+ onJfbHide(options) {
156
+ console.log('event.onJfbHide', options)
157
+ },
158
+ onJfbBack(options) {
159
+ console.log('event.onJfbBack', options)
160
+ },
161
+ onJfbUpdate(...data) {
162
+ console.log('event.onJfbUpdate', data)
163
+ },
164
+ onJfbCustomEvent(options) {
165
+ console.log('event.onJfbReachBottom', options)
166
+ },
167
+ }
168
+ }
169
+
170
+ </script>
171
+
172
+ <style scoped lang="less">
173
+ @import "./JfbBaseAfterSalesFastLess.less";
174
+
175
+ .jfb-base-after-sales-fast {
176
+ &__body{
177
+ padding: 20rpx 20rpx 120rpx;
178
+ box-sizing: border-box;
179
+ background-color: #EEEEEE;
180
+ .list_section{
181
+ padding: 24rpx 36rpx;
182
+ border-radius: 16rpx;
183
+ background-color: #FFFFFF;
184
+ display: flex;
185
+ flex-direction: column;
186
+ margin: 20rpx 0;
187
+ color: #333333;
188
+ font-size: 28rpx;
189
+ &.section_inline{
190
+ flex-direction: row;
191
+ justify-content: space-between;
192
+ .sec_label{
193
+ margin-bottom: 0;
194
+ }
195
+ }
196
+ .sec_label{
197
+ display: flex;
198
+ align-items: center;
199
+ margin-bottom: 24rpx;
200
+ .label_require{
201
+ color: #FF5733;
202
+ margin-right: 4rpx;
203
+ }
204
+ .label_sub{
205
+ color: #CCCCCC;
206
+ font-size: 24rpx;
207
+ margin-left: 16rpx;
208
+ }
209
+ }
210
+ .sec_content{
211
+ display: flex;
212
+ align-items: center;
213
+ color: #666666;
214
+
215
+ .img_list{
216
+ display: flex;
217
+ flex-wrap: wrap;
218
+ .img_box{
219
+ width: 160rpx;
220
+ height: 160rpx;
221
+ border-radius: 8rpx;
222
+ border: 1px solid #E0E0E0;
223
+ margin-right: 28rpx;
224
+ margin-bottom: 28rpx;
225
+ }
226
+ }
227
+ }
228
+ }
229
+ .refund_warm_tip{
230
+ padding: 24rpx;
231
+ .tip_title{
232
+ font-size: 26rpx;
233
+ color: #333333;
234
+ font-weight: 500;
235
+ margin-bottom: 24rpx;
236
+ }
237
+ }
238
+ .bottom_fixed{
239
+ position: fixed;
240
+ bottom: 0;
241
+ left: 0;
242
+ width: 100%;
243
+ padding: 20rpx;
244
+ box-sizing: border-box;
245
+ }
246
+ .refund_reason_head{
247
+ padding: 32rpx 0;
248
+ text-align: center;
249
+ border-bottom: 1px solid #F2F2F2;
250
+ margin: 0 32rpx;
251
+ }
252
+ .refund_reason_body{
253
+ display: flex;
254
+ flex-direction: column;
255
+ .reason_cont{
256
+ flex: 1;
257
+ padding: 0 40rpx;
258
+ overflow: auto;
259
+ .reason_item{
260
+ display: flex;
261
+ align-items: center;
262
+ justify-content: space-between;
263
+ padding: 20rpx 20rpx;
264
+ }
265
+ }
266
+ .reason_foot{
267
+ padding: 32rpx;
268
+ border-top: 1px solid #F2F2F2;
269
+ }
270
+ }
271
+ }
272
+ }
273
+ </style>
@@ -0,0 +1,79 @@
1
+ /**
2
+ * @desc 获取绝对路径完整地址
3
+ * @param @path
4
+ **/
5
+ //例如:https://image.jufubao.cn/20220501010108/image/bg/default_gonghui_bg.png
6
+ @basePath: 'business/';
7
+ @doMain: '//sandbox-img.jufubao.cn/';
8
+
9
+ .getBusinessImageUrl(@path, @size: 'size8') {
10
+ @url: "@{doMain}@{basePath}@{path}?x-oss-process=style/@{size}";
11
+ background-image: url(@url);
12
+ }
13
+
14
+ //start
15
+ .jfb-base-after-sales-fast {
16
+ box-sizing: border-box;
17
+
18
+ &__body{
19
+ position: relative;
20
+ overflow: hidden;
21
+ z-index: 2
22
+ }
23
+
24
+ &.editx,&.editx:hover {
25
+ position: relative;
26
+ min-height: unit(100, rpx);
27
+ z-index: 3;
28
+ &::after {
29
+ border: 2rpx dashed blue;
30
+ content: " ";
31
+ position: absolute;
32
+ top:0;
33
+ left:0;
34
+ bottom:0;
35
+ right:0;
36
+ z-index: 4;
37
+ cursor: pointer;
38
+ }
39
+
40
+ }
41
+
42
+
43
+ &__edit {
44
+ cursor: pointer;
45
+ position: absolute;
46
+ right: unit(0, rpx);
47
+ top: unit(-52, rpx);
48
+ height: unit(50, rpx);
49
+ line-height: unit(50, rpx);
50
+ display: flex;
51
+ justify-content: center;
52
+ align-items: center;
53
+ background: rgba(0, 0, 0, .6);
54
+ border-radius: unit(10, rpx);
55
+ box-shadow: 0 0 10px rbga(0, 0, 0, 0.3);
56
+ color: #fff;
57
+ font-size: unit(22, rpx);
58
+
59
+ &-icon{
60
+ padding: 0 unit(20, rpx);
61
+ }
62
+
63
+ &.editx {
64
+ box-sizing: border-box;
65
+
66
+ }
67
+ }
68
+ }
69
+ //end
70
+
71
+
72
+ /**notPreview**/
73
+ .jfb-base-after-sales-fast {
74
+ //&:before {
75
+ //content: " ";
76
+ //display: table;
77
+ //}
78
+ }
79
+ /**endNotPreview**/
@@ -0,0 +1,30 @@
1
+ 'use strict';
2
+
3
+
4
+ //@AttrImport
5
+ import Attr from "./Attr";
6
+ //@EndAttrImport
7
+
8
+
9
+ export default {
10
+ data() {
11
+ return {
12
+ //#ifdef H5
13
+
14
+ //@AttrData
15
+ Attr:{}, //对外开发编辑属性
16
+ //@EndAttrData
17
+
18
+ // #endif
19
+ cssRoot: 'jfb-base-after-sales-fast'
20
+ }
21
+ },
22
+ created() {
23
+
24
+ //@AttrDataCreated
25
+ this.Attr = this.$xdUniHelper.customClone(Attr);
26
+ //@EndAttrDataCreated
27
+
28
+
29
+ },
30
+ }
@@ -0,0 +1,13 @@
1
+ 'use strict';
2
+
3
+ module.exports = {
4
+
5
+ getAfterByIdFilmSquate:{},
6
+
7
+ updateAfterFilmPaiqiDate:{},
8
+
9
+ removeAfterFilmAddress:{},
10
+
11
+ addAfterFilmcart:{},
12
+
13
+ }
@@ -0,0 +1,18 @@
1
+ 'use strict';
2
+ /**
3
+ * @description 接口配置,
4
+ * 在设置方法名字当时候,别忘记加上【模块名字】:After
5
+ * @type {*[]}
6
+ */
7
+ module.exports = [
8
+ {
9
+ mapFnName: 'getAfterServiceOrderList',
10
+ title: '获取服务单列表',
11
+ path: '/aftersale/v1/service-order/list',
12
+ isRule: false,
13
+ params: {
14
+ },
15
+ isConsole: true,
16
+ disabled: true,
17
+ },
18
+ ];
@@ -0,0 +1,48 @@
1
+ 'use strict';
2
+
3
+ /**
4
+ * @description 当表单组件中有联动操作时候,使用方法进行返回
5
+ */
6
+ export default {
7
+ style: [],
8
+ content: (data) => {
9
+ return [
10
+ {
11
+ label: '背景颜色:',
12
+ ele: 'xd-color',
13
+ valueKey: 'bgColor',
14
+ value: data.bgColor || '',
15
+ placeholder: '请输入占位框背景颜色',
16
+ groupKey:'content',
17
+ },
18
+ {
19
+ label: '选中路径:',
20
+ groupKey:'advanced',
21
+ className: 'input100',
22
+ ele: 'xd-select-pages-path',
23
+ valueKey: 'select-pages-path',
24
+ value: data['select-pages-path'] || null,
25
+ setting: {
26
+ router: XdBus.getParentApi('getPagesTree')
27
+ },
28
+ },
29
+ data.bgColor && {
30
+ label: '高度:',
31
+ ele: 'el-input',
32
+ groupKey:'style',
33
+ type: 'number',
34
+ valueKey: 'height',
35
+ value: data.height || 100,
36
+ placeholder: '请输入占位框高度,单位像素,默认:10px',
37
+ className: 'input60',
38
+ },
39
+ {
40
+ label: '', //label
41
+ groupKey:'advanced',
42
+ ele: 'slot', //package 名称
43
+ slot: 'is_reference',
44
+ },
45
+ ].filter(i=>i)
46
+ },
47
+ advanced: [],
48
+ };