Commit 21cc65b9 by wq

8.21

parent 6a1b610a
This source diff could not be displayed because it is too large. You can view the blob instead.
...@@ -148,7 +148,18 @@ export function loadSendOutList(id: number) { ...@@ -148,7 +148,18 @@ export function loadSendOutList(id: number) {
}, },
) )
} }
// 设置备注
export function backEndCommentsApi(id: number, remark: string) {
return axios.get<never, BaseRespData<SendOrderData[]>>(
'factory/customJomallOrderProduct/setRemark',
{
params: {
id,
remark
},
},
)
}
// 操作日志 // 操作日志
export function getLogList(id: number) { export function getLogList(id: number) {
return axios.get<never, BaseRespData<LogListData[]>>( return axios.get<never, BaseRespData<LogListData[]>>(
......
...@@ -102,7 +102,6 @@ ...@@ -102,7 +102,6 @@
</span> </span>
</div> </div>
<div <div
v-if="item.remark"
:title="item.remark || ''" :title="item.remark || ''"
class="order-list-expand_item_info_title" class="order-list-expand_item_info_title"
> >
......
<template> <template>
<div class="card flex-column h-100 overflow-hidden"> <div class="card flex-column h-100 overflow-hidden">
<split-div ref="splitRef"> <split-div ref="splitRef">
<template #top> <template #top>
<div class="header-filter"> <div class="header-filter">
<div class="header-filter-form"> <div class="header-filter-form">
<ElForm :model="searchForm" size="default" inline> <ElForm :model="searchForm" size="default" inline>
<ElFormItem> <ElFormItem>
<el-select v-model="searchForm.timeType" clearable style="width:100px;margin-right: 5px ;" placeholder="时间类型" > <el-select
<el-option v-if="statusCode !== 6" value="1" label="创建时间"></el-option> v-model="searchForm.timeType"
clearable
style="width: 100px; margin-right: 5px"
placeholder="时间类型"
>
<el-option
v-if="statusCode !== 6"
value="1"
label="创建时间"
></el-option>
<el-option value="2" label="确认时间"></el-option> <el-option value="2" label="确认时间"></el-option>
<el-option v-if="statusCode !== 6" value="3" label="完成时间"></el-option> <el-option
<el-option v-if="statusCode === 6" value="4" label="发货时间"></el-option> v-if="statusCode !== 6"
value="3"
label="完成时间"
></el-option>
<el-option
v-if="statusCode === 6"
value="4"
label="发货时间"
></el-option>
</el-select> </el-select>
<el-date-picker <el-date-picker
v-model="timeRange" v-model="timeRange"
:default-time="[new Date(0,0,0,0,0,0),new Date(0,0,0,23,59,59)]" :default-time="[
new Date(0, 0, 0, 0, 0, 0),
new Date(0, 0, 0, 23, 59, 59),
]"
placeholder="收货人" placeholder="收货人"
value-format="YYYY-MM-DD HH:mm:ss" value-format="YYYY-MM-DD HH:mm:ss"
type="datetimerange" type="datetimerange"
...@@ -24,7 +44,6 @@ ...@@ -24,7 +44,6 @@
clearable clearable
style="width: 210px" style="width: 210px"
> >
</el-date-picker> </el-date-picker>
</ElFormItem> </ElFormItem>
<ElFormItem label="SKU"> <ElFormItem label="SKU">
...@@ -42,7 +61,9 @@ ...@@ -42,7 +61,9 @@
placeholder="请输入成品ID" placeholder="请输入成品ID"
clearable clearable
style="width: 130px" style="width: 130px"
@blur="searchForm.endProductId = searchForm.endProductId.trim()" @blur="
searchForm.endProductId = searchForm.endProductId.trim()
"
></ElInput> ></ElInput>
</ElFormItem> </ElFormItem>
<ElFormItem label="生产单号"> <ElFormItem label="生产单号">
...@@ -52,8 +73,8 @@ ...@@ -52,8 +73,8 @@
clearable clearable
style="width: 130px" style="width: 130px"
@blur=" @blur="
searchForm.subOrderNumber = searchForm.subOrderNumber.trim() searchForm.subOrderNumber = searchForm.subOrderNumber.trim()
" "
></ElInput> ></ElInput>
</ElFormItem> </ElFormItem>
<ElFormItem label="订单号"> <ElFormItem label="订单号">
...@@ -80,7 +101,9 @@ ...@@ -80,7 +101,9 @@
placeholder="内部标签" placeholder="内部标签"
clearable clearable
style="width: 130px" style="width: 130px"
@blur="searchForm.internalMemo = searchForm.internalMemo.trim()" @blur="
searchForm.internalMemo = searchForm.internalMemo.trim()
"
></ElInput> ></ElInput>
</ElFormItem> </ElFormItem>
<ElFormItem v-if="statusCode === 6" label="物流跟踪号"> <ElFormItem v-if="statusCode === 6" label="物流跟踪号">
...@@ -90,9 +113,9 @@ ...@@ -90,9 +113,9 @@
clearable clearable
style="width: 130px" style="width: 130px"
@blur=" @blur="
searchForm.logisticsTracking = searchForm.logisticsTracking =
searchForm.logisticsTracking.trim() searchForm.logisticsTracking.trim()
" "
></ElInput> ></ElInput>
</ElFormItem> </ElFormItem>
<ElFormItem v-if="statusCode === 6" label="发货单号"> <ElFormItem v-if="statusCode === 6" label="发货单号">
...@@ -113,7 +136,6 @@ ...@@ -113,7 +136,6 @@
></ElInput> ></ElInput>
</ElFormItem> </ElFormItem>
<ElFormItem> <ElFormItem>
<ElButton type="primary" @click="search">查询</ElButton> <ElButton type="primary" @click="search">查询</ElButton>
</ElFormItem> </ElFormItem>
...@@ -128,7 +150,9 @@ ...@@ -128,7 +150,9 @@
v-for="item in tabsNav" v-for="item in tabsNav"
:key="item.statusCode" :key="item.statusCode"
class="tabs-node" class="tabs-node"
:class="item.statusCode === statusCode ? 'tabs-node_active' : ''" :class="
item.statusCode === statusCode ? 'tabs-node_active' : ''
"
@click="changeTab(item)" @click="changeTab(item)"
> >
<span class="tabs-node_label">{{ item.statusName }}</span> <span class="tabs-node_label">{{ item.statusName }}</span>
...@@ -142,72 +166,92 @@ ...@@ -142,72 +166,92 @@
<div class="order-content flex-1 flex-column overflow-hidden"> <div class="order-content flex-1 flex-column overflow-hidden">
<!-- 操作按钮 --> <!-- 操作按钮 -->
<div class="order-operate-btn"> <div class="order-operate-btn">
<span v-if="statusCode === 2" class="item"> <span v-if="statusCode === 2" class="item">
<ElButton type="success" @click="confirmProduce">确认生产</ElButton> <ElButton type="success" @click="confirmProduce"
</span> >确认生产</ElButton
>
</span>
<span <span
v-if="statusCode === 2 || statusCode === 3 || statusCode === 4" v-if="statusCode === 2 || statusCode === 3 || statusCode === 4"
class="item" class="item"
> >
<ElButton <ElButton
:disabled="selection.find(item=>item.manuscriptStatus !== 30)" type="warning" is-dark :disabled="
@click="downloadManuscript" selection.find((item) => item.manuscriptStatus !== 30)
>下载稿件</ElButton "
> type="warning"
</span> is-dark
@click="downloadManuscript"
>下载稿件</ElButton
>
</span>
<span <span
v-if="statusCode === 2 || statusCode === 3 || statusCode === 4" v-if="statusCode === 2 || statusCode === 3 || statusCode === 4"
class="item" class="item"
> >
<ElButton <ElButton
:disabled="selection.find(item=>item.manuscriptStatus !== 30) || selection.length!==1" type="success" is-dark :disabled="
@click="reGenerateManuscript" selection.find((item) => item.manuscriptStatus !== 30) ||
>重新打包稿件 </ElButton selection.length !== 1
> "
type="success"
is-dark
@click="reGenerateManuscript"
>重新打包稿件
</ElButton>
</span> </span>
<span <span
v-if="statusCode === 2 || statusCode === 3 || statusCode === 4" v-if="statusCode === 2 || statusCode === 3 || statusCode === 4"
class="item" class="item"
> >
<ElButton <ElButton
:disabled="selection.find(item=>item.manuscriptStatus !== 30) || selection.length!==1" :disabled="
type="warning" is-dark @click="reCreateManuscript" selection.find((item) => item.manuscriptStatus !== 30) ||
>重新生成稿件 </ElButton selection.length !== 1
> "
</span> type="warning"
is-dark
@click="reCreateManuscript"
>重新生成稿件
</ElButton>
</span>
<span v-if="statusCode === 2 || statusCode === 3" class="item"> <span v-if="statusCode === 2 || statusCode === 3" class="item">
<ElButton :loading="btnLoading" type="primary" dark @click="printManuscript" <ElButton
>打印生产单</ElButton :loading="btnLoading"
> type="primary"
</span> dark
@click="printManuscript"
>打印生产单</ElButton
>
</span>
<span <span
v-if="statusCode === 2 || statusCode === 3 || statusCode === 7" v-if="statusCode === 2 || statusCode === 3 || statusCode === 7"
class="item" class="item"
> >
<ElButton type="success" dark @click="exportManuscript" <ElButton type="success" dark @click="exportManuscript"
>导出生产单</ElButton >导出生产单</ElButton
> >
</span> </span>
<span class="item"> <span class="item">
<ElButton type="warning" @click="addInternalTag" <ElButton type="warning" @click="addInternalTag"
>添加内部标签</ElButton >添加内部标签</ElButton
> >
</span> </span>
<span <span
v-if="statusCode === 2 || statusCode === 3 || statusCode === 4" v-if="statusCode === 2 || statusCode === 3 || statusCode === 4"
class="item" class="item"
> >
<ElButton type="primary" @click="refreshProduct" <ElButton type="primary" @click="refreshProduct"
>刷新商品信息</ElButton >刷新商品信息</ElButton
> >
</span> </span>
<span v-if="statusCode === 3 || statusCode === 4" class="item"> <span v-if="statusCode === 3 || statusCode === 4" class="item">
<ElButton type="success" @click="confirmDelivery">发货</ElButton> <ElButton type="success" @click="confirmDelivery">发货</ElButton>
</span> </span>
<span v-if="statusCode === 6" class="item"> <span v-if="statusCode === 6" class="item">
<ElButton type="success" @click="confirmCheck">质检</ElButton> <ElButton type="success" @click="confirmCheck">质检</ElButton>
</span> </span>
</div> </div>
<div <div
ref="tableWrapperRef" ref="tableWrapperRef"
...@@ -232,47 +276,56 @@ ...@@ -232,47 +276,56 @@
class="order-list-expand" class="order-list-expand"
:style="{ width: `${thOrderDetailWidth + 50}px` }" :style="{ width: `${thOrderDetailWidth + 50}px` }"
> >
<ProductInfo :row="row" :status="statusCode" /> <ProductInfo
:row="row"
:status="statusCode"
@update-remark="handleUpdateRemark"
/>
<template v-if="row.productList.length > 2"> <template v-if="row.productList.length > 2">
<div class="order-list-expand_more"> <div class="order-list-expand_more">
<span @click="openAll(row)"> <span @click="openAll(row)">
<template v-if="!row.moreable"> <template v-if="!row.moreable">
展开全部<strong style="color: red" 展开全部<strong style="color: red"
>({{ row.productList.length }})</strong >({{ row.productList.length }})</strong
>条商品信息<el-icon style="vertical-align: middle" >条商品信息<el-icon style="vertical-align: middle"
><ArrowDown /></el-icon ><ArrowDown /></el-icon
></template> ></template>
<template v-else> <template v-else>
收起商品信息<el-icon style="vertical-align: middle" 收起商品信息<el-icon
><ArrowUp style="vertical-align: middle"
/></el-icon> ><ArrowUp
</template> /></el-icon>
</span> </template>
</span>
</div> </div>
</template> </template>
</div> </div>
<div class="order-actual-payment"> <div class="order-actual-payment">
<div class="order-actual-payment_info"> <div class="order-actual-payment_info">
<div class="order-list-expand_item_info_title"> <div class="order-list-expand_item_info_title">
<span class="order-list-expand_item_label">商品价:</span> <span class="order-list-expand_item_label"
>商品价:</span
>
<span class="order-list-expand_item_value">{{ <span class="order-list-expand_item_value">{{
row.productAmount row.productAmount
}}</span> }}</span>
</div> </div>
<div class="order-list-expand_item_info_title"> <div class="order-list-expand_item_info_title">
<span class="order-list-expand_item_label">小计:</span> <span class="order-list-expand_item_label"
>小计:</span
>
<span class="order-list-expand_item_value">{{ <span class="order-list-expand_item_value">{{
row.totalAmount || '--' row.totalAmount || '--'
}}</span> }}</span>
</div> </div>
<div <div
v-if="row.totolBuyNumber" v-if="row.totolBuyNumber"
class="order-list-expand_item_info_title" class="order-list-expand_item_info_title"
> >
<span class="order-list-expand_item_value" <span class="order-list-expand_item_value"
>{{ row.totolBuyNumber }}</span >{{ row.totolBuyNumber }}</span
> >
</div> </div>
</div> </div>
</div> </div>
...@@ -295,7 +348,10 @@ ...@@ -295,7 +348,10 @@
> >
<span>{{ memo.operatorTime || '' }}</span> <span>{{ memo.operatorTime || '' }}</span>
</div> </div>
<div v-if="memo.content" class="order-memo-item__content"> <div
v-if="memo.content"
class="order-memo-item__content"
>
<span>{{ memo.content || '' }}</span> <span>{{ memo.content || '' }}</span>
</div> </div>
</div> </div>
...@@ -304,36 +360,39 @@ ...@@ -304,36 +360,39 @@
<div class="order-time"> <div class="order-time">
<div class="order-time_info"> <div class="order-time_info">
<div class="order-list-expand_item_info_title"> <div class="order-list-expand_item_info_title">
<span class="order-list-expand_item_label" <span class="order-list-expand_item_label"
>创建时间:</span >创建时间:</span
> >
<span class="order-list-expand_item_value">{{ <span class="order-list-expand_item_value">{{
row.createTime || '--' row.createTime || '--'
}}</span> }}</span>
</div> </div>
<div class="order-list-expand_item_info_title"> <div class="order-list-expand_item_info_title">
<span class="order-list-expand_item_label" <span class="order-list-expand_item_label"
>确认时间:</span >确认时间:</span
> >
<span class="order-list-expand_item_value">{{ <span class="order-list-expand_item_value">{{
row.startStockingTime || '--' row.startStockingTime || '--'
}}</span> }}</span>
</div> </div>
<div class="order-list-expand_item_info_title"> <div class="order-list-expand_item_info_title">
<span class="order-list-expand_item_label" <span class="order-list-expand_item_label"
>完成时间:</span >完成时间:</span
> >
<span class="order-list-expand_item_value">{{ <span class="order-list-expand_item_value">{{
row.finishTime || '--' row.finishTime || '--'
}}</span> }}</span>
</div> </div>
</div> </div>
</div> </div>
<div class="order-operate"> <div class="order-operate">
<div class="order-operate_info"> <div class="order-operate_info">
<div class="order-list-expand_item_info_title"> <div class="order-list-expand_item_info_title">
<ElButton text type="primary" @click="openDetail(row.id)" <ElButton
>查看详情 text
type="primary"
@click="openDetail(row.id)"
>查看详情
</ElButton> </ElButton>
</div> </div>
<div <div
...@@ -344,21 +403,24 @@ ...@@ -344,21 +403,24 @@
text text
type="primary" type="primary"
@click="openShipment(row.id)" @click="openShipment(row.id)"
>查看发货单 >查看发货单
</ElButton> </ElButton>
</div> </div>
<div class="order-list-expand_item_info_title"> <div class="order-list-expand_item_info_title">
<ElButton text type="primary" @click="openLog(row.id)" <ElButton text type="primary" @click="openLog(row.id)"
>操作日志 >操作日志
</ElButton> </ElButton>
</div> </div>
<div <div
v-if="statusCode === 1 || statusCode === 3" v-if="statusCode === 1 || statusCode === 3"
class="order-list-expand_item_info_title" class="order-list-expand_item_info_title"
> >
<ElButton text type="danger" @click="cancelOrder(row.id)" <ElButton
>取消 text
type="danger"
@click="cancelOrder(row.id)"
>取消
</ElButton> </ElButton>
</div> </div>
</div> </div>
...@@ -375,7 +437,10 @@ ...@@ -375,7 +437,10 @@
> >
<template #default="scope"> <template #default="scope">
<div class="order-detail"> <div class="order-detail">
<div :title="scope.row.orderNumber" class="order-detail_item"> <div
:title="scope.row.orderNumber"
class="order-detail_item"
>
<span class="label">订单号:</span> <span class="label">订单号:</span>
<span class="value">{{ scope.row.orderNumber }}</span> <span class="value">{{ scope.row.orderNumber }}</span>
</div> </div>
...@@ -385,24 +450,32 @@ ...@@ -385,24 +450,32 @@
> >
<span class="label">第三方订单号:</span> <span class="label">第三方订单号:</span>
<span class="value" :title="scope.row.erpOrderNumber">{{ <span class="value" :title="scope.row.erpOrderNumber">{{
scope.row.erpOrderNumber || '--' scope.row.erpOrderNumber || '--'
}}</span> }}</span>
</div> </div>
<div <div
:title="scope.row.manuscriptStatusStr" :title="scope.row.manuscriptStatusStr"
class="order-detail_item" class="order-detail_item"
> >
<span class="label">稿件状态:</span> <span class="label">稿件状态:</span>
<span class="value" :title="scope.row.manuscriptStatusStr">{{ <span
scope.row.manuscriptStatusStr || '--' class="value"
}}</span> :title="scope.row.manuscriptStatusStr"
>{{ scope.row.manuscriptStatusStr || '--' }}</span
>
</div> </div>
<div :title="scope.row.lanshouName" class="order-detail_item"> <div
:title="scope.row.lanshouName"
class="order-detail_item"
>
<span class="label">收货人:</span> <span class="label">收货人:</span>
<span class="value">{{ scope.row.lanshouName }}</span> <span class="value">{{ scope.row.lanshouName }}</span>
</div> </div>
<div :title="scope.row.lanshouPhone" class="order-detail_item"> <div
:title="scope.row.lanshouPhone"
class="order-detail_item"
>
<span class="label">电话:</span> <span class="label">电话:</span>
<span class="value">{{ scope.row.lanshouPhone }}</span> <span class="value">{{ scope.row.lanshouPhone }}</span>
</div> </div>
...@@ -412,10 +485,13 @@ ...@@ -412,10 +485,13 @@
> >
<span class="label">收货地址:</span> <span class="label">收货地址:</span>
<span class="value" :title="scope.row.lanshouAddress">{{ <span class="value" :title="scope.row.lanshouAddress">{{
scope.row.lanshouAddress scope.row.lanshouAddress
}}</span> }}</span>
</div> </div>
<div :title="scope.row.lanshouPost" class="order-detail_item"> <div
:title="scope.row.lanshouPost"
class="order-detail_item"
>
<span class="label">邮编:</span> <span class="label">邮编:</span>
<span class="value">{{ scope.row.lanshouPost }}</span> <span class="value">{{ scope.row.lanshouPost }}</span>
</div> </div>
...@@ -474,33 +550,37 @@ ...@@ -474,33 +550,37 @@
<ProductInfoInspected :row="row" :status="statusCode" /> <ProductInfoInspected :row="row" :status="statusCode" />
<template v-if="row.detailList.length > 2"> <template v-if="row.detailList.length > 2">
<div class="order-list-expand_more"> <div class="order-list-expand_more">
<span @click="openAll(row)"> <span @click="openAll(row)">
<template v-if="!row.moreable"> <template v-if="!row.moreable">
展开全部<strong style="color: red" 展开全部<strong style="color: red"
>({{ row.detailList.length }})</strong >({{ row.detailList.length }})</strong
>条商品信息<el-icon style="vertical-align: middle" >条商品信息<el-icon style="vertical-align: middle"
><ArrowDown /></el-icon ><ArrowDown /></el-icon
></template> ></template>
<template v-else> <template v-else>
收起商品信息<el-icon style="vertical-align: middle" 收起商品信息<el-icon
><ArrowUp style="vertical-align: middle"
/></el-icon> ><ArrowUp
</template> /></el-icon>
</span> </template>
</span>
</div> </div>
</template> </template>
</div> </div>
<div class="order-actual-payment"> <div class="order-actual-payment">
<div class="order-actual-payment_info"> <div class="order-actual-payment_info">
<div class="order-list-expand_item_info_title"> <div class="order-list-expand_item_info_title">
<span class="order-list-expand_item_label">订单号:</span> <span class="order-list-expand_item_label"
>订单号:</span
>
<span class="order-list-expand_item_value">{{ <span class="order-list-expand_item_value">{{
row.orderNumber row.orderNumber
}}</span> }}</span>
<el-icon class="icon" @click="copy(row.orderNumber || '')" <el-icon
class="icon"
@click="copy(row.orderNumber || '')"
> >
<DocumentCopy <DocumentCopy />
/>
</el-icon> </el-icon>
</div> </div>
...@@ -514,89 +594,93 @@ ...@@ -514,89 +594,93 @@
<!-- /></el-icon>--> <!-- /></el-icon>-->
<!-- </div>--> <!-- </div>-->
<div class="order-list-expand_item_info_title"> <div class="order-list-expand_item_info_title">
<span class="order-list-expand_item_label" <span class="order-list-expand_item_label"
>发货方式:</span >发货方式:</span
> >
<span class="order-list-expand_item_value">{{ <span class="order-list-expand_item_value">{{
row.shippingWay === 1 ? '送货上门' : '快递' row.shippingWay === 1 ? '送货上门' : '快递'
}}</span> }}</span>
</div> </div>
<div <div
v-if="row.shippingWay !== 1" v-if="row.shippingWay !== 1"
class="order-list-expand_item_info_title" class="order-list-expand_item_info_title"
> >
<span class="order-list-expand_item_label" <span class="order-list-expand_item_label"
>物流名称:</span >物流名称:</span
> >
<span class="order-list-expand_item_value">{{ <span class="order-list-expand_item_value">{{
row.carriageName row.carriageName
}}</span> }}</span>
</div> </div>
<div <div
v-if="row.shippingWay === 2" v-if="row.shippingWay === 2"
class="order-list-expand_item_info_title" class="order-list-expand_item_info_title"
> >
<span class="order-list-expand_item_label" <span class="order-list-expand_item_label"
>物流跟踪号:</span >物流跟踪号:</span
> >
<span <span
style="color: red" style="color: red"
class="order-list-expand_item_value" class="order-list-expand_item_value"
>{{ row.logisticsTracking }}</span >{{ row.logisticsTracking }}</span
> >
</div> </div>
<div class="order-list-expand_item_info_title"> <div class="order-list-expand_item_info_title">
<span class="order-list-expand_item_label" <span class="order-list-expand_item_label"
>发货时间:</span >发货时间:</span
> >
<span <span
style="color: red" style="color: red"
class="order-list-expand_item_value" class="order-list-expand_item_value"
>{{ row.createTime || '--' }}</span >{{ row.createTime || '--' }}</span
> >
</div> </div>
<div class="order-list-expand_item_info_title"> <div class="order-list-expand_item_info_title">
<span class="order-list-expand_item_label" <span class="order-list-expand_item_label"
>确认时间:</span >确认时间:</span
> >
<span <span
style="color: red" style="color: red"
class="order-list-expand_item_value" class="order-list-expand_item_value"
>{{ >{{
row.order ? row.order.startStockingTime : '' row.order ? row.order.startStockingTime : ''
}}</span }}</span
> >
</div> </div>
<div class="order-list-expand_item_info_title"> <div class="order-list-expand_item_info_title">
<span class="order-list-expand_item_label">收货人:</span> <span class="order-list-expand_item_label"
>收货人:</span
>
<span <span
style="color: red" style="color: red"
class="order-list-expand_item_value" class="order-list-expand_item_value"
>{{ row.lanshouName || '--' }}</span >{{ row.lanshouName || '--' }}</span
> >
</div> </div>
<div class="order-list-expand_item_info_title"> <div class="order-list-expand_item_info_title">
<span class="order-list-expand_item_label" <span class="order-list-expand_item_label"
>收货人电话:</span >收货人电话:</span
> >
<span class="order-list-expand_item_value">{{ <span class="order-list-expand_item_value">{{
row.lanshouPhone || '--' row.lanshouPhone || '--'
}}</span> }}</span>
</div> </div>
<div class="order-list-expand_item_info_title"> <div class="order-list-expand_item_info_title">
<span class="order-list-expand_item_label">邮编:</span> <span class="order-list-expand_item_label"
>邮编:</span
>
<span class="order-list-expand_item_value">{{ <span class="order-list-expand_item_value">{{
row.lanshouPost || '--' row.lanshouPost || '--'
}}</span> }}</span>
</div> </div>
<div class="order-list-expand_item_info_title"> <div class="order-list-expand_item_info_title">
<span class="order-list-expand_item_label" <span class="order-list-expand_item_label"
>收货地址:</span >收货地址:</span
> >
<span class="order-list-expand_item_value">{{ <span class="order-list-expand_item_value">{{
row.lanshouRegion + row.lanshouAddress row.lanshouRegion + row.lanshouAddress
}}</span> }}</span>
</div> </div>
</div> </div>
</div> </div>
...@@ -607,7 +691,7 @@ ...@@ -607,7 +691,7 @@
text text
type="primary" type="primary"
@click="openLog(row.orderId)" @click="openLog(row.orderId)"
>操作日志 >操作日志
</ElButton> </ElButton>
</div> </div>
</div> </div>
...@@ -662,7 +746,7 @@ ...@@ -662,7 +746,7 @@
type="primary" type="primary"
size="large" size="large"
@click="searchShipmentByOrderNumber" @click="searchShipmentByOrderNumber"
>查询 >查询
</el-button> </el-button>
</div> </div>
<Shipment <Shipment
...@@ -731,10 +815,10 @@ ...@@ -731,10 +815,10 @@
<template #footer> <template #footer>
<div class="dialog-footer"> <div class="dialog-footer">
<el-button size="large" @click="shipmentVisible = false" <el-button size="large" @click="shipmentVisible = false"
>取消 >取消
</el-button> </el-button>
<el-button size="large" type="primary" @click="saveShipment" <el-button size="large" type="primary" @click="saveShipment"
>发货 >发货
</el-button> </el-button>
</div> </div>
</template> </template>
...@@ -774,21 +858,31 @@ ...@@ -774,21 +858,31 @@
@keyup.enter="searchQaByOrderNumber" @keyup.enter="searchQaByOrderNumber"
/> />
<el-button type="primary" size="large" @click="searchQaByOrderNumber" <el-button type="primary" size="large" @click="searchQaByOrderNumber"
>查询 >查询
</el-button> </el-button>
</div> </div>
<Quarantine :quarantine="quarantine" /> <Quarantine :quarantine="quarantine" />
<template #footer> <template #footer>
<div class="dialog-footer"> <div class="dialog-footer">
<el-button size="large" @click="quarantineVisible = false" <el-button size="large" @click="quarantineVisible = false"
>取消 >取消
</el-button> </el-button>
<el-button size="large" type="primary" @click="() => saveQuarantine()" <el-button size="large" type="primary" @click="() => saveQuarantine()"
>质检完成 >质检完成
</el-button> </el-button>
</div> </div>
</template> </template>
</el-dialog> </el-dialog>
<!-- 设置备注 -->
<el-dialog v-model="dialogVisible" title="设置备注" width="30%">
<el-input v-model="inputValue" clearable placeholder="请输入备注" />
<template #footer>
<span class="dialog-footer">
<el-button @click="dialogVisible = false">取消</el-button>
<el-button type="primary" @click="submitRemark">确认</el-button>
</span>
</template>
</el-dialog>
<ElDrawer <ElDrawer
v-model="orderDetailDialogVisible" v-model="orderDetailDialogVisible"
title="生产订单详情" title="生产订单详情"
...@@ -824,12 +918,14 @@ import { ...@@ -824,12 +918,14 @@ import {
printOrder, printOrder,
exportOrder, exportOrder,
addInternalTagApi, addInternalTagApi,
backEndCommentsApi,
loadSendOutList, loadSendOutList,
getLogList, getLogList,
getOrderDetail, getOrderDetail,
cancelOrderApi, cancelOrderApi,
reGenerateScriptUrlApi, reGenerateScriptUrlApi,
refreshProductInfo, reCreateScriptUrlApi, refreshProductInfo,
reCreateScriptUrlApi,
} from '@/api/order' } from '@/api/order'
import { showConfirm } from '@/utils/ui' import { showConfirm } from '@/utils/ui'
import { useValue } from '@/utils/hooks/useValue' import { useValue } from '@/utils/hooks/useValue'
...@@ -860,6 +956,9 @@ const [searchForm] = useValue<SearchForm>({ ...@@ -860,6 +956,9 @@ const [searchForm] = useValue<SearchForm>({
const tabsNav = ref<Tab[]>([]) const tabsNav = ref<Tab[]>([])
const splitRef = ref<InstanceType<typeof SplitDiv>>() const splitRef = ref<InstanceType<typeof SplitDiv>>()
const btnLoading = ref<boolean>(false) const btnLoading = ref<boolean>(false)
const dialogVisible = ref<boolean>(false)
const inputValue = ref<string>('')
const remarkId = ref<number>(0)
function getStartTime() { function getStartTime() {
const date = new Date() const date = new Date()
const year = date.getFullYear() const year = date.getFullYear()
...@@ -871,111 +970,111 @@ const pickerOptions = { ...@@ -871,111 +970,111 @@ const pickerOptions = {
shortcuts: [ shortcuts: [
{ {
text: '今日', text: '今日',
value:() =>{ value: () => {
const start = new Date(new Date(getStartTime()).getTime()) const start = new Date(new Date(getStartTime()).getTime())
const end = new Date() const end = new Date()
return [start, end] return [start, end]
} },
}, },
{ {
text: '昨天', text: '昨天',
value:() =>{ value: () => {
const start = new Date() const start = new Date()
const end = new Date(new Date(getStartTime()).getTime() - 1) const end = new Date(new Date(getStartTime()).getTime() - 1)
start.setTime(end.getTime() - 3600 * 1000 * 24 * 1 + 1) start.setTime(end.getTime() - 3600 * 1000 * 24 * 1 + 1)
return [start, end] return [start, end]
} },
}, },
{ {
text: '最近7天', text: '最近7天',
value:() =>{ value: () => {
const end = new Date() const end = new Date()
const start = new Date(getStartTime()) const start = new Date(getStartTime())
start.setTime(start.getTime() - 3600 * 1000 * 24 * 6) start.setTime(start.getTime() - 3600 * 1000 * 24 * 6)
return [start, end] return [start, end]
} },
}, },
{ {
text: '最近14天', text: '最近14天',
value:() =>{ value: () => {
const end = new Date() const end = new Date()
const start = new Date(getStartTime()) const start = new Date(getStartTime())
start.setTime(start.getTime() - 3600 * 1000 * 24 * 13) start.setTime(start.getTime() - 3600 * 1000 * 24 * 13)
return [start, end] return [start, end]
} },
}, },
{ {
text: '最近30天', text: '最近30天',
value:() =>{ value: () => {
const end = new Date() const end = new Date()
const start = new Date(getStartTime()) const start = new Date(getStartTime())
start.setTime(start.getTime() - 3600 * 1000 * 24 * 29) start.setTime(start.getTime() - 3600 * 1000 * 24 * 29)
return [start, end] return [start, end]
} },
}, },
{ {
text: '本星期', text: '本星期',
value:() =>{ value: () => {
const end = new Date() const end = new Date()
const start = new Date() const start = new Date()
const nowDay = new Date().getDay() - 1 const nowDay = new Date().getDay() - 1
start.setTime( start.setTime(
new Date(getStartTime()).getTime() - 3600 * 1000 * 24 * nowDay new Date(getStartTime()).getTime() - 3600 * 1000 * 24 * nowDay,
) )
return [start, end] return [start, end]
} },
}, },
{ {
text: '上星期', text: '上星期',
value:() =>{ value: () => {
const end = new Date() const end = new Date()
const start = new Date() const start = new Date()
const nowDay = new Date().getDay() - 1 const nowDay = new Date().getDay() - 1
end.setTime( end.setTime(
new Date(getStartTime()).getTime() - 3600 * 1000 * 24 * nowDay - 1 new Date(getStartTime()).getTime() - 3600 * 1000 * 24 * nowDay - 1,
) )
start.setTime(end.getTime() - 3600 * 1000 * 24 * 7 + 1) start.setTime(end.getTime() - 3600 * 1000 * 24 * 7 + 1)
return [start, end] return [start, end]
} },
}, },
{ {
text: '这个月', text: '这个月',
value:() =>{ value: () => {
const end = new Date() const end = new Date()
const start = new Date() const start = new Date()
const nowDate = new Date().getDate() - 1 const nowDate = new Date().getDate() - 1
start.setTime( start.setTime(
new Date(getStartTime()).getTime() - 3600 * 1000 * 24 * nowDate new Date(getStartTime()).getTime() - 3600 * 1000 * 24 * nowDate,
) )
return [start, end] return [start, end]
} },
}, },
{ {
text: '上个月', text: '上个月',
value:() =>{ value: () => {
const date = new Date() const date = new Date()
let year = date.getFullYear() let year = date.getFullYear()
let month = date.getMonth() let month = date.getMonth()
const end = new Date( const end = new Date(
new Date(`${year}-${month + 1}-1 00:00:00`).getTime() - 1 new Date(`${year}-${month + 1}-1 00:00:00`).getTime() - 1,
) )
if (month === 0) { if (month === 0) {
month = 12 month = 12
year = year - 1 year = year - 1
} }
const start = new Date( const start = new Date(
new Date(`${year}-${month}-1 00:00:00`).getTime() new Date(`${year}-${month}-1 00:00:00`).getTime(),
) )
return [start, end] return [start, end]
} },
}, },
{ {
text: '历史', text: '历史',
value:() =>{ value: () => {
return ['', ''] return ['', '']
} },
} },
] ],
} }
const statusCode = ref(2) const statusCode = ref(2)
const selection = ref<OrderData[]>([]) const selection = ref<OrderData[]>([])
...@@ -1025,8 +1124,18 @@ const { ...@@ -1025,8 +1124,18 @@ const {
...searchForm.value, ...searchForm.value,
status: statusCode.value, status: statusCode.value,
timeType: timeRange.value.length > 0 ? searchForm.value.timeType : null, timeType: timeRange.value.length > 0 ? searchForm.value.timeType : null,
startTime: searchForm.value.timeType === '' ? null : timeRange.value.length > 0 ? timeRange.value[0] : null, startTime:
endTime: searchForm.value.timeType === '' ? null : timeRange.value.length > 0 ? timeRange.value[1] : null, searchForm.value.timeType === ''
? null
: timeRange.value.length > 0
? timeRange.value[0]
: null,
endTime:
searchForm.value.timeType === ''
? null
: timeRange.value.length > 0
? timeRange.value[1]
: null,
}, },
page, page,
pageSize, pageSize,
...@@ -1107,11 +1216,35 @@ const changeTab = (item: Tab) => { ...@@ -1107,11 +1216,35 @@ const changeTab = (item: Tab) => {
statusCode.value = item.statusCode statusCode.value = item.statusCode
searchForm.value.timeType = '' searchForm.value.timeType = ''
search() search()
nextTick(()=>{ nextTick(() => {
(splitRef.value)!.domResize() splitRef.value!.domResize()
}) })
} }
const handleUpdateRemark = (payload: { id: number; remark: string }) => {
dialogVisible.value = true
inputValue.value = payload.remark
remarkId.value = payload.id
}
const submitRemark = async () => {
try {
const res = await backEndCommentsApi(remarkId.value, inputValue.value)
search()
dialogVisible.value = false
inputValue.value = ''
ElMessage({
message: res.message,
type: 'success',
offset: window.innerHeight / 2,
})
} catch (e) {
ElMessage({
message: '提交失败,请重试',
type: 'error',
offset: window.innerHeight / 2,
})
dialogVisible.value = true
}
}
const copy = (text: string) => { const copy = (text: string) => {
navigator.clipboard.writeText(text) navigator.clipboard.writeText(text)
ElMessage.success('复制成功') ElMessage.success('复制成功')
...@@ -1280,7 +1413,10 @@ const printManuscript = async () => { ...@@ -1280,7 +1413,10 @@ const printManuscript = async () => {
// 导出生产单 // 导出生产单
const exportManuscript = async () => { const exportManuscript = async () => {
try { try {
const res = await exportOrder({ids:selection.value.map(el=>el.id),status: statusCode.value }) const res = await exportOrder({
ids: selection.value.map((el) => el.id),
status: statusCode.value,
})
window.open(filePath + res.message) window.open(filePath + res.message)
} catch (e) { } catch (e) {
// showError(e) // showError(e)
......
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