绑定下拉数据
parent
a729731716
commit
96f8e07a89
|
@ -15,6 +15,8 @@ module.exports = {
|
||||||
this.createMafiListRespList()
|
this.createMafiListRespList()
|
||||||
this.createSafetyInspectionRespList()
|
this.createSafetyInspectionRespList()
|
||||||
this.createShipmentShipLoadPlansRespList()
|
this.createShipmentShipLoadPlansRespList()
|
||||||
|
this.createShipmentShipManage()
|
||||||
|
this.createShipOption()
|
||||||
},
|
},
|
||||||
// 创建人员信息 messageRespList
|
// 创建人员信息 messageRespList
|
||||||
createMessageRespList() {
|
createMessageRespList() {
|
||||||
|
@ -79,15 +81,26 @@ module.exports = {
|
||||||
},
|
},
|
||||||
// 创建作业查询 shipmentShipLoadPlansRespList
|
// 创建作业查询 shipmentShipLoadPlansRespList
|
||||||
createShipmentShipLoadPlansRespList() {
|
createShipmentShipLoadPlansRespList() {
|
||||||
console.log("创建作业查询表");
|
|
||||||
let sql =
|
let sql =
|
||||||
'CREATE TABLE if not exists shipmentShipLoadPlansRespList ("webId" text NOT NULL,"agentId" text,"agentName" text,"amount" text,"brdId" text,"brdName" text,"bvdId" text,"bvdName" text,"bvmId" text,"bvmName" text,"carHeight" text,"carLength" text,"carWidth" text,"customsDeclareNo" text,"customsDeclareStatus" text,"mnfBl" text,"potId" text,"potName" text,"sourceType" text,"vvyId" text,"vvyName" text,"yardPos" text,"webStatus" text,"webDate" text, PRIMARY KEY("webId"));'
|
'CREATE TABLE if not exists shipmentShipLoadPlansRespList ("webId" text NOT NULL,"agentId" text,"agentName" text,"amount" text,"brdId" text,"brdName" text,"bvdId" text,"bvdName" text,"bvmId" text,"bvmName" text,"carHeight" text,"carLength" text,"carWidth" text,"customsDeclareNo" text,"customsDeclareStatus" text,"mnfBl" text,"potId" text,"potName" text,"sourceType" text,"vvyId" text,"vvyName" text,"yardPos" text,"webStatus" text,"webDate" text, PRIMARY KEY("webId"));'
|
||||||
this.executeSql(sql)
|
this.executeSql(sql)
|
||||||
},
|
},
|
||||||
|
// 创建船舶资料 shipmentShipManage
|
||||||
|
createShipmentShipManage() {
|
||||||
|
let sql =
|
||||||
|
'CREATE TABLE if not exists shipmentShipManage ("webId" text NOT NULL,"vslCd" text,"vslCnname" text,"vslGton" text,"vslNetton" text,"vslLoa" text,"vslBreadth" text,"vslDraftunload" text,"vslDraftload" text,"spmCabinht" text,"spmMintide" text,"spmCab" text,"spmBoardCentrele" text,"spmBoardFrontle" text,"spmBoardLaterle" text,"spmBoardCentrerg" text,"spmBoardFrontrg" text,"spmBoardLaterrg" text,"webStatus" text,"webDate" text, PRIMARY KEY("webId"));'
|
||||||
|
this.executeSql(sql)
|
||||||
|
},
|
||||||
|
// 创建下拉数据 shipOption
|
||||||
|
createShipOption() {
|
||||||
|
let sql =
|
||||||
|
'CREATE TABLE if not exists shipOption ("dictionariesName" text,"ptrCode" text,"ptrDesc" text,"webId" text NOT NULL,"webStatus" text,"webDate" text, PRIMARY KEY("webId"));'
|
||||||
|
this.executeSql(sql)
|
||||||
|
},
|
||||||
executeSql(sql) {
|
executeSql(sql) {
|
||||||
sqlite.executeSqlCeshi(sql).then((value) => {
|
sqlite.executeSqlCeshi(sql).then((value) => {
|
||||||
// 在resolve时执行的回调函数
|
// 在resolve时执行的回调函数
|
||||||
console.log(value);
|
// console.log(value);
|
||||||
}).catch((error) => {
|
}).catch((error) => {
|
||||||
// 在reject时执行的回调函数
|
// 在reject时执行的回调函数
|
||||||
console.error(error);
|
console.error(error);
|
||||||
|
|
|
@ -118,25 +118,17 @@ module.exports = {
|
||||||
// 判断有没有传参
|
// 判断有没有传参
|
||||||
if (dbTable !== undefined && data !== undefined) {
|
if (dbTable !== undefined && data !== undefined) {
|
||||||
// 判断传的参是否有值
|
// 判断传的参是否有值
|
||||||
var bol = (JSON.stringify(data) == "{}");
|
var bol = (data == "");
|
||||||
if (!bol) {
|
if (!bol) {
|
||||||
if (condition == undefined) {
|
if (condition == undefined) {
|
||||||
var sql = `INSERT INTO ${dbTable} VALUES('${data}')`;
|
var sql = `INSERT INTO ${dbTable} VALUES(${data})`;
|
||||||
|
// console.log(sql);
|
||||||
} else {
|
} else {
|
||||||
var sql = `INSERT INTO ${dbTable} (${condition}) VALUES(${data})`;
|
var sql = `INSERT INTO ${dbTable} (${condition}) VALUES(${data})`;
|
||||||
}
|
}
|
||||||
|
// console.log(sql);
|
||||||
return new Promise((resolve, reject) => {
|
return new Promise((resolve, reject) => {
|
||||||
// 表格添加数据
|
resolve(sql)
|
||||||
plus.sqlite.executeSql({
|
|
||||||
name: this.dbName,
|
|
||||||
sql: sql,
|
|
||||||
success(e) {
|
|
||||||
resolve(e);
|
|
||||||
},
|
|
||||||
fail(e) {
|
|
||||||
reject(e);
|
|
||||||
}
|
|
||||||
})
|
|
||||||
})
|
})
|
||||||
} else {
|
} else {
|
||||||
return new Promise((resolve, reject) => {
|
return new Promise((resolve, reject) => {
|
||||||
|
|
101
pages.json
101
pages.json
|
@ -15,10 +15,7 @@
|
||||||
{
|
{
|
||||||
"path": "pages/index/instruct",
|
"path": "pages/index/instruct",
|
||||||
"style": {
|
"style": {
|
||||||
"navigationBarTitleText": "指令",
|
"navigationBarTitleText": "指令"
|
||||||
"usingComponents": {
|
|
||||||
"van-progress": "/wxcomponents/vant/dist/progress/index"
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
|
@ -48,10 +45,7 @@
|
||||||
{
|
{
|
||||||
"path": "pages/shipWork/sign",
|
"path": "pages/shipWork/sign",
|
||||||
"style": {
|
"style": {
|
||||||
"navigationBarTitleText": "单证签名",
|
"navigationBarTitleText": "单证签名"
|
||||||
"usingComponents": {
|
|
||||||
"van-button": "/wxcomponents/vant/dist/button/index"
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
|
@ -63,28 +57,18 @@
|
||||||
{
|
{
|
||||||
"path": "pages/shipWork/peopleAdd",
|
"path": "pages/shipWork/peopleAdd",
|
||||||
"style": {
|
"style": {
|
||||||
"navigationBarTitleText": "杂项作业(人员信息)",
|
"navigationBarTitleText": "杂项作业(人员信息)"
|
||||||
"usingComponents": {
|
|
||||||
"van-button": "/wxcomponents/vant/dist/button/index"
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"path": "pages/shipWork/shiftAdd",
|
"path": "pages/shipWork/shiftAdd",
|
||||||
"style": {
|
"style": {
|
||||||
"navigationBarTitleText": "杂项作业(工班信息)",
|
"navigationBarTitleText": "杂项作业(工班信息)"
|
||||||
"usingComponents": {
|
|
||||||
"van-icon": "/wxcomponents/vant/dist/icon/index",
|
|
||||||
"van-button": "/wxcomponents/vant/dist/button/index"
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
}, {
|
}, {
|
||||||
"path": "pages/shipWork/shiftDetails",
|
"path": "pages/shipWork/shiftDetails",
|
||||||
"style": {
|
"style": {
|
||||||
"navigationBarTitleText": "杂项作业(工班信息)",
|
"navigationBarTitleText": "杂项作业(工班信息)"
|
||||||
"usingComponents": {
|
|
||||||
"van-button": "/wxcomponents/vant/dist/button/index"
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
}, {
|
}, {
|
||||||
"path": "pages/shipWork/untieCord",
|
"path": "pages/shipWork/untieCord",
|
||||||
|
@ -95,11 +79,7 @@
|
||||||
{
|
{
|
||||||
"path": "pages/shipWork/untieAdd",
|
"path": "pages/shipWork/untieAdd",
|
||||||
"style": {
|
"style": {
|
||||||
"navigationBarTitleText": "系解缆信息",
|
"navigationBarTitleText": "系解缆信息"
|
||||||
"usingComponents": {
|
|
||||||
"van-icon": "/wxcomponents/vant/dist/icon/index",
|
|
||||||
"van-button": "/wxcomponents/vant/dist/button/index"
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
|
@ -111,11 +91,7 @@
|
||||||
{
|
{
|
||||||
"path": "pages/shipWork/supplyAdd",
|
"path": "pages/shipWork/supplyAdd",
|
||||||
"style": {
|
"style": {
|
||||||
"navigationBarTitleText": "供给信息",
|
"navigationBarTitleText": "供给信息"
|
||||||
"usingComponents": {
|
|
||||||
"van-icon": "/wxcomponents/vant/dist/icon/index",
|
|
||||||
"van-button": "/wxcomponents/vant/dist/button/index"
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
|
@ -127,11 +103,7 @@
|
||||||
{
|
{
|
||||||
"path": "pages/shipWork/workAssignAdd",
|
"path": "pages/shipWork/workAssignAdd",
|
||||||
"style": {
|
"style": {
|
||||||
"navigationBarTitleText": "指导员作业布置信息",
|
"navigationBarTitleText": "指导员作业布置信息"
|
||||||
"usingComponents": {
|
|
||||||
"van-icon": "/wxcomponents/vant/dist/icon/index",
|
|
||||||
"van-button": "/wxcomponents/vant/dist/button/index"
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
}, {
|
}, {
|
||||||
"path": "pages/shipWork/notice",
|
"path": "pages/shipWork/notice",
|
||||||
|
@ -142,11 +114,7 @@
|
||||||
{
|
{
|
||||||
"path": "pages/shipWork/noticeAdd",
|
"path": "pages/shipWork/noticeAdd",
|
||||||
"style": {
|
"style": {
|
||||||
"navigationBarTitleText": "船舶装卸通知书信息",
|
"navigationBarTitleText": "船舶装卸通知书信息"
|
||||||
"usingComponents": {
|
|
||||||
"van-icon": "/wxcomponents/vant/dist/icon/index",
|
|
||||||
"van-button": "/wxcomponents/vant/dist/button/index"
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
}, {
|
}, {
|
||||||
"path": "pages/shipWork/opinion",
|
"path": "pages/shipWork/opinion",
|
||||||
|
@ -156,11 +124,7 @@
|
||||||
}, {
|
}, {
|
||||||
"path": "pages/shipWork/opinionAdd",
|
"path": "pages/shipWork/opinionAdd",
|
||||||
"style": {
|
"style": {
|
||||||
"navigationBarTitleText": "质量意见征询信息",
|
"navigationBarTitleText": "质量意见征询信息"
|
||||||
"usingComponents": {
|
|
||||||
"van-icon": "/wxcomponents/vant/dist/icon/index",
|
|
||||||
"van-button": "/wxcomponents/vant/dist/button/index"
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
}, {
|
}, {
|
||||||
"path": "pages/shipWork/abnormal",
|
"path": "pages/shipWork/abnormal",
|
||||||
|
@ -170,11 +134,7 @@
|
||||||
}, {
|
}, {
|
||||||
"path": "pages/shipWork/abnormalAdd",
|
"path": "pages/shipWork/abnormalAdd",
|
||||||
"style": {
|
"style": {
|
||||||
"navigationBarTitleText": "异常情况信息",
|
"navigationBarTitleText": "异常情况信息"
|
||||||
"usingComponents": {
|
|
||||||
"van-icon": "/wxcomponents/vant/dist/icon/index",
|
|
||||||
"van-button": "/wxcomponents/vant/dist/button/index"
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
}, {
|
}, {
|
||||||
"path": "pages/shipWork/mafi",
|
"path": "pages/shipWork/mafi",
|
||||||
|
@ -184,11 +144,7 @@
|
||||||
}, {
|
}, {
|
||||||
"path": "pages/shipWork/mafiAdd",
|
"path": "pages/shipWork/mafiAdd",
|
||||||
"style": {
|
"style": {
|
||||||
"navigationBarTitleText": "MAFI清单信息",
|
"navigationBarTitleText": "MAFI清单信息"
|
||||||
"usingComponents": {
|
|
||||||
"van-icon": "/wxcomponents/vant/dist/icon/index",
|
|
||||||
"van-button": "/wxcomponents/vant/dist/button/index"
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
}, {
|
}, {
|
||||||
"path": "pages/shipWork/patrol",
|
"path": "pages/shipWork/patrol",
|
||||||
|
@ -198,11 +154,7 @@
|
||||||
}, {
|
}, {
|
||||||
"path": "pages/shipWork/patrolAdd",
|
"path": "pages/shipWork/patrolAdd",
|
||||||
"style": {
|
"style": {
|
||||||
"navigationBarTitleText": "安全巡检信息",
|
"navigationBarTitleText": "安全巡检信息"
|
||||||
"usingComponents": {
|
|
||||||
"van-icon": "/wxcomponents/vant/dist/icon/index",
|
|
||||||
"van-button": "/wxcomponents/vant/dist/button/index"
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
}, {
|
}, {
|
||||||
"path": "pages/shipWork/shipInfo",
|
"path": "pages/shipWork/shipInfo",
|
||||||
|
@ -234,30 +186,19 @@
|
||||||
{
|
{
|
||||||
"path": "pages/monitor/edit",
|
"path": "pages/monitor/edit",
|
||||||
"style": {
|
"style": {
|
||||||
"navigationBarTitleText": "编辑货物质量",
|
"navigationBarTitleText": "编辑货物质量"
|
||||||
"usingComponents": {
|
|
||||||
"van-icon": "/wxcomponents/vant/dist/icon/index",
|
|
||||||
"van-button": "/wxcomponents/vant/dist/button/index",
|
|
||||||
"van-uploader": "/wxcomponents/vant/dist/uploader/index"
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"path": "pages/monitor/details",
|
"path": "pages/monitor/details",
|
||||||
"style": {
|
"style": {
|
||||||
"navigationBarTitleText": "质损详情",
|
"navigationBarTitleText": "质损详情"
|
||||||
"usingComponents": {
|
|
||||||
"van-button": "/wxcomponents/vant/dist/button/index"
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"path": "pages/monitor/sign",
|
"path": "pages/monitor/sign",
|
||||||
"style": {
|
"style": {
|
||||||
"navigationBarTitleText": "签名",
|
"navigationBarTitleText": "签名"
|
||||||
"usingComponents": {
|
|
||||||
"van-button": "/wxcomponents/vant/dist/button/index"
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
|
@ -276,8 +217,14 @@
|
||||||
"backgroundTextStyle": "light",
|
"backgroundTextStyle": "light",
|
||||||
"navigationBarBackgroundColor": "#0052A4",
|
"navigationBarBackgroundColor": "#0052A4",
|
||||||
"navigationBarTitleText": "港口Ipad",
|
"navigationBarTitleText": "港口Ipad",
|
||||||
"navigationBarTextStyle": "white"
|
"navigationBarTextStyle": "white",
|
||||||
|
"usingComponents": {
|
||||||
|
"van-icon": "/wxcomponents/vant/dist/icon/index",
|
||||||
|
"van-button": "/wxcomponents/vant/dist/button/index",
|
||||||
|
"van-uploader": "/wxcomponents/vant/dist/uploader/index",
|
||||||
|
"van-progress": "/wxcomponents/vant/dist/progress/index",
|
||||||
|
"van-stepper": "/wxcomponents/vant/dist/stepper/index"
|
||||||
|
}
|
||||||
|
|
||||||
},
|
},
|
||||||
"uniIdRouter": {},
|
"uniIdRouter": {},
|
||||||
|
|
|
@ -81,6 +81,9 @@
|
||||||
type: "",
|
type: "",
|
||||||
// 描述
|
// 描述
|
||||||
remark: "",
|
remark: "",
|
||||||
|
|
||||||
|
// 下拉数据
|
||||||
|
optionData: [],
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
onLoad(options) {
|
onLoad(options) {
|
||||||
|
@ -93,17 +96,35 @@
|
||||||
if (this.obj.state == 'edit' || this.obj.state == 'look') {
|
if (this.obj.state == 'edit' || this.obj.state == 'look') {
|
||||||
this.getRow();
|
this.getRow();
|
||||||
}
|
}
|
||||||
this.getShip()
|
this.executeSql1('shipOption')
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
|
// 查
|
||||||
|
executeSql1(tableName) {
|
||||||
|
let sql = `select * from ${tableName}`
|
||||||
|
sqlite.executeSqlCeshi(sql).then((value) => {
|
||||||
|
// 在resolve时执行的回调函数
|
||||||
|
this.optionData = value
|
||||||
|
this.getShip()
|
||||||
|
}).catch((error) => {
|
||||||
|
// 在reject时执行的回调函数
|
||||||
|
console.error(error);
|
||||||
|
});
|
||||||
|
},
|
||||||
// 获取船只信息
|
// 获取船只信息
|
||||||
getShip() {
|
getShip() {
|
||||||
this.shipInfo = uni.getStorageSync('shipInfo')
|
this.shipInfo = uni.getStorageSync('shipInfo')
|
||||||
// 航次数据
|
// 航次下拉数据
|
||||||
this.shipInfo.voyageScheduleDataList.forEach((v, index) => {
|
let hcOption = []
|
||||||
|
this.optionData.forEach((v, index) => {
|
||||||
|
if (v.dictionariesName == 'vvyList') {
|
||||||
|
hcOption.push(v)
|
||||||
|
}
|
||||||
|
})
|
||||||
|
hcOption.forEach((v, index) => {
|
||||||
this.hcList.push({
|
this.hcList.push({
|
||||||
text: v.vvyName,
|
text: v.ptrDesc,
|
||||||
value: v.vvyId
|
value: v.ptrCode
|
||||||
})
|
})
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
|
@ -138,9 +159,6 @@
|
||||||
},
|
},
|
||||||
// 弹框删除
|
// 弹框删除
|
||||||
delConfirm() {
|
delConfirm() {
|
||||||
// let addAbnormalArr = uni.getStorageSync('addAbnormalArr')
|
|
||||||
// addAbnormalArr.splice(this.abnormalRowIndex, 1)
|
|
||||||
// uni.setStorageSync('addAbnormalArr', addAbnormalArr);
|
|
||||||
let sql = `DELETE FROM abnormalConditionRespList WHERE webId = '${this.abnormalRow.webId}';`
|
let sql = `DELETE FROM abnormalConditionRespList WHERE webId = '${this.abnormalRow.webId}';`
|
||||||
this.executeSql(sql)
|
this.executeSql(sql)
|
||||||
uni.navigateTo({
|
uni.navigateTo({
|
||||||
|
@ -170,30 +188,6 @@
|
||||||
'${this.shipInfo.voyageScheduleDataList[0].spmName}','${webStatus}','${webDate}')`
|
'${this.shipInfo.voyageScheduleDataList[0].spmName}','${webStatus}','${webDate}')`
|
||||||
this.executeSql(sql)
|
this.executeSql(sql)
|
||||||
}
|
}
|
||||||
// let addAbnormalArr = uni.getStorageSync('addAbnormalArr')
|
|
||||||
// let addAbnormalObj = {
|
|
||||||
// vvyId: this.vvyId,
|
|
||||||
// vvyName: this.vvyName,
|
|
||||||
// type: this.type,
|
|
||||||
// remark: this.remark,
|
|
||||||
// workTime: this.workTime,
|
|
||||||
// tradeTypeName: this.shipInfo.voyageScheduleDataList[0].tradeTypeName,
|
|
||||||
// importExportFlagName: this.shipInfo.voyageScheduleDataList[0].importExportFlagName,
|
|
||||||
// spmName: this.shipInfo.voyageScheduleDataList[0].spmName,
|
|
||||||
// }
|
|
||||||
// if (this.obj.state == "edit") {
|
|
||||||
// addAbnormalArr[this.abnormalRowIndex] = addAbnormalObj;
|
|
||||||
// uni.setStorageSync('addAbnormalArr', addAbnormalArr);
|
|
||||||
// } else if (this.obj.state == "add") {
|
|
||||||
// if (addAbnormalArr != "") {
|
|
||||||
// addAbnormalArr.push(addAbnormalObj)
|
|
||||||
// uni.setStorageSync('addAbnormalArr', addAbnormalArr);
|
|
||||||
// } else {
|
|
||||||
// addAbnormalArr = []
|
|
||||||
// addAbnormalArr.push(addAbnormalObj)
|
|
||||||
// uni.setStorageSync('addAbnormalArr', addAbnormalArr);
|
|
||||||
// }
|
|
||||||
// }
|
|
||||||
uni.navigateTo({
|
uni.navigateTo({
|
||||||
url: '/pages/shipWork/abnormal'
|
url: '/pages/shipWork/abnormal'
|
||||||
})
|
})
|
||||||
|
|
|
@ -27,7 +27,12 @@
|
||||||
<p>货代:{{item.agentName}}</p>
|
<p>货代:{{item.agentName}}</p>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
|
<view class="pageBox" v-if="total > 0">
|
||||||
|
<uni-pagination :show-icon="true" :total="total" :pageSize="pageSize" :current="current"
|
||||||
|
@change="changePage" />
|
||||||
|
</view>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<o-empty v-else height="70vh" bg="#fff" />
|
<o-empty v-else height="70vh" bg="#fff" />
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
|
@ -43,7 +48,13 @@
|
||||||
hasChoose: false,
|
hasChoose: false,
|
||||||
menuList: [],
|
menuList: [],
|
||||||
defaultValue: {},
|
defaultValue: {},
|
||||||
listInfo: []
|
listInfo: [],
|
||||||
|
allList: [],
|
||||||
|
|
||||||
|
// 分页
|
||||||
|
total: 0,
|
||||||
|
pageSize: 3,
|
||||||
|
current: 1,
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
mounted() {
|
mounted() {
|
||||||
|
@ -174,34 +185,50 @@
|
||||||
let sql = `select * from ${tableName}`
|
let sql = `select * from ${tableName}`
|
||||||
sqlite.executeSqlCeshi(sql).then((value) => {
|
sqlite.executeSqlCeshi(sql).then((value) => {
|
||||||
// 在resolve时执行的回调函数
|
// 在resolve时执行的回调函数
|
||||||
this.listInfo = value
|
this.allList = value
|
||||||
console.log(this.listInfo)
|
this.total = value.length
|
||||||
|
let newArr = this.getMapping(value, this.pageSize)
|
||||||
|
this.listInfo = newArr[this.current - 1];
|
||||||
}).catch((error) => {
|
}).catch((error) => {
|
||||||
// 在reject时执行的回调函数
|
// 在reject时执行的回调函数
|
||||||
console.error(error);
|
console.error(error);
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
|
// 分页切割数组(数组,分割个数)
|
||||||
|
getMapping(list, num) {
|
||||||
|
let len = list.length
|
||||||
|
let newList = []
|
||||||
|
if (len) {
|
||||||
|
var chunk = num
|
||||||
|
for (var i = 0, j = len; i < j; i += chunk) {
|
||||||
|
newList.push(list.slice(i, i + chunk))
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return newList
|
||||||
|
},
|
||||||
|
changePage(e) {
|
||||||
|
this.current = e.current;
|
||||||
|
this.executeSql1('shipmentShipLoadPlansRespList')
|
||||||
|
},
|
||||||
// 点击搜索右侧图标
|
// 点击搜索右侧图标
|
||||||
iconClick() {
|
iconClick() {
|
||||||
if (this.searchValue != "") {
|
if (this.searchValue != "") {
|
||||||
let listIndexArr = []
|
let listIndexArr = []
|
||||||
let newArr = []
|
let newArr = []
|
||||||
this.listInfo.forEach((v, index) => {
|
this.allList.forEach((v, index) => {
|
||||||
if (v.brdName.indexOf(this.searchValue) != -1 || v.mnfBl.indexOf(this.searchValue) != -1) {
|
if (v.brdName.indexOf(this.searchValue) != -1 || v.mnfBl.indexOf(this.searchValue) != -1) {
|
||||||
console.log(index)
|
|
||||||
listIndexArr.push(index)
|
listIndexArr.push(index)
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
console.log(listIndexArr)
|
|
||||||
if (listIndexArr.length > 0) {
|
if (listIndexArr.length > 0) {
|
||||||
listIndexArr.forEach((v, index) => {
|
listIndexArr.forEach((v, index) => {
|
||||||
newArr.push(this.listInfo[v])
|
newArr.push(this.allList[v])
|
||||||
})
|
})
|
||||||
this.listInfo = newArr
|
this.listInfo = newArr
|
||||||
console.log(this.listInfo)
|
this.total = 0
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
this.initData()
|
this.executeSql1('shipmentShipLoadPlansRespList')
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
// 点击筛选
|
// 点击筛选
|
||||||
|
|
|
@ -20,6 +20,7 @@
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script>
|
<script>
|
||||||
|
import sqlite from "../../common/sqlite.js"
|
||||||
export default {
|
export default {
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
|
@ -73,13 +74,23 @@
|
||||||
url: "brandDetails"
|
url: "brandDetails"
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
shipInfo: []
|
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
mounted() {
|
mounted() {
|
||||||
this.shipInfo = uni.getStorageSync('shipInfo')
|
this.executeSql1('shipOption')
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
|
// 查
|
||||||
|
executeSql1(tableName) {
|
||||||
|
let sql = `select * from ${tableName}`
|
||||||
|
sqlite.executeSqlCeshi(sql).then((value) => {
|
||||||
|
// 在resolve时执行的回调函数
|
||||||
|
console.log(value)
|
||||||
|
}).catch((error) => {
|
||||||
|
// 在reject时执行的回调函数
|
||||||
|
console.error(error);
|
||||||
|
});
|
||||||
|
},
|
||||||
toGo(url) {
|
toGo(url) {
|
||||||
uni.navigateTo({
|
uni.navigateTo({
|
||||||
url: `/pages/shipWork/${url}`
|
url: `/pages/shipWork/${url}`
|
||||||
|
|
|
@ -119,6 +119,27 @@
|
||||||
current: 1,
|
current: 1,
|
||||||
|
|
||||||
shipInfo: {},
|
shipInfo: {},
|
||||||
|
// 船舶资料
|
||||||
|
shipData: {
|
||||||
|
vslCd: "123",
|
||||||
|
vslCnname: "兰花快航",
|
||||||
|
vslGton: "9535",
|
||||||
|
vslNetton: "2861",
|
||||||
|
vslLoa: "100.29",
|
||||||
|
vslBreadth: "0",
|
||||||
|
vslDraftunload: "0",
|
||||||
|
vslDraftload: "0",
|
||||||
|
spmCabinht: "0",
|
||||||
|
spmMintide: "0",
|
||||||
|
spmCab: "15",
|
||||||
|
spmBoardCentrele: "0",
|
||||||
|
spmBoardFrontle: "0",
|
||||||
|
spmBoardLaterle: "0",
|
||||||
|
spmBoardCentrerg: "0",
|
||||||
|
spmBoardFrontrg: "0",
|
||||||
|
spmBoardLaterrg: "0"
|
||||||
|
},
|
||||||
|
// 作业查询数据
|
||||||
workList: [{
|
workList: [{
|
||||||
agentId: "1",
|
agentId: "1",
|
||||||
agentName: "华图供应链管理(天津)有限公司",
|
agentName: "华图供应链管理(天津)有限公司",
|
||||||
|
@ -165,6 +186,120 @@
|
||||||
vvyName: "HC8595986",
|
vvyName: "HC8595986",
|
||||||
yardPos: "C4区15道*2,16道*2",
|
yardPos: "C4区15道*2,16道*2",
|
||||||
}
|
}
|
||||||
|
],
|
||||||
|
// 下拉数据
|
||||||
|
optionData: [{
|
||||||
|
dictionariesName: "epTypeList",
|
||||||
|
ptrCode: "1",
|
||||||
|
ptrDesc: "贸易方式一",
|
||||||
|
},
|
||||||
|
{
|
||||||
|
dictionariesName: "epTypeList",
|
||||||
|
ptrCode: "2",
|
||||||
|
ptrDesc: "贸易方式二",
|
||||||
|
}, {
|
||||||
|
dictionariesName: "handTypeList",
|
||||||
|
ptrCode: "1",
|
||||||
|
ptrDesc: "装货",
|
||||||
|
}, {
|
||||||
|
dictionariesName: "handTypeList",
|
||||||
|
ptrCode: "2",
|
||||||
|
ptrDesc: "卸货",
|
||||||
|
}, {
|
||||||
|
dictionariesName: "loadTypeList",
|
||||||
|
ptrCode: "1",
|
||||||
|
ptrDesc: "Others",
|
||||||
|
}, {
|
||||||
|
dictionariesName: "loadTypeList",
|
||||||
|
ptrCode: "2",
|
||||||
|
ptrDesc: "Ro/Ro",
|
||||||
|
}, {
|
||||||
|
dictionariesName: "loadTypeList",
|
||||||
|
ptrCode: "3",
|
||||||
|
ptrDesc: "PortDevice",
|
||||||
|
}, {
|
||||||
|
dictionariesName: "ieTypeList",
|
||||||
|
ptrCode: "1",
|
||||||
|
ptrDesc: "出口",
|
||||||
|
}, {
|
||||||
|
dictionariesName: "ieTypeList",
|
||||||
|
ptrCode: "2",
|
||||||
|
ptrDesc: "进口",
|
||||||
|
},
|
||||||
|
{
|
||||||
|
dictionariesName: "supplyTypeList",
|
||||||
|
ptrCode: "1",
|
||||||
|
ptrDesc: "供油",
|
||||||
|
}, {
|
||||||
|
dictionariesName: "supplyTypeList",
|
||||||
|
ptrCode: "2",
|
||||||
|
ptrDesc: "供水",
|
||||||
|
}, {
|
||||||
|
dictionariesName: "supplyTypeList",
|
||||||
|
ptrCode: "3",
|
||||||
|
ptrDesc: "供电",
|
||||||
|
}, {
|
||||||
|
dictionariesName: "supplyTypeList",
|
||||||
|
ptrCode: "4",
|
||||||
|
ptrDesc: "其他",
|
||||||
|
}, {
|
||||||
|
dictionariesName: "turnoverTypeList",
|
||||||
|
ptrCode: "1",
|
||||||
|
ptrDesc: "舱内翻",
|
||||||
|
}, {
|
||||||
|
dictionariesName: "turnoverTypeList",
|
||||||
|
ptrCode: "2",
|
||||||
|
ptrDesc: "舱外翻",
|
||||||
|
webStatus: "0",
|
||||||
|
}, {
|
||||||
|
dictionariesName: "turnoverTypeList",
|
||||||
|
ptrCode: "3",
|
||||||
|
ptrDesc: "货物重装",
|
||||||
|
}, {
|
||||||
|
dictionariesName: "bthList",
|
||||||
|
ptrCode: "1",
|
||||||
|
ptrDesc: "泊位1",
|
||||||
|
}, {
|
||||||
|
dictionariesName: "bthList",
|
||||||
|
ptrCode: "2",
|
||||||
|
ptrDesc: "泊位2",
|
||||||
|
}, {
|
||||||
|
dictionariesName: "bthList",
|
||||||
|
ptrCode: "3",
|
||||||
|
ptrDesc: "泊位3",
|
||||||
|
}, {
|
||||||
|
dictionariesName: "carList",
|
||||||
|
ptrCode: "1",
|
||||||
|
ptrDesc: "轿车111",
|
||||||
|
}, {
|
||||||
|
dictionariesName: "carList",
|
||||||
|
ptrCode: "2",
|
||||||
|
ptrDesc: "备件",
|
||||||
|
}, {
|
||||||
|
dictionariesName: "carList",
|
||||||
|
ptrCode: "3",
|
||||||
|
ptrDesc: "大型轿车",
|
||||||
|
}, {
|
||||||
|
dictionariesName: "shiftList",
|
||||||
|
ptrCode: "1",
|
||||||
|
ptrDesc: "工班1",
|
||||||
|
}, {
|
||||||
|
dictionariesName: "shiftList",
|
||||||
|
ptrCode: "2",
|
||||||
|
ptrDesc: "工班2",
|
||||||
|
}, {
|
||||||
|
dictionariesName: "shiftList",
|
||||||
|
ptrCode: "3",
|
||||||
|
ptrDesc: "工班3",
|
||||||
|
}, {
|
||||||
|
dictionariesName: "vvyList",
|
||||||
|
ptrCode: "1",
|
||||||
|
ptrDesc: "hc123",
|
||||||
|
}, {
|
||||||
|
dictionariesName: "vvyList",
|
||||||
|
ptrCode: "2",
|
||||||
|
ptrDesc: "hc456",
|
||||||
|
},
|
||||||
]
|
]
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
@ -217,7 +352,7 @@
|
||||||
this.executeSql(sql)
|
this.executeSql(sql)
|
||||||
},
|
},
|
||||||
dropData() {
|
dropData() {
|
||||||
let sql = "delete from shipmentShipLoadPlansRespList"
|
let sql = "delete from shipOption"
|
||||||
this.executeSql(sql)
|
this.executeSql(sql)
|
||||||
},
|
},
|
||||||
add() {
|
add() {
|
||||||
|
@ -239,8 +374,7 @@
|
||||||
executeSql(sql) {
|
executeSql(sql) {
|
||||||
sqlite.executeSqlCeshi(sql).then((value) => {
|
sqlite.executeSqlCeshi(sql).then((value) => {
|
||||||
// 在resolve时执行的回调函数
|
// 在resolve时执行的回调函数
|
||||||
// this.sqlData = value
|
// console.log(value);
|
||||||
console.log(value); // 输出:Hello, World!
|
|
||||||
}).catch((error) => {
|
}).catch((error) => {
|
||||||
// 在reject时执行的回调函数
|
// 在reject时执行的回调函数
|
||||||
console.error(error);
|
console.error(error);
|
||||||
|
@ -326,10 +460,23 @@
|
||||||
}]
|
}]
|
||||||
// this.initData()
|
// this.initData()
|
||||||
},
|
},
|
||||||
// 下载
|
// 船舶资料数据
|
||||||
download(item) {
|
cbzlData() {
|
||||||
// 下载创建单证内的表
|
let webStatus = 0
|
||||||
tableList.createAllTable()
|
let sql = ""
|
||||||
|
let date = new Date().getTime()
|
||||||
|
let webId = uuidv4()
|
||||||
|
let webDate = api.getDate(date)
|
||||||
|
sql =
|
||||||
|
`insert into shipmentShipManage values('${webId}','${this.shipData.vslCd}','${this.shipData.vslCnname}',
|
||||||
|
'${this.shipData.vslGton}','${this.shipData.vslNetton}','${this.shipData.vslLoa}','${this.shipData.vslBreadth}','${this.shipData.vslDraftunload}','${this.shipData.vslDraftload}',
|
||||||
|
'${this.shipData.spmCabinht}','${this.shipData.spmMintide}','${this.shipData.spmCab}','${this.shipData.spmBoardCentrele}',
|
||||||
|
'${this.shipData.spmBoardFrontle}','${this.shipData.spmBoardLaterle}','${this.shipData.spmBoardCentrerg}','${this.shipData.spmBoardFrontrg}','${this.shipData.spmBoardLaterrg}',
|
||||||
|
'${webStatus}','${webDate}')`
|
||||||
|
this.executeSql(sql)
|
||||||
|
},
|
||||||
|
// 作业查询数据
|
||||||
|
zycxData() {
|
||||||
let webStatus = 0
|
let webStatus = 0
|
||||||
let sql = ""
|
let sql = ""
|
||||||
for (let i = 0; i < this.workList.length; i++) {
|
for (let i = 0; i < this.workList.length; i++) {
|
||||||
|
@ -345,6 +492,38 @@
|
||||||
'${webStatus}','${webDate}')`
|
'${webStatus}','${webDate}')`
|
||||||
this.executeSql(sql)
|
this.executeSql(sql)
|
||||||
}
|
}
|
||||||
|
},
|
||||||
|
// 下拉数据
|
||||||
|
xlData() {
|
||||||
|
for (let i = 0; i < this.optionData.length; i++) {
|
||||||
|
this.optionData[i]["webId"] = uuidv4()
|
||||||
|
let date = new Date().getTime()
|
||||||
|
this.optionData[i]["webStatus"] = "0"
|
||||||
|
this.optionData[i]["webDate"] = api.getDate(date)
|
||||||
|
let dbTable = 'shipOption'
|
||||||
|
let Arr = []
|
||||||
|
for (let key in this.optionData[i]) {
|
||||||
|
Arr.push(`'${ this.optionData[i][key]}'`);
|
||||||
|
}
|
||||||
|
let Str = Arr.join(',')
|
||||||
|
// console.log(Str)
|
||||||
|
sqlite.insertTableData(dbTable, Str).then((value) => {
|
||||||
|
// 在resolve时执行的回调函数
|
||||||
|
// console.log(value);
|
||||||
|
this.executeSql(value)
|
||||||
|
}).catch((error) => {
|
||||||
|
// 在reject时执行的回调函数
|
||||||
|
console.error(error);
|
||||||
|
});
|
||||||
|
}
|
||||||
|
},
|
||||||
|
// 下载
|
||||||
|
download(item) {
|
||||||
|
// 下载创建单证内的表
|
||||||
|
tableList.createAllTable()
|
||||||
|
this.zycxData()
|
||||||
|
this.cbzlData()
|
||||||
|
this.xlData()
|
||||||
// let ids = []
|
// let ids = []
|
||||||
// if (item.inVvyId != null && item.outVvyId == null) {
|
// if (item.inVvyId != null && item.outVvyId == null) {
|
||||||
// ids.push(item.inVvyId)
|
// ids.push(item.inVvyId)
|
||||||
|
|
|
@ -108,6 +108,9 @@
|
||||||
loaderTypeId: "",
|
loaderTypeId: "",
|
||||||
loaderType: "",
|
loaderType: "",
|
||||||
zxList: [],
|
zxList: [],
|
||||||
|
|
||||||
|
// 下拉数据
|
||||||
|
optionData: [],
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
onLoad(options) {
|
onLoad(options) {
|
||||||
|
@ -120,21 +123,45 @@
|
||||||
if (this.obj.state == 'edit' || this.obj.state == 'look') {
|
if (this.obj.state == 'edit' || this.obj.state == 'look') {
|
||||||
this.getRow();
|
this.getRow();
|
||||||
}
|
}
|
||||||
this.getShip()
|
this.executeSql1('shipOption')
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
|
// 查
|
||||||
|
executeSql1(tableName) {
|
||||||
|
let sql = `select * from ${tableName}`
|
||||||
|
sqlite.executeSqlCeshi(sql).then((value) => {
|
||||||
|
// 在resolve时执行的回调函数
|
||||||
|
this.optionData = value
|
||||||
|
this.getShip()
|
||||||
|
}).catch((error) => {
|
||||||
|
// 在reject时执行的回调函数
|
||||||
|
console.error(error);
|
||||||
|
});
|
||||||
|
},
|
||||||
// 获取船只信息
|
// 获取船只信息
|
||||||
getShip() {
|
getShip() {
|
||||||
this.shipInfo = uni.getStorageSync('shipInfo')
|
this.shipInfo = uni.getStorageSync('shipInfo')
|
||||||
// 航次数据
|
// 航次下拉数据
|
||||||
this.shipInfo.voyageScheduleDataList.forEach((v, index) => {
|
let hcOption = []
|
||||||
|
this.optionData.forEach((v, index) => {
|
||||||
|
if (v.dictionariesName == 'vvyList') {
|
||||||
|
hcOption.push(v)
|
||||||
|
}
|
||||||
|
})
|
||||||
|
hcOption.forEach((v, index) => {
|
||||||
this.hcList.push({
|
this.hcList.push({
|
||||||
text: v.vvyName,
|
text: v.ptrDesc,
|
||||||
value: v.vvyId
|
value: v.ptrCode
|
||||||
})
|
})
|
||||||
})
|
})
|
||||||
// 装卸类型数据
|
// 装卸类型数据
|
||||||
this.shipInfo.handTypeList.forEach((v, index) => {
|
let zxOption = []
|
||||||
|
this.optionData.forEach((v, index) => {
|
||||||
|
if (v.dictionariesName == 'handTypeList') {
|
||||||
|
zxOption.push(v)
|
||||||
|
}
|
||||||
|
})
|
||||||
|
zxOption.forEach((v, index) => {
|
||||||
this.zxList.push({
|
this.zxList.push({
|
||||||
text: v.ptrDesc,
|
text: v.ptrDesc,
|
||||||
value: v.ptrCode
|
value: v.ptrCode
|
||||||
|
@ -194,9 +221,6 @@
|
||||||
},
|
},
|
||||||
// 弹框删除
|
// 弹框删除
|
||||||
delConfirm() {
|
delConfirm() {
|
||||||
// let addMafiArr = uni.getStorageSync('addMafiArr')
|
|
||||||
// addMafiArr.splice(this.mafiRowIndex, 1)
|
|
||||||
// uni.setStorageSync('addMafiArr', addMafiArr);
|
|
||||||
let sql = `DELETE FROM mafiListRespList WHERE webId = '${this.mafiRow.webId}';`
|
let sql = `DELETE FROM mafiListRespList WHERE webId = '${this.mafiRow.webId}';`
|
||||||
this.executeSql(sql)
|
this.executeSql(sql)
|
||||||
uni.navigateTo({
|
uni.navigateTo({
|
||||||
|
@ -227,34 +251,6 @@
|
||||||
'${this.shipInfo.voyageScheduleDataList[0].spmName}','${webStatus}','${webDate}')`
|
'${this.shipInfo.voyageScheduleDataList[0].spmName}','${webStatus}','${webDate}')`
|
||||||
this.executeSql(sql)
|
this.executeSql(sql)
|
||||||
}
|
}
|
||||||
// let addMafiArr = uni.getStorageSync('addMafiArr')
|
|
||||||
// let addMafiObj = {
|
|
||||||
// vvyId: this.vvyId,
|
|
||||||
// vvyName: this.vvyName,
|
|
||||||
// loaderTypeId: this.loaderTypeId,
|
|
||||||
// loaderType: this.loaderType,
|
|
||||||
// typeId: this.typeId,
|
|
||||||
// type: this.type,
|
|
||||||
// size: this.size,
|
|
||||||
// mafiBarcode: this.mafiBarcode,
|
|
||||||
// workDate: this.workDate,
|
|
||||||
// tradeTypeName: this.shipInfo.voyageScheduleDataList[0].tradeTypeName,
|
|
||||||
// importExportFlagName: this.shipInfo.voyageScheduleDataList[0].importExportFlagName,
|
|
||||||
// spmName: this.shipInfo.voyageScheduleDataList[0].spmName,
|
|
||||||
// }
|
|
||||||
// if (this.obj.state == "edit") {
|
|
||||||
// addMafiArr[this.mafiRowIndex] = addMafiObj;
|
|
||||||
// uni.setStorageSync('addMafiArr', addMafiArr);
|
|
||||||
// } else if (this.obj.state == "add") {
|
|
||||||
// if (addMafiArr != "") {
|
|
||||||
// addMafiArr.push(addMafiObj)
|
|
||||||
// uni.setStorageSync('addMafiArr', addMafiArr);
|
|
||||||
// } else {
|
|
||||||
// addMafiArr = []
|
|
||||||
// addMafiArr.push(addMafiObj)
|
|
||||||
// uni.setStorageSync('addMafiArr', addMafiArr);
|
|
||||||
// }
|
|
||||||
// }
|
|
||||||
uni.navigateTo({
|
uni.navigateTo({
|
||||||
url: '/pages/shipWork/mafi'
|
url: '/pages/shipWork/mafi'
|
||||||
})
|
})
|
||||||
|
|
|
@ -80,7 +80,6 @@
|
||||||
sqlite.executeSqlCeshi(sql).then((value) => {
|
sqlite.executeSqlCeshi(sql).then((value) => {
|
||||||
if (this.tabsType == 0) {
|
if (this.tabsType == 0) {
|
||||||
this.peopleInfo = value
|
this.peopleInfo = value
|
||||||
console.log(this.peopleInfo)
|
|
||||||
}
|
}
|
||||||
}).catch((error) => {
|
}).catch((error) => {
|
||||||
// 在reject时执行的回调函数
|
// 在reject时执行的回调函数
|
||||||
|
|
|
@ -66,6 +66,9 @@
|
||||||
hcList: [],
|
hcList: [],
|
||||||
// 作业时间
|
// 作业时间
|
||||||
workDate: [''],
|
workDate: [''],
|
||||||
|
|
||||||
|
// 下拉数据
|
||||||
|
optionData: [],
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
onLoad(options) {
|
onLoad(options) {
|
||||||
|
@ -78,17 +81,35 @@
|
||||||
if (this.obj.state == 'edit' || this.obj.state == 'look') {
|
if (this.obj.state == 'edit' || this.obj.state == 'look') {
|
||||||
this.getRow();
|
this.getRow();
|
||||||
}
|
}
|
||||||
this.getShip()
|
this.executeSql1('shipOption')
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
|
// 查
|
||||||
|
executeSql1(tableName) {
|
||||||
|
let sql = `select * from ${tableName}`
|
||||||
|
sqlite.executeSqlCeshi(sql).then((value) => {
|
||||||
|
// 在resolve时执行的回调函数
|
||||||
|
this.optionData = value
|
||||||
|
this.getShip()
|
||||||
|
}).catch((error) => {
|
||||||
|
// 在reject时执行的回调函数
|
||||||
|
console.error(error);
|
||||||
|
});
|
||||||
|
},
|
||||||
// 获取船只信息
|
// 获取船只信息
|
||||||
getShip() {
|
getShip() {
|
||||||
this.shipInfo = uni.getStorageSync('shipInfo')
|
this.shipInfo = uni.getStorageSync('shipInfo')
|
||||||
// 航次数据
|
// 航次下拉数据
|
||||||
this.shipInfo.voyageScheduleDataList.forEach((v, index) => {
|
let hcOption = []
|
||||||
|
this.optionData.forEach((v, index) => {
|
||||||
|
if (v.dictionariesName == 'vvyList') {
|
||||||
|
hcOption.push(v)
|
||||||
|
}
|
||||||
|
})
|
||||||
|
hcOption.forEach((v, index) => {
|
||||||
this.hcList.push({
|
this.hcList.push({
|
||||||
text: v.vvyName,
|
text: v.ptrDesc,
|
||||||
value: v.vvyId
|
value: v.ptrCode
|
||||||
})
|
})
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
|
@ -121,9 +142,6 @@
|
||||||
},
|
},
|
||||||
// 弹框删除
|
// 弹框删除
|
||||||
delConfirm() {
|
delConfirm() {
|
||||||
// let addNoticeArr = uni.getStorageSync('addNoticeArr')
|
|
||||||
// addNoticeArr.splice(this.noticeRowIndex, 1)
|
|
||||||
// uni.setStorageSync('addNoticeArr', addNoticeArr);
|
|
||||||
let sql = `DELETE FROM shipmentLoadUnloadNoticeRespList WHERE webId = '${this.noticeRow.webId}';`
|
let sql = `DELETE FROM shipmentLoadUnloadNoticeRespList WHERE webId = '${this.noticeRow.webId}';`
|
||||||
this.executeSql(sql)
|
this.executeSql(sql)
|
||||||
uni.navigateTo({
|
uni.navigateTo({
|
||||||
|
@ -151,28 +169,6 @@
|
||||||
'${this.shipInfo.voyageScheduleDataList[0].spmName}','${webStatus}','${webDate}')`
|
'${this.shipInfo.voyageScheduleDataList[0].spmName}','${webStatus}','${webDate}')`
|
||||||
this.executeSql(sql)
|
this.executeSql(sql)
|
||||||
}
|
}
|
||||||
// let addNoticeArr = uni.getStorageSync('addNoticeArr')
|
|
||||||
// let addNoticeObj = {
|
|
||||||
// vvyId: this.vvyId,
|
|
||||||
// vvyName: this.vvyName,
|
|
||||||
// workDate: this.workDate,
|
|
||||||
// tradeTypeName: this.shipInfo.voyageScheduleDataList[0].tradeTypeName,
|
|
||||||
// importExportFlagName: this.shipInfo.voyageScheduleDataList[0].importExportFlagName,
|
|
||||||
// spmName: this.shipInfo.voyageScheduleDataList[0].spmName,
|
|
||||||
// }
|
|
||||||
// if (this.obj.state == "edit") {
|
|
||||||
// addNoticeArr[this.noticeRowIndex] = addNoticeObj;
|
|
||||||
// uni.setStorageSync('addNoticeArr', addNoticeArr);
|
|
||||||
// } else if (this.obj.state == "add") {
|
|
||||||
// if (addNoticeArr != "") {
|
|
||||||
// addNoticeArr.push(addNoticeObj)
|
|
||||||
// uni.setStorageSync('addNoticeArr', addNoticeArr);
|
|
||||||
// } else {
|
|
||||||
// addNoticeArr = []
|
|
||||||
// addNoticeArr.push(addNoticeObj)
|
|
||||||
// uni.setStorageSync('addNoticeArr', addNoticeArr);
|
|
||||||
// }
|
|
||||||
// }
|
|
||||||
uni.navigateTo({
|
uni.navigateTo({
|
||||||
url: '/pages/shipWork/notice'
|
url: '/pages/shipWork/notice'
|
||||||
})
|
})
|
||||||
|
|
|
@ -100,6 +100,9 @@
|
||||||
sparePart: 0,
|
sparePart: 0,
|
||||||
// 作业时间
|
// 作业时间
|
||||||
workTime: [''],
|
workTime: [''],
|
||||||
|
|
||||||
|
// 下拉数据
|
||||||
|
optionData: [],
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
onLoad(options) {
|
onLoad(options) {
|
||||||
|
@ -112,31 +115,61 @@
|
||||||
if (this.obj.state == 'edit' || this.obj.state == 'look') {
|
if (this.obj.state == 'edit' || this.obj.state == 'look') {
|
||||||
this.getRow();
|
this.getRow();
|
||||||
}
|
}
|
||||||
this.getShip()
|
this.executeSql1('shipOption')
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
|
// 查
|
||||||
|
executeSql1(tableName) {
|
||||||
|
let sql = `select * from ${tableName}`
|
||||||
|
sqlite.executeSqlCeshi(sql).then((value) => {
|
||||||
|
// 在resolve时执行的回调函数
|
||||||
|
this.optionData = value
|
||||||
|
this.getShip()
|
||||||
|
}).catch((error) => {
|
||||||
|
// 在reject时执行的回调函数
|
||||||
|
console.error(error);
|
||||||
|
});
|
||||||
|
},
|
||||||
// 获取船只信息
|
// 获取船只信息
|
||||||
getShip() {
|
getShip() {
|
||||||
this.shipInfo = uni.getStorageSync('shipInfo')
|
this.shipInfo = uni.getStorageSync('shipInfo')
|
||||||
// 航次数据
|
// 航次下拉数据
|
||||||
this.shipInfo.voyageScheduleDataList.forEach((v, index) => {
|
let hcOption = []
|
||||||
|
this.optionData.forEach((v, index) => {
|
||||||
|
if (v.dictionariesName == 'vvyList') {
|
||||||
|
hcOption.push(v)
|
||||||
|
}
|
||||||
|
})
|
||||||
|
hcOption.forEach((v, index) => {
|
||||||
this.hcList.push({
|
this.hcList.push({
|
||||||
text: v.vvyName,
|
text: v.ptrDesc,
|
||||||
value: v.vvyId
|
value: v.ptrCode
|
||||||
})
|
})
|
||||||
})
|
})
|
||||||
// 装卸类型数据
|
// 装卸类型数据
|
||||||
this.shipInfo.handTypeList.forEach((v, index) => {
|
let zxOption = []
|
||||||
|
this.optionData.forEach((v, index) => {
|
||||||
|
if (v.dictionariesName == 'handTypeList') {
|
||||||
|
zxOption.push(v)
|
||||||
|
}
|
||||||
|
})
|
||||||
|
zxOption.forEach((v, index) => {
|
||||||
this.zxList.push({
|
this.zxList.push({
|
||||||
text: v.ptrDesc,
|
text: v.ptrDesc,
|
||||||
value: v.ptrCode
|
value: v.ptrCode
|
||||||
})
|
})
|
||||||
})
|
})
|
||||||
// 泊位数据
|
// 船舶下拉数据
|
||||||
this.shipInfo.pubBerthesManageRespList.forEach((v, index) => {
|
let bwOption = []
|
||||||
|
this.optionData.forEach((v, index) => {
|
||||||
|
if (v.dictionariesName == 'bthList') {
|
||||||
|
bwOption.push(v)
|
||||||
|
}
|
||||||
|
})
|
||||||
|
bwOption.forEach((v, index) => {
|
||||||
this.bwList.push({
|
this.bwList.push({
|
||||||
text: v.bthBthnm,
|
text: v.ptrDesc,
|
||||||
value: v.bthId
|
value: v.ptrCode
|
||||||
})
|
})
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
|
@ -193,9 +226,6 @@
|
||||||
},
|
},
|
||||||
// 弹框删除
|
// 弹框删除
|
||||||
delConfirm() {
|
delConfirm() {
|
||||||
// let addOpinionArr = uni.getStorageSync('addOpinionArr')
|
|
||||||
// addOpinionArr.splice(this.opinionRowIndex, 1)
|
|
||||||
// uni.setStorageSync('addOpinionArr', addOpinionArr);
|
|
||||||
let sql = `DELETE FROM shipmentQualityConsultationRespList WHERE webId = '${this.opinionRow.webId}';`
|
let sql = `DELETE FROM shipmentQualityConsultationRespList WHERE webId = '${this.opinionRow.webId}';`
|
||||||
this.executeSql(sql)
|
this.executeSql(sql)
|
||||||
uni.navigateTo({
|
uni.navigateTo({
|
||||||
|
@ -228,34 +258,6 @@
|
||||||
console.log(sql)
|
console.log(sql)
|
||||||
this.executeSql(sql)
|
this.executeSql(sql)
|
||||||
}
|
}
|
||||||
// let addOpinionArr = uni.getStorageSync('addOpinionArr')
|
|
||||||
// let addOpinionObj = {
|
|
||||||
// vvyId: this.vvyId,
|
|
||||||
// vvyName: this.vvyName,
|
|
||||||
// bthId: this.bthId,
|
|
||||||
// bthIdName: this.bthIdName,
|
|
||||||
// loaderTypeId: this.loaderTypeId,
|
|
||||||
// loaderType: this.loaderType,
|
|
||||||
// vehicleSize: this.vehicleSize,
|
|
||||||
// sparePart: this.sparePart,
|
|
||||||
// workTime: this.workTime,
|
|
||||||
// tradeTypeName: this.shipInfo.voyageScheduleDataList[0].tradeTypeName,
|
|
||||||
// importExportFlagName: this.shipInfo.voyageScheduleDataList[0].importExportFlagName,
|
|
||||||
// spmName: this.shipInfo.voyageScheduleDataList[0].spmName,
|
|
||||||
// }
|
|
||||||
// if (this.obj.state == "edit") {
|
|
||||||
// addOpinionArr[this.opinionRowIndex] = addOpinionObj;
|
|
||||||
// uni.setStorageSync('addOpinionArr', addOpinionArr);
|
|
||||||
// } else if (this.obj.state == "add") {
|
|
||||||
// if (addOpinionArr != "") {
|
|
||||||
// addOpinionArr.push(addOpinionObj)
|
|
||||||
// uni.setStorageSync('addOpinionArr', addOpinionArr);
|
|
||||||
// } else {
|
|
||||||
// addOpinionArr = []
|
|
||||||
// addOpinionArr.push(addOpinionObj)
|
|
||||||
// uni.setStorageSync('addOpinionArr', addOpinionArr);
|
|
||||||
// }
|
|
||||||
// }
|
|
||||||
uni.navigateTo({
|
uni.navigateTo({
|
||||||
url: '/pages/shipWork/opinion'
|
url: '/pages/shipWork/opinion'
|
||||||
})
|
})
|
||||||
|
|
|
@ -89,6 +89,9 @@
|
||||||
url: [], // 待增加
|
url: [], // 待增加
|
||||||
// 描述
|
// 描述
|
||||||
remark: "",
|
remark: "",
|
||||||
|
|
||||||
|
// 下拉数据
|
||||||
|
optionData: [],
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
onLoad(options) {
|
onLoad(options) {
|
||||||
|
@ -101,17 +104,35 @@
|
||||||
if (this.obj.state == 'edit' || this.obj.state == 'look') {
|
if (this.obj.state == 'edit' || this.obj.state == 'look') {
|
||||||
this.getRow();
|
this.getRow();
|
||||||
}
|
}
|
||||||
this.getShip()
|
this.executeSql1('shipOption')
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
|
// 查
|
||||||
|
executeSql1(tableName) {
|
||||||
|
let sql = `select * from ${tableName}`
|
||||||
|
sqlite.executeSqlCeshi(sql).then((value) => {
|
||||||
|
// 在resolve时执行的回调函数
|
||||||
|
this.optionData = value
|
||||||
|
this.getShip()
|
||||||
|
}).catch((error) => {
|
||||||
|
// 在reject时执行的回调函数
|
||||||
|
console.error(error);
|
||||||
|
});
|
||||||
|
},
|
||||||
// 获取船只信息
|
// 获取船只信息
|
||||||
getShip() {
|
getShip() {
|
||||||
this.shipInfo = uni.getStorageSync('shipInfo')
|
this.shipInfo = uni.getStorageSync('shipInfo')
|
||||||
// 航次数据
|
// 航次下拉数据
|
||||||
this.shipInfo.voyageScheduleDataList.forEach((v, index) => {
|
let hcOption = []
|
||||||
|
this.optionData.forEach((v, index) => {
|
||||||
|
if (v.dictionariesName == 'vvyList') {
|
||||||
|
hcOption.push(v)
|
||||||
|
}
|
||||||
|
})
|
||||||
|
hcOption.forEach((v, index) => {
|
||||||
this.hcList.push({
|
this.hcList.push({
|
||||||
text: v.vvyName,
|
text: v.ptrDesc,
|
||||||
value: v.vvyId
|
value: v.ptrCode
|
||||||
})
|
})
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
|
@ -146,9 +167,6 @@
|
||||||
},
|
},
|
||||||
// 弹框删除
|
// 弹框删除
|
||||||
delConfirm() {
|
delConfirm() {
|
||||||
// let addPatrolArr = uni.getStorageSync('addPatrolArr')
|
|
||||||
// addPatrolArr.splice(this.patrolRowIndex, 1)
|
|
||||||
// uni.setStorageSync('addPatrolArr', addPatrolArr);
|
|
||||||
let sql = `DELETE FROM safetyInspectionRespList WHERE webId = '${this.patrolRow.webId}';`
|
let sql = `DELETE FROM safetyInspectionRespList WHERE webId = '${this.patrolRow.webId}';`
|
||||||
this.executeSql(sql)
|
this.executeSql(sql)
|
||||||
uni.navigateTo({
|
uni.navigateTo({
|
||||||
|
@ -177,30 +195,6 @@
|
||||||
'${this.shipInfo.voyageScheduleDataList[0].spmName}','${webStatus}','${webDate}')`
|
'${this.shipInfo.voyageScheduleDataList[0].spmName}','${webStatus}','${webDate}')`
|
||||||
this.executeSql(sql)
|
this.executeSql(sql)
|
||||||
}
|
}
|
||||||
// let addPatrolArr = uni.getStorageSync('addPatrolArr')
|
|
||||||
// let addPatrolObj = {
|
|
||||||
// vvyId: this.vvyId,
|
|
||||||
// vvyName: this.vvyName,
|
|
||||||
// type: this.type,
|
|
||||||
// remark: this.remark,
|
|
||||||
// url: this.url,
|
|
||||||
// tradeTypeName: this.shipInfo.voyageScheduleDataList[0].tradeTypeName,
|
|
||||||
// importExportFlagName: this.shipInfo.voyageScheduleDataList[0].importExportFlagName,
|
|
||||||
// spmName: this.shipInfo.voyageScheduleDataList[0].spmName,
|
|
||||||
// }
|
|
||||||
// if (this.obj.state == "edit") {
|
|
||||||
// addPatrolArr[this.patrolRowIndex] = addPatrolObj;
|
|
||||||
// uni.setStorageSync('addPatrolArr', addPatrolArr);
|
|
||||||
// } else if (this.obj.state == "add") {
|
|
||||||
// if (addPatrolArr != "") {
|
|
||||||
// addPatrolArr.push(addPatrolObj)
|
|
||||||
// uni.setStorageSync('addPatrolArr', addPatrolArr);
|
|
||||||
// } else {
|
|
||||||
// addPatrolArr = []
|
|
||||||
// addPatrolArr.push(addPatrolObj)
|
|
||||||
// uni.setStorageSync('addPatrolArr', addPatrolArr);
|
|
||||||
// }
|
|
||||||
// }
|
|
||||||
uni.navigateTo({
|
uni.navigateTo({
|
||||||
url: '/pages/shipWork/patrol'
|
url: '/pages/shipWork/patrol'
|
||||||
})
|
})
|
||||||
|
|
|
@ -96,13 +96,15 @@
|
||||||
tqList: [{
|
tqList: [{
|
||||||
value: "0",
|
value: "0",
|
||||||
text: "晴"
|
text: "晴"
|
||||||
}, {
|
},
|
||||||
|
{
|
||||||
value: " 1",
|
value: " 1",
|
||||||
text: "阴"
|
text: "阴"
|
||||||
}, {
|
}, {
|
||||||
value: "2",
|
value: "2",
|
||||||
text: "雨"
|
text: "雨"
|
||||||
}],
|
}
|
||||||
|
],
|
||||||
// 作业组数
|
// 作业组数
|
||||||
workValue: 0,
|
workValue: 0,
|
||||||
// 单船人数
|
// 单船人数
|
||||||
|
@ -111,6 +113,9 @@
|
||||||
datetime: ['', ''],
|
datetime: ['', ''],
|
||||||
startTime: "",
|
startTime: "",
|
||||||
endTime: "",
|
endTime: "",
|
||||||
|
|
||||||
|
// 下拉数据
|
||||||
|
optionData: [],
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
onLoad(options) {
|
onLoad(options) {
|
||||||
|
@ -123,29 +128,54 @@
|
||||||
if (this.obj.state == "edit" || this.obj.state == "look") {
|
if (this.obj.state == "edit" || this.obj.state == "look") {
|
||||||
this.getRow()
|
this.getRow()
|
||||||
}
|
}
|
||||||
this.getShip()
|
this.executeSql1('shipOption')
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
|
// 查
|
||||||
|
executeSql1(tableName) {
|
||||||
|
let sql = `select * from ${tableName}`
|
||||||
|
sqlite.executeSqlCeshi(sql).then((value) => {
|
||||||
|
// 在resolve时执行的回调函数
|
||||||
|
this.optionData = value
|
||||||
|
this.getShip()
|
||||||
|
}).catch((error) => {
|
||||||
|
// 在reject时执行的回调函数
|
||||||
|
console.error(error);
|
||||||
|
});
|
||||||
|
},
|
||||||
// 获取船只信息
|
// 获取船只信息
|
||||||
getShip() {
|
getShip() {
|
||||||
this.shipInfo = uni.getStorageSync('shipInfo')
|
this.shipInfo = uni.getStorageSync('shipInfo')
|
||||||
this.shipInfo.pubBerthesManageRespList.forEach((v, index) => {
|
// 航次下拉数据
|
||||||
this.bwList.push({
|
let hcOption = []
|
||||||
text: v.bthBthnm,
|
this.optionData.forEach((v, index) => {
|
||||||
value: v.bthId
|
if (v.dictionariesName == 'vvyList') {
|
||||||
|
hcOption.push(v)
|
||||||
|
}
|
||||||
})
|
})
|
||||||
})
|
hcOption.forEach((v, index) => {
|
||||||
this.shipInfo.voyageScheduleDataList.forEach((v, index) => {
|
|
||||||
this.hcList.push({
|
this.hcList.push({
|
||||||
text: v.vvyName,
|
text: v.ptrDesc,
|
||||||
value: v.vvyId
|
value: v.ptrCode
|
||||||
|
})
|
||||||
|
})
|
||||||
|
// 船舶下拉数据
|
||||||
|
let bwOption = []
|
||||||
|
this.optionData.forEach((v, index) => {
|
||||||
|
if (v.dictionariesName == 'bthList') {
|
||||||
|
bwOption.push(v)
|
||||||
|
}
|
||||||
|
})
|
||||||
|
bwOption.forEach((v, index) => {
|
||||||
|
this.bwList.push({
|
||||||
|
text: v.ptrDesc,
|
||||||
|
value: v.ptrCode
|
||||||
})
|
})
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
// 获取当前行信息
|
// 获取当前行信息
|
||||||
getRow() {
|
getRow() {
|
||||||
this.peopleRow = uni.getStorageSync('peopleRow');
|
this.peopleRow = uni.getStorageSync('peopleRow');
|
||||||
this.peopleRowIndex = uni.getStorageSync('peopleRowIndex');
|
|
||||||
this.hcValue = this.peopleRow.vvyId
|
this.hcValue = this.peopleRow.vvyId
|
||||||
this.hcTextValue = this.peopleRow.vvyName
|
this.hcTextValue = this.peopleRow.vvyName
|
||||||
this.tqValue = this.peopleRow.weatherId
|
this.tqValue = this.peopleRow.weatherId
|
||||||
|
@ -208,9 +238,6 @@
|
||||||
},
|
},
|
||||||
// 弹框删除
|
// 弹框删除
|
||||||
delConfirm() {
|
delConfirm() {
|
||||||
// let addPeopleArr = uni.getStorageSync('addPeopleArr')
|
|
||||||
// addPeopleArr.splice(this.peopleRowIndex, 1)
|
|
||||||
// uni.setStorageSync('addPeopleArr', addPeopleArr);
|
|
||||||
let sql = `DELETE FROM messageRespList WHERE webId = '${this.peopleRow.webId}';`
|
let sql = `DELETE FROM messageRespList WHERE webId = '${this.peopleRow.webId}';`
|
||||||
this.executeSql(sql)
|
this.executeSql(sql)
|
||||||
uni.setStorageSync('tabsType', 0);
|
uni.setStorageSync('tabsType', 0);
|
||||||
|
@ -230,7 +257,7 @@
|
||||||
let webDate = api.getDate(date)
|
let webDate = api.getDate(date)
|
||||||
if (this.obj.state == "edit") {
|
if (this.obj.state == "edit") {
|
||||||
let sql =
|
let sql =
|
||||||
`UPDATE messageRespList SET bthId = '${this.bwValue}',bthIdName = '${this.bthIdName}',
|
`UPDATE messageRespList SET bthId = '${this.bwValue}',bthIdName = '${this.bwTextValue}',
|
||||||
jobStartTime = '${this.startTime}',jobEndTime = '${this.endTime}',shipPerson = '${this.shipValue}',
|
jobStartTime = '${this.startTime}',jobEndTime = '${this.endTime}',shipPerson = '${this.shipValue}',
|
||||||
vvyId = '${this.hcValue}',vvyName = '${this.hcTextValue}',weatherId = '${this.tqValue}',
|
vvyId = '${this.hcValue}',vvyName = '${this.hcTextValue}',weatherId = '${this.tqValue}',
|
||||||
weatherType = '${this.tqTextValue}',workSuite = '${this.workValue}',webStatus = '${webStatus}',
|
weatherType = '${this.tqTextValue}',workSuite = '${this.workValue}',webStatus = '${webStatus}',
|
||||||
|
@ -244,36 +271,6 @@
|
||||||
'${webStatus}','${webDate}')`
|
'${webStatus}','${webDate}')`
|
||||||
this.executeSql(sql)
|
this.executeSql(sql)
|
||||||
}
|
}
|
||||||
// let addPeopleArr = uni.getStorageSync('addPeopleArr')
|
|
||||||
// let addPeopleObj = {
|
|
||||||
// bthId: this.bwValue, // 泊位id
|
|
||||||
// bthIdName: this.bwTextValue, // 泊位名转义
|
|
||||||
// jobStartTime: this.startTime, // 作业开始时间
|
|
||||||
// jobEndTime: this.endTime, // 作业结束时间
|
|
||||||
// shipPerson: this.shipValue, // 单船人数
|
|
||||||
// vvyId: this.hcValue, // 航次id
|
|
||||||
// vvyName: this.hcTextValue, // 航次id名
|
|
||||||
// weatherId: this.tqValue, // 天气ID
|
|
||||||
// weatherType: this.tqTextValue, // 天气类型
|
|
||||||
// workSuite: this.workValue, // 作业组数
|
|
||||||
// tradeTypeName: this.shipInfo.voyageScheduleDataList[0].tradeTypeName, // 贸易类型
|
|
||||||
// importExportFlagName: this.shipInfo.voyageScheduleDataList[0].importExportFlagName, // 进出口
|
|
||||||
// spmName: this.shipInfo.voyageScheduleDataList[0].spmName, // 船只名
|
|
||||||
// }
|
|
||||||
// if (this.obj.state == "edit") {
|
|
||||||
// addPeopleArr[this.peopleRowIndex] = addPeopleObj;
|
|
||||||
// uni.setStorageSync('addPeopleArr', addPeopleArr);
|
|
||||||
// } else if (this.obj.state == "add") {
|
|
||||||
// if (addPeopleArr != "") {
|
|
||||||
// addPeopleArr.push(addPeopleObj)
|
|
||||||
// uni.setStorageSync('addPeopleArr', addPeopleArr);
|
|
||||||
// } else {
|
|
||||||
// addPeopleArr = []
|
|
||||||
// addPeopleArr.push(addPeopleObj)
|
|
||||||
// uni.setStorageSync('addPeopleArr', addPeopleArr);
|
|
||||||
// }
|
|
||||||
|
|
||||||
// }
|
|
||||||
uni.setStorageSync('tabsType', 0);
|
uni.setStorageSync('tabsType', 0);
|
||||||
uni.navigateTo({
|
uni.navigateTo({
|
||||||
url: '/pages/shipWork/mixWork'
|
url: '/pages/shipWork/mixWork'
|
||||||
|
|
|
@ -182,6 +182,7 @@
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script>
|
<script>
|
||||||
|
import sqlite from "../../common/sqlite.js"
|
||||||
export default {
|
export default {
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
|
@ -270,6 +271,9 @@
|
||||||
describe: "",
|
describe: "",
|
||||||
dgWork: "",
|
dgWork: "",
|
||||||
notes: "",
|
notes: "",
|
||||||
|
|
||||||
|
// 下拉数据
|
||||||
|
optionData: [],
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
@ -280,56 +284,103 @@
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
mounted() {
|
mounted() {
|
||||||
|
this.executeSql1('shipOption')
|
||||||
if (this.obj.state == 'edit') {
|
if (this.obj.state == 'edit') {
|
||||||
this.editData();
|
this.editData();
|
||||||
}
|
}
|
||||||
this.getShip()
|
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
|
// 查
|
||||||
|
executeSql1(tableName) {
|
||||||
|
let sql = `select * from ${tableName}`
|
||||||
|
sqlite.executeSqlCeshi(sql).then((value) => {
|
||||||
|
// 在resolve时执行的回调函数
|
||||||
|
this.optionData = value
|
||||||
|
this.getShip()
|
||||||
|
}).catch((error) => {
|
||||||
|
// 在reject时执行的回调函数
|
||||||
|
console.error(error);
|
||||||
|
});
|
||||||
|
},
|
||||||
// 获取船只信息
|
// 获取船只信息
|
||||||
getShip() {
|
getShip() {
|
||||||
this.shipInfo = uni.getStorageSync('shipInfo')
|
this.shipInfo = uni.getStorageSync('shipInfo')
|
||||||
// 航次数据
|
// 航次下拉数据
|
||||||
this.shipInfo.voyageScheduleDataList.forEach((v, index) => {
|
let hcOption = []
|
||||||
|
this.optionData.forEach((v, index) => {
|
||||||
|
if (v.dictionariesName == 'vvyList') {
|
||||||
|
hcOption.push(v)
|
||||||
|
}
|
||||||
|
})
|
||||||
|
hcOption.forEach((v, index) => {
|
||||||
this.hcList.push({
|
this.hcList.push({
|
||||||
text: v.vvyName,
|
text: v.ptrDesc,
|
||||||
value: v.vvyId
|
value: v.ptrCode
|
||||||
})
|
})
|
||||||
})
|
})
|
||||||
// 装卸类型数据
|
// 装卸类型数据
|
||||||
this.shipInfo.handTypeList.forEach((v, index) => {
|
let zxOption = []
|
||||||
|
this.optionData.forEach((v, index) => {
|
||||||
|
if (v.dictionariesName == 'handTypeList') {
|
||||||
|
zxOption.push(v)
|
||||||
|
}
|
||||||
|
})
|
||||||
|
zxOption.forEach((v, index) => {
|
||||||
this.zxList.push({
|
this.zxList.push({
|
||||||
text: v.ptrDesc,
|
text: v.ptrDesc,
|
||||||
value: v.ptrCode
|
value: v.ptrCode
|
||||||
})
|
})
|
||||||
})
|
})
|
||||||
// 工班数据
|
// 工班数据
|
||||||
this.shipInfo.shipmentBasicShiftList.forEach((v, index) => {
|
let gbOption = []
|
||||||
|
this.optionData.forEach((v, index) => {
|
||||||
|
if (v.dictionariesName == 'shiftList') {
|
||||||
|
gbOption.push(v)
|
||||||
|
}
|
||||||
|
})
|
||||||
|
gbOption.forEach((v, index) => {
|
||||||
this.gbList.push({
|
this.gbList.push({
|
||||||
text: v.pwcTypeDesc,
|
text: v.ptrDesc,
|
||||||
value: v.pwcId
|
value: v.ptrCode
|
||||||
})
|
})
|
||||||
})
|
})
|
||||||
// 车型数据
|
// 车型数据
|
||||||
this.shipInfo.shipmentVehicleModeList.forEach((v, index) => {
|
let cxOption = []
|
||||||
|
this.optionData.forEach((v, index) => {
|
||||||
|
if (v.dictionariesName == 'carList') {
|
||||||
|
cxOption.push(v)
|
||||||
|
}
|
||||||
|
})
|
||||||
|
cxOption.forEach((v, index) => {
|
||||||
this.cxList.push({
|
this.cxList.push({
|
||||||
text: v.bvmName,
|
text: v.ptrDesc,
|
||||||
value: v.bvmId
|
value: v.ptrCode
|
||||||
})
|
})
|
||||||
})
|
})
|
||||||
// 装卸方式
|
// 装卸方式
|
||||||
this.shipInfo.loadTypeList.forEach((v, index) => {
|
let fsOption = []
|
||||||
|
this.optionData.forEach((v, index) => {
|
||||||
|
if (v.dictionariesName == 'loadTypeList') {
|
||||||
|
fsOption.push(v)
|
||||||
|
}
|
||||||
|
})
|
||||||
|
fsOption.forEach((v, index) => {
|
||||||
this.fsList.push({
|
this.fsList.push({
|
||||||
text: v.ptrDesc,
|
text: v.ptrDesc,
|
||||||
value: v.ptrCode
|
value: v.ptrCode
|
||||||
})
|
})
|
||||||
})
|
})
|
||||||
// 翻仓类型
|
// 翻仓类型
|
||||||
this.shipInfo.turnoverTypeList.forEach((v, index) => {
|
let fcOption = []
|
||||||
|
this.optionData.forEach((v, index) => {
|
||||||
|
if (v.dictionariesName == 'turnoverTypeList') {
|
||||||
|
fcOption.push(v)
|
||||||
|
}
|
||||||
|
})
|
||||||
|
fcOption.forEach((v, index) => {
|
||||||
this.fcList.push({
|
this.fcList.push({
|
||||||
text: v.ptrDesc,
|
text: v.ptrDesc,
|
||||||
value: v.ptrCode
|
value: v.ptrCode
|
||||||
|
|
||||||
})
|
})
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
|
|
|
@ -11,7 +11,7 @@
|
||||||
</view>
|
</view>
|
||||||
<view class="li">
|
<view class="li">
|
||||||
<p>航次:</p>
|
<p>航次:</p>
|
||||||
<text>{{shipInfo.voyageScheduleDataList[0].vvyName}}</text>
|
<text>{{dataInfo.vvyName}}</text>
|
||||||
</view>
|
</view>
|
||||||
<view class="li">
|
<view class="li">
|
||||||
<p>进出口:</p>
|
<p>进出口:</p>
|
||||||
|
@ -60,7 +60,7 @@
|
||||||
<view class="ul" v-for="(item2,index2) in item.fcUlList2" :key="index2 + 'info'">
|
<view class="ul" v-for="(item2,index2) in item.fcUlList2" :key="index2 + 'info'">
|
||||||
<view class="li">
|
<view class="li">
|
||||||
<p>航次:</p>
|
<p>航次:</p>
|
||||||
<text>{{shipInfo.voyageScheduleDataList[0].vvyName}}</text>
|
<text>{{dataInfo.vvyName}}</text>
|
||||||
</view>
|
</view>
|
||||||
<view class="li">
|
<view class="li">
|
||||||
<p>翻舱起点:</p>
|
<p>翻舱起点:</p>
|
||||||
|
|
|
@ -2,40 +2,52 @@
|
||||||
<view class="shipInfo">
|
<view class="shipInfo">
|
||||||
<view class="container">
|
<view class="container">
|
||||||
<view class="ul">
|
<view class="ul">
|
||||||
<view class="li">船名:{{shipInfo.shipmentShipManage.vslCnname}}</view>
|
<view class="li">船名:{{shipInfo.vslCnname}}</view>
|
||||||
<view class="li">总重:{{shipInfo.shipmentShipManage.vslGton}}</view>
|
<view class="li">总重:{{shipInfo.vslGton}}</view>
|
||||||
<view class="li">净重:{{shipInfo.shipmentShipManage.vslNetton}}</view>
|
<view class="li">净重:{{shipInfo.vslNetton}}</view>
|
||||||
<view class="li">长度:{{shipInfo.shipmentShipManage.vslLoa}}</view>
|
<view class="li">长度:{{shipInfo.vslLoa}}</view>
|
||||||
<view class="li">宽度:{{shipInfo.shipmentShipManage.vslBreadth}}</view>
|
<view class="li">宽度:{{shipInfo.vslBreadth}}</view>
|
||||||
<view class="li">空载吃水:{{shipInfo.shipmentShipManage.vslDraftunload}}</view>
|
<view class="li">空载吃水:{{shipInfo.vslDraftunload}}</view>
|
||||||
<view class="li">重载吃水:{{shipInfo.shipmentShipManage.vslDraftload}}</view>
|
<view class="li">重载吃水:{{shipInfo.vslDraftload}}</view>
|
||||||
<view class="li">舱口高度:{{shipInfo.shipmentShipManage.spmCabinht}}</view>
|
<view class="li">舱口高度:{{shipInfo.spmCabinht}}</view>
|
||||||
<view class="li">最低作业潮水:{{shipInfo.shipmentShipManage.spmMintide}}</view>
|
<view class="li">最低作业潮水:{{shipInfo.spmMintide}}</view>
|
||||||
<view class="li">驾驶台位置:{{shipInfo.shipmentShipManage.spmCab}}</view>
|
<view class="li">驾驶台位置:{{shipInfo.spmCab}}</view>
|
||||||
<view class="li">跳板中左:{{shipInfo.shipmentShipManage.spmBoardCentrele}}</view>
|
<view class="li">跳板中左:{{shipInfo.spmBoardCentrele}}</view>
|
||||||
<view class="li">跳板前左:{{shipInfo.shipmentShipManage.spmBoardFrontle}}</view>
|
<view class="li">跳板前左:{{shipInfo.spmBoardFrontle}}</view>
|
||||||
<view class="li">跳板后左:{{shipInfo.shipmentShipManage.spmBoardLaterle}}</view>
|
<view class="li">跳板后左:{{shipInfo.spmBoardLaterle}}</view>
|
||||||
<view class="li">跳板中右:{{shipInfo.shipmentShipManage.spmBoardCentrerg}}</view>
|
<view class="li">跳板中右:{{shipInfo.spmBoardCentrerg}}</view>
|
||||||
<view class="li">跳板前右:{{shipInfo.shipmentShipManage.spmBoardFrontrg}}</view>
|
<view class="li">跳板前右:{{shipInfo.spmBoardFrontrg}}</view>
|
||||||
<view class="li">跳板后右 :{{shipInfo.shipmentShipManage.spmBoardLaterrg}}</view>
|
<view class="li">跳板后右 :{{shipInfo.spmBoardLaterrg}}</view>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script>
|
<script>
|
||||||
|
import sqlite from "../../common/sqlite.js"
|
||||||
export default {
|
export default {
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
shipInfo: {
|
shipInfo: {},
|
||||||
shipmentShipManage: {}
|
|
||||||
},
|
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
mounted() {
|
mounted() {
|
||||||
this.shipInfo = uni.getStorageSync('shipInfo')
|
// this.shipInfo = uni.getStorageSync('shipInfo')
|
||||||
|
this.executeSql1('shipmentShipManage')
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
|
// 查
|
||||||
|
executeSql1(tableName) {
|
||||||
|
let sql = `select * from ${tableName}`
|
||||||
|
sqlite.executeSqlCeshi(sql).then((value) => {
|
||||||
|
// 在resolve时执行的回调函数
|
||||||
|
this.shipInfo = value[0]
|
||||||
|
console.log(this.shipInfo)
|
||||||
|
}).catch((error) => {
|
||||||
|
// 在reject时执行的回调函数
|
||||||
|
console.error(error);
|
||||||
|
});
|
||||||
|
},
|
||||||
onBackPress(event) {
|
onBackPress(event) {
|
||||||
uni.navigateTo({
|
uni.navigateTo({
|
||||||
url: '/pages/shipWork/documentList'
|
url: '/pages/shipWork/documentList'
|
||||||
|
|
|
@ -92,6 +92,9 @@
|
||||||
supplyAmount: 0,
|
supplyAmount: 0,
|
||||||
// 日期
|
// 日期
|
||||||
supplyDate: [""],
|
supplyDate: [""],
|
||||||
|
|
||||||
|
// 下拉数据
|
||||||
|
optionData: [],
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
onLoad(options) {
|
onLoad(options) {
|
||||||
|
@ -104,25 +107,58 @@
|
||||||
if (this.obj.state == "edit" || this.obj.state == "look") {
|
if (this.obj.state == "edit" || this.obj.state == "look") {
|
||||||
this.getRow()
|
this.getRow()
|
||||||
}
|
}
|
||||||
this.getShip()
|
this.executeSql1('shipOption')
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
|
// 查
|
||||||
|
executeSql1(tableName) {
|
||||||
|
let sql = `select * from ${tableName}`
|
||||||
|
sqlite.executeSqlCeshi(sql).then((value) => {
|
||||||
|
// 在resolve时执行的回调函数
|
||||||
|
this.optionData = value
|
||||||
|
this.getShip()
|
||||||
|
}).catch((error) => {
|
||||||
|
// 在reject时执行的回调函数
|
||||||
|
console.error(error);
|
||||||
|
});
|
||||||
|
},
|
||||||
// 获取船只信息
|
// 获取船只信息
|
||||||
getShip() {
|
getShip() {
|
||||||
this.shipInfo = uni.getStorageSync('shipInfo')
|
this.shipInfo = uni.getStorageSync('shipInfo')
|
||||||
this.shipInfo.pubBerthesManageRespList.forEach((v, index) => {
|
// 航次下拉数据
|
||||||
this.bwList.push({
|
let hcOption = []
|
||||||
text: v.bthBthnm,
|
this.optionData.forEach((v, index) => {
|
||||||
value: v.bthId
|
if (v.dictionariesName == 'vvyList') {
|
||||||
|
hcOption.push(v)
|
||||||
|
}
|
||||||
})
|
})
|
||||||
})
|
hcOption.forEach((v, index) => {
|
||||||
this.shipInfo.voyageScheduleDataList.forEach((v, index) => {
|
|
||||||
this.hcList.push({
|
this.hcList.push({
|
||||||
text: v.vvyName,
|
text: v.ptrDesc,
|
||||||
value: v.vvyId
|
value: v.ptrCode
|
||||||
})
|
})
|
||||||
})
|
})
|
||||||
this.shipInfo.supplyTypeList.forEach((v, index) => {
|
// 泊位下拉数据
|
||||||
|
let bwOption = []
|
||||||
|
this.optionData.forEach((v, index) => {
|
||||||
|
if (v.dictionariesName == 'bthList') {
|
||||||
|
bwOption.push(v)
|
||||||
|
}
|
||||||
|
})
|
||||||
|
bwOption.forEach((v, index) => {
|
||||||
|
this.bwList.push({
|
||||||
|
text: v.ptrDesc,
|
||||||
|
value: v.ptrCode
|
||||||
|
})
|
||||||
|
})
|
||||||
|
// 供给下拉数据
|
||||||
|
let gjOption = []
|
||||||
|
this.optionData.forEach((v, index) => {
|
||||||
|
if (v.dictionariesName == 'supplyTypeList') {
|
||||||
|
gjOption.push(v)
|
||||||
|
}
|
||||||
|
})
|
||||||
|
gjOption.forEach((v, index) => {
|
||||||
this.gjList.push({
|
this.gjList.push({
|
||||||
text: v.ptrDesc,
|
text: v.ptrDesc,
|
||||||
value: v.ptrCode
|
value: v.ptrCode
|
||||||
|
@ -181,9 +217,6 @@
|
||||||
},
|
},
|
||||||
// 弹框删除
|
// 弹框删除
|
||||||
delConfirm() {
|
delConfirm() {
|
||||||
// let addSupplyArr = uni.getStorageSync('addSupplyArr')
|
|
||||||
// addSupplyArr.splice(this.supplyRowIndex, 1)
|
|
||||||
// uni.setStorageSync('addSupplyArr', addSupplyArr);
|
|
||||||
let sql = `DELETE FROM shipmentShipSupplyRespList WHERE webId = '${this.supplyRow.webId}';`
|
let sql = `DELETE FROM shipmentShipSupplyRespList WHERE webId = '${this.supplyRow.webId}';`
|
||||||
this.executeSql(sql)
|
this.executeSql(sql)
|
||||||
uni.navigateTo({
|
uni.navigateTo({
|
||||||
|
@ -217,33 +250,6 @@
|
||||||
'${webStatus}','${webDate}')`
|
'${webStatus}','${webDate}')`
|
||||||
this.executeSql(sql)
|
this.executeSql(sql)
|
||||||
}
|
}
|
||||||
// let addSupplyArr = uni.getStorageSync('addSupplyArr')
|
|
||||||
// let addSupplyObj = {
|
|
||||||
// vvyId: this.vvyId,
|
|
||||||
// vvyName: this.vvyName,
|
|
||||||
// stopBerthage: this.stopBerthage,
|
|
||||||
// stopBerthageName: this.stopBerthageName,
|
|
||||||
// sssId: this.supplyTypeId,
|
|
||||||
// supplyType: this.supplyType,
|
|
||||||
// supplyAmount: this.supplyAmount,
|
|
||||||
// supplyDate: this.supplyDate,
|
|
||||||
// tradeTypeName: this.shipInfo.voyageScheduleDataList[0].tradeTypeName,
|
|
||||||
// importExportFlagName: this.shipInfo.voyageScheduleDataList[0].importExportFlagName,
|
|
||||||
// spmName: this.shipInfo.voyageScheduleDataList[0].spmName,
|
|
||||||
// }
|
|
||||||
// if (this.obj.state == "edit") {
|
|
||||||
// addSupplyArr[this.supplyRowIndex] = addSupplyObj;
|
|
||||||
// uni.setStorageSync('addSupplyArr', addSupplyArr);
|
|
||||||
// } else if (this.obj.state == "add") {
|
|
||||||
// if (addSupplyArr != "") {
|
|
||||||
// addSupplyArr.push(addSupplyObj)
|
|
||||||
// uni.setStorageSync('addSupplyArr', addSupplyArr);
|
|
||||||
// } else {
|
|
||||||
// addSupplyArr = []
|
|
||||||
// addSupplyArr.push(addSupplyObj)
|
|
||||||
// uni.setStorageSync('addSupplyArr', addSupplyArr);
|
|
||||||
// }
|
|
||||||
// }
|
|
||||||
uni.navigateTo({
|
uni.navigateTo({
|
||||||
url: '/pages/shipWork/supply'
|
url: '/pages/shipWork/supply'
|
||||||
})
|
})
|
||||||
|
|
|
@ -103,6 +103,9 @@
|
||||||
shiftingBerthTime: [''],
|
shiftingBerthTime: [''],
|
||||||
// 停泊时间
|
// 停泊时间
|
||||||
noProductBerthTime: [''],
|
noProductBerthTime: [''],
|
||||||
|
|
||||||
|
// 下拉数据
|
||||||
|
optionData: [],
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
onLoad(options) {
|
onLoad(options) {
|
||||||
|
@ -115,22 +118,48 @@
|
||||||
if (this.obj.state == "edit" || this.obj.state == "look") {
|
if (this.obj.state == "edit" || this.obj.state == "look") {
|
||||||
this.getRow()
|
this.getRow()
|
||||||
}
|
}
|
||||||
this.getShip()
|
this.executeSql1('shipOption')
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
|
// 查
|
||||||
|
executeSql1(tableName) {
|
||||||
|
let sql = `select * from ${tableName}`
|
||||||
|
sqlite.executeSqlCeshi(sql).then((value) => {
|
||||||
|
// 在resolve时执行的回调函数
|
||||||
|
this.optionData = value
|
||||||
|
this.getShip()
|
||||||
|
}).catch((error) => {
|
||||||
|
// 在reject时执行的回调函数
|
||||||
|
console.error(error);
|
||||||
|
});
|
||||||
|
},
|
||||||
// 获取船只信息
|
// 获取船只信息
|
||||||
getShip() {
|
getShip() {
|
||||||
this.shipInfo = uni.getStorageSync('shipInfo')
|
this.shipInfo = uni.getStorageSync('shipInfo')
|
||||||
this.shipInfo.pubBerthesManageRespList.forEach((v, index) => {
|
// 航次下拉数据
|
||||||
this.bwList.push({
|
let hcOption = []
|
||||||
text: v.bthBthnm,
|
this.optionData.forEach((v, index) => {
|
||||||
value: v.bthId
|
if (v.dictionariesName == 'vvyList') {
|
||||||
|
hcOption.push(v)
|
||||||
|
}
|
||||||
})
|
})
|
||||||
})
|
hcOption.forEach((v, index) => {
|
||||||
this.shipInfo.voyageScheduleDataList.forEach((v, index) => {
|
|
||||||
this.hcList.push({
|
this.hcList.push({
|
||||||
text: v.vvyName,
|
text: v.ptrDesc,
|
||||||
value: v.vvyId
|
value: v.ptrCode
|
||||||
|
})
|
||||||
|
})
|
||||||
|
// 泊位下拉数据
|
||||||
|
let bwOption = []
|
||||||
|
this.optionData.forEach((v, index) => {
|
||||||
|
if (v.dictionariesName == 'bthList') {
|
||||||
|
bwOption.push(v)
|
||||||
|
}
|
||||||
|
})
|
||||||
|
bwOption.forEach((v, index) => {
|
||||||
|
this.bwList.push({
|
||||||
|
text: v.ptrDesc,
|
||||||
|
value: v.ptrCode
|
||||||
})
|
})
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
|
@ -190,9 +219,6 @@
|
||||||
},
|
},
|
||||||
// 弹框删除
|
// 弹框删除
|
||||||
delConfirm() {
|
delConfirm() {
|
||||||
// let addUntieArr = uni.getStorageSync('addUntieArr')
|
|
||||||
// addUntieArr.splice(this.untieRowIndex, 1)
|
|
||||||
// uni.setStorageSync('addUntieArr', addUntieArr);
|
|
||||||
let sql = `DELETE FROM attachUnmoorRespList WHERE webId = '${this.untieRow.webId}';`
|
let sql = `DELETE FROM attachUnmoorRespList WHERE webId = '${this.untieRow.webId}';`
|
||||||
this.executeSql(sql)
|
this.executeSql(sql)
|
||||||
uni.navigateTo({
|
uni.navigateTo({
|
||||||
|
@ -225,34 +251,6 @@
|
||||||
'${this.attachTime}','${this.unmoorTime}','${this.shiftingBerthTime}','${this.noProductBerthTime}','${webStatus}','${webDate}')`
|
'${this.attachTime}','${this.unmoorTime}','${this.shiftingBerthTime}','${this.noProductBerthTime}','${webStatus}','${webDate}')`
|
||||||
this.executeSql(sql)
|
this.executeSql(sql)
|
||||||
}
|
}
|
||||||
// let addUntieArr = uni.getStorageSync('addUntieArr')
|
|
||||||
// let addUntieObj = {
|
|
||||||
// shipDeadWeight: this.zlShip,
|
|
||||||
// vvyId: this.vvyId,
|
|
||||||
// vvyName: this.vvyName,
|
|
||||||
// bthId: this.bthId,
|
|
||||||
// bthIdName: this.bthIdName,
|
|
||||||
// tradeTypeName: this.shipInfo.voyageScheduleDataList[0].tradeTypeName,
|
|
||||||
// importExportFlagName: this.shipInfo.voyageScheduleDataList[0].importExportFlagName,
|
|
||||||
// spmName: this.shipInfo.voyageScheduleDataList[0].spmName,
|
|
||||||
// attachTime: this.attachTime,
|
|
||||||
// unmoorTime: this.unmoorTime,
|
|
||||||
// shiftingBerthTime: this.shiftingBerthTime,
|
|
||||||
// noProductBerthTime: this.noProductBerthTime
|
|
||||||
// }
|
|
||||||
// if (this.obj.state == "edit") {
|
|
||||||
// addUntieArr[this.untieRowIndex] = addUntieObj;
|
|
||||||
// uni.setStorageSync('addUntieArr', addUntieArr);
|
|
||||||
// } else if (this.obj.state == "add") {
|
|
||||||
// if (addUntieArr != "") {
|
|
||||||
// addUntieArr.push(addUntieObj)
|
|
||||||
// uni.setStorageSync('addUntieArr', addUntieArr);
|
|
||||||
// } else {
|
|
||||||
// addUntieArr = []
|
|
||||||
// addUntieArr.push(addUntieObj)
|
|
||||||
// uni.setStorageSync('addUntieArr', addUntieArr);
|
|
||||||
// }
|
|
||||||
// }
|
|
||||||
uni.navigateTo({
|
uni.navigateTo({
|
||||||
url: '/pages/shipWork/untieCord'
|
url: '/pages/shipWork/untieCord'
|
||||||
})
|
})
|
||||||
|
|
|
@ -119,6 +119,9 @@
|
||||||
workTime: ['', ''],
|
workTime: ['', ''],
|
||||||
startTime: "",
|
startTime: "",
|
||||||
endTime: "",
|
endTime: "",
|
||||||
|
|
||||||
|
// 下拉数据
|
||||||
|
optionData: [],
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
onLoad(options) {
|
onLoad(options) {
|
||||||
|
@ -131,38 +134,74 @@
|
||||||
if (this.obj.state == 'edit' || this.obj.state == 'look') {
|
if (this.obj.state == 'edit' || this.obj.state == 'look') {
|
||||||
this.getRow();
|
this.getRow();
|
||||||
}
|
}
|
||||||
this.getShip()
|
this.executeSql1('shipOption')
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
|
// 查
|
||||||
|
executeSql1(tableName) {
|
||||||
|
let sql = `select * from ${tableName}`
|
||||||
|
sqlite.executeSqlCeshi(sql).then((value) => {
|
||||||
|
// 在resolve时执行的回调函数
|
||||||
|
this.optionData = value
|
||||||
|
this.getShip()
|
||||||
|
}).catch((error) => {
|
||||||
|
// 在reject时执行的回调函数
|
||||||
|
console.error(error);
|
||||||
|
});
|
||||||
|
},
|
||||||
// 获取船只信息
|
// 获取船只信息
|
||||||
getShip() {
|
getShip() {
|
||||||
this.shipInfo = uni.getStorageSync('shipInfo')
|
this.shipInfo = uni.getStorageSync('shipInfo')
|
||||||
// 航次数据
|
// 航次下拉数据
|
||||||
this.shipInfo.voyageScheduleDataList.forEach((v, index) => {
|
let hcOption = []
|
||||||
|
this.optionData.forEach((v, index) => {
|
||||||
|
if (v.dictionariesName == 'vvyList') {
|
||||||
|
hcOption.push(v)
|
||||||
|
}
|
||||||
|
})
|
||||||
|
hcOption.forEach((v, index) => {
|
||||||
this.hcList.push({
|
this.hcList.push({
|
||||||
text: v.vvyName,
|
text: v.ptrDesc,
|
||||||
value: v.vvyId
|
value: v.ptrCode
|
||||||
|
})
|
||||||
|
})
|
||||||
|
// 泊位下拉数据
|
||||||
|
let bwOption = []
|
||||||
|
this.optionData.forEach((v, index) => {
|
||||||
|
if (v.dictionariesName == 'bthList') {
|
||||||
|
bwOption.push(v)
|
||||||
|
}
|
||||||
|
})
|
||||||
|
bwOption.forEach((v, index) => {
|
||||||
|
this.bwList.push({
|
||||||
|
text: v.ptrDesc,
|
||||||
|
value: v.ptrCode
|
||||||
})
|
})
|
||||||
})
|
})
|
||||||
// 装卸类型数据
|
// 装卸类型数据
|
||||||
this.shipInfo.handTypeList.forEach((v, index) => {
|
let zxOption = []
|
||||||
|
this.optionData.forEach((v, index) => {
|
||||||
|
if (v.dictionariesName == 'handTypeList') {
|
||||||
|
zxOption.push(v)
|
||||||
|
}
|
||||||
|
})
|
||||||
|
zxOption.forEach((v, index) => {
|
||||||
this.zxList.push({
|
this.zxList.push({
|
||||||
text: v.ptrDesc,
|
text: v.ptrDesc,
|
||||||
value: v.ptrCode
|
value: v.ptrCode
|
||||||
})
|
})
|
||||||
})
|
})
|
||||||
// 工班数据
|
// 工班数据
|
||||||
this.shipInfo.shipmentBasicShiftList.forEach((v, index) => {
|
let gbOption = []
|
||||||
|
this.optionData.forEach((v, index) => {
|
||||||
|
if (v.dictionariesName == 'shiftList') {
|
||||||
|
gbOption.push(v)
|
||||||
|
}
|
||||||
|
})
|
||||||
|
gbOption.forEach((v, index) => {
|
||||||
this.gbList.push({
|
this.gbList.push({
|
||||||
text: v.pwcTypeDesc,
|
text: v.ptrDesc,
|
||||||
value: v.pwcId
|
value: v.ptrCode
|
||||||
})
|
|
||||||
})
|
|
||||||
// 泊位数据
|
|
||||||
this.shipInfo.pubBerthesManageRespList.forEach((v, index) => {
|
|
||||||
this.bwList.push({
|
|
||||||
text: v.bthBthnm,
|
|
||||||
value: v.bthId
|
|
||||||
})
|
})
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
|
@ -236,9 +275,6 @@
|
||||||
},
|
},
|
||||||
// 弹框删除
|
// 弹框删除
|
||||||
delConfirm() {
|
delConfirm() {
|
||||||
// let addAssignArr = uni.getStorageSync('addAssignArr')
|
|
||||||
// addAssignArr.splice(this.assignRowIndex, 1)
|
|
||||||
// uni.setStorageSync('addAssignArr', addAssignArr);
|
|
||||||
let sql = `DELETE FROM shipmentAdviserLayoutRespList WHERE webId = '${this.assignRow.webId}';`
|
let sql = `DELETE FROM shipmentAdviserLayoutRespList WHERE webId = '${this.assignRow.webId}';`
|
||||||
this.executeSql(sql)
|
this.executeSql(sql)
|
||||||
uni.navigateTo({
|
uni.navigateTo({
|
||||||
|
@ -273,39 +309,6 @@
|
||||||
'${webStatus}','${webDate}')`
|
'${webStatus}','${webDate}')`
|
||||||
this.executeSql(sql)
|
this.executeSql(sql)
|
||||||
}
|
}
|
||||||
// let addAssignArr = uni.getStorageSync('addAssignArr')
|
|
||||||
// let addAssignObj = {
|
|
||||||
// vvyId: this.vvyId,
|
|
||||||
// vvyName: this.vvyName,
|
|
||||||
// bthId: this.bthId,
|
|
||||||
// bthIdName: this.bthIdName,
|
|
||||||
// pwcTypeId: this.pwcTypeId,
|
|
||||||
// pwcType: this.pwcType,
|
|
||||||
// personNumber: this.personNumber,
|
|
||||||
// loaderTypeId: this.loaderTypeId,
|
|
||||||
// loaderType: this.loaderType,
|
|
||||||
// vehicleSize: this.vehicleSize,
|
|
||||||
// sparePart: this.sparePart,
|
|
||||||
// workTime: this.workTime,
|
|
||||||
// startTime: this.startTime,
|
|
||||||
// endTime: this.endTime,
|
|
||||||
// tradeTypeName: this.shipInfo.voyageScheduleDataList[0].tradeTypeName,
|
|
||||||
// importExportFlagName: this.shipInfo.voyageScheduleDataList[0].importExportFlagName,
|
|
||||||
// spmName: this.shipInfo.voyageScheduleDataList[0].spmName,
|
|
||||||
// }
|
|
||||||
// if (this.obj.state == "edit") {
|
|
||||||
// addAssignArr[this.assignRowIndex] = addAssignObj;
|
|
||||||
// uni.setStorageSync('addAssignArr', addAssignArr);
|
|
||||||
// } else if (this.obj.state == "add") {
|
|
||||||
// if (addAssignArr != "") {
|
|
||||||
// addAssignArr.push(addAssignObj)
|
|
||||||
// uni.setStorageSync('addAssignArr', addAssignArr);
|
|
||||||
// } else {
|
|
||||||
// addAssignArr = []
|
|
||||||
// addAssignArr.push(addAssignObj)
|
|
||||||
// uni.setStorageSync('addAssignArr', addAssignArr);
|
|
||||||
// }
|
|
||||||
// }
|
|
||||||
uni.navigateTo({
|
uni.navigateTo({
|
||||||
url: '/pages/shipWork/workAssign'
|
url: '/pages/shipWork/workAssign'
|
||||||
})
|
})
|
||||||
|
|
Loading…
Reference in New Issue