Commit 15fb77a9a28df6db1eb41dd67c042e11cd44b1c1
1 parent
a41fe73c
feat: 规格变更单-厚度&厚度公差+-&宽度&宽度公差+-&长度&长度公差+- 增加单位(mm)
Showing
1 changed file
with
46 additions
and
26 deletions
| @@ -34,58 +34,74 @@ | @@ -34,58 +34,74 @@ | ||
| 34 | </template> | 34 | </template> |
| 35 | </uni-list-item> | 35 | </uni-list-item> |
| 36 | <view v-show="!item.collapsed"> | 36 | <view v-show="!item.collapsed"> |
| 37 | - <uni-list-item title="厚度"> | 37 | + <uni-list-item title="厚度(mm)"> |
| 38 | <template v-slot:footer> | 38 | <template v-slot:footer> |
| 39 | - <uni-easyinput type="digit" v-model="item.thickness" placeholder="请输入厚度" :inputBorder="false" | ||
| 40 | - @input="onNonNegativeNumberInput($event, item, idx, 'thickness')" @blur="onNonNegativeNumberBlur(item, idx, 'thickness')" /> | 39 | + <uni-easyinput type="digit" v-model="item.thickness" placeholder="请输入厚度" |
| 40 | + :inputBorder="false" | ||
| 41 | + @input="onNonNegativeNumberInput($event, item, idx, 'thickness')" | ||
| 42 | + @blur="onNonNegativeNumberBlur(item, idx, 'thickness')" /> | ||
| 41 | </template> | 43 | </template> |
| 42 | </uni-list-item> | 44 | </uni-list-item> |
| 43 | - <uni-list-item title="厚度公差 +"> | 45 | + <uni-list-item title="厚度公差 +(mm)"> |
| 44 | <template v-slot:footer> | 46 | <template v-slot:footer> |
| 45 | <uni-easyinput type="digit" v-model="item.thicknessTolPos" placeholder="请输入厚度公差 +" | 47 | <uni-easyinput type="digit" v-model="item.thicknessTolPos" placeholder="请输入厚度公差 +" |
| 46 | - :inputBorder="false" @input="onNonNegativeNumberInput($event, item, idx, 'thicknessTolPos')" @blur="onNonNegativeNumberBlur(item, idx, 'thicknessTolPos')" /> | 48 | + :inputBorder="false" |
| 49 | + @input="onNonNegativeNumberInput($event, item, idx, 'thicknessTolPos')" | ||
| 50 | + @blur="onNonNegativeNumberBlur(item, idx, 'thicknessTolPos')" /> | ||
| 47 | </template> | 51 | </template> |
| 48 | </uni-list-item> | 52 | </uni-list-item> |
| 49 | - <uni-list-item title="厚度公差 -"> | 53 | + <uni-list-item title="厚度公差 -(mm)"> |
| 50 | <template v-slot:footer> | 54 | <template v-slot:footer> |
| 51 | <uni-easyinput type="digit" v-model="item.thicknessTolNeg" placeholder="请输入厚度公差 -" | 55 | <uni-easyinput type="digit" v-model="item.thicknessTolNeg" placeholder="请输入厚度公差 -" |
| 52 | - :inputBorder="false" @input="onNonNegativeNumberInput($event, item, idx, 'thicknessTolNeg')" @blur="onNonNegativeNumberBlur(item, idx, 'thicknessTolNeg')" /> | 56 | + :inputBorder="false" |
| 57 | + @input="onNonNegativeNumberInput($event, item, idx, 'thicknessTolNeg')" | ||
| 58 | + @blur="onNonNegativeNumberBlur(item, idx, 'thicknessTolNeg')" /> | ||
| 53 | </template> | 59 | </template> |
| 54 | </uni-list-item> | 60 | </uni-list-item> |
| 55 | - <uni-list-item title="宽度"> | 61 | + <uni-list-item title="宽度(mm)"> |
| 56 | <template v-slot:footer> | 62 | <template v-slot:footer> |
| 57 | - <uni-easyinput type="digit" v-model="item.width" placeholder="请输入宽度" :inputBorder="false" | ||
| 58 | - @input="onNonNegativeNumberInput($event, item, idx, 'width')" @blur="onNonNegativeNumberBlur(item, idx, 'width')" /> | 63 | + <uni-easyinput type="digit" v-model="item.width" placeholder="请输入宽度" |
| 64 | + :inputBorder="false" @input="onNonNegativeNumberInput($event, item, idx, 'width')" | ||
| 65 | + @blur="onNonNegativeNumberBlur(item, idx, 'width')" /> | ||
| 59 | </template> | 66 | </template> |
| 60 | </uni-list-item> | 67 | </uni-list-item> |
| 61 | - <uni-list-item title="宽度公差 +"> | 68 | + <uni-list-item title="宽度公差 +(mm)"> |
| 62 | <template v-slot:footer> | 69 | <template v-slot:footer> |
| 63 | <uni-easyinput type="digit" v-model="item.widthTolPos" placeholder="请输入宽度公差 +" | 70 | <uni-easyinput type="digit" v-model="item.widthTolPos" placeholder="请输入宽度公差 +" |
| 64 | - :inputBorder="false" @input="onNonNegativeNumberInput($event, item, idx, 'widthTolPos')" @blur="onNonNegativeNumberBlur(item, idx, 'widthTolPos')" /> | 71 | + :inputBorder="false" |
| 72 | + @input="onNonNegativeNumberInput($event, item, idx, 'widthTolPos')" | ||
| 73 | + @blur="onNonNegativeNumberBlur(item, idx, 'widthTolPos')" /> | ||
| 65 | </template> | 74 | </template> |
| 66 | </uni-list-item> | 75 | </uni-list-item> |
| 67 | - <uni-list-item title="宽度公差 -"> | 76 | + <uni-list-item title="宽度公差 -(mm)"> |
| 68 | <template v-slot:footer> | 77 | <template v-slot:footer> |
| 69 | <uni-easyinput type="digit" v-model="item.widthTolNeg" placeholder="请输入宽度公差 -" | 78 | <uni-easyinput type="digit" v-model="item.widthTolNeg" placeholder="请输入宽度公差 -" |
| 70 | - :inputBorder="false" @input="onNonNegativeNumberInput($event, item, idx, 'widthTolNeg')" @blur="onNonNegativeNumberBlur(item, idx, 'widthTolNeg')" /> | 79 | + :inputBorder="false" |
| 80 | + @input="onNonNegativeNumberInput($event, item, idx, 'widthTolNeg')" | ||
| 81 | + @blur="onNonNegativeNumberBlur(item, idx, 'widthTolNeg')" /> | ||
| 71 | </template> | 82 | </template> |
| 72 | </uni-list-item> | 83 | </uni-list-item> |
| 73 | - <uni-list-item title="长度"> | 84 | + <uni-list-item title="长度(mm)"> |
| 74 | <template v-slot:footer> | 85 | <template v-slot:footer> |
| 75 | - <uni-easyinput type="digit" v-model="item.length" placeholder="请输入长度" :inputBorder="false" | ||
| 76 | - @input="onNonNegativeNumberInput($event, item, idx, 'length')" @blur="onNonNegativeNumberBlur(item, idx, 'length')" /> | 86 | + <uni-easyinput type="digit" v-model="item.length" placeholder="请输入长度" |
| 87 | + :inputBorder="false" @input="onNonNegativeNumberInput($event, item, idx, 'length')" | ||
| 88 | + @blur="onNonNegativeNumberBlur(item, idx, 'length')" /> | ||
| 77 | </template> | 89 | </template> |
| 78 | </uni-list-item> | 90 | </uni-list-item> |
| 79 | - <uni-list-item title="长度公差 +"> | 91 | + <uni-list-item title="长度公差 +(mm)"> |
| 80 | <template v-slot:footer> | 92 | <template v-slot:footer> |
| 81 | <uni-easyinput type="digit" v-model="item.lengthTolPos" placeholder="请输入长度公差 +" | 93 | <uni-easyinput type="digit" v-model="item.lengthTolPos" placeholder="请输入长度公差 +" |
| 82 | - :inputBorder="false" @input="onNonNegativeNumberInput($event, item, idx, 'lengthTolPos')" @blur="onNonNegativeNumberBlur(item, idx, 'lengthTolPos')" /> | 94 | + :inputBorder="false" |
| 95 | + @input="onNonNegativeNumberInput($event, item, idx, 'lengthTolPos')" | ||
| 96 | + @blur="onNonNegativeNumberBlur(item, idx, 'lengthTolPos')" /> | ||
| 83 | </template> | 97 | </template> |
| 84 | </uni-list-item> | 98 | </uni-list-item> |
| 85 | - <uni-list-item title="长度公差 -"> | 99 | + <uni-list-item title="长度公差 -(mm)"> |
| 86 | <template v-slot:footer> | 100 | <template v-slot:footer> |
| 87 | <uni-easyinput type="digit" v-model="item.lengthTolNeg" placeholder="请输入长度公差 -" | 101 | <uni-easyinput type="digit" v-model="item.lengthTolNeg" placeholder="请输入长度公差 -" |
| 88 | - :inputBorder="false" @input="onNonNegativeNumberInput($event, item, idx, 'lengthTolNeg')" @blur="onNonNegativeNumberBlur(item, idx, 'lengthTolNeg')" /> | 102 | + :inputBorder="false" |
| 103 | + @input="onNonNegativeNumberInput($event, item, idx, 'lengthTolNeg')" | ||
| 104 | + @blur="onNonNegativeNumberBlur(item, idx, 'lengthTolNeg')" /> | ||
| 89 | </template> | 105 | </template> |
| 90 | </uni-list-item> | 106 | </uni-list-item> |
| 91 | <uni-list-item title="状态"> | 107 | <uni-list-item title="状态"> |
| @@ -95,14 +111,18 @@ | @@ -95,14 +111,18 @@ | ||
| 95 | </uni-list-item> | 111 | </uni-list-item> |
| 96 | <uni-list-item title="数量kg"> | 112 | <uni-list-item title="数量kg"> |
| 97 | <template v-slot:footer> | 113 | <template v-slot:footer> |
| 98 | - <uni-easyinput type="digit" v-model="item.quantity" placeholder="请输入数量kg" :inputBorder="false" | ||
| 99 | - @input="onNonNegativeNumberInput($event, item, idx, 'quantity')" @blur="onNonNegativeNumberBlur(item, idx, 'quantity')" /> | 114 | + <uni-easyinput type="digit" v-model="item.quantity" placeholder="请输入数量kg" |
| 115 | + :inputBorder="false" | ||
| 116 | + @input="onNonNegativeNumberInput($event, item, idx, 'quantity')" | ||
| 117 | + @blur="onNonNegativeNumberBlur(item, idx, 'quantity')" /> | ||
| 100 | </template> | 118 | </template> |
| 101 | </uni-list-item> | 119 | </uni-list-item> |
| 102 | <uni-list-item v-if="item.showSalesPrice" title="销售价格"> | 120 | <uni-list-item v-if="item.showSalesPrice" title="销售价格"> |
| 103 | <template v-slot:footer> | 121 | <template v-slot:footer> |
| 104 | - <uni-easyinput type="digit" v-model="item.salesPrice" placeholder="请输入销售价格" :inputBorder="false" | ||
| 105 | - @input="onNonNegativeNumberInput($event, item, idx, 'salesPrice')" @blur="onNonNegativeNumberBlur(item, idx, 'salesPrice')" /> | 122 | + <uni-easyinput type="digit" v-model="item.salesPrice" placeholder="请输入销售价格" |
| 123 | + :inputBorder="false" | ||
| 124 | + @input="onNonNegativeNumberInput($event, item, idx, 'salesPrice')" | ||
| 125 | + @blur="onNonNegativeNumberBlur(item, idx, 'salesPrice')" /> | ||
| 106 | </template> | 126 | </template> |
| 107 | </uni-list-item> | 127 | </uni-list-item> |
| 108 | <uni-list-item title="发货日期"> | 128 | <uni-list-item title="发货日期"> |
| @@ -247,7 +267,7 @@ export default { | @@ -247,7 +267,7 @@ export default { | ||
| 247 | assessmentExceedsAgreement: '' | 267 | assessmentExceedsAgreement: '' |
| 248 | } | 268 | } |
| 249 | }, | 269 | }, |
| 250 | - | 270 | + |
| 251 | onAdd() { | 271 | onAdd() { |
| 252 | if (this.items.length >= this.max) return uni.showToast({ title: `最多添加${this.max}个`, icon: 'none' }) | 272 | if (this.items.length >= this.max) return uni.showToast({ title: `最多添加${this.max}个`, icon: 'none' }) |
| 253 | const obj = this.defaultItem() | 273 | const obj = this.defaultItem() |