|
|
@@ -5,7 +5,7 @@ import {
|
|
|
Page({
|
|
|
data: {
|
|
|
id: '',
|
|
|
- tab: 1,
|
|
|
+ tab: 4,
|
|
|
shipDischargeCurrentPage: 1,
|
|
|
truckLoadCurrentPage: 1,
|
|
|
coordinates: [],
|
|
|
@@ -29,6 +29,7 @@ Page({
|
|
|
pageSize: 20,
|
|
|
latitude: 31.891992,
|
|
|
longitude: 120.551369,
|
|
|
+ currentPortId: 0
|
|
|
},
|
|
|
changeTab(e) {
|
|
|
let {
|
|
|
@@ -102,7 +103,10 @@ Page({
|
|
|
policys,
|
|
|
voyage,
|
|
|
waybills,
|
|
|
+ currentPortId: voyage?.voyageDetails[0].portId
|
|
|
})
|
|
|
+ this.getCarLoadRecordList()
|
|
|
+ this.getDischargeList()
|
|
|
},
|
|
|
subTimeStr(str) {
|
|
|
if (!str || typeof str != "string") return;
|
|
|
@@ -118,6 +122,7 @@ Page({
|
|
|
this.data.truckLoadCurrentPage = 1
|
|
|
}
|
|
|
let res = await postApi("/voyage/getCarLoadRecordList", {
|
|
|
+ portId: this.data.currentPortId,
|
|
|
voyageId: this.data.id,
|
|
|
size: this.data.pageSize,
|
|
|
currentPage: this.data.truckLoadCurrentPage,
|
|
|
@@ -164,6 +169,7 @@ Page({
|
|
|
this.data.shipDischargeCurrentPage = 1
|
|
|
}
|
|
|
let res = await postApi("/voyage/getDischargeList", {
|
|
|
+ portId: this.data.currentPortId,
|
|
|
voyageId: this.data.id,
|
|
|
size: this.data.pageSize,
|
|
|
currentPage: this.data.shipDischargeCurrentPage,
|
|
|
@@ -254,6 +260,19 @@ Page({
|
|
|
this.getCarLoadRecordList(true)
|
|
|
},
|
|
|
|
|
|
+ changePort(e) {
|
|
|
+ let currentPortId = e.target.dataset.id
|
|
|
+ this.setData({
|
|
|
+ currentPortId
|
|
|
+ })
|
|
|
+ if (this.data.infoType == "ship") {
|
|
|
+ this.getDischargeList()
|
|
|
+ } else {
|
|
|
+ this.getCarLoadRecordList()
|
|
|
+ }
|
|
|
+
|
|
|
+ },
|
|
|
+
|
|
|
|
|
|
onShareAppMessage() {
|
|
|
let id = wx.getStorageSync('voyageDetailId')
|
|
|
@@ -273,7 +292,6 @@ Page({
|
|
|
id
|
|
|
})
|
|
|
this.getVoyageDetail()
|
|
|
- this.getCarLoadRecordList()
|
|
|
- this.getDischargeList()
|
|
|
+
|
|
|
},
|
|
|
})
|