zhangyuewww 3 years ago
parent
commit
ef3b2f9a5d

+ 1 - 1
src/views/tranManagement/tranManagementDriver.vue

@@ -233,7 +233,7 @@
             }}</span>
           </template>
         </el-table-column>
-        <el-table-column prop="address" label="操作" >
+        <el-table-column prop="address" label="操作" width="300" >
           <template slot-scope="scope">
             <el-button size="medium" type="text" class="record" @click="look(scope.row)"
               >查看</el-button

+ 13 - 27
src/views/warehouse/warehouseManagementDelivery.vue

@@ -676,21 +676,14 @@ export default {
           return
         }
         if (
-          this.deptBudgetList.warehouseInOutDetail.bulkDensity < 1 ||
-          this.deptBudgetList.warehouseInOutDetail.bulkDensity > 40 ||
-          (String(this.deptBudgetList.warehouseInOutDetail.bulkDensity).indexOf(
-            '.'
-          ) != -1 &&
-            String(this.deptBudgetList.warehouseInOutDetail.bulkDensity)
-              .length -
-              (String(
-                this.deptBudgetList.warehouseInOutDetail.bulkDensity
-              ).indexOf('.') +
-                1) >
-              0)
+          (this.deptBudgetList.warehouseInOutDetail.bulkDensity &&
+            String(this.deptBudgetList.warehouseInOutDetail.bulkDensity).indexOf('.') != -1 &&
+            String(this.deptBudgetList.warehouseInOutDetail.bulkDensity).length -
+              (String(this.deptBudgetList.warehouseInOutDetail.bulkDensity).indexOf('.') + 1) >
+              2) || this.deptBudgetList.warehouseInOutDetail.bulkDensity > 1000 || this.deptBudgetList.warehouseInOutDetail.bulkDensity < 0
         ) {
           this.$message({
-            message: '容重(克/升)输入错误! 取值范围1-40之间且是整数',
+            message: '容重输入错误',
             type: 'warning',
           })
           return
@@ -1037,22 +1030,15 @@ export default {
           })
           return
         }
-        if (
-          this.deptBudgetList.warehouseInOutDetail.bulkDensity < 1 ||
-          this.deptBudgetList.warehouseInOutDetail.bulkDensity > 40 ||
-          (String(this.deptBudgetList.warehouseInOutDetail.bulkDensity).indexOf(
-            '.'
-          ) != -1 &&
-            String(this.deptBudgetList.warehouseInOutDetail.bulkDensity)
-              .length -
-              (String(
-                this.deptBudgetList.warehouseInOutDetail.bulkDensity
-              ).indexOf('.') +
-                1) >
-              0)
+          if (
+          (this.deptBudgetList.warehouseInOutDetail.bulkDensity &&
+            String(this.deptBudgetList.warehouseInOutDetail.bulkDensity).indexOf('.') != -1 &&
+            String(this.deptBudgetList.warehouseInOutDetail.bulkDensity).length -
+              (String(this.deptBudgetList.warehouseInOutDetail.bulkDensity).indexOf('.') + 1) >
+              2) || this.deptBudgetList.warehouseInOutDetail.bulkDensity > 1000 || this.deptBudgetList.warehouseInOutDetail.bulkDensity < 0
         ) {
           this.$message({
-            message: '容重(克/升)输入错误! 取值范围1-40之间且是整数',
+            message: '容重输入错误',
             type: 'warning',
           })
           return

+ 5 - 11
src/views/warehouse/warehouseManagementPerfectDelivery.vue

@@ -760,20 +760,14 @@ export default {
           return
         }
         if (
-          this.dataList.warehouseInOutDetail.bulkDensity < 1 ||
-          this.dataList.warehouseInOutDetail.bulkDensity > 40 ||
-          (String(this.dataList.warehouseInOutDetail.bulkDensity).indexOf(
-            '.'
-          ) != -1 &&
+          (this.dataList.warehouseInOutDetail.bulkDensity &&
+            String(this.dataList.warehouseInOutDetail.bulkDensity).indexOf('.') != -1 &&
             String(this.dataList.warehouseInOutDetail.bulkDensity).length -
-              (String(this.dataList.warehouseInOutDetail.bulkDensity).indexOf(
-                '.'
-              ) +
-                1) >
-              0)
+              (String(this.dataList.warehouseInOutDetail.bulkDensity).indexOf('.') + 1) >
+              2) || this.dataList.warehouseInOutDetail.bulkDensity > 1000 || this.dataList.warehouseInOutDetail.bulkDensity < 0
         ) {
           this.$message({
-            message: '容重(克/升)输入错误! 取值范围1-40之间且是整数',
+            message: '容重输入错误',
             type: 'warning',
           })
           return

+ 5 - 11
src/views/warehouse/warehouseManagementPerfectput.vue

@@ -811,20 +811,14 @@ export default {
           return
         }
         if (
-          this.dataList.warehouseInOutDetail.bulkDensity < 1 ||
-          this.dataList.warehouseInOutDetail.bulkDensity > 40 ||
-          (String(this.dataList.warehouseInOutDetail.bulkDensity).indexOf(
-            '.'
-          ) != -1 &&
+          (this.dataList.warehouseInOutDetail.bulkDensity &&
+            String(this.dataList.warehouseInOutDetail.bulkDensity).indexOf('.') != -1 &&
             String(this.dataList.warehouseInOutDetail.bulkDensity).length -
-              (String(this.dataList.warehouseInOutDetail.bulkDensity).indexOf(
-                '.'
-              ) +
-                1) >
-              0)
+              (String(this.dataList.warehouseInOutDetail.bulkDensity).indexOf('.') + 1) >
+              2) || this.dataList.warehouseInOutDetail.bulkDensity > 1000 || this.dataList.warehouseInOutDetail.bulkDensity < 0
         ) {
           this.$message({
-            message: '容重(克/升)输入错误! 取值范围1-40之间且是整数',
+            message: '容重输入错误',
             type: 'warning',
           })
           return

+ 14 - 28
src/views/warehouse/warehouseManagementPut.vue

@@ -733,22 +733,15 @@ export default {
           return
         }
         if (
-          this.deptBudgetList.warehouseInOutDetail.bulkDensity < 1 ||
-          this.deptBudgetList.warehouseInOutDetail.bulkDensity > 40 ||
-          (String(this.deptBudgetList.warehouseInOutDetail.bulkDensity).indexOf(
-            '.'
-          ) != -1 &&
-            String(this.deptBudgetList.warehouseInOutDetail.bulkDensity)
-              .length -
-              (String(
-                this.deptBudgetList.warehouseInOutDetail.bulkDensity
-              ).indexOf('.') +
-                1) >
-              0)
+          (this.deptBudgetList.warehouseInOutDetail.bulkDensity &&
+            String(this.deptBudgetList.warehouseInOutDetail.bulkDensity).indexOf('.') != -1 &&
+            String(this.deptBudgetList.warehouseInOutDetail.bulkDensity).length -
+              (String(this.deptBudgetList.warehouseInOutDetail.bulkDensity).indexOf('.') + 1) >
+              2) || this.deptBudgetList.warehouseInOutDetail.bulkDensity > 1000 || this.deptBudgetList.warehouseInOutDetail.bulkDensity < 0
         ) {
           this.$message({
-            message: '容重(克/升)输入错误! 取值范围1-40之间且是整数',
-            type: 'warning'
+            message: '容重输入错误',
+            type: 'warning',
           })
           return
         }
@@ -1062,22 +1055,15 @@ export default {
           return
         }
         if (
-          this.deptBudgetList.warehouseInOutDetail.bulkDensity < 1 ||
-          this.deptBudgetList.warehouseInOutDetail.bulkDensity > 40 ||
-          (String(this.deptBudgetList.warehouseInOutDetail.bulkDensity).indexOf(
-            '.'
-          ) != -1 &&
-            String(this.deptBudgetList.warehouseInOutDetail.bulkDensity)
-              .length -
-              (String(
-                this.deptBudgetList.warehouseInOutDetail.bulkDensity
-              ).indexOf('.') +
-                1) >
-              0)
+          (this.deptBudgetList.warehouseInOutDetail.bulkDensity &&
+            String(this.deptBudgetList.warehouseInOutDetail.bulkDensity).indexOf('.') != -1 &&
+            String(this.deptBudgetList.warehouseInOutDetail.bulkDensity).length -
+              (String(this.deptBudgetList.warehouseInOutDetail.bulkDensity).indexOf('.') + 1) >
+              2) || this.deptBudgetList.warehouseInOutDetail.bulkDensity > 1000 || this.deptBudgetList.warehouseInOutDetail.bulkDensity < 0
         ) {
           this.$message({
-            message: '容重(克/升)输入错误! 取值范围1-40之间且是整数',
-            type: 'warning'
+            message: '容重输入错误',
+            type: 'warning',
           })
           return
         }