Commit 6b7d0f83 authored by dragondean@qq.com's avatar dragondean@qq.com
parents cfcfa44c 8cc706aa
{
"ExpandedNodes": [
"",
"\\src"
],
"SelectedNode": "\\src\\main.js",
"PreviewInSolutionExplorer": false
}
\ No newline at end of file
File added
......@@ -63,6 +63,15 @@ export function getReceivableDiscountLogById(query) {
})
}
// 根据订单ID获得需要预付应收款列表
export function getFirstReceivableListByOrderId(query) {
return request({
url: '/ecw/receivable/getFirstReceivableListByOrderId',
method: 'get',
params: query
})
}
// 核销收款单
// export function receiptVerification(id) {
// return request({
......
......@@ -303,6 +303,21 @@ export const constantRoutes = [
name: 'discount',
meta: {title: '订单优惠申请', icon: '', activeMenu: '/order/index'}
},
{
path: 'specialWeight/:orderId(\\d+)',
component: (resolve) => import('@/views/ecw/order/special/weight'),
props: true,
name: 'special-weight',
meta: {title: '申请重货优惠', icon: '', activeMenu: '/order/index'}
},
{
path: 'specialCommission/:orderItemId(\\d+)',
component: (resolve) => import('@/views/ecw/order/special/commission'),
props: true,
name: 'special-commission',
meta: {title: '修改佣金规则', icon: '', activeMenu: '/order/index'}
},
{
path: 'associated-order/:orderId(\\d+)',
component: (resolve) => require(['@/views/ecw/order/associatedOrder'],resolve),
......
......@@ -171,7 +171,7 @@ export const DICT_TYPE = {
NEED_KNOW_TYPE:'need_know_type',//需知类型
NEED_KNOW_STATUS:'need_know_status',//需知状态
MANUAL_EXCEPTION_TYPE:'manual_exception_type',
APPLY_STATUS:'apply_status',//特价申请审核状态
ECASH_INIT:'ecash_init', //e-cash
FEE_TYPE:'receivable_fee_type',
......
......@@ -117,7 +117,7 @@
<el-button type="primary" @click="handlerClick('modifyCabinet','修改柜信息')">修改柜信息</el-button>
</div>
<div v-if="isUnderReview">
<el-button type="primary" :disabled=true>封柜审核中</el-button>
<el-button type="primary" @click="jumpReviewDetail">封柜审核中</el-button>
<el-button plain type="primary" @click="canclAudit">取消审核</el-button>
<el-button plain type="primary" @click="$emit('closeDialog')">返回</el-button>
</div>
......@@ -220,6 +220,7 @@ import {
serviceMsg,
getCapacity,
sumStatistics,
toReviewDetail,
} from "../../utils";
import splitOrder from "./splitOrder.vue";
import WorkFlow from "@/components/WorkFlow";
......@@ -519,6 +520,11 @@ export default {
});
});
},
jumpReviewDetail() {
const { cabinetApprovalInfo } = this.shipmentObj;
toReviewDetail.apply(this, [cabinetApprovalInfo.bpmProcessId]);
this.$emit("closeDialog", "close");
},
},
computed: {
/* 是否审核中 */
......
......@@ -30,7 +30,7 @@
<el-date-picker type="datetime" placeholder="请选择日期" v-model="cusDeclarationObj.dcCutOffTime" value-format="yyyy-MM-dd HH:mm:ss"></el-date-picker>
</el-form-item>
<el-form-item label="状态" prop="dcCustomsStatus">
<el-radio-group v-model="cusDeclarationObj.dcCustomsStatus">
<el-radio-group v-model="cusDeclarationObj.dcCustomsStatus" :disabled="inReview">
<el-radio v-for="item in this.getDictDatas(DICT_TYPE.BOX_SHIPPING_DCCUSTOMS_STATUS)" :key="item.value" :label="item.value">{{item.label}}</el-radio>
</el-radio-group>
</el-form-item>
......@@ -38,7 +38,7 @@
<!-- 查验 -->
<div v-show="cusDeclarationObj.dcCustomsStatus === '3'">
<el-form-item label="查验">
<el-radio-group v-model="cusDeclarationObj.dcCheckStatus">
<el-radio-group v-model="cusDeclarationObj.dcCheckStatus" :disabled="inReview">
<el-radio v-for="item in this.getDictDatas(DICT_TYPE.BOX_SHIPPING_CHECK_STATUS)" :key="item.value" :label="item.value">{{item.label}}</el-radio>
</el-radio-group>
</el-form-item>
......@@ -70,9 +70,13 @@
</el-form-item>
</el-form>
<el-row class="operate-button" v-if="inReview">
<el-button type="primary" @click="jumpReviewDetail">{{cusDeclarationObj.dcCheckStatus === '1' ? '部分退场审核中' : '全部退场审核中'}}</el-button>
<el-button type="primary" plain @click="canclAudit">{{cusDeclarationObj.dcCheckStatus === '1' ? '取消部分退场审核' : '取消全部退场审核'}}</el-button>
</el-row>
<el-row class="operate-button">
<el-button type="primary" @click="onSubmit(1)">保存</el-button>
<el-button type="success" @click="onSubmit(2)">提交</el-button>
<el-button type="success" v-if="!inReview" @click="onSubmit(2)">提交</el-button>
<el-button @click="cancel">关闭</el-button>
<el-button type="primary" @click="extraCost" v-show="cusDeclarationObj.dcCustomsStatus === '2' || cusDeclarationObj.dcCustomsStatus === '3'">额外费用</el-button>
</el-row>
......@@ -141,7 +145,12 @@ import {
extraCostUpdate,
approvalCreate,
} from "@/api/ecw/boxSea";
import { formatNumberString, formatDateStr, serviceMsg } from "../utils";
import {
formatNumberString,
formatDateStr,
serviceMsg,
toReviewDetail,
} from "../utils";
import ImageUpload from "@/components/ImageUpload";
/**
......@@ -151,6 +160,9 @@ export default {
name: "cusDeclaration",
inheritAttrs: false,
components: { supplierSelect, ImageUpload },
props: {
shipmentObj: Object,
},
data() {
return {
// 报关对象
......@@ -160,7 +172,9 @@ export default {
dcBoxWgt: [{ required: true, message: "必填", trigger: "change" }],
dcGoodsWgt: [{ required: true, message: "必填", trigger: "change" }],
dcCustomsType: [{ required: true, message: "必填", trigger: "change" }],
dcCustomsStatus: [{ required: true, message: "必填", trigger: "change" }],
dcCustomsStatus: [
{ required: true, message: "必填", trigger: "change" },
],
},
// 弹窗配置
dialogConfig: {
......@@ -173,14 +187,16 @@ export default {
costOrderList: [],
// 额外费用列表
costList: [],
// 是否审核中
inReview: false,
};
},
created() {
const { currNode, shipmentObj } = this.$attrs;
const { currNode } = this.$attrs;
const { voName } = currNode;
let oldData = {
...shipmentObj[voName],
documentInfo: shipmentObj.documentInfo?.split(",") ?? [],
...this.shipmentObj[voName],
documentInfo: this.shipmentObj.documentInfo?.split(",") ?? [],
};
oldData = formatDateStr(oldData, [
"dcCutOffTime",
......@@ -199,36 +215,73 @@ export default {
const newList = Array.from(new Set(documentInfo));
return newList.length > 2 ? "混合报关" : "VGM声明";
},
submitCustomsCreate(operateType) {
customsCreate({
...this.cusDeclarationObj,
shipmentId: this.shipmentObj.id,
operateType,
}).then((res) => {
serviceMsg(res, this).then(() => {
this.cancel("submit");
});
});
},
/** 提交 */
onSubmit(operateType) {
this.$refs["cusDeclarationForm"].validate((valid) => {
if (valid) {
customsCreate({
...this.cusDeclarationObj,
shipmentId: this.$attrs.shipmentObj.id,
operateType,
}).then((res) => {
// 查验
const { dcCustomsStatus, dcCheckStatus } = this.cusDeclarationObj;
if (dcCustomsStatus === "3") {
// 退场/部分退场
if (["1", "2"].includes(dcCheckStatus)) {
approvalCreate({
approvalStatus: 0,
approvalType: dcCheckStatus === "1" ? 5 : 6, // 5报关全退,6报关部分退
shipmentId: this.$attrs.shipmentObj.id,
}).then((res) => {
serviceMsg(res, this).then(() => {
this.cancel("submit");
if (operateType === 1) {
this.submitCustomsCreate(operateType);
return;
// 保存
}
// 提交
const { dcCustomsStatus, dcCheckStatus } = this.cusDeclarationObj;
// 1.状态 报关中/放行 直接提交
if (dcCustomsStatus !== "3") {
this.submitCustomsCreate(operateType);
return;
}
// 2.查验状态,空 直接提交
if (!dcCheckStatus) {
this.submitCustomsCreate(operateType);
return;
}
// 3.查验状态,查验后放行 直接提交
if (dcCheckStatus === "3") {
const { checkExamineStatus } = this.shipmentObj;
// 没有退场审核中的状态
if (checkExamineStatus !== 1) {
this.submitCustomsCreate(operateType);
return;
}
}
// 4.查验状态,退场/部分退场 提示
if (["1", "2"].includes(dcCheckStatus)) {
const { checkExamineStatus } = this.shipmentObj;
// 退场审核状态,1-审核中,2-审核成功,3-审核失败,4-取消
if ([0, 3, 4].includes(checkExamineStatus)) {
this.$modal
.confirm(
`您确认提交${
dcCheckStatus === "1" ? "全部退场" : "部分退场"
}审核吗?`
)
.then(() => {
customsCreate({
...this.cusDeclarationObj,
shipmentId: this.shipmentObj.id,
operateType,
}).then((res) => {
serviceMsg(res, this).then(() => {
// 触发外层重新查询出货信息
this.$emit("getBoxInfo");
});
});
});
}
} else {
serviceMsg(res, this).then(() => {
this.cancel("submit");
});
})
.catch(() => {});
}
});
}
}
});
},
......@@ -239,7 +292,7 @@ export default {
return;
}
extraCostOrder({
shipmentId: this.$attrs.shipmentObj.id,
shipmentId: this.shipmentObj.id,
orderNo: this.orderNo,
}).then((res) => {
this.costOrderList = [
......@@ -254,7 +307,7 @@ export default {
/* 查询额外费用订单 */
searchCostList(orderId) {
extraCostList({
shipmentId: this.$attrs.shipmentObj.id,
shipmentId: this.shipmentObj.id,
orderId: orderId,
}).then((res) => {
this.costList = res.data.map((item) => {
......@@ -272,7 +325,7 @@ export default {
fee: row.fee,
orderId: row.orderId,
orderNo: row.orderNo,
shipmentId: this.$attrs.shipmentObj.id,
shipmentId: this.shipmentObj.id,
}).then((res) => {
serviceMsg(res, this).then(() => {
this.searchCostList(row.orderId);
......@@ -321,12 +374,15 @@ export default {
},
// 额外费用
extraCost() {
const { shipmentObj } = this.$attrs;
// 清空额外费用
this.orderNo = "";
this.costOrderList = [];
this.costList = [];
this.$set(this.dialogConfig, "title", `${shipmentObj.selfNo} 报关费用`);
this.$set(
this.dialogConfig,
"title",
`${this.shipmentObj.selfNo} 报关费用`
);
this.$set(this.dialogConfig, "dialogVisible", true);
},
// 计算VGM重量
......@@ -345,6 +401,27 @@ export default {
dcBoxWgtTmp + dcGoodsWgtTmp
);
},
// 审核详情
jumpReviewDetail() {
const { customsApprovalInfo } = this.shipmentObj;
toReviewDetail.apply(this, [customsApprovalInfo.bpmProcessId]);
this.cancel("close");
},
/* 取消审核 */
canclAudit() {
const { currNode, shipmentObj } = this.$attrs;
const { voName } = currNode;
approvalCancel({
applyReason: "取消审核",
id: shipmentObj[voName].id,
shipmentId: shipmentObj.id,
}).then((res) => {
serviceMsg(res, this).then(() => {
// 触发外层重新查询出货信息
this.$emit("getBoxInfo");
});
});
},
},
watch: {
"cusDeclarationObj.dcBoxWgt"(dcBoxWgt) {
......@@ -358,6 +435,18 @@ export default {
this.$set(this.cusDeclarationObj, "dcCheckStatus", "");
}
},
shipmentObj: {
deep: true,
immediate: true,
handler: function (val) {
// 监听查验状态变化
let { checkExamineStatus } = val;
if (checkExamineStatus === 1) {
// 按钮变成审核中
this.inReview = true;
}
},
},
},
};
</script>
......
......@@ -277,7 +277,7 @@
<work-flow xmlkey="shipment_preassemble" v-model="selectedUsers"></work-flow>
</div>
<div v-show="isAudit">
<el-button type="primary" :disabled=true>审核中</el-button>
<el-button type="primary" @click="jumpReviewDetail">审核中</el-button>
<el-button plain type="primary" @click="canclAudit">取消审核</el-button>
<el-button plain type="primary" @click="closeDialog">返回</el-button>
</div>
......@@ -302,7 +302,13 @@ import {
approvalCancel,
} from "@/api/ecw/boxSea";
import userSelect from "./common/userSelect.vue";
import { formatDate, getTotlContent, serviceMsg, getCapacity } from "../utils";
import {
formatDate,
getTotlContent,
serviceMsg,
getCapacity,
toReviewDetail,
} from "../utils";
import dayjs from "dayjs";
import WorkFlow from "@/components/WorkFlow";
......@@ -613,6 +619,11 @@ export default {
});
});
},
jumpReviewDetail() {
const { currNode, shipmentObj } = this.$attrs;
toReviewDetail.apply(this, [shipmentObj[currNode.voName].bpmProcessId]);
this.$emit("closeDialog");
},
},
};
</script>
......
......@@ -56,7 +56,7 @@
</el-table-column>
<el-table-column label="异常状态" align="center" prop="">
<template slot-scope="scope">
<el-button type="text" size="small" @click="handleError(scope.row)" icon="el-icon-edit">{{getOrderError(scope.row, 'errorStatus')}}</el-button>
<el-button v-if="scope.row.exceptionList" type="text" size="small" @click="handleError(scope.row)" icon="el-icon-edit">{{getOrderError(scope.row, 'errorStatus')}}</el-button>
</template>
</el-table-column>
<el-table-column label="异常类型" align="center" prop="">
......@@ -100,7 +100,7 @@
<el-button plain type="primary" @click="$emit('closeStart')">返回</el-button>
</div>
<div v-if="isUnderReview">
<el-button type="primary" :disabled=true>卸柜审核中</el-button>
<el-button type="primary" @click="jumpReviewDetail">卸柜审核中</el-button>
<el-button plain type="primary" @click="canclAudit">取消审核</el-button>
<el-button plain type="primary" @click="$emit('closeStart')">返回</el-button>
</div>
......@@ -123,7 +123,7 @@ import {
approvalCancel,
getSectionList,
} from "@/api/ecw/boxSea";
import { serviceMsg, getTotlContent } from "../../utils";
import { serviceMsg, getTotlContent, toReviewDetail } from "../../utils";
import WorkFlow from "@/components/WorkFlow";
/**
......@@ -277,7 +277,7 @@ export default {
});
},
// 获取异常类型
getUnloadError(exceptionList) {
getUnloadError(exceptionList = []) {
const codes = this.getDictDatas(this.DICT_TYPE.ORDER_ERROR_TYPE);
let errorLabels = [];
exceptionList.forEach((item) => {
......@@ -302,6 +302,11 @@ export default {
path: `/order/pending?id=${row.orderId}`,
});
},
jumpReviewDetail() {
const { cabinetUnloadApprovalInfo } = this.$attrs.shipmentObj;
toReviewDetail.apply(this, [cabinetUnloadApprovalInfo.bpmProcessId]);
this.$emit("closeStart", "close");
},
},
computed: {
/* 是否审核中 */
......
......@@ -20,7 +20,7 @@
<!-- 弹窗 -->
<el-dialog custom-class="shipping-dialog" :title="dialogConfig.title" :visible.sync="dialogConfig.dialogVisible" :width="dialogConfig.width" :fullscreen="dialogConfig.fullscreen" :close-on-click-modal=false :modal-append-to-body=false append-to-body>
<component v-bind:is="currentComponent" v-if="dialogConfig.dialogVisible" @closeDialog="closeDialog" v-bind="$attrs" :shipmentObj="shipmentObj" :currNode="currNode"></component>
<component v-bind:is="currentComponent" v-if="dialogConfig.dialogVisible" @closeDialog="closeDialog" v-bind="$attrs" v-on="$listeners" :shipmentObj="shipmentObj" :currNode="currNode"></component>
</el-dialog>
</div>
</template>
......@@ -178,7 +178,8 @@ export default {
watch: {
/* 监听发货对象 */
shipmentObj(val) {
let newNodes = [];
let newNodes = [],
finish = 0;
// 迭代每个节点
for (let i = 0; i < this.seaBaseData.length; i++) {
const nodes = this.seaBaseData[i];
......@@ -187,6 +188,7 @@ export default {
const node = nodes[j];
const { keyName, voName, status, type } = node;
// agent
if (!keyName && type === "agent") {
if (val[voName]) {
// 已完成agent节点
......@@ -212,6 +214,20 @@ export default {
if (end.includes(val[keyName])) {
node.currStatus = "end";
// 报关
if (type === "cusDeclaration") {
const { dcCustomsStatus, dcCheckStatus } = val;
// 查验状态并且是退场/部分退场
if (dcCustomsStatus === 3 && [1, 2].includes(dcCheckStatus)) {
// 只有审核通过并且已处理才算完成
if (val.checkExamineStatus === 2 && val.checkDealStatus === 1) {
// 已完成节点个数
++nodeIndex;
} else {
continue;
}
}
}
// 已完成节点个数
++nodeIndex;
}
......@@ -219,10 +235,11 @@ export default {
// 如果相等标识该步骤已完成
if (nodeIndex === nodes.length) {
// 加1表示为已完成步骤后一步
this.currIndex = i + 1;
finish = finish + 1;
}
newNodes.push(nodes);
}
this.currIndex = finish;
this.processData = newNodes;
},
},
......
......@@ -1030,6 +1030,18 @@ function serviceMsg(result, _vue) {
});
}
/**
* 跳转审核详情
*
* @param {*} bpmProcessId
*/
function toReviewDetail(bpmProcessId) {
this.$router.push({
path: "/bpm/process-instance/detail",
query: { id: bpmProcessId },
});
}
export {
getStatusName,
getColmnMapping,
......@@ -1044,4 +1056,5 @@ export {
getCapacity,
sumStatistics,
serviceMsg,
toReviewDetail,
};
......@@ -147,6 +147,7 @@ import {DICT_TYPE} from '@/utils/dict'
import { userList } from "@/api/system/user"
import CustomerSelector from '@/components/CustomerSelector'
import ProductSelector from '@/components/ProductSelector'
import getProduct from '@/api/ecw/product'
export default {
name: "Exception",
......@@ -217,14 +218,14 @@ export default {
this.getList();
},
handEdit(id){
this.$router.push({
path:"./pending?id="+id,
})
this.$router.push({
path:"./pending?id="+id,
})
},
specialNeedTag(value){
var tag = ''
if(!value){
return
return
}
if(value.indexOf("1")!=-1||value.indexOf("2")!=-1){
tag += '(木)'
......
......@@ -14,18 +14,18 @@
<dict-tag :type="DICT_TYPE.ORDER_STATUS" :value="orderData.status" />
</el-descriptions-item>
<el-descriptions-item label="送货日期">
{{orderData.consigneeVO?orderData.consigneeVO.deliveryDate||'':''}}
{{orderData.deliveryDate||''}}
<!-- <span v-if="orderData">{{orderData.status>=5?(orderData.orderItemVOList.length>0?parseTime(orderData.orderItemVOList[0].warehouseInInfoVO.firstInTime):''):(orderData.consigneeVO?orderData.consigneeVO.deliveryDate:'')}}</span> -->
</el-descriptions-item>
<el-descriptions-item label="运输方式">
<dict-tag :type="DICT_TYPE.ECW_TRANSPORT_TYPE" :value="orderData.transportId" />
</el-descriptions-item>
<el-descriptions-item label="始发地">
{{orderData.logisticsInfoDto?orderData.logisticsInfoDto.startTitleZh:''}}
</el-descriptions-item>
<el-descriptions-item label="目的地">
{{orderData.logisticsInfoDto?orderData.logisticsInfoDto.destTitleZh:''}}
</el-descriptions-item>
<el-descriptions-item label="始发地" :span="2">
{{orderData.logisticsInfoDto?orderData.logisticsInfoDto.startAddressZh:''}}
</el-descriptions-item>
<el-descriptions-item label="目的地">
{{orderData.logisticsInfoDto?orderData.logisticsInfoDto.destAddressZh:''}}
</el-descriptions-item>
</el-descriptions>
<el-descriptions :column="4">
<el-descriptions-item label="发货人">
......@@ -91,7 +91,7 @@
<el-table-column label="操作" align="center">
<template slot-scope="scope">
<el-tag v-if="scope.row.orderExceptionStatus>0">已完成</el-tag>
<el-button v-else size="mini" type="text" icon="el-icon-edit" @click="handEdit(scope.row.id,scope.row.orderExceptionType)">处理</el-button>
<el-button v-else size="mini" type="text" icon="el-icon-edit" @click="handEdit(scope.row)">处理</el-button>
</template>
</el-table-column>
</el-table>
......@@ -150,14 +150,24 @@ export default {
});
},
handEdit(id, type){
if(type == 8||type==15){
handEdit(row){
if(row.orderExceptionType=='order_no_quote_exception'){
getProduct(row.orderItemId).then(res=>{
this.$router.push({
name: 'ProductPrice',
query: {
product_id: row.orderItemId,
product_type: res.data.typeId
}
})
})
}else if(row.orderExceptionType == 'order_heavy_cargo_exception'||row.orderExceptionType=='order_bulky_cargo_exception'){
this.$router.push({
path:"/order/weightDeal?id="+id,
path:"/order/weightDeal?id="+row.id+'&type='+row.orderExceptionType,
})
}else{
this.$router.push({
path:"/order/prepayDeal?id="+id,
path:"/order/prepayDeal?id="+row.id,
})
}
......
This diff is collapsed.
<template>
<div class="app-container">
<!-- 搜索工作栏 -->
<el-card>
<div slot="header" class="card-title">修改佣金规则-{{form.orderNo||''}}</div>
<el-form :model="form" ref="queryForms" label-width="120px" class="card">
<el-form-item label="商品类型">
<span>{{form.prodType }}</span>
</el-form-item>
<el-form-item label="商品名称">
<span>{{ form.prodTitleZh }}</span>
</el-form-item>
<el-form-item label="英文名称">
<span>{{ form.prodTitleEn }}</span>
</el-form-item>
<el-form-item label="线路">
{{ `【${getDictDataLabel(DICT_TYPE.TRANSPORT_TYPE, form.transportId)}】${ getChannelNameById(form.channelId) }从【${form.startTitleZh}】发往【${form.destTitleZh}】`}}
</el-form-item>
<el-form-item label="运费:" >
<span>{{ form.orgFreight }} {{ currentMap[form.orgFreightCurrency] }}</span>
</el-form-item>
<el-form-item label="清关费:">
<span>{{ form.orgClearanceFreight }} {{ currentMap[form.orgClearanceFreightCurrency] }}</span>
</el-form-item>
<el-form-item label="佣金类型:">
<el-radio v-model="form.commissionType" v-for="dict in getDictDatas('commission_type')"
:key="dict.value" :label="dict.label" :value="dict.value">
</el-radio>
</el-form-item>
<el-form-item v-if="form.commissionType==3" label="暗佣佣金:">
<el-input style="width: 100px;" type="text" v-model="form.lightCommissionAmount" />
<el-select v-model="form.commissionCurrencyId" style="width: 100px;margin-left: 10px;">
<el-option v-for="dict in getDictDatas('shipping_price_unit')"
:key="dict.value" :label="dict.label" :value="dict.value"/>
</el-select>
<el-select v-model="form.commissionCurrencyId" style="width: 100px;margin-left: 10px;">
<el-option v-for="dict in unitType"
:key="dict.id" :label="dict.titleZh" :value="dict.id"/>
</el-select>
</el-form-item >
<el-form-item v-if="form.commissionType==1||form.commissionType==3" label="明佣佣金:">
<el-input style="width: 100px;" type="text" v-model="form.lightCommissionAmount" />
<el-select v-model="form.commissionCurrencyId" style="width: 100px;margin-left: 10px;">
<el-option v-for="dict in getDictDatas('shipping_price_unit')"
:key="dict.value" :label="dict.label" :value="dict.value"/>
</el-select>
<el-select v-model="form.commissionCurrencyId" style="width: 100px;margin-left: 10px;">
<el-option v-for="dict in unitType"
:key="dict.id" :label="dict.titleZh" :value="dict.id"/>
</el-select>
</el-form-item >
<el-form-item v-if="form.commissionType==1" label="商品:">
<span>{{form.prodTitleZh }}</span>
<span>销售价:{{11}}美元/千克</span>
<span v-if="form.commissionType==3">成本价:190美元/千克</span>
<span v-if="form.commissionType==2" style="color: #1E98D7;" @click="$router.phsh(`/customer/customerCommission`)">去设置</span>
<span v-if="form.commissionType==3">实际佣金返点:40美元/千克</span>
</el-form-item>
<el-form-item label="审核状态:">
<dict-tag :type="DICT_TYPE.APPLY_STATUS" :value="form.applyStatus"></dict-tag>
</el-form-item>
</el-form>
</el-card>
<div slot="header" class="card-title">审批流程</div>
<work-flow xmlkey="commission_config" v-model="selectedUsers" style="margin-top: 20px;"></work-flow>
<div slot="footer" class="card footer_btn">
<el-button type="primary" v-if="form.applyStatus==0" @click="submitForm">提交</el-button>
<el-button plain type="primary" v-if="form.applyStatus==0" @click="$router.back()">取消</el-button>
<el-button v-if="form.applyStatus==1" type="primary" disabled>审核中</el-button>
<el-button v-if="form.applyStatus==1" plain type="primary" @click="dialogVisible = true">取消审核</el-button>
<el-button v-if="form.applyStatus==1" plain type="primary" @click="$router.back()">返回</el-button>
</div>
<el-dialog
title="提示"
:visible.sync="dialogVisible"
width="30%">
<span class="cancel_notice">特价申请正在审核中,你确定取消特价申请吗?</span>
<div class="cancel_content">
<span>取消原因:</span>
<el-input v-model="reason" placeholder="请输入取消原因"></el-input>
</div>
<span slot="footer" class="dialog-footer">
<el-button @click="dialogVisible = false"> </el-button>
<el-button type="primary" @click="cancelSplit"> </el-button>
</span>
</el-dialog>
</div>
</template>
<script>
import {getDictData, getDictDatas,DICT_TYPE,getDictDataLabel} from '@/utils/dict'
import WorkFlow from '@/components/WorkFlow'
import {getOrder,getOrderSpecial,createOrderSpecial} from '@/api/ecw/order'
import {getChannelList} from "@/api/ecw/channel"
import { getCurrencyList } from '@/api/ecw/currency'
import { getProductAttrList } from '@/api/ecw/productAttr'
import {getUnitList} from '@/api/ecw/unit'
export default {
name: "specialCommission",
components: {
WorkFlow
},
props: {
orderItemId: [String, Number]
},
data() {
return {
reason:'',
dialogVisible:false,
loading:false,
form:{},
selectedUsers:[],
orderData:{},
channelList:[],
currencyList:[],
productAttrList:[],
unitType:[]
};
},
created() {
if(this.orderItemId){
this.form.orderItemId = this.orderItemId - 0
this.getOrderSpecialData()
}
// this.getOrderData()
// this.getList()
this.getUnitTypeData()
getChannelList().then(res => this.channelList = res.data)
getCurrencyList().then(res => this.currencyList = res.data)
getProductAttrList().then(res => this.productAttrList = res.data)
},
computed:{
getDictData(){
return (type, value) => getDictData(type, value) || {}
},
getDictDatas(){
return getDictDatas
},
// 根据渠道id显示渠道名
getChannelNameById(){
return channelId => {
const s = this.channelList.find(item => item.channelId == channelId) ?. nameZh
return s ? '' + s + '' : ''
}
},
currentMap(){
let map = {}
this.currencyList.forEach(item => {
map[item.id] = item.titleZh
})
return map
}
},
methods: {
getUnitTypeData () {
getUnitList().then(res => {
if(res.code==0&&res.data&&res.data.length>0){
this.unitType = res.data
}
})
},
getOrderData(){
getOrder(this.queryParams.orderId).then(response => {
this.orderData = response.data
});
},
getProductAttrNameById(id){
return this.productAttrList.find(e => e.id === id)?.attrName || ''
},
/** 查询列表 */
getOrderSpecialData(){
getOrderSpecial(this.form.orderItemId,3).then(r => {
this.form = r.data
})
},
submitForm(){
createOrderSpecial({
applyType: this.form.applyType,
lineId: this.form.lineId,
commissionType: this.form.commissionType,
orderId: this.form.orderId,
orderNo: this.form.orderNo,
orderItemId: this.form.orderItemId,
prodId:this.form.prodId,
ccIds:this.selectedUsers.join(',')
}).then(r => {
this.$message.success(r.msg || '提交成功')
})
},
cancelSplit(){
let that = this
if(!that.reason){
that.$message.error("请输入取消原因");
return
}
cancelApply({orderId:that.queryParams.orderId,reason:that.reason}).then(res=>{
that.$message.success("取消成功");
that.$router.back()
})
},
}
}
</script>
<style>
.card-title{
font-size: 18px;
font-weight: bold;
margin-top: 10px;
}
.card-info{
font-size: 16px;
}
.card{
margin-top: 20px;
}
.btn-header{
width: 90%;
display: flex;
align-items: center;
justify-content: space-between;
margin: 20px 0;
}
.red{
color:#ff3430;
font-size: 15px;
}
.footer_btn{
padding-bottom: 60px;
}
.cancel_notice{
font-size: 16px;
font-weight: 600;
}
.cancel_content{
display: flex;
align-items: center;
padding-top: 20px;
}
.cancel_content span{
width: 100px;
}
</style>
......@@ -79,7 +79,7 @@
label="操作">
<template v-slot="{row}">
<el-button size="mini" type="text" v-hasPermi="['ecw:order:update']" @click="$router.push(`/order/discount/${row.orderItemId}?orderId=${row.orderId}`)">优惠申请</el-button>
<el-button size="mini" type="text" v-hasPermi="['ecw:order:update']">佣金规则</el-button>
<el-button size="mini" type="text" v-hasPermi="['ecw:order:update']" @click="$router.push(`/order/specialCommission/${row.orderItemId}`)">佣金规则</el-button>
<el-button size="mini" type="text" v-hasPermi="['ecw:order:update']">管理折扣</el-button>
</template>
</el-table-column>
......@@ -87,7 +87,7 @@
</el-table>
<div style="text-align: center;margin-top: 80px">
<el-button type="primary">申请重货优惠</el-button>
<el-button type="primary" @click="toweight">申请重货优惠</el-button>
<el-button type="primary">申请泡货优惠</el-button>
<el-button type="primary">关闭窗口</el-button>
</div>
......@@ -152,6 +152,11 @@ export default {
this.order = response.data
})
},
toweight(){
this.$router.push({
path:"/order/specialWeight/"+this.params.orderId,
})
},
getProductNamesByIds(ids){
const result = []
ids.split(',').forEach(e => {
......
<template>
<div class="app-container">
<!-- 搜索工作栏 -->
<el-card>
<div slot="header" class="card-title">申请泡货优惠-{{queryParams.orderNo||''}}</div>
<el-form :model="queryParams" ref="queryForms" size="small" :inline="true" label-width="120px" class="card">
<el-row >
<el-form-item label="原泡货标准:" label-width="150px">
<span>{{queryParams.orgVWeight}}kg/cbm</span>
</el-form-item>
</el-row>
<el-row :span="8" >
<el-form-item label="* 现泡货申请标准:" size="medium" label-width="150px">
<el-input style="width: 100px;" type="text" v-model="queryParams.vweight" />
<span style="margin-left: 10px;">kg/cbm</span>
</el-form-item>
</el-row>
<el-row :span="8">
<el-form-item label="备注:" size="medium" label-width="150px">
<el-input style="width: 500px;" type="textarea" v-model="queryParams.orderExceptionHandlerRemark" />
</el-form-item>
</el-row>
</el-form>
</el-card>
<work-flow xmlkey="heavy_goods_discount" v-model="selectedUsers" style="margin-top: 20px;"></work-flow>
<div slot="footer" class="card footer_btn">
<el-button type="primary" @click="submitForm">提交</el-button>
<el-button plain type="primary" @click="$router.back()">取消</el-button>
<!-- <el-button v-if="orderData.inWarehouseState==207" type="primary" disabled>审核中</el-button> -->
<!-- <el-button v-if="orderData.inWarehouseState==207" plain type="primary" @click="dialogVisible = true">取消审核</el-button> -->
<!-- <el-button v-if="orderData.inWarehouseState==207" plain type="primary" @click="$router.back()">返回</el-button> -->
</div>
<el-dialog
title="提示"
:visible.sync="dialogVisible"
width="30%">
<span class="cancel_notice">申请泡货优惠正在审核中,你确定取消申请泡货优惠吗?</span>
<div class="cancel_content">
<span>取消原因:</span>
<el-input v-model="reason" placeholder="请输入取消原因"></el-input>
</div>
<span slot="footer" class="dialog-footer">
<el-button @click="dialogVisible = false">取 消</el-button>
<el-button type="primary" @click="cancelSplit">确 定</el-button>
</span>
</el-dialog>
</div>
</template>
<script>
import {getDictData, getDictDatas,DICT_TYPE} from '@/utils/dict'
import WorkFlow from '@/components/WorkFlow'
import {getOrderSpecial,createOrderSpecial} from '@/api/ecw/order'
export default {
name: "specialWeight",
components: {
WorkFlow
},
props: {
orderId: [String, Number]
},
data() {
return {
reason:'',
dialogVisible:false,
loading:false,
queryParams:{
orderId:7,
lang:0
},
selectedUsers:[],
orderData:{},
};
},
created() {
if (this.orderId) {
this.queryParams.orderId = this.orderId
this.getOrderSpecialData()
}
// this.getList()
},
computed:{
getDictData(){
return (type, value) => getDictData(type, value) || {}
},
getDictDatas(){
return getDictDatas
}
},
methods: {
getOrderSpecialData(){
getOrderSpecial(this.queryParams.orderId,5).then(r => {
this.queryParams = r.data
})
},
submitForm(){
createOrderSpecial({
applyType: this.queryParams.applyType,
lineId: this.queryParams.lineId,
vweight: this.queryParams.vweight,
orderId: this.queryParams.orderId,
orderNo: this.queryParams.orderNo,
orderItemId: this.queryParams.orderItemId,
prodId:this.queryParams.prodId,
ccIds:this.selectedUsers.join(',')
}).then(r => {
this.$message.success(r.msg || '提交成功')
})
},
cancelSplit(){
let that = this
if(!that.reason){
that.$message.error("请输入取消原因");
return
}
cancelApply({orderId:that.queryParams.orderId,reason:that.reason}).then(res=>{
that.$message.success("取消成功");
that.$router.back()
})
},
}
}
</script>
<style>
.card-title{
font-size: 18px;
font-weight: bold;
margin-top: 10px;
}
.card-info{
font-size: 16px;
}
.card{
margin-top: 20px;
}
.btn-header{
width: 90%;
display: flex;
align-items: center;
justify-content: space-between;
margin: 20px 0;
}
.red{
color:#ff3430;
font-size: 15px;
}
.footer_btn{
padding-bottom: 60px;
}
.cancel_notice{
font-size: 16px;
font-weight: 600;
}
.cancel_content{
display: flex;
align-items: center;
padding-top: 20px;
}
.cancel_content span{
width: 100px;
}
</style>
<template>
<div class="app-container">
<!-- 搜索工作栏 -->
<el-card>
<div slot="header" class="card-title">申请重货优惠-{{queryParams.orderNo||''}}</div>
<el-form :model="queryParams" ref="queryForms" size="small" :inline="true" label-width="120px" class="card">
<el-row >
<el-form-item label="原重货标准:" label-width="150px">
<span>{{queryParams.orgWVolume}}kg/cbm</span>
</el-form-item>
</el-row>
<el-row :span="8" >
<el-form-item label="* 现重货申请标准:" size="medium" label-width="150px">
<el-input style="width: 100px;" type="text" v-model="queryParams.wvolume" />
<span style="margin-left: 10px;">kg/cbm</span>
</el-form-item>
</el-row>
<el-row :span="8">
<el-form-item label="备注:" size="medium" label-width="150px">
<el-input style="width: 500px;" type="textarea" v-model="queryParams.orderExceptionHandlerRemark" />
</el-form-item>
</el-row>
</el-form>
</el-card>
<work-flow xmlkey="heavy_goods_discount" v-model="selectedUsers" style="margin-top: 20px;"></work-flow>
<div slot="footer" class="card footer_btn">
<el-button type="primary" v-if="queryParams.applyStatus==0" @click="submitForm">提交</el-button>
<el-button plain type="primary" v-if="queryParams.applyStatus==0" @click="$router.back()">取消</el-button>
<el-button v-if="queryParams.applyStatus==1" type="primary" disabled>审核中</el-button>
<el-button v-if="queryParams.applyStatus==1" plain type="primary" @click="dialogVisible = true">取消审核</el-button>
<el-button v-if="queryParams.applyStatus==1" plain type="primary" @click="$router.back()">返回</el-button>
</div>
<el-dialog
title="提示"
:visible.sync="dialogVisible"
width="30%">
<span class="cancel_notice">申请重货优惠正在审核中,你确定取消申请重货优惠吗?</span>
<div class="cancel_content">
<span>取消原因:</span>
<el-input v-model="reason" placeholder="请输入取消原因"></el-input>
</div>
<span slot="footer" class="dialog-footer">
<el-button @click="dialogVisible = false">取 消</el-button>
<el-button type="primary" @click="cancelSplit">确 定</el-button>
</span>
</el-dialog>
</div>
</template>
<script>
import {getDictData, getDictDatas,DICT_TYPE} from '@/utils/dict'
import WorkFlow from '@/components/WorkFlow'
import {getOrderSpecial,createOrderSpecial} from '@/api/ecw/order'
export default {
name: "specialWeight",
components: {
WorkFlow
},
props: {
orderId: [String, Number]
},
data() {
return {
reason:'',
dialogVisible:false,
loading:false,
queryParams:{
orderId:7,
lang:0
},
selectedUsers:[],
orderData:{}
};
},
created() {
if (this.orderId) {
this.queryParams.orderId = this.orderId
this.getOrderSpecialData()
}
// this.getList()
},
computed:{
getDictData(){
return (type, value) => getDictData(type, value) || {}
},
getDictDatas(){
return getDictDatas
}
},
methods: {
/** 查询列表 */
getOrderSpecialData(){
getOrderSpecial(this.queryParams.orderId,'4').then(r => {
this.queryParams = r.data
})
},
submitForm(){
createOrderSpecial({
applyType: this.queryParams.applyType,
lineId: this.queryParams.lineId,
wvolume: this.queryParams.wvolume,
orderId: this.queryParams.orderId,
orderNo: this.queryParams.orderNo,
orderItemId: this.queryParams.orderItemId,
prodId:this.queryParams.prodId,
ccIds:this.selectedUsers.join(',')
}).then(r => {
this.$message.success(r.msg || '提交成功')
})
},
cancelSplit(){
let that = this
if(!that.reason){
that.$message.error("请输入取消原因");
return
}
cancelApply({orderId:that.queryParams.orderId,reason:that.reason}).then(res=>{
that.$message.success("取消成功");
that.$router.back()
})
},
}
}
</script>
<style>
.card-title{
font-size: 18px;
font-weight: bold;
margin-top: 10px;
}
.card-info{
font-size: 16px;
}
.card{
margin-top: 20px;
}
.btn-header{
width: 90%;
display: flex;
align-items: center;
justify-content: space-between;
margin: 20px 0;
}
.red{
color:#ff3430;
font-size: 15px;
}
.footer_btn{
padding-bottom: 60px;
}
.cancel_notice{
font-size: 16px;
font-weight: 600;
}
.cancel_content{
display: flex;
align-items: center;
padding-top: 20px;
}
.cancel_content span{
width: 100px;
}
</style>
......@@ -14,17 +14,17 @@
<dict-tag :type="DICT_TYPE.ORDER_STATUS" :value="orderData.status" />
</el-descriptions-item>
<el-descriptions-item label="送货日期">
<span v-if="orderData">{{orderData.status>=5?(orderData.orderItemVOList.length>0?orderData.orderItemVOList[0].warehouseInInfoVO.inTime:''):(orderData.consigneeVO?orderData.consigneeVO.deliveryDate:'')}}</span>
<span>{{orderData.deliveryDate||''}}</span>
</el-descriptions-item>
<el-descriptions-item label="运输方式">
<dict-tag :type="DICT_TYPE.ECW_TRANSPORT_TYPE" :value="orderData.transportId" />
</el-descriptions-item>
<el-descriptions-item label="始发地">
{{orderData.logisticsInfoDto?orderData.logisticsInfoDto.startTitleZh:''}}
</el-descriptions-item>
<el-descriptions-item label="目的地">
{{orderData.logisticsInfoDto?orderData.logisticsInfoDto.destTitleZh:''}}
</el-descriptions-item>
<el-descriptions-item label="始发地" :span="2">
{{orderData.logisticsInfoDto?orderData.logisticsInfoDto.startAddressZh:''}}
</el-descriptions-item>
<el-descriptions-item label="目的地">
{{orderData.logisticsInfoDto?orderData.logisticsInfoDto.destAddressZh:''}}
</el-descriptions-item>
</el-descriptions>
<el-descriptions :column="4">
<el-descriptions-item label="发货人">
......@@ -76,16 +76,21 @@
<template slot-scope="scope">
<span>规格:{{scope.row.boxGauge||0}}</span>
<p>
<span>品牌:<dict-tag :value="scope.row.brand" :type="DICT_TYPE.ECW_IS_BRAND" /></span>
<span>箱数:{{scope.row.num||0}}</span>
<span>体积:{{scope.row.volume||0}}CBM</span>
<span>重量:{{scope.row.weight||0}}KG</span>
<span>品牌:<dict-tag :value="scope.row.brandType" :type="DICT_TYPE.ECW_IS_BRAND" /></span>
<span>箱数:{{scope.row.warehouseInInfoVO?scope.row.warehouseInInfoVO.cartonsNum:0}}</span>
<span>体积:{{scope.row.warehouseInInfoVO?scope.row.warehouseInInfoVO.volume:0}}CBM</span>
<span>重量:{{scope.row.warehouseInInfoVO?scope.row.warehouseInInfoVO.weight:0}}KG</span>
</p>
</template>
</el-table-column>
<el-table-column label="重货方数" align="center" >
<el-table-column label="重货方数" align="center" v-if="type=='order_heavy_cargo_exception'">
<template slot-scope="scope">
<span>{{scope.row.ss||0}}CBM</span>
<span>{{ scope.row.warehouseInInfoVO?(scope.row.warehouseInInfoVO.heavyNumber||0):0}}CBM</span>
</template>
</el-table-column>
<el-table-column label="泡货方数" align="center" v-else >
<template slot-scope="scope">
<span>{{ scope.row.warehouseInInfoVO?(scope.row.warehouseInInfoVO.lightNumber||0):0}}CBM</span>
</template>
</el-table-column>
<el-table-column label="最后操作时间" scope="handlerTime" />
......@@ -119,13 +124,16 @@ export default {
orderData:{},
list: {},
orderId:0,
type:''
};
},
created() {
if(this.$route.query.id){
this.id = this.$route.query.id
this.getList()
}
if(this.$route.query.type){
this.type = this.$route.query.type
}
},
methods: {
......
......@@ -94,8 +94,10 @@
<el-table-column
prop="startTime"
width="200px"
:formatter="(row) => parseTime(row.startTime, '{y}-{m}-{d}') + ' - ' + parseTime(row.endTime, '{y}-{m}-{d}')"
label="授权时间">
<template v-slot="{row}">
<span>{{row.startTime?(parseTime(row.startTime, '{y}-{m}-{d}') + ' - ' + parseTime(row.endTime, '{y}-{m}-{d}')):'永久'}}</span>
</template>
</el-table-column>
<el-table-column
prop="feeScale"
......
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