|
@@ -107,7 +107,7 @@
|
|
|
</vxe-column>
|
|
|
</vxe-table>
|
|
|
<div class="button-box">
|
|
|
- <el-button type="primary" @click="makeSure">确认分解</el-button>
|
|
|
+ <el-button type="primary" @click="makeSure" :disabled = "disabled">确认分解</el-button>
|
|
|
<el-button type="primary" @click="cancel">返回</el-button>
|
|
|
</div>
|
|
|
</div>
|
|
@@ -122,6 +122,7 @@ export default {
|
|
|
},
|
|
|
data() {
|
|
|
return {
|
|
|
+ disabled:false,
|
|
|
truckText:null,
|
|
|
shiyHeigth:140,
|
|
|
isHeigth:true,
|
|
@@ -188,13 +189,35 @@ export default {
|
|
|
};
|
|
|
},
|
|
|
created(){
|
|
|
- this.userCarrierId = getCookie("userId")
|
|
|
- this.second.requestUrl = "/api/v1/oms/getCapacityAndDriverList?apiId=246"
|
|
|
+ if (getCookie("orgCode") == "chengyunshang") {
|
|
|
+ this.second.requestUrl =
|
|
|
+ "/api/v1/uc/getAllCapacityByCarrierLike?apiId=248&carrierSsoId=" +
|
|
|
+ getCookie("userId");
|
|
|
+ } else if(getCookie("orgCode") == "wuliuchuyunzhongxin"){
|
|
|
+ this.second.requestUrl =
|
|
|
+ "/api/v1/uc/getAllCapacityByCarrierLike?apiId=248&carrierSsoId=" + null + "&con="+"物流储运中心";
|
|
|
+ }else {
|
|
|
+ this.second.requestUrl =
|
|
|
+ "/api/v1/uc/getAllCapacityByCarrierLike?apiId=248&carrierSsoId=" + null
|
|
|
+ }
|
|
|
},
|
|
|
mounted(){
|
|
|
this.information()
|
|
|
},
|
|
|
methods: {
|
|
|
+ getInwardRequestUrl(){
|
|
|
+ if (getCookie("orgCode") == "chengyunshang") {
|
|
|
+ this.second.requestUrl =
|
|
|
+ "/api/v1/uc/getAllCapacityByCarrierLike?apiId=248&carrierSsoId=" +
|
|
|
+ getCookie("userId") + "&i=" + new Date();
|
|
|
+ } else if(getCookie("orgCode") == "wuliuchuyunzhongxin"){
|
|
|
+ this.second.requestUrl =
|
|
|
+ "/api/v1/uc/getAllCapacityByCarrierLike?apiId=248&carrierSsoId=" + null + "&con="+"物流储运中心" + "&i=" + new Date();
|
|
|
+ }else {
|
|
|
+ this.second.requestUrl =
|
|
|
+ "/api/v1/uc/getAllCapacityByCarrierLike?apiId=248&carrierSsoId=" + null + "&i=" + new Date();
|
|
|
+ }
|
|
|
+ },
|
|
|
getRequirementMaterial(row) {
|
|
|
// 记录重复点击次数
|
|
|
if (this.oldRow === row) {
|
|
@@ -226,10 +249,10 @@ export default {
|
|
|
this.tableData1 = res.data.data
|
|
|
})
|
|
|
},
|
|
|
- drawerCapacity(){
|
|
|
+ drawerCapacity(){
|
|
|
+ this.getInwardRequestUrl()
|
|
|
this.drawer = true;
|
|
|
- //重新初始化
|
|
|
- this.second.requestUrl = "/api/v1/uc/getAllCapacityByCarrierLike?apiId=429&carrierSsoId=" + null + "&i=" + new Date();
|
|
|
+ //重新初始化
|
|
|
},
|
|
|
onConfirm(){
|
|
|
console.log(this.mapList1)
|
|
@@ -244,7 +267,6 @@ export default {
|
|
|
this.linedrawer = true
|
|
|
},
|
|
|
onclick(){
|
|
|
- console.log(this.truckText,"truckText")
|
|
|
if(this.truckText != null){
|
|
|
this.second.requestUrl = "/api/v1/uc/getAllCapacityByCarrierLike?apiId=429&carrierSsoId="+this.input +"&carrierId=" + getCookie('userId') + "&index=" + this.truckText;
|
|
|
}else{
|
|
@@ -309,9 +331,11 @@ export default {
|
|
|
},
|
|
|
// 修改
|
|
|
makeSure() {
|
|
|
+ this.disabled = true
|
|
|
for(var i=0;i<this.$refs.xTable.getInsertRecords().length;i++){
|
|
|
if(this.$refs.xTable.getInsertRecords()[i].capacityNumber == null){
|
|
|
this.$alert('未选择车牌,请选择车牌')
|
|
|
+ this.disabled = false
|
|
|
return
|
|
|
}
|
|
|
}
|
|
@@ -333,6 +357,7 @@ export default {
|
|
|
|
|
|
} else {
|
|
|
this.$message.error("分解失败!");
|
|
|
+ this.disabled = false
|
|
|
}
|
|
|
});
|
|
|
},
|