Commit c1bc4acd authored by Smile's avatar Smile

需求131 后台-集运-包裹列表-签收包裹/修改签收 页面入口添加

parent 8df055b5
......@@ -9,7 +9,7 @@
:key="$route.fullPath"
:validate-on-rule-change="false"
>
<div class="page-title">{{ editMode ? $t('编辑包裹') + '-' + (form.consNum) : $t('新建包裹') }}</div>
<div class="page-title">{{ editMode ? $t('编辑包裹') + '-' + (form.consNum) : (signedMode?$t('签收包裹') + '-' + (form.consNum):$t('新建包裹')) }}</div>
<el-card class="form-section mt-10">
<el-form-item :label="$t('集运仓库')" v-model="form.wareId" prop="wareId" :rules="{
required: true, message: '请选择集运仓库', trigger: 'blur'
......@@ -195,15 +195,15 @@
</el-row>
</div>
</el-card>
<el-card class="form-section mt-10">
<el-card class="form-section mt-10" v-if="signedMode">
<div slot="header" class="card-title1">{{ $t('签收图片') }}</div>
<el-form-item prop="mediaUrl">
<image-upload v-model="form.mediaUrl"/>
</el-form-item>
</el-card>
</el-form>
<el-button type="primary" @click="submitForm(0)" v-if="!editMode&&!signedMode">{{ $t('添加包裹') }}</el-button><!--草稿-->
<el-button type="primary" @click="submitForm(1)" v-if="editMode">{{ $t('保存') }}</el-button><!--草稿-->
<el-button type="primary" @click="submitForm(0)" v-if="editMode">{{ $t('添加包裹') }}</el-button><!--草稿-->
<el-button type="primary" @click="submitForm(1)" v-if="!editMode&&!signedMode">{{ $t('保存') }}</el-button><!--草稿-->
<el-button type="primary" @click="submitForm(1)" v-if="signedMode">{{ $t('确认签收') }}</el-button><!--草稿-->
<el-button @click="$store.dispatch('tagsView/delCurrentView')">{{ $t('取消') }}</el-button>
<choose-contact-dialog v-if="!!contactChooseType" :type="2" @choose="onContactChoose"
......@@ -318,10 +318,10 @@ export default {
},
// 是否编辑
editMode() {
return this.$route.path.indexOf('create') == -1
return this.$route.path.indexOf('edit') > 0
},
signedMode() {
return this.$route.path.indexOf('signed') >= 0
return this.$route.path.indexOf('sign') > 0;
},
exportCityList() {
console.log("this.tradeCityList", this.tradeCityList)
......@@ -409,7 +409,11 @@ export default {
});
});
}else {
this.createCons()
if (val===0){
this.createCons()
}else {
this.updateCons()
}
}
},
......
......@@ -97,7 +97,19 @@
<!-- 列表 -->
<el-table v-loading="loading" :data="list" @selection-change="handleSelectionChange">
<el-table-column type="selection" width="55" fixed></el-table-column>
<el-table-column label="快递单号" align="center" prop="expressNo"/>
<el-table-column label="快递单号" align="center" prop="expressNo">
<template slot-scope="scope">
<router-link
:to="{
path: '/cons/detail',
query: { consId: scope.row.id }
}"
class="link-type"
>
<span>{{ scope.row.expressNo }}</span>
</router-link>
</template>
</el-table-column>
<el-table-column label="客户" align="center">
<template slot-scope="scope">
{{ scope.row.customerName }}({{ scope.row.customerNumber }})
......@@ -199,8 +211,9 @@
</el-table-column>
<el-table-column label="操作" align="center" class-name="small-padding fixed-width">
<template slot-scope="scope">
<el-button size="mini" type="text" icon="el-icon-edit" @click="handleUpdate(scope.row)"
v-hasPermi="['ecw:cons:update']">修改
<el-button size="mini" type="text" icon="el-icon-edit" @click="handleUpdate(scope.row)">修改
</el-button>
<el-button size="mini" type="text" icon="el-icon-edit" @click="handleSign(scope.row)">签收
</el-button>
<el-button size="mini" type="text" icon="el-icon-delete" @click="handleDelete(scope.row)"
v-hasPermi="['ecw:cons:delete']">删除
......@@ -218,7 +231,15 @@
<el-button size="mini" type="text" icon="el-icon-edit" @click="consFollowup(scope.row)">{{ $t('跟进') }}
</el-button>
<el-button size="mini" type="text" icon="el-icon-edit" @click="exceptionHandling(scope.row)">{{$t('处理异常')}}</el-button>
<!-- 退仓 -->
<el-button size="mini" type="text" icon="el-icon-edit"
@click.native="
show = true
consId = scope.row.id
"
v-hasPermi="['ecw:order:warehouse_exit']"
>{{ $t("退仓") }}
</el-button>
</template>
</el-table-column>
</el-table>
......@@ -317,6 +338,7 @@
:consIds="consIds"></batch-sign-off>
<batch-cons-edit :showConsBatchEdit.sync="showConsBatchEdit" @determine="getList"
:consIds="consIds"></batch-cons-edit>
<consWithdrawal v-if="show" :dialog-visible="show" :consId="consId"></consWithdrawal>
</div>
</template>
......@@ -332,15 +354,16 @@ import SpecialNeedsConsLook from "@/views/ecw/cons/components/SpecialNeedsConsLo
import {getCurrencyList} from "@/api/ecw/currency"
import FeeApplicationCons from "@/views/ecw/cons/components/FeeApplicationCons.vue"
import FeeApplication from "@/views/ecw/order/feeApplication.vue"
import {getChannelList} from "@/api/ecw/channel";
import ConsFollowupEdit from "@/views/ecw/consFollowup/components/ConsFollowupEdit.vue"
import BatchSignOff from "@/views/ecw/cons/batchSignOff.vue";
import BatchConsEdit from "@/views/ecw/cons/batchConsEdit.vue";
import consWithdrawal from "@/views/ecw/cons/withdrawal.vue";
export default {
name: "Cons",
components: {
consWithdrawal,
UserSelector,
Transmutation,
Template,
......@@ -359,6 +382,8 @@ export default {
exportLoading: false,
// 显示搜索条件
showSearch: true,
show: false,
consId: undefined,
// 总条数
total: 0,
// 集运包裹主列表
......@@ -673,12 +698,23 @@ export default {
},
/** 修改按钮操作 */
handleUpdate(row) {
this.reset();
const id = row.id;
getCons(id).then(response => {
this.form = response.data;
this.open = true;
this.title = "修改集运包裹主";
this.$router.push({
path: "/cons/edit",
query: {
id: id,
}
});
},
/** 签收按钮操作 */
handleSign(row) {
debugger
const id = row.id;
this.$router.push({
path: "/cons/sign",
query: {
id: id,
}
});
},
/** 提交按钮 */
......
<script>
// 对edit组件复用并更名,防止keepalive缓存数据
import edit from './edit.vue'
edit.name = 'EcwConsSign'
export default edit
</script>
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment