Commit d843d7ac by wuqian

Merge branch 'master' of http://47.99.244.21:9999/qinjianhui/factory_front into wq

parents 9975a499 1a0f850f
......@@ -82,6 +82,12 @@ export function printOrder(ids: number[]) {
ids,
)
}
export function exportOrder(ids: number[], status: string | number) {
return axios.post<never, BaseRespData<never>>(
'factory/podJomallOrder/exportData',
{ ids: ids, status },
)
}
// 发货单
export function getDeliveryNoteList(
data: PodDeliveryNoteSearchForm,
......@@ -119,7 +125,7 @@ export function updateRemarkApi(id: number, remark: string) {
'factory/podJomallOrder/setRemark',
{
params: {
productId:id,
productId: id,
remark,
},
},
......
......@@ -39,15 +39,15 @@
style="width: 130px"
></ElInput>
</ElFormItem>
<ElFormItem label="发货单号">
<!-- <ElFormItem label="发货单号">
<ElInput
v-model="searchForm.shipmentNumber"
placeholder="发货单号"
clearable
style="width: 130px"
/>
</ElFormItem>
<ElFormItem label="定制生产单号">
</ElFormItem> -->
<ElFormItem label="生产单号">
<ElInput
v-model="searchForm.factorySubOrderNumber"
placeholder="定制生产单号"
......@@ -55,7 +55,7 @@
style="width: 130px"
/>
</ElFormItem>
<ElFormItem label="定制订单号">
<ElFormItem label="订单号">
<ElInput
v-model="searchForm.factoryOrderNumber"
placeholder="定制订单号"
......@@ -129,6 +129,14 @@
>打印生产单</ElButton
>
</span>
<span
v-if="status === 'TO_BE_CONFIRMED' || status === 'IN_PRODUCTION'"
class="item"
>
<ElButton type="success" dark @click="exportManuscript"
>导出生产单</ElButton
>
</span>
<span class="item">
<ElButton type="warning" @click="addInternalTag"
>添加内部标签</ElButton
......@@ -146,7 +154,10 @@
下载素材</ElButton
>
</span>
<span v-if="status === 'IN_PRODUCTION' || status === 'PART_SHIPPING'" class="item">
<span
v-if="status === 'IN_PRODUCTION' || status === 'PART_SHIPPING'"
class="item"
>
<ElButton type="success" @click="confirmDelivery">发货</ElButton>
</span>
</div>
......@@ -231,10 +242,18 @@
>
<span>{{ memo.operatorEmployeeName || '' }}</span>
</div>
<div v-if="memo.operatorTime" class="order-memo-item__time">
<div
v-if="memo.operatorTime"
class="order-memo-item__time"
:title="memo.operatorTime"
>
<span>{{ memo.operatorTime || '' }}</span>
</div>
<div v-if="memo.content" class="order-memo-item__content">
<div
v-if="memo.content"
class="order-memo-item__content"
:title="memo.content"
>
<span>{{ memo.content || '' }}</span>
</div>
</div>
......@@ -249,6 +268,14 @@
}}</span>
</div>
<div class="order-list-expand_item_info_title">
<span class="order-list-expand_item_label"
>期望交货时间:</span
>
<span class="order-list-expand_item_value">{{
row.expectDeliveryTime || '--'
}}</span>
</div>
<div class="order-list-expand_item_info_title">
<span class="order-list-expand_item_label">确认时间:</span>
<span class="order-list-expand_item_value">{{
row.startStockingTime || '--'
......@@ -473,6 +500,7 @@ import {
downloadMaterialApi,
addInternalTagApi,
printOrder,
exportOrder,
getLogList,
updateRemarkApi,
} from '@/api/podOrder'
......@@ -624,13 +652,13 @@ const tableColumns = computed<CustomColumn<OrderData[]>>(() => {
{
label: '内部便签',
key: 'customerName',
width: 280,
width: 300,
showOverflowTooltip: true,
},
{
label: '时间',
key: 'status',
width: 280,
width: 300,
align: 'center',
},
{
......@@ -852,14 +880,44 @@ const printManuscript = async () => {
offset: window.innerHeight / 2,
})
}
const ids = selection.value.map((item) => item.id)
try {
await showConfirm('是否打印生产单', {
confirmButtonText: '确认',
cancelButtonText: '取消',
type: 'warning',
})
} catch {
return
}
const loading = ElLoading.service({
lock: true,
text: '加载中...',
background: 'rgba(0, 0, 0, 0.7)',
})
try {
const res = await printOrder(ids)
window.open(filePath + res.message)
} catch (e) {
// showError(e)
console.error(e)
} finally {
loading.close()
}
}
const exportManuscript = async () => {
if (selection.value.length === 0) {
return ElMessage({
message: '请选择订单',
type: 'warning',
offset: window.innerHeight / 2,
})
}
const ids = selection.value.map((item) => item.id)
try {
await showConfirm('是否打印生产单', {
await showConfirm('是否导出生产单', {
confirmButtonText: '确认',
cancelButtonText: '取消',
type: 'warning',
......@@ -867,8 +925,13 @@ const printManuscript = async () => {
} catch {
return
}
const loading = ElLoading.service({
lock: true,
text: '加载中...',
background: 'rgba(0, 0, 0, 0.7)',
})
try {
const res = await printOrder(ids)
const res = await exportOrder(ids, status.value)
window.open(filePath + res.message)
} catch (e) {
// showError(e)
......@@ -1020,7 +1083,7 @@ onMounted(() => {
border-right: 1px solid #eee;
}
.order-memo {
width: 280px;
width: 300px;
border-right: 1px solid #eee;
}
......@@ -1028,6 +1091,12 @@ onMounted(() => {
padding: 20px;
font-size: 14px;
}
.order-memo-item__content,
.order-memo-item__time {
white-space: nowrap;
overflow: hidden;
text-overflow: ellipsis;
}
.order-memo-info {
padding: 20px;
......@@ -1044,7 +1113,7 @@ onMounted(() => {
margin-right: 6px;
}
.order-time {
width: 280px;
width: 300px;
border-right: 1px solid #eee;
}
.order-operate {
......
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