Commit be747969 by 李伟康

众筹

1 parent 9eef2941
......@@ -132,6 +132,7 @@
:data-index="index"
style="width: 150px"
type="number"
@input="formatAppend('crowdFundingPrice',index)"
><span slot="append">元</span></el-input>
<span class="balancePayment">尾款:
{{ editForm.crowdFundingPrice[index] | filterBalancePayment(editForm.activityPrice[index]) }}</span>
......@@ -146,6 +147,7 @@
:data-index="index"
style="width: 150px"
type="number"
@input="formatAppend('activityPrice',index)"
><span slot="append">元</span></el-input>
</el-form-item>
......@@ -160,6 +162,7 @@
style="width: 150px"
:disabled="isDisabled"
type="number"
@input="formatAppend('goodsStock',index, true)"
><span slot="append">件</span></el-input>
</el-form-item>
</div>
......@@ -2265,18 +2268,28 @@ export default {
//多选 this.selectedProInfo = this.editForm.goodsId ? { id: this.editForm.goodsId } : {}
this.handleSingleSelectClose()
},
handleSingleSelectConfirm (selectedProInfo) {
formatAppend (target, index, isInt) {
const val = this.editForm[target][index]
let str = String(val)
if (isInt) this.editForm[target][index] = Math.floor(val)
if (str.indexOf('.') > 0) this.editForm[target][index] = Number(str.slice(0, str.indexOf('.') + 3))
},
handleSingleSelectConfirm (list) {
// this.editForm.activityPrice = ''
// this.editForm.goodsStock = ''
let { selectedProInfo } = this
this.handleSingleSelectClose()
if (selectedProInfo) {
selectedProInfo.map((e, index) => {
this.editForm.activityPrice[index] = ''
this.editForm.goodsStock[index] = ''
if (list) {
list.map((e, index) => {
if (!selectedProInfo.length) {
this.editForm.activityPrice[index] = ''
this.editForm.crowdFundingPrice[index] = ''
this.editForm.goodsStock[index] = ''
}
})
// 多选 this.editForm.goodsId = selectedProInfo.id
// this.getGoodInfo(selectedProInfo.id)
this.selectedProInfo = selectedProInfo || []
this.selectedProInfo = list || []
}
},
handleSingleSelectClose (isCancel = false) {
......@@ -3433,4 +3446,14 @@ export default {
margin-top: 10px;
}
}
.el-input input::-webkit-outer-spin-button,
.el-input input::-webkit-inner-spin-button {
-webkit-appearance: none !important;
}
.el-input input[type='number'] {
-moz-appearance: textfield;
}
.el-input .el-input__inner {
line-height: 1 !important;
}
</style>
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!