bug 修复
This commit is contained in:
parent
57505f9d03
commit
1944aa9ca3
|
|
@ -52,7 +52,7 @@
|
||||||
{{ formatCurrency(row.costIndicators || '') }}
|
{{ formatCurrency(row.costIndicators || '') }}
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
<el-table-column label="所属工程" align="center" prop="proName" show-overflow-tooltip />
|
<!-- <el-table-column label="所属工程" align="center" prop="proName" show-overflow-tooltip /> -->
|
||||||
<el-table-column label="所属上级" align="center" prop="deptName" show-overflow-tooltip />
|
<el-table-column label="所属上级" align="center" prop="deptName" show-overflow-tooltip />
|
||||||
<el-table-column label="联系人" align="center" prop="linkMan" show-overflow-tooltip />
|
<el-table-column label="联系人" align="center" prop="linkMan" show-overflow-tooltip />
|
||||||
<el-table-column label="联系电话" align="center" prop="telphone" show-overflow-tooltip />
|
<el-table-column label="联系电话" align="center" prop="telphone" show-overflow-tooltip />
|
||||||
|
|
|
||||||
|
|
@ -141,7 +141,7 @@
|
||||||
v-model="row.deviceNum"
|
v-model="row.deviceNum"
|
||||||
style="width: 180px"
|
style="width: 180px"
|
||||||
placeholder="请输入数量"
|
placeholder="请输入数量"
|
||||||
@change="deviceNumChange"
|
@change="deviceNumChange(row)"
|
||||||
maxlength="9"
|
maxlength="9"
|
||||||
/>
|
/>
|
||||||
</template>
|
</template>
|
||||||
|
|
@ -332,6 +332,7 @@ export default {
|
||||||
this.title = '成套设备编辑'
|
this.title = '成套设备编辑'
|
||||||
this.addCompleteForm.completeSetName = row.wholeTypeName
|
this.addCompleteForm.completeSetName = row.wholeTypeName
|
||||||
this.addCompleteForm.mainDevice = row.deviceTypeId
|
this.addCompleteForm.mainDevice = row.deviceTypeId
|
||||||
|
this.addCompleteForm.assortDevice = ''
|
||||||
this.saveParams.id = row.id
|
this.saveParams.id = row.id
|
||||||
this.mainDeviceDisabled = true
|
this.mainDeviceDisabled = true
|
||||||
this.isEdit = true
|
this.isEdit = true
|
||||||
|
|
@ -481,10 +482,11 @@ export default {
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
// 数量输入框校验
|
// 数量输入框校验
|
||||||
deviceNumChange(val) {
|
deviceNumChange(row) {
|
||||||
let reg = /^[1-9]\d*$/
|
let reg = /^[1-9]\d*$/
|
||||||
if (!reg.test(val)) {
|
if (!reg.test(row.deviceNum)) {
|
||||||
this.$message.error('请输入大于0的正整数!')
|
this.$message.error('请输入大于0的正整数!')
|
||||||
|
row.deviceNum = 1
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
// 保存按钮
|
// 保存按钮
|
||||||
|
|
|
||||||
|
|
@ -339,12 +339,13 @@
|
||||||
type="number"
|
type="number"
|
||||||
placeholder="请输入租赁价格"
|
placeholder="请输入租赁价格"
|
||||||
maxlength="10"
|
maxlength="10"
|
||||||
|
@input="changeNum(form)"
|
||||||
/>
|
/>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
</el-col>
|
</el-col>
|
||||||
<el-col :span="12">
|
<el-col :span="12">
|
||||||
<el-form-item label="原值" prop="buyPrice">
|
<el-form-item label="原值" prop="buyPrice">
|
||||||
<el-input v-model="form.buyPrice" type="number" placeholder="请输入原值" maxlength="30" />
|
<el-input v-model="form.buyPrice" type="number" placeholder="请输入原值" maxlength="30" @input="changeNum(form)"/>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
</el-col>
|
</el-col>
|
||||||
|
|
||||||
|
|
@ -683,14 +684,14 @@ export default {
|
||||||
leasePrice: [
|
leasePrice: [
|
||||||
{
|
{
|
||||||
required: true,
|
required: true,
|
||||||
message: '内部租赁价格不能为空',
|
message: '请输入正确的内部租赁价格',
|
||||||
trigger: 'blur',
|
trigger: 'blur',
|
||||||
},
|
},
|
||||||
],
|
],
|
||||||
buyPrice: [
|
buyPrice: [
|
||||||
{
|
{
|
||||||
required: true,
|
required: true,
|
||||||
message: '原值不能为空',
|
message: '请输入正确的原值',
|
||||||
trigger: 'blur',
|
trigger: 'blur',
|
||||||
},
|
},
|
||||||
],
|
],
|
||||||
|
|
@ -834,6 +835,14 @@ export default {
|
||||||
this.queryParams.level = data.level
|
this.queryParams.level = data.level
|
||||||
this.handleQuery()
|
this.handleQuery()
|
||||||
},
|
},
|
||||||
|
changeNum(form) {
|
||||||
|
console.log('🚀 ~ changeNum ~ item:', form)
|
||||||
|
if (Number(form.leasePrice) < 0) {
|
||||||
|
form.leasePrice = 0
|
||||||
|
} else if (Number(form.buyPrice) < 0) {
|
||||||
|
form.buyPrice = 0
|
||||||
|
}
|
||||||
|
},
|
||||||
// 取消按钮
|
// 取消按钮
|
||||||
cancel() {
|
cancel() {
|
||||||
this.open = false
|
this.open = false
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue