|
@@ -714,9 +714,42 @@ export default {
|
|
|
}
|
|
|
}
|
|
|
for(var i=0; i<newObj.syShippingDetailsItemList.length; i++){
|
|
|
+ debugger
|
|
|
var rowData = newObj.syShippingDetailsItemList[i];
|
|
|
+ console.log(typeof rowData.customsDeclarationUnitPrice)
|
|
|
+ debugger
|
|
|
+ // //判断输入报关单价是否为数字
|
|
|
+ // if(isNaN(Number(rowData.customsDeclarationUnitPrice,10)) && rowData.customsDeclarationUnitPrice){
|
|
|
+ // this.$message.error('第'+(i+1)+'行报关单价必须为数字!');
|
|
|
+ // return
|
|
|
+ // }
|
|
|
+
|
|
|
+ // //判断输入发货数量是否为数字
|
|
|
+ // if(isNaN(Number(rowData.shipmentQuantity,10)) && rowData.shipmentQuantity){
|
|
|
+ // this.$message.error('第'+(i+1)+'行发货数量必须为数字!');
|
|
|
+ // return
|
|
|
+ // }
|
|
|
+
|
|
|
+ // //判断输入套装件数是否为数字
|
|
|
+ // if(isNaN(Number(rowData.numberOfSets,10)) && rowData.numberOfSets){
|
|
|
+ // this.$message.error('第'+(i+1)+'行套装件数必须为数字!');
|
|
|
+ // return
|
|
|
+ // }
|
|
|
+
|
|
|
+ // //判断输入工厂单价是否为数字
|
|
|
+ // if(isNaN(Number(rowData.factoryUnitPrice,10)) && rowData.factoryUnitPrice){
|
|
|
+ // this.$message.error('第'+(i+1)+'行工厂单价必须为数字!');
|
|
|
+ // return
|
|
|
+ // }
|
|
|
+
|
|
|
+ // //判断输入工厂单价是否为数字
|
|
|
+ // if(isNaN(Number(rowData.manualYarnUnitPrice,10)) && rowData.manualYarnUnitPrice){
|
|
|
+ // this.$message.error('手册纱单价必须为数字!');
|
|
|
+ // return
|
|
|
+ // }
|
|
|
+
|
|
|
//报关单价不超过四位小数
|
|
|
- if(!Number.isInteger(Number(rowData.customsDeclarationUnitPrice)) && rowData.customsDeclarationUnitPrice !== '' && rowData.customsDeclarationUnitPrice !== undefined){
|
|
|
+ if(!Number.isInteger(Number(rowData.customsDeclarationUnitPrice)) && rowData.customsDeclarationUnitPrice !== '' && rowData.customsDeclarationUnitPrice !== undefined){
|
|
|
console.log(rowData.customsDeclarationUnitPrice)
|
|
|
var position = rowData.customsDeclarationUnitPrice.toString().indexOf('.') + 1; //小数点的位置
|
|
|
var digit = rowData.customsDeclarationUnitPrice.toString().length - position; //小数的位数
|
|
@@ -726,11 +759,11 @@ export default {
|
|
|
}
|
|
|
}
|
|
|
|
|
|
- //发货数量必须是整数
|
|
|
- if(!Number.isInteger(Number(rowData.shipmentQuantity)) && rowData.shipmentQuantity !== '' && rowData.shipmentQuantity !== undefined){
|
|
|
- this.$message.error('第'+(i+1)+'行发货数量不为整数!');
|
|
|
- return
|
|
|
- }
|
|
|
+ // //发货数量必须是整数
|
|
|
+ // if(!Number.isInteger(Number(rowData.shipmentQuantity)) && rowData.shipmentQuantity !== '' && rowData.shipmentQuantity !== undefined){
|
|
|
+ // this.$message.error('第'+(i+1)+'行发货数量不为整数!');
|
|
|
+ // return
|
|
|
+ // }
|
|
|
//套装件数必须为整数
|
|
|
if(!Number.isInteger(Number(rowData.numberOfSets)) && rowData.numberOfSets !== '' && rowData.numberOfSets !== undefined){
|
|
|
this.$message.error('第'+(i+1)+'行套装件数不为整数!');
|