|
|
@@ -97,11 +97,15 @@
|
|
|
</el-button>
|
|
|
</el-button-group>
|
|
|
<div v-if="bidStatus === 1">
|
|
|
- <el-button type="primary" size="small" @click="showAddShip()">
|
|
|
+ <el-button
|
|
|
+ v-if="tenderData.status === 1"
|
|
|
+ type="primary"
|
|
|
+ size="small"
|
|
|
+ @click="showAddShip()"
|
|
|
+ >
|
|
|
<i class="el-icon-plus"></i>
|
|
|
<span>添加船舶</span>
|
|
|
</el-button>
|
|
|
- <el-button @click="print">print</el-button>
|
|
|
</div>
|
|
|
</div>
|
|
|
<div v-if="bidStatus === 1">
|
|
|
@@ -140,7 +144,10 @@
|
|
|
<div class="df aic mb10">
|
|
|
<div class="info-title">装载吨位:</div>
|
|
|
<div class="info-text df aic">
|
|
|
- <el-input v-model="item.loadTons">
|
|
|
+ <el-input
|
|
|
+ v-model="item.loadTons"
|
|
|
+ :disabled="item.status === 2 || tenderData.status === 2"
|
|
|
+ >
|
|
|
<template #append>吨</template>
|
|
|
</el-input>
|
|
|
</div>
|
|
|
@@ -148,7 +155,10 @@
|
|
|
<div class="df aic mb10">
|
|
|
<div class="info-title">预计船期:</div>
|
|
|
<div class="info-text df aic">
|
|
|
- <el-input v-model="item.estimatedSailingDays">
|
|
|
+ <el-input
|
|
|
+ v-model="item.estimatedSailingDays"
|
|
|
+ :disabled="item.status === 2 || tenderData.status === 2"
|
|
|
+ >
|
|
|
<template #append>天</template>
|
|
|
</el-input>
|
|
|
</div>
|
|
|
@@ -156,7 +166,10 @@
|
|
|
<div class="df aic mb10">
|
|
|
<div class="info-title">装卸天数:</div>
|
|
|
<div class="info-text df aic">
|
|
|
- <el-input v-model="item.loadDiscDays">
|
|
|
+ <el-input
|
|
|
+ v-model="item.loadDiscDays"
|
|
|
+ :disabled="item.status === 2 || tenderData.status === 2"
|
|
|
+ >
|
|
|
<template #append>天</template>
|
|
|
</el-input>
|
|
|
</div>
|
|
|
@@ -164,7 +177,10 @@
|
|
|
<div class="df aic mb10">
|
|
|
<div class="info-title">报价:</div>
|
|
|
<div class="info-text df aic">
|
|
|
- <el-input v-model="item.quotePrice">
|
|
|
+ <el-input
|
|
|
+ v-model="item.quotePrice"
|
|
|
+ :disabled="item.status === 2 || tenderData.status === 2"
|
|
|
+ >
|
|
|
<template #append>元/吨</template>
|
|
|
</el-input>
|
|
|
</div>
|
|
|
@@ -186,7 +202,11 @@
|
|
|
</el-image>
|
|
|
</div>
|
|
|
</div>
|
|
|
- <div class="df aic jcfe mt20" v-if="item.status !== 2">
|
|
|
+
|
|
|
+ <div
|
|
|
+ class="df aic jcfe mt20"
|
|
|
+ v-if="item.status !== 2 && tenderData.status === 1"
|
|
|
+ >
|
|
|
<el-button type="danger" size="small" @click="deleteTender(index)">
|
|
|
删除
|
|
|
</el-button>
|
|
|
@@ -206,6 +226,36 @@
|
|
|
投标
|
|
|
</el-button>
|
|
|
</div>
|
|
|
+ <div v-if="tenderData.status === 2">
|
|
|
+ <div v-if="item.status === 2 && tenderData.transType === 1">
|
|
|
+ <div class="df aic">
|
|
|
+ <div class="info-title">航次开始时间:</div>
|
|
|
+ <div class="info-text df aic">
|
|
|
+ <el-date-picker
|
|
|
+ class="w200"
|
|
|
+ v-model="item.voyageStartDate"
|
|
|
+ type="date"
|
|
|
+ value-format="YYYY/MM/DD"
|
|
|
+ placeholder="航次开始时间"
|
|
|
+ :disabled="!!item.voyageId"
|
|
|
+ ></el-date-picker>
|
|
|
+ </div>
|
|
|
+ </div>
|
|
|
+ <div class="df jcfe mt20">
|
|
|
+ <el-button
|
|
|
+ type="primary"
|
|
|
+ size="small"
|
|
|
+ @click="createTenderVoyage(item)"
|
|
|
+ >
|
|
|
+ {{ item.voyageId ? "查看航次详情" : "创建航次" }}
|
|
|
+ </el-button>
|
|
|
+ </div>
|
|
|
+ </div>
|
|
|
+ <div class="df aic jcfe mt20">
|
|
|
+ <el-tag v-if="item.status === 2" type="success">已中标</el-tag>
|
|
|
+ <el-tag v-else type="error">未中标</el-tag>
|
|
|
+ </div>
|
|
|
+ </div>
|
|
|
</div>
|
|
|
</div>
|
|
|
</div>
|
|
|
@@ -420,8 +470,45 @@ function tenderShip(index, bidType) {
|
|
|
});
|
|
|
}
|
|
|
|
|
|
-function print() {
|
|
|
- console.log(tenderData.value);
|
|
|
+async function createTenderVoyage(item) {
|
|
|
+ if (item.voyageId) {
|
|
|
+ router.push({
|
|
|
+ path: "/voyage/voyageDetail",
|
|
|
+ query: {
|
|
|
+ id: item.voyageId,
|
|
|
+ },
|
|
|
+ });
|
|
|
+ } else {
|
|
|
+ if (!item.voyageStartDate) {
|
|
|
+ ElMessage.error("请选择航次开始时间");
|
|
|
+ return;
|
|
|
+ }
|
|
|
+ ElMessageBox.confirm("是否创建航次?", "提示", {
|
|
|
+ confirmButtonText: "确定",
|
|
|
+ cancelButtonText: "取消",
|
|
|
+ type: "warning",
|
|
|
+ }).then(async () => {
|
|
|
+ let { data } = await api.createTenderVoyage({
|
|
|
+ tenderId: route.query.id,
|
|
|
+ proxyBidId: item.id,
|
|
|
+ voyageStartDate: item.voyageStartDate,
|
|
|
+ });
|
|
|
+ if (data.status === 0) {
|
|
|
+ ElNotification({
|
|
|
+ title: "成功",
|
|
|
+ message: "创建航次成功",
|
|
|
+ type: "success",
|
|
|
+ });
|
|
|
+ getTenderDetail();
|
|
|
+ } else {
|
|
|
+ ElNotification({
|
|
|
+ title: "失败",
|
|
|
+ message: data.msg,
|
|
|
+ type: "error",
|
|
|
+ });
|
|
|
+ }
|
|
|
+ });
|
|
|
+ }
|
|
|
}
|
|
|
|
|
|
onMounted(() => {
|