Showing
1 changed file
with
48 additions
and
9 deletions
| ... | @@ -6,17 +6,30 @@ | ... | @@ -6,17 +6,30 @@ |
| 6 | label-width="200px" | 6 | label-width="200px" |
| 7 | size="small" | 7 | size="small" |
| 8 | :disabled="disable" | 8 | :disabled="disable" |
| 9 | + :rules="rules" | ||
| 9 | > | 10 | > |
| 10 | - <el-form-item label="航班号"> | 11 | + <el-form-item label="航班号" prop="purposeOfFlightNo"> |
| 11 | <el-input | 12 | <el-input |
| 12 | v-model="form.purposeOfFlightNo" | 13 | v-model="form.purposeOfFlightNo" |
| 13 | style="width: 30%" | 14 | style="width: 30%" |
| 14 | ></el-input> | 15 | ></el-input> |
| 15 | </el-form-item> | 16 | </el-form-item> |
| 16 | 17 | ||
| 18 | + <el-form-item style="width: 40%"> | ||
| 19 | + <el-alert | ||
| 20 | + title="提示:站点之间用回车符分隔" | ||
| 21 | + type="warning" | ||
| 22 | + show-icon | ||
| 23 | + size="small" | ||
| 24 | + :closable="false" | ||
| 25 | + style="height: 30px" | ||
| 26 | + > | ||
| 27 | + </el-alert> | ||
| 28 | + </el-form-item> | ||
| 17 | <el-row :gutter="20"> | 29 | <el-row :gutter="20"> |
| 18 | <el-col :span="10"> | 30 | <el-col :span="10"> |
| 19 | <el-form-item label="站点包含"> | 31 | <el-form-item label="站点包含"> |
| 32 | + <!-- <el-alert title="提示:站点之间用回车符分隔" type="info" show-icon size="small" :closable="false" style="height:30px; margin-buttom"> </el-alert> --> | ||
| 20 | <el-input | 33 | <el-input |
| 21 | type="textarea" | 34 | type="textarea" |
| 22 | v-model="form.location" | 35 | v-model="form.location" |
| ... | @@ -37,6 +50,17 @@ | ... | @@ -37,6 +50,17 @@ |
| 37 | </el-col> | 50 | </el-col> |
| 38 | </el-row> | 51 | </el-row> |
| 39 | 52 | ||
| 53 | + <el-form-item style="width: 40%"> | ||
| 54 | + <el-alert | ||
| 55 | + title="提示:URSA之间用分号分隔,例:F2;F3;P_" | ||
| 56 | + type="warning" | ||
| 57 | + show-icon | ||
| 58 | + size="small" | ||
| 59 | + :closable="false" | ||
| 60 | + style="height: 30px" | ||
| 61 | + > | ||
| 62 | + </el-alert> | ||
| 63 | + </el-form-item> | ||
| 40 | <el-row :gutter="20"> | 64 | <el-row :gutter="20"> |
| 41 | <el-col :span="10"> | 65 | <el-col :span="10"> |
| 42 | <el-form-item label="URSA包含"> | 66 | <el-form-item label="URSA包含"> |
| ... | @@ -86,6 +110,7 @@ | ... | @@ -86,6 +110,7 @@ |
| 86 | :precision="0" | 110 | :precision="0" |
| 87 | :controls="false" | 111 | :controls="false" |
| 88 | style="width: 100%" | 112 | style="width: 100%" |
| 113 | + :min="form.minNumOfPieces + 1" | ||
| 89 | ></el-input-number> | 114 | ></el-input-number> |
| 90 | </el-col> | 115 | </el-col> |
| 91 | </el-form-item> | 116 | </el-form-item> |
| ... | @@ -104,6 +129,7 @@ | ... | @@ -104,6 +129,7 @@ |
| 104 | style="width: 100%" | 129 | style="width: 100%" |
| 105 | ></el-input-number> | 130 | ></el-input-number> |
| 106 | </el-col> | 131 | </el-col> |
| 132 | + <el-col :span="1" style="text-align: center"><span>Kg</span></el-col> | ||
| 107 | <el-col style="text-align: center" :span="1">-</el-col> | 133 | <el-col style="text-align: center" :span="1">-</el-col> |
| 108 | <el-col :span="3"> | 134 | <el-col :span="3"> |
| 109 | <!-- <el-input v-model="form.maxWeight"></el-input> --> | 135 | <!-- <el-input v-model="form.maxWeight"></el-input> --> |
| ... | @@ -116,12 +142,14 @@ | ... | @@ -116,12 +142,14 @@ |
| 116 | :precision="2" | 142 | :precision="2" |
| 117 | :controls="false" | 143 | :controls="false" |
| 118 | style="width: 100%" | 144 | style="width: 100%" |
| 145 | + :min="form.minWeight + 0.01" | ||
| 119 | ></el-input-number> | 146 | ></el-input-number> |
| 120 | </el-col> | 147 | </el-col> |
| 148 | + <el-col :span="1" style="text-align: center"><span>Kg</span></el-col> | ||
| 121 | </el-form-item> | 149 | </el-form-item> |
| 122 | 150 | ||
| 123 | <el-form-item label="申报类别"> | 151 | <el-form-item label="申报类别"> |
| 124 | - <el-card shadow="never" style="width:70%"> | 152 | + <el-card shadow="never" style="width: 70%"> |
| 125 | <el-checkbox-group v-model="form.typeOfGoods"> | 153 | <el-checkbox-group v-model="form.typeOfGoods"> |
| 126 | <el-checkbox | 154 | <el-checkbox |
| 127 | v-for="item in cargoType" | 155 | v-for="item in cargoType" |
| ... | @@ -134,7 +162,7 @@ | ... | @@ -134,7 +162,7 @@ |
| 134 | </el-form-item> | 162 | </el-form-item> |
| 135 | 163 | ||
| 136 | <el-form-item label="货物类型"> | 164 | <el-form-item label="货物类型"> |
| 137 | - <el-card shadow="never" style="width:70%"> | 165 | + <el-card shadow="never" style="width: 70%"> |
| 138 | <el-checkbox-group v-model="form.declarationCategory"> | 166 | <el-checkbox-group v-model="form.declarationCategory"> |
| 139 | <el-checkbox | 167 | <el-checkbox |
| 140 | v-for="item in cargoStatus" | 168 | v-for="item in cargoStatus" |
| ... | @@ -147,7 +175,7 @@ | ... | @@ -147,7 +175,7 @@ |
| 147 | </el-form-item> | 175 | </el-form-item> |
| 148 | 176 | ||
| 149 | <el-form-item label="Service Code"> | 177 | <el-form-item label="Service Code"> |
| 150 | - <el-card shadow="never" style="width:70%"> | 178 | + <el-card shadow="never" style="width: 70%"> |
| 151 | <el-checkbox-group v-model="form.serviceCode"> | 179 | <el-checkbox-group v-model="form.serviceCode"> |
| 152 | <el-checkbox | 180 | <el-checkbox |
| 153 | v-for="item in serviceCode" | 181 | v-for="item in serviceCode" |
| ... | @@ -160,7 +188,7 @@ | ... | @@ -160,7 +188,7 @@ |
| 160 | </el-form-item> | 188 | </el-form-item> |
| 161 | 189 | ||
| 162 | <el-form-item label="Sub Category"> | 190 | <el-form-item label="Sub Category"> |
| 163 | - <el-card shadow="never" style="width:70%"> | 191 | + <el-card shadow="never" style="width: 70%"> |
| 164 | <el-checkbox-group v-model="form.subCategory"> | 192 | <el-checkbox-group v-model="form.subCategory"> |
| 165 | <el-checkbox | 193 | <el-checkbox |
| 166 | v-for="item in subCategory" | 194 | v-for="item in subCategory" |
| ... | @@ -177,7 +205,7 @@ | ... | @@ -177,7 +205,7 @@ |
| 177 | type="primary" | 205 | type="primary" |
| 178 | size="small" | 206 | size="small" |
| 179 | v-if="$route.params.handle != 'detail'" | 207 | v-if="$route.params.handle != 'detail'" |
| 180 | - @click="submit" | 208 | + @click="submit('form')" |
| 181 | :loading="btnLoading" | 209 | :loading="btnLoading" |
| 182 | > | 210 | > |
| 183 | <span v-if="$route.params.handle === 'add'">添加</span> | 211 | <span v-if="$route.params.handle === 'add'">添加</span> |
| ... | @@ -204,6 +232,11 @@ export default { | ... | @@ -204,6 +232,11 @@ export default { |
| 204 | serviceCode: [], | 232 | serviceCode: [], |
| 205 | subCategory: [], | 233 | subCategory: [], |
| 206 | }, | 234 | }, |
| 235 | + rules: { | ||
| 236 | + purposeOfFlightNo: [ | ||
| 237 | + { required: true, message: "请输入航班号", trigger: "blur" }, | ||
| 238 | + ], | ||
| 239 | + }, | ||
| 207 | typeOfGoods: [], | 240 | typeOfGoods: [], |
| 208 | declarationCategory: [], | 241 | declarationCategory: [], |
| 209 | formServiceCode: [], | 242 | formServiceCode: [], |
| ... | @@ -218,7 +251,13 @@ export default { | ... | @@ -218,7 +251,13 @@ export default { |
| 218 | }; | 251 | }; |
| 219 | }, | 252 | }, |
| 220 | methods: { | 253 | methods: { |
| 221 | - submit() { | 254 | + submit(form) { |
| 255 | + this.$refs[form].validate((valid) => { | ||
| 256 | + if (!valid) { | ||
| 257 | + return false; | ||
| 258 | + } | ||
| 259 | + }); | ||
| 260 | + | ||
| 222 | this.btnLoading = true; | 261 | this.btnLoading = true; |
| 223 | let handle = this.$route.params.handle; | 262 | let handle = this.$route.params.handle; |
| 224 | if (handle === "update") { | 263 | if (handle === "update") { |
| ... | @@ -340,8 +379,8 @@ export default { | ... | @@ -340,8 +379,8 @@ export default { |
| 340 | .el-checkbox__input.is-disabled.is-checked .el-checkbox__inner::after { | 379 | .el-checkbox__input.is-disabled.is-checked .el-checkbox__inner::after { |
| 341 | border-color: #303133; | 380 | border-color: #303133; |
| 342 | } | 381 | } |
| 343 | -.el-checkbox__input.is-disabled.is-checked .el-checkbox__inner{ | 382 | +.el-checkbox__input.is-disabled.is-checked .el-checkbox__inner { |
| 344 | - border-color: #606266 | 383 | + border-color: #606266; |
| 345 | } | 384 | } |
| 346 | </style> | 385 | </style> |
| 347 | 386 | ... | ... |
-
Please register or login to post a comment