|
@@ -5,9 +5,17 @@
|
|
<div class="admin1">
|
|
<div class="admin1">
|
|
<el-tabs v-model="activeName">
|
|
<el-tabs v-model="activeName">
|
|
<el-tab-pane label="补录计量实绩" name="first">
|
|
<el-tab-pane label="补录计量实绩" name="first">
|
|
- <div class="admin2">
|
|
|
|
- <div class="carrier from">
|
|
|
|
- <el-form
|
|
|
|
|
|
+ <div class="switch">
|
|
|
|
+ <el-switch
|
|
|
|
+ v-model="switchValue"
|
|
|
|
+ active-text="二次过磅"
|
|
|
|
+ inactive-text="首次过磅"
|
|
|
|
+ @change = "onchange">
|
|
|
|
+ </el-switch>
|
|
|
|
+ </div>
|
|
|
|
+ <div class="admin2">
|
|
|
|
+ <div class="carrier from">
|
|
|
|
+ <el-form
|
|
:inline="true"
|
|
:inline="true"
|
|
class="demo-form-inline"
|
|
class="demo-form-inline"
|
|
label-width="80px"
|
|
label-width="80px"
|
|
@@ -40,25 +48,26 @@
|
|
</el-option>
|
|
</el-option>
|
|
</el-select>
|
|
</el-select>
|
|
</div>
|
|
</div>
|
|
- <div class="firstWeight from">
|
|
|
|
- <span class="demonstration">磅单号:</span>
|
|
|
|
|
|
+
|
|
|
|
+ <div class="poundNo from">
|
|
|
|
+ <span class="text">磅单号:</span>
|
|
<el-input v-model="poundNo"></el-input>
|
|
<el-input v-model="poundNo"></el-input>
|
|
</div>
|
|
</div>
|
|
- <div class="block">
|
|
|
|
- <span class="demonstration">首次称重时间:</span>
|
|
|
|
|
|
+ <div class="block" v-if="first">
|
|
|
|
+ <span class="text">首次称重时间:</span>
|
|
<el-date-picker
|
|
<el-date-picker
|
|
v-model="value1"
|
|
v-model="value1"
|
|
type="datetime"
|
|
type="datetime"
|
|
placeholder="选择日期时间">
|
|
placeholder="选择日期时间">
|
|
</el-date-picker>
|
|
</el-date-picker>
|
|
</div>
|
|
</div>
|
|
- <div class="firstWeight from">
|
|
|
|
- <span class="demonstration">首次称重重量(吨):</span>
|
|
|
|
|
|
+ <div class="firstWeight from " v-if="first">
|
|
|
|
+ <span class="text">首次称重重量(吨):</span>
|
|
<el-input v-model="firstWeight"></el-input>
|
|
<el-input v-model="firstWeight"></el-input>
|
|
</div>
|
|
</div>
|
|
- <div class="material from">
|
|
|
|
|
|
+ <div class="truckCalFirst from" v-if="first">
|
|
<span class="text">首次汽车衡:</span>
|
|
<span class="text">首次汽车衡:</span>
|
|
- <el-select v-model="truckCalFirst" placeholder="请选择">
|
|
|
|
|
|
+ <el-select v-model="truckCalFirst" placeholder="请选择" @change="onchange1">
|
|
<el-option
|
|
<el-option
|
|
v-for="item in truckCalFirstList"
|
|
v-for="item in truckCalFirstList"
|
|
:key="item.value"
|
|
:key="item.value"
|
|
@@ -68,21 +77,21 @@
|
|
</el-option>
|
|
</el-option>
|
|
</el-select>
|
|
</el-select>
|
|
</div>
|
|
</div>
|
|
- <div class="block">
|
|
|
|
- <span class="demonstration">二次称重时间:</span>
|
|
|
|
|
|
+ <div class="block" v-if="second">
|
|
|
|
+ <span class="text">二次称重时间:</span>
|
|
<el-date-picker
|
|
<el-date-picker
|
|
v-model="value2"
|
|
v-model="value2"
|
|
type="datetime"
|
|
type="datetime"
|
|
placeholder="选择日期时间">
|
|
placeholder="选择日期时间">
|
|
</el-date-picker>
|
|
</el-date-picker>
|
|
</div>
|
|
</div>
|
|
- <div class="firstWeight from">
|
|
|
|
- <span class="demonstration">二次称重重量(吨):</span>
|
|
|
|
|
|
+ <div class="secondWeight from" v-if="second">
|
|
|
|
+ <span class="text">二次称重重量(吨):</span>
|
|
<el-input v-model="secondWeight"></el-input>
|
|
<el-input v-model="secondWeight"></el-input>
|
|
</div>
|
|
</div>
|
|
- <div class="material from">
|
|
|
|
|
|
+ <div class="truckCalSecond from" v-if="second">
|
|
<span class="text">二次汽车衡:</span>
|
|
<span class="text">二次汽车衡:</span>
|
|
- <el-select v-model="truckCalSecond" placeholder="请选择">
|
|
|
|
|
|
+ <el-select v-model="truckCalSecond" placeholder="请选择" @change="onchange2">
|
|
<el-option
|
|
<el-option
|
|
v-for="item in truckCalSecondList"
|
|
v-for="item in truckCalSecondList"
|
|
:key="item.value"
|
|
:key="item.value"
|
|
@@ -92,8 +101,8 @@
|
|
</el-option>
|
|
</el-option>
|
|
</el-select>
|
|
</el-select>
|
|
</div>
|
|
</div>
|
|
- <div class="firstWeight from">
|
|
|
|
- <span class="demonstration">净重(吨):</span>
|
|
|
|
|
|
+ <div class="netWeight from" v-if="second">
|
|
|
|
+ <span class="text">净重(吨):</span>
|
|
<el-input v-model="netWeight"></el-input>
|
|
<el-input v-model="netWeight"></el-input>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
@@ -103,6 +112,41 @@
|
|
</div>
|
|
</div>
|
|
</el-tab-pane>
|
|
</el-tab-pane>
|
|
<el-tab-pane label="修改路段顺序" name="second">
|
|
<el-tab-pane label="修改路段顺序" name="second">
|
|
|
|
+ <div class="admin2">
|
|
|
|
+ <div class="carrier from">
|
|
|
|
+ <el-form
|
|
|
|
+ :inline="true"
|
|
|
|
+ class="demo-form-inline"
|
|
|
|
+ label-width="80px"
|
|
|
|
+ >
|
|
|
|
+ <el-form-item label="车牌号:">
|
|
|
|
+ <el-autocomplete
|
|
|
|
+ class="inline-input"
|
|
|
|
+ v-model="capacityName"
|
|
|
|
+ :fetch-suggestions="querySearchCapacity"
|
|
|
|
+ placeholder="车牌号"
|
|
|
|
+ :trigger-on-focus="false"
|
|
|
|
+ @select="handleSelectCapacity"
|
|
|
|
+ >
|
|
|
|
+ <template slot-scope="{ item }">
|
|
|
|
+ <div class="name">{{ item.capacityNumber }}</div>
|
|
|
|
+ </template>
|
|
|
|
+ </el-autocomplete>
|
|
|
|
+ </el-form-item>
|
|
|
|
+ </el-form>
|
|
|
|
+ </div>
|
|
|
|
+ <div class="poundNo from">
|
|
|
|
+ <span class="text">运输订单号:</span>
|
|
|
|
+ <el-input v-model="orderNumber" disabled></el-input>
|
|
|
|
+ </div>
|
|
|
|
+ <div class="poundNo from">
|
|
|
|
+ <span class="text">路段顺序号:</span>
|
|
|
|
+ <el-input v-model="lineQuence" @input="oninput"></el-input>
|
|
|
|
+ </div>
|
|
|
|
+ <div class="button_box">
|
|
|
|
+ <el-button type="primary" @click="updateLineSqe" :disabled = "disabled">确认</el-button>
|
|
|
|
+ </div>
|
|
|
|
+ </div>
|
|
</el-tab-pane>
|
|
</el-tab-pane>
|
|
</el-tabs>
|
|
</el-tabs>
|
|
</div>
|
|
</div>
|
|
@@ -114,6 +158,9 @@ import { toDateString } from "../app.js"
|
|
export default {
|
|
export default {
|
|
data() {
|
|
data() {
|
|
return {
|
|
return {
|
|
|
|
+ orderNumber:null,
|
|
|
|
+ first:true,
|
|
|
|
+ second:true,
|
|
activeName:"first",
|
|
activeName:"first",
|
|
capacityName:null,
|
|
capacityName:null,
|
|
stateCapacity:null,
|
|
stateCapacity:null,
|
|
@@ -131,7 +178,11 @@ export default {
|
|
truckCalFirstList:[],
|
|
truckCalFirstList:[],
|
|
truckCalSecondList:[],
|
|
truckCalSecondList:[],
|
|
truckCalFirst:null,
|
|
truckCalFirst:null,
|
|
- truckCalSecond:null
|
|
|
|
|
|
+ truckCalSecond:null,
|
|
|
|
+ switchValue:true,
|
|
|
|
+ truckCalFirstNum:null,
|
|
|
|
+ truckCalSecondNum:null,
|
|
|
|
+ lineQuence:null
|
|
};
|
|
};
|
|
},
|
|
},
|
|
created(){
|
|
created(){
|
|
@@ -139,14 +190,60 @@ export default {
|
|
mounted(){
|
|
mounted(){
|
|
this.information()
|
|
this.information()
|
|
},
|
|
},
|
|
- methods: {
|
|
|
|
- //运力弹出层
|
|
|
|
- handleSelectCapacity(item){
|
|
|
|
|
|
+ methods: {
|
|
|
|
+ updateLineSqe(){
|
|
|
|
+ let map = {
|
|
|
|
+ orderId:this.orderId,
|
|
|
|
+ orderLineSqe:this.lineQuence
|
|
|
|
+ }
|
|
|
|
+ this.axios.post("/api/v1/uc/updateLineSqe",map).then((res) =>{
|
|
|
|
+ console.log(res.data);
|
|
|
|
+ if(res.data.code == "200"){
|
|
|
|
+ this.$message.success("修改路段顺序号成功")
|
|
|
|
+ this.$router.go(-1)
|
|
|
|
+ }
|
|
|
|
+
|
|
|
|
+ })
|
|
|
|
+ },
|
|
|
|
+ oninput(){
|
|
|
|
+
|
|
|
|
+ },
|
|
|
|
+ onchange(){
|
|
|
|
+ console.log(this.switchValue)
|
|
|
|
+ console.log(typeof(this.switchValue))
|
|
|
|
+ if(this.switchValue){
|
|
|
|
+ this.first = true
|
|
|
|
+ this.second = true
|
|
|
|
+ }else{
|
|
|
|
+ this.second = false
|
|
|
|
+ }
|
|
|
|
+ },
|
|
|
|
+ onchange1(){
|
|
|
|
+ console.log(this.truckCalFirst)
|
|
|
|
+ this.truckCalFirstList.forEach(e => {
|
|
|
|
+ if(this.truckCalFirst == e.value){
|
|
|
|
+ this.truckCalFirstNum = e.label
|
|
|
|
+ }
|
|
|
|
+ });
|
|
|
|
+ },
|
|
|
|
+ onchange2(){
|
|
|
|
+ console.log(this.truckCalSecond)
|
|
|
|
+ this.truckCalSecondList.forEach(e => {
|
|
|
|
+ if(this.truckCalSecond == e.value){
|
|
|
|
+ this.truckCalSecondNum = e.label
|
|
|
|
+ }
|
|
|
|
+ });
|
|
|
|
+ },
|
|
|
|
+ //运力弹出层
|
|
|
|
+ handleSelectCapacity(item){
|
|
|
|
+ console.log(item)
|
|
this.capacityId = item.capacityId
|
|
this.capacityId = item.capacityId
|
|
this.capacityName = item.capacityNumber
|
|
this.capacityName = item.capacityNumber
|
|
this.axios.get("/api/v1/uc/getOrderNumber?capacityId=" + this.capacityId).then((res) =>{
|
|
this.axios.get("/api/v1/uc/getOrderNumber?capacityId=" + this.capacityId).then((res) =>{
|
|
if(res.data.code == "200"){
|
|
if(res.data.code == "200"){
|
|
- console.log(res.data.data)
|
|
|
|
|
|
+ console.log("----");
|
|
|
|
+ console.log(res.data)
|
|
|
|
+ console.log("----");
|
|
this.orderId = res.data.data.orderId
|
|
this.orderId = res.data.data.orderId
|
|
this.orderNumber = res.data.data.orderNumber
|
|
this.orderNumber = res.data.data.orderNumber
|
|
this.axios.get("/api/v1/uc/getMaterialIdByOrderId?orderId=" + this.orderId).then((res) =>{
|
|
this.axios.get("/api/v1/uc/getMaterialIdByOrderId?orderId=" + this.orderId).then((res) =>{
|
|
@@ -186,21 +283,53 @@ export default {
|
|
})
|
|
})
|
|
},
|
|
},
|
|
onClickConfirm(){
|
|
onClickConfirm(){
|
|
- console.log(toDateString(this.value1))
|
|
|
|
- console.log(toDateString(this.value2))
|
|
|
|
- console.log(this.firstWeight)
|
|
|
|
- console.log(this.secondWeight)
|
|
|
|
- console.log(this.netWeight)
|
|
|
|
- console.log(this.orderId)
|
|
|
|
- console.log(this.materialId)
|
|
|
|
- console.log(this.poundNo)
|
|
|
|
- let map = {
|
|
|
|
|
|
+ if(this.switchValue){
|
|
|
|
+ if(this.orderNumber==null||this.truckCalFirst==null||this.truckCalSecond==null||
|
|
|
|
+ this.firstWeight==null||this.secondWeight==null||this.netWeight==null||this.value1==null
|
|
|
|
+ ||this.value2==null||this.poundNo==null||this.materialId==null){
|
|
|
|
+ this.$message.warning("请填写所有值!!!")
|
|
|
|
+ return
|
|
|
|
+ }
|
|
|
|
+ }else{
|
|
|
|
+ if(this.orderNumber==null||this.truckCalFirst==null||
|
|
|
|
+ this.firstWeight==null||this.value1==null
|
|
|
|
+ ||this.poundNo==null||this.materialId==null){
|
|
|
|
+ this.$message.warning("请填写所有值!!!")
|
|
|
|
+ return
|
|
|
|
+ }
|
|
|
|
+ }
|
|
|
|
+ let mapFirst = {
|
|
orderNumber:this.orderNumber,
|
|
orderNumber:this.orderNumber,
|
|
-
|
|
|
|
|
|
+ resultTareCalculateNumber: this.truckCalFirstNum,
|
|
|
|
+ resultTareWeight: this.firstWeight + "",
|
|
|
|
+ resultTareWeightTime: toDateString(this.value1),
|
|
|
|
+ resultPoundNo: this.poundNo,
|
|
|
|
+ materialId: this.materialId + ""
|
|
}
|
|
}
|
|
- var array = []
|
|
|
|
- array.push(map)
|
|
|
|
- console.log(array)
|
|
|
|
|
|
+ let mapSecond = {
|
|
|
|
+ orderNumber:this.orderNumber,
|
|
|
|
+ resultTareCalculateNumber: this.truckCalFirstNum,
|
|
|
|
+ resultCrossCalculateNumber: this.truckCalSecondNum,
|
|
|
|
+ resultTareWeight: this.firstWeight + "",
|
|
|
|
+ resultCrossWeight: this.secondWeight + "",
|
|
|
|
+ resultNetWeight: this.netWeight + "",
|
|
|
|
+ resultTareWeightTime: toDateString(this.value1),
|
|
|
|
+ resultCrossWeightTime: toDateString(this.value2),
|
|
|
|
+ resultPoundNo: this.poundNo,
|
|
|
|
+ materialId: this.materialId + ""
|
|
|
|
+ }
|
|
|
|
+ var arr = []
|
|
|
|
+ if(this.switchValue){
|
|
|
|
+ arr.push(mapSecond)
|
|
|
|
+ }else{
|
|
|
|
+ arr.push(mapFirst)
|
|
|
|
+ }
|
|
|
|
+ this.axios.post("/api/v1/join/receiveTmsTruckWeightResult",arr).then((res) =>{
|
|
|
|
+ if(res.data.code == "200"){
|
|
|
|
+ this.$message.success("补录计量实绩成功")
|
|
|
|
+ this.$router.go(-1)
|
|
|
|
+ }
|
|
|
|
+ })
|
|
},
|
|
},
|
|
onClickCancel(){
|
|
onClickCancel(){
|
|
},
|
|
},
|
|
@@ -211,8 +340,16 @@ export default {
|
|
<style lang="scss">
|
|
<style lang="scss">
|
|
.admin{
|
|
.admin{
|
|
.admin1 {
|
|
.admin1 {
|
|
|
|
+
|
|
margin-top: 40px;
|
|
margin-top: 40px;
|
|
margin-left: 40px;
|
|
margin-left: 40px;
|
|
|
|
+ .switch {
|
|
|
|
+ display: flex;
|
|
|
|
+ justify-content: center;
|
|
|
|
+ align-items: center;
|
|
|
|
+ margin-top: 20px;
|
|
|
|
+ color: aqua;
|
|
|
|
+ }
|
|
.button_box {
|
|
.button_box {
|
|
display: flex;
|
|
display: flex;
|
|
justify-content: center;
|
|
justify-content: center;
|
|
@@ -220,44 +357,142 @@ export default {
|
|
width: 100%;
|
|
width: 100%;
|
|
height: 100px;
|
|
height: 100px;
|
|
}
|
|
}
|
|
- .admin2 {
|
|
|
|
-
|
|
|
|
|
|
+ .admin2 {
|
|
margin-top: 40px;
|
|
margin-top: 40px;
|
|
.from {
|
|
.from {
|
|
display: flex;
|
|
display: flex;
|
|
align-items: center;
|
|
align-items: center;
|
|
justify-content: center;
|
|
justify-content: center;
|
|
- margin-top: 5px;
|
|
|
|
|
|
+ margin-top: 20px;
|
|
margin-bottom: 20px;
|
|
margin-bottom: 20px;
|
|
}
|
|
}
|
|
|
|
+ .carrier{
|
|
|
|
+ display: flex;
|
|
|
|
+ justify-content: center;
|
|
|
|
+ align-items: center;
|
|
|
|
+ .el-form-item {
|
|
|
|
+ text-align: right;
|
|
|
|
+ }
|
|
|
|
+ .el-autocomplete{
|
|
|
|
+ width: 250px;
|
|
|
|
+ }
|
|
|
|
+ }
|
|
.material {
|
|
.material {
|
|
display: flex;
|
|
display: flex;
|
|
justify-content: center;
|
|
justify-content: center;
|
|
margin-top: 20px;
|
|
margin-top: 20px;
|
|
- margin-right: 120px;
|
|
|
|
|
|
+ margin-right: 100px;
|
|
.text {
|
|
.text {
|
|
display: inline-block;
|
|
display: inline-block;
|
|
width: 170px;
|
|
width: 170px;
|
|
text-align: right;
|
|
text-align: right;
|
|
}
|
|
}
|
|
|
|
+ .el-input {
|
|
|
|
+ width: 250px;
|
|
|
|
+ }
|
|
}
|
|
}
|
|
|
|
+ .poundNo {
|
|
|
|
+ display: flex;
|
|
|
|
+ justify-content: center;
|
|
|
|
+ align-items: center;
|
|
|
|
+ margin-top: 20px;
|
|
|
|
+ margin-right: 100px;
|
|
|
|
+ .text {
|
|
|
|
+ display: inline-block;
|
|
|
|
+ width: 170px;
|
|
|
|
+ text-align: right;
|
|
|
|
+ }
|
|
|
|
+ .el-input {
|
|
|
|
+ width: 250px;
|
|
|
|
+ }
|
|
|
|
+ }
|
|
.block {
|
|
.block {
|
|
display: flex;
|
|
display: flex;
|
|
justify-content: center;
|
|
justify-content: center;
|
|
align-items: center;
|
|
align-items: center;
|
|
|
|
+ margin-top: 20px;
|
|
|
|
+ margin-right: 100px;
|
|
|
|
+ .el-input {
|
|
|
|
+ width: 250px;
|
|
|
|
+ }
|
|
|
|
+ .text {
|
|
|
|
+ display: inline-block;
|
|
|
|
+ width: 170px;
|
|
|
|
+ text-align: right;
|
|
|
|
+ }
|
|
}
|
|
}
|
|
-
|
|
|
|
- .firstWeight {
|
|
|
|
|
|
+ .truckCalFirst {
|
|
|
|
+ display: flex;
|
|
|
|
+ justify-content: center;
|
|
|
|
+ margin-top: 20px;
|
|
|
|
+ margin-right: 100px;
|
|
|
|
+ .text {
|
|
|
|
+ display: inline-block;
|
|
|
|
+ width: 170px;
|
|
|
|
+ text-align: right;
|
|
|
|
+ }
|
|
.el-input {
|
|
.el-input {
|
|
width: 250px;
|
|
width: 250px;
|
|
- margin-right: 20px;
|
|
|
|
}
|
|
}
|
|
}
|
|
}
|
|
- .carrier{
|
|
|
|
- display: flex;
|
|
|
|
- .el-autocomplete{
|
|
|
|
|
|
+ .truckCalSecond {
|
|
|
|
+ display: flex;
|
|
|
|
+ justify-content: center;
|
|
|
|
+ margin-top: 20px;
|
|
|
|
+ margin-right: 100px;
|
|
|
|
+ .text {
|
|
|
|
+ display: inline-block;
|
|
|
|
+ width: 170px;
|
|
|
|
+ text-align: right;
|
|
|
|
+ }
|
|
|
|
+ .el-input {
|
|
|
|
+ width: 250px;
|
|
|
|
+ }
|
|
|
|
+ }
|
|
|
|
+ .secondWeight {
|
|
|
|
+ display: flex;
|
|
|
|
+ justify-content: center;
|
|
|
|
+ align-items: center;
|
|
|
|
+ margin-top: 20px;
|
|
|
|
+ margin-right: 100px;
|
|
|
|
+ .text {
|
|
|
|
+ display: inline-block;
|
|
|
|
+ width: 170px;
|
|
|
|
+ text-align: right;
|
|
|
|
+ }
|
|
|
|
+ .el-input {
|
|
width: 250px;
|
|
width: 250px;
|
|
|
|
+ }
|
|
}
|
|
}
|
|
|
|
+ .firstWeight {
|
|
|
|
+ display: flex;
|
|
|
|
+ justify-content: center;
|
|
|
|
+ align-items: center;
|
|
|
|
+ margin-top: 20px;
|
|
|
|
+ margin-right: 100px;
|
|
|
|
+ .text {
|
|
|
|
+ display: inline-block;
|
|
|
|
+ width: 170px;
|
|
|
|
+ text-align: right;
|
|
|
|
+ }
|
|
|
|
+ .el-input {
|
|
|
|
+ width: 250px;
|
|
|
|
+ }
|
|
|
|
+ }
|
|
|
|
+ .netWeight {
|
|
|
|
+ display: flex;
|
|
|
|
+ justify-content: center;
|
|
|
|
+ align-items: center;
|
|
|
|
+ margin-top: 20px;
|
|
|
|
+ margin-right: 100px;
|
|
|
|
+ .text {
|
|
|
|
+ display: inline-block;
|
|
|
|
+ width: 170px;
|
|
|
|
+ text-align: right;
|
|
|
|
+ }
|
|
|
|
+ .el-input {
|
|
|
|
+ width: 250px;
|
|
|
|
+ }
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|