Commit 1e67e3e5 authored by dragondean@qq.com's avatar dragondean@qq.com

批量加价不能有小数

parent ab00143c
...@@ -12,7 +12,7 @@ ...@@ -12,7 +12,7 @@
<selector :disabled="approval" v-model="form.freightUnitId" :options="unitList" :label-field="$l('title')" value-field="id" defaultable class="w-100 ml-10" /> <selector :disabled="approval" v-model="form.freightUnitId" :options="unitList" :label-field="$l('title')" value-field="id" defaultable class="w-100 ml-10" />
</div> </div>
<div class="mt-10"> <div class="mt-10">
{{$t('清关费加价')}} {{$t('清关费加价')}}
<!--货币--> <!--货币-->
<selector :disabled="approval" v-model="form.clearanceCurrencyId" :options="currencyList" :label-field="$l('title')" value-field="id" defaultable class="w-100 ml-10" /> <selector :disabled="approval" v-model="form.clearanceCurrencyId" :options="currencyList" :label-field="$l('title')" value-field="id" defaultable class="w-100 ml-10" />
<!--金额--> <!--金额-->
...@@ -273,9 +273,8 @@ export default { ...@@ -273,9 +273,8 @@ export default {
methods:{ methods:{
// 检查正数 // 检查正数
checkPositive(object, field){ checkPositive(object, field){
object[field] = parseInt(object[field]) object[field] = parseFloat(object[field])
if(isNaN(object[field]) || object[field] < 0) object[field] = '' object[field] = isNaN(object[field]) ? '' : object[field].toString()
else object[field] = object[field].toString()
}, },
// 表格多选 // 表格多选
handleSelectionChange(selection) { handleSelectionChange(selection) {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment