|
@@ -16,43 +16,95 @@ |
|
@@ -16,43 +16,95 @@ |
|
16
|
|
16
|
|
|
17
|
<view v-if="mode === 'add'" class="section">
|
17
|
<view v-if="mode === 'add'" class="section">
|
|
18
|
<view v-for="(item, idx) in items" :key="'a-' + idx" class="block">
|
18
|
<view v-for="(item, idx) in items" :key="'a-' + idx" class="block">
|
|
19
|
- <view class="row"><text class="label">行业</text><text class="value">{{ item.industry }}</text></view>
|
|
|
|
20
|
- <view class="row"><text class="label">品质</text><text class="value">{{ item.quality }}</text></view>
|
|
|
|
21
|
- <view class="row"><text class="label">牌号</text><text class="value">{{ item.brand }}</text></view>
|
19
|
+ <view v-show="item.collapsed">
|
|
|
|
20
|
+ <view class="row"><text class="label">行业</text><text class="value">{{ item.industry }}</text></view>
|
|
|
|
21
|
+ <view class="row"><text class="label">品质</text><text class="value">{{ item.quality }}</text></view>
|
|
|
|
22
|
+ <view class="row"><text class="label">牌号</text><text class="value">{{ item.brand }}</text></view>
|
|
|
|
23
|
+ </view>
|
|
|
|
24
|
+
|
|
22
|
|
25
|
|
|
23
|
<view v-show="!item.collapsed">
|
26
|
<view v-show="!item.collapsed">
|
|
24
|
- <!-- 厚(公差) * 宽(公差) * 长(公差) -->
|
|
|
|
25
|
- <view class="row row-spec"><text class="label">规格(mm)</text>
|
|
|
|
26
|
- <view class="value value-spec">
|
|
|
|
27
|
- <view v-if="item.thickness" class="value-spec_val">{{ item.thickness }}</view>
|
|
|
|
28
|
- <view v-if="item.thickness" class="value-spec_box">
|
|
|
|
29
|
- <view v-if="item.thicknessTolPos" class="value-spec_box_1">{{ item.thicknessTolPos ? '+' + item.thicknessTolPos : item.thicknessTolPos }}
|
|
|
|
30
|
- </view>
|
|
|
|
31
|
- <view v-if="item.thicknessTolNeg" class="value-spec_box_2">{{ item.thicknessTolNeg ? '+' + item.thicknessTolNeg : item.thicknessTolNeg }}
|
|
|
|
32
|
- </view>
|
|
|
|
33
|
- </view>
|
|
|
|
34
|
- <view v-if="item.width" class="value-spec_val p12">*</view>
|
|
|
|
35
|
- <view v-if="item.width" class="value-spec_val">{{ item.width }}</view>
|
|
|
|
36
|
- <view v-if="item.width" class="value-spec_box">
|
|
|
|
37
|
- <view v-if="item.widthTolPos" class="value-spec_box_1">{{ item.widthTolPos > 0 ? '+' + item.widthTolPos : item.widthTolPos }}</view>
|
|
|
|
38
|
- <view v-if="item.widthTolNeg" class="value-spec_box_2">{{ item.widthTolNeg > 0 ? '+' + item.widthTolNeg : item.widthTolNeg }}</view>
|
|
|
|
39
|
- </view>
|
|
|
|
40
|
- <view v-if="item.length" class="value-spec_val p12">*</view>
|
|
|
|
41
|
- <view v-if="item.length" class="value-spec_val">{{ item.length }}</view>
|
|
|
|
42
|
- <view v-if="item.length" class="value-spec_box">
|
|
|
|
43
|
- <view v-if="item.lengthTolPos" class="value-spec_box_1">{{ item.lengthTolPos > 0 ? '+' + item.lengthTolPos : item.lengthTolPos }}</view>
|
|
|
|
44
|
- <view v-if="item.lengthTolNeg" class="value-spec_box_2">{{ item.lengthTolNeg > 0 ? '+' + item.lengthTolNeg : item.lengthTolNeg }}</view>
|
|
|
|
45
|
- </view>
|
|
|
|
46
|
- </view>
|
|
|
|
47
|
- </view>
|
|
|
|
48
|
- <view class="row"><text class="label">状态</text><text class="value">{{ item.status }}</text></view>
|
|
|
|
49
|
- <view class="row" :class="{ 'noneStyle': !item.showSalesPrice }"><text
|
|
|
|
50
|
- class="label">数量kg</text><text class="value">{{ item.quantity }}</text>
|
|
|
|
51
|
- </view>
|
|
|
|
52
|
- <view class="row" :class="{ 'noneStyle': item.showSalesPrice }" v-if="item.showSalesPrice"><text
|
|
|
|
53
|
- class="label">销售价格</text><text class="value">{{
|
|
|
|
54
|
- item.salesPrice }}</text></view>
|
|
|
|
55
|
<uni-list class="edit-list">
|
27
|
<uni-list class="edit-list">
|
|
|
|
28
|
+ <uni-list-item title="行业">
|
|
|
|
29
|
+ <template v-slot:footer>
|
|
|
|
30
|
+ <uni-easyinput v-model="item.industry" placeholder="请输入行业" :inputBorder="false" :disabled="canEditDeliveryAndAssessment" />
|
|
|
|
31
|
+ </template>
|
|
|
|
32
|
+ </uni-list-item>
|
|
|
|
33
|
+ <uni-list-item title="品质">
|
|
|
|
34
|
+ <template v-slot:footer>
|
|
|
|
35
|
+ <uni-easyinput v-model="item.quality" placeholder="请输入品质" :inputBorder="false" :disabled="canEditDeliveryAndAssessment" />
|
|
|
|
36
|
+ </template>
|
|
|
|
37
|
+ </uni-list-item>
|
|
|
|
38
|
+ <uni-list-item title="牌号">
|
|
|
|
39
|
+ <template v-slot:footer>
|
|
|
|
40
|
+ <uni-easyinput v-model="item.brand" placeholder="请输入牌号" :inputBorder="false" :disabled="canEditDeliveryAndAssessment" />
|
|
|
|
41
|
+ </template>
|
|
|
|
42
|
+ </uni-list-item>
|
|
|
|
43
|
+
|
|
|
|
44
|
+ <uni-list-item title="厚度(mm)">
|
|
|
|
45
|
+ <template v-slot:footer>
|
|
|
|
46
|
+ <uni-easyinput type="digit" v-model="item.thickness" placeholder="请输入厚度" :inputBorder="false" :disabled="canEditDeliveryAndAssessment" />
|
|
|
|
47
|
+ </template>
|
|
|
|
48
|
+ </uni-list-item>
|
|
|
|
49
|
+ <uni-list-item title="厚度公差上限(mm)">
|
|
|
|
50
|
+ <template v-slot:footer>
|
|
|
|
51
|
+ <uni-easyinput type="digit" v-model="item.thicknessTolPos" placeholder="请输入厚度公差上限" :inputBorder="false" :disabled="canEditDeliveryAndAssessment" />
|
|
|
|
52
|
+ </template>
|
|
|
|
53
|
+ </uni-list-item>
|
|
|
|
54
|
+ <uni-list-item title="厚度公差下限(mm)">
|
|
|
|
55
|
+ <template v-slot:footer>
|
|
|
|
56
|
+ <uni-easyinput type="digit" v-model="item.thicknessTolNeg" placeholder="请输入厚度公差下限" :inputBorder="false" :disabled="canEditDeliveryAndAssessment" />
|
|
|
|
57
|
+ </template>
|
|
|
|
58
|
+ </uni-list-item>
|
|
|
|
59
|
+
|
|
|
|
60
|
+ <uni-list-item title="宽度(mm)">
|
|
|
|
61
|
+ <template v-slot:footer>
|
|
|
|
62
|
+ <uni-easyinput type="digit" v-model="item.width" placeholder="请输入宽度" :inputBorder="false" :disabled="canEditDeliveryAndAssessment" />
|
|
|
|
63
|
+ </template>
|
|
|
|
64
|
+ </uni-list-item>
|
|
|
|
65
|
+ <uni-list-item title="宽度公差上限(mm)">
|
|
|
|
66
|
+ <template v-slot:footer>
|
|
|
|
67
|
+ <uni-easyinput type="digit" v-model="item.widthTolPos" placeholder="请输入宽度公差上限" :inputBorder="false" :disabled="canEditDeliveryAndAssessment" />
|
|
|
|
68
|
+ </template>
|
|
|
|
69
|
+ </uni-list-item>
|
|
|
|
70
|
+ <uni-list-item title="宽度公差下限(mm)">
|
|
|
|
71
|
+ <template v-slot:footer>
|
|
|
|
72
|
+ <uni-easyinput type="digit" v-model="item.widthTolNeg" placeholder="请输入宽度公差下限" :inputBorder="false" :disabled="canEditDeliveryAndAssessment" />
|
|
|
|
73
|
+ </template>
|
|
|
|
74
|
+ </uni-list-item>
|
|
|
|
75
|
+
|
|
|
|
76
|
+ <uni-list-item title="长度(mm)">
|
|
|
|
77
|
+ <template v-slot:footer>
|
|
|
|
78
|
+ <uni-easyinput type="digit" v-model="item.length" placeholder="请输入长度" :inputBorder="false" :disabled="canEditDeliveryAndAssessment" />
|
|
|
|
79
|
+ </template>
|
|
|
|
80
|
+ </uni-list-item>
|
|
|
|
81
|
+ <uni-list-item title="长度公差上限(mm)">
|
|
|
|
82
|
+ <template v-slot:footer>
|
|
|
|
83
|
+ <uni-easyinput type="digit" v-model="item.lengthTolPos" placeholder="请输入长度公差上限" :inputBorder="false" :disabled="canEditDeliveryAndAssessment" />
|
|
|
|
84
|
+ </template>
|
|
|
|
85
|
+ </uni-list-item>
|
|
|
|
86
|
+ <uni-list-item title="长度公差下限(mm)">
|
|
|
|
87
|
+ <template v-slot:footer>
|
|
|
|
88
|
+ <uni-easyinput type="digit" v-model="item.lengthTolNeg" placeholder="请输入长度公差下限" :inputBorder="false" :disabled="canEditDeliveryAndAssessment" />
|
|
|
|
89
|
+ </template>
|
|
|
|
90
|
+ </uni-list-item>
|
|
|
|
91
|
+
|
|
|
|
92
|
+ <uni-list-item title="状态">
|
|
|
|
93
|
+ <template v-slot:footer>
|
|
|
|
94
|
+ <uni-easyinput v-model="item.status" placeholder="请输入状态" :inputBorder="false" :disabled="canEditDeliveryAndAssessment" />
|
|
|
|
95
|
+ </template>
|
|
|
|
96
|
+ </uni-list-item>
|
|
|
|
97
|
+ <uni-list-item title="数量kg">
|
|
|
|
98
|
+ <template v-slot:footer>
|
|
|
|
99
|
+ <uni-easyinput type="digit" v-model="item.quantity" placeholder="请输入数量" :inputBorder="false" :disabled="canEditDeliveryAndAssessment" />
|
|
|
|
100
|
+ </template>
|
|
|
|
101
|
+ </uni-list-item>
|
|
|
|
102
|
+ <uni-list-item title="销售价格" v-if="item.showSalesPrice">
|
|
|
|
103
|
+ <template v-slot:footer>
|
|
|
|
104
|
+ <uni-easyinput type="digit" v-model="item.salesPrice" placeholder="请输入销售价格" :inputBorder="false" :disabled="canEditDeliveryAndAssessment" />
|
|
|
|
105
|
+ </template>
|
|
|
|
106
|
+ </uni-list-item>
|
|
|
|
107
|
+
|
|
56
|
<uni-list-item class="amount-item">
|
108
|
<uni-list-item class="amount-item">
|
|
57
|
<template v-slot:body>
|
109
|
<template v-slot:body>
|
|
58
|
<view class="item-title"><text>包装费</text></view>
|
110
|
<view class="item-title"><text>包装费</text></view>
|
|
@@ -61,6 +113,7 @@ |
|
@@ -61,6 +113,7 @@ |
|
61
|
<view class="amount-row">
|
113
|
<view class="amount-row">
|
|
62
|
<uni-easyinput type="digit" v-model="item.packagingFee" placeholder="0.00"
|
114
|
<uni-easyinput type="digit" v-model="item.packagingFee" placeholder="0.00"
|
|
63
|
:inputBorder="false"
|
115
|
:inputBorder="false"
|
|
|
|
116
|
+ :disabled="canEditDeliveryAndAssessment"
|
|
64
|
@input="onNonNegativeNumberInput($event, item, idx, 'packagingFee')"
|
117
|
@input="onNonNegativeNumberInput($event, item, idx, 'packagingFee')"
|
|
65
|
@blur="onNonNegativeNumberBlur(item, idx, 'packagingFee')" />
|
118
|
@blur="onNonNegativeNumberBlur(item, idx, 'packagingFee')" />
|
|
66
|
<text class="unit">元</text>
|
119
|
<text class="unit">元</text>
|
|
@@ -70,17 +123,23 @@ |
|
@@ -70,17 +123,23 @@ |
|
70
|
<uni-list-item title="发货日期">
|
123
|
<uni-list-item title="发货日期">
|
|
71
|
<template v-slot:footer>
|
124
|
<template v-slot:footer>
|
|
72
|
<uni-datetime-picker type="date" v-model="item.deliveryDate" :start="minDeliveryDate"
|
125
|
<uni-datetime-picker type="date" v-model="item.deliveryDate" :start="minDeliveryDate"
|
|
|
|
126
|
+ :disabled="!canEditDeliveryAndAssessment"
|
|
73
|
@change="onDeliveryChange($event, item, idx)" />
|
127
|
@change="onDeliveryChange($event, item, idx)" />
|
|
74
|
</template>
|
128
|
</template>
|
|
75
|
</uni-list-item>
|
129
|
</uni-list-item>
|
|
76
|
<uni-list-item title="考核超协">
|
130
|
<uni-list-item title="考核超协">
|
|
77
|
<template v-slot:footer>
|
131
|
<template v-slot:footer>
|
|
78
|
- <uni-easyinput type="digit" :disabled="pageType === 'modify'"
|
|
|
|
79
|
- v-model="item.assessmentExceedsAgreement"
|
|
|
|
80
|
- :placeholder="pageType === 'modify' ? '' : '请输入考核超协'" :inputBorder="false"
|
132
|
+ <uni-easyinput type="digit" v-model="item.assessmentExceedsAgreement" placeholder="请输入考核超协" :inputBorder="false"
|
|
|
|
133
|
+ :disabled="!canEditDeliveryAndAssessment"
|
|
81
|
@input="onAssessmentInput($event, idx)" @blur="onAssessmentBlur($event, idx)" />
|
134
|
@input="onAssessmentInput($event, idx)" @blur="onAssessmentBlur($event, idx)" />
|
|
82
|
</template>
|
135
|
</template>
|
|
83
|
</uni-list-item>
|
136
|
</uni-list-item>
|
|
|
|
137
|
+ <uni-list-item class="select-item" :class="String(item.sampleOrder) ? 'is-filled' : 'is-empty'" :clickable="!canEditDeliveryAndAssessment"
|
|
|
|
138
|
+ @click="openSheet(idx)" :rightText="(item.sampleOrder === true ? '是' : (item.sampleOrder === false ? '否' : '')) || '请选择'" showArrow>
|
|
|
|
139
|
+ <template v-slot:body>
|
|
|
|
140
|
+ <view class="item-title"><text>是否为试样订单</text></view>
|
|
|
|
141
|
+ </template>
|
|
|
|
142
|
+ </uni-list-item>
|
|
84
|
</uni-list>
|
143
|
</uni-list>
|
|
85
|
</view>
|
144
|
</view>
|
|
86
|
|
145
|
|
|
@@ -142,7 +201,7 @@ |
|
@@ -142,7 +201,7 @@ |
|
142
|
<uni-easyinput type="digit" v-model="item.packagingFee" placeholder="0.00"
|
201
|
<uni-easyinput type="digit" v-model="item.packagingFee" placeholder="0.00"
|
|
143
|
:inputBorder="false"
|
202
|
:inputBorder="false"
|
|
144
|
@input="onNonNegativeNumberInput($event, item, idx, 'packagingFee')"
|
203
|
@input="onNonNegativeNumberInput($event, item, idx, 'packagingFee')"
|
|
145
|
- @blur="onNonNegativeNumberBlur(item, idx, 'packagingFee')" />
|
204
|
+ @blur="onNonNegativeNumberBlur(item, idx, 'packagingFee')" :disabled="canEditDeliveryAndAssessment"/>
|
|
146
|
<text class="unit">元</text>
|
205
|
<text class="unit">元</text>
|
|
147
|
</view>
|
206
|
</view>
|
|
148
|
</template>
|
207
|
</template>
|
|
@@ -150,17 +209,18 @@ |
|
@@ -150,17 +209,18 @@ |
|
150
|
<uni-list-item title="发货日期">
|
209
|
<uni-list-item title="发货日期">
|
|
151
|
<template v-slot:footer>
|
210
|
<template v-slot:footer>
|
|
152
|
<uni-datetime-picker type="date" v-model="item.deliveryDate" :start="minDeliveryDate"
|
211
|
<uni-datetime-picker type="date" v-model="item.deliveryDate" :start="minDeliveryDate"
|
|
|
|
212
|
+ :disabled="!canEditDeliveryAndAssessment"
|
|
153
|
@change="onDeliveryChange($event, item, idx)" />
|
213
|
@change="onDeliveryChange($event, item, idx)" />
|
|
154
|
</template>
|
214
|
</template>
|
|
155
|
</uni-list-item>
|
215
|
</uni-list-item>
|
|
156
|
<uni-list-item title="考核超协">
|
216
|
<uni-list-item title="考核超协">
|
|
157
|
<template v-slot:footer>
|
217
|
<template v-slot:footer>
|
|
158
|
- <uni-easyinput :disabled="pageType === 'modify'"
|
218
|
+ <uni-easyinput :disabled="pageType === 'modify' || !canEditDeliveryAndAssessment"
|
|
159
|
v-model="item.assessmentExceedsAgreement"
|
219
|
v-model="item.assessmentExceedsAgreement"
|
|
160
|
:placeholder="pageType === 'modify' ? '' : '请输入考核超协'" :inputBorder="false" />
|
220
|
:placeholder="pageType === 'modify' ? '' : '请输入考核超协'" :inputBorder="false" />
|
|
161
|
</template>
|
221
|
</template>
|
|
162
|
</uni-list-item>
|
222
|
</uni-list-item>
|
|
163
|
- <uni-list-item class="select-item" :class="String(item.sampleOrder) ? 'is-filled' : 'is-empty'" clickable
|
223
|
+ <uni-list-item class="select-item" :class="String(item.sampleOrder) ? 'is-filled' : 'is-empty'" :clickable="!canEditDeliveryAndAssessment"
|
|
164
|
@click="openSheet(idx)" :rightText="(item.sampleOrder ? '是' : '否') || '请选择'" showArrow>
|
224
|
@click="openSheet(idx)" :rightText="(item.sampleOrder ? '是' : '否') || '请选择'" showArrow>
|
|
165
|
<template v-slot:body>
|
225
|
<template v-slot:body>
|
|
166
|
<view class="item-title"><text>是否为试样订单</text></view>
|
226
|
<view class="item-title"><text>是否为试样订单</text></view>
|
|
@@ -310,7 +370,9 @@ export default { |
|
@@ -310,7 +370,9 @@ export default { |
|
310
|
max: { type: Number, default: 8 },
|
370
|
max: { type: Number, default: 8 },
|
|
311
|
totalQuantity: { type: Number, default: 0 },
|
371
|
totalQuantity: { type: Number, default: 0 },
|
|
312
|
pageType: { type: String, default: '' },
|
372
|
pageType: { type: String, default: '' },
|
|
313
|
- orderDate: { type: String, default: '' }
|
373
|
+ orderDate: { type: String, default: '' },
|
|
|
|
374
|
+ canEditDeliveryAndAssessment: { type: Boolean, default: false },
|
|
|
|
375
|
+ // onlyEditDeliveryAndAssessment: { type: Boolean, default: false }
|
|
314
|
},
|
376
|
},
|
|
315
|
data() {
|
377
|
data() {
|
|
316
|
return {
|
378
|
return {
|
|
@@ -358,7 +420,29 @@ export default { |
|
@@ -358,7 +420,29 @@ export default { |
|
358
|
},
|
420
|
},
|
|
359
|
methods: {
|
421
|
methods: {
|
|
360
|
defaultItem() {
|
422
|
defaultItem() {
|
|
361
|
- return { collapsed: false, packagingFee: '' }
|
423
|
+ return {
|
|
|
|
424
|
+ collapsed: false,
|
|
|
|
425
|
+ industry: '',
|
|
|
|
426
|
+ quality: '',
|
|
|
|
427
|
+ brand: '',
|
|
|
|
428
|
+ thickness: '',
|
|
|
|
429
|
+ thicknessTolPos: '',
|
|
|
|
430
|
+ thicknessTolNeg: '',
|
|
|
|
431
|
+ width: '',
|
|
|
|
432
|
+ widthTolPos: '',
|
|
|
|
433
|
+ widthTolNeg: '',
|
|
|
|
434
|
+ length: '',
|
|
|
|
435
|
+ lengthTolPos: '',
|
|
|
|
436
|
+ lengthTolNeg: '',
|
|
|
|
437
|
+ status: '',
|
|
|
|
438
|
+ quantity: '',
|
|
|
|
439
|
+ salesPrice: '',
|
|
|
|
440
|
+ showSalesPrice: false,
|
|
|
|
441
|
+ packagingFee: '',
|
|
|
|
442
|
+ deliveryDate: '',
|
|
|
|
443
|
+ assessmentExceedsAgreement: '',
|
|
|
|
444
|
+ sampleOrder: ''
|
|
|
|
445
|
+ }
|
|
362
|
},
|
446
|
},
|
|
363
|
toggleItem(idx) {
|
447
|
toggleItem(idx) {
|
|
364
|
const it = this.items[idx]
|
448
|
const it = this.items[idx]
|
|
@@ -707,7 +791,7 @@ export default { |
|
@@ -707,7 +791,7 @@ export default { |
|
707
|
|
791
|
|
|
708
|
.block {
|
792
|
.block {
|
|
709
|
background: #ffffff;
|
793
|
background: #ffffff;
|
|
710
|
- padding: 32rpx 0;
|
794
|
+ //padding: 32rpx 0;
|
|
711
|
margin-bottom: 20rpx;
|
795
|
margin-bottom: 20rpx;
|
|
712
|
|
796
|
|
|
713
|
&:last-child {
|
797
|
&:last-child {
|