Commit 10c1edcf by linjinhong

Merge remote-tracking branch 'origin/master' into linjinhong

parents e22d350f 84ed5778
...@@ -6,6 +6,7 @@ ...@@ -6,6 +6,7 @@
export {} export {}
declare global { declare global {
const EffectScope: typeof import('vue')['EffectScope'] const EffectScope: typeof import('vue')['EffectScope']
const ElInput: typeof import('element-plus/es')['ElInput']
const ElLoading: typeof import('element-plus/es')['ElLoading'] const ElLoading: typeof import('element-plus/es')['ElLoading']
const ElMessage: typeof import('element-plus/es')['ElMessage'] const ElMessage: typeof import('element-plus/es')['ElMessage']
const ElMessageBox: typeof import('element-plus/es')['ElMessageBox'] const ElMessageBox: typeof import('element-plus/es')['ElMessageBox']
......
...@@ -7,10 +7,10 @@ export {} ...@@ -7,10 +7,10 @@ export {}
declare module 'vue' { declare module 'vue' {
export interface GlobalComponents { export interface GlobalComponents {
AmountInput: typeof import('./src/components/Form.vue/AmountInput.vue')['default'] AmountInput: typeof import('./src/components/Form/AmountInput.vue')['default']
CommonCard: typeof import('./src/components/CommonCard.vue')['default'] CommonCard: typeof import('./src/components/CommonCard.vue')['default']
DatePicker: typeof import('./src/components/Form.vue/DatePicker.vue')['default'] DatePicker: typeof import('./src/components/Form/DatePicker.vue')['default']
DateRangePicker: typeof import('./src/components/Form.vue/DateRangePicker.vue')['default'] DateRangePicker: typeof import('./src/components/Form/DateRangePicker.vue')['default']
ElButton: typeof import('element-plus/es')['ElButton'] ElButton: typeof import('element-plus/es')['ElButton']
ElCard: typeof import('element-plus/es')['ElCard'] ElCard: typeof import('element-plus/es')['ElCard']
ElCarousel: typeof import('element-plus/es')['ElCarousel'] ElCarousel: typeof import('element-plus/es')['ElCarousel']
...@@ -49,6 +49,8 @@ declare module 'vue' { ...@@ -49,6 +49,8 @@ declare module 'vue' {
ElTabPane: typeof import('element-plus/es')['ElTabPane'] ElTabPane: typeof import('element-plus/es')['ElTabPane']
ElTabs: typeof import('element-plus/es')['ElTabs'] ElTabs: typeof import('element-plus/es')['ElTabs']
ElTag: typeof import('element-plus/es')['ElTag'] ElTag: typeof import('element-plus/es')['ElTag']
ElTimeline: typeof import('element-plus/es')['ElTimeline']
ElTimelineItem: typeof import('element-plus/es')['ElTimelineItem']
ElTooltip: typeof import('element-plus/es')['ElTooltip'] ElTooltip: typeof import('element-plus/es')['ElTooltip']
ElTree: typeof import('element-plus/es')['ElTree'] ElTree: typeof import('element-plus/es')['ElTree']
ElUpload: typeof import('element-plus/es')['ElUpload'] ElUpload: typeof import('element-plus/es')['ElUpload']
...@@ -59,11 +61,11 @@ declare module 'vue' { ...@@ -59,11 +61,11 @@ declare module 'vue' {
RenderColumn: typeof import('./src/components/RenderColumn.vue')['default'] RenderColumn: typeof import('./src/components/RenderColumn.vue')['default']
RouterLink: typeof import('vue-router')['RouterLink'] RouterLink: typeof import('vue-router')['RouterLink']
RouterView: typeof import('vue-router')['RouterView'] RouterView: typeof import('vue-router')['RouterView']
Select: typeof import('./src/components/Form.vue/Select.vue')['default'] Select: typeof import('./src/components/Form/Select.vue')['default']
ShipmentOrderDetail: typeof import('./src/components/ShipmentOrderDetail.vue')['default'] ShipmentOrderDetail: typeof import('./src/components/ShipmentOrderDetail.vue')['default']
SplitDiv: typeof import('./src/components/splitDiv/splitDiv.vue')['default'] SplitDiv: typeof import('./src/components/splitDiv/splitDiv.vue')['default']
'Switch ': typeof import('./src/components/Form.vue/Switch .vue')['default'] 'Switch ': typeof import('./src/components/Form/Switch .vue')['default']
TableRightMenu: typeof import('./src/components/TableRightMenu.vue')['default'] TableRightClickMenu: typeof import('./src/components/TableRightClickMenu.vue')['default']
TableView: typeof import('./src/components/TableView.vue')['default'] TableView: typeof import('./src/components/TableView.vue')['default']
UploadExcel: typeof import('./src/components/UploadExcel.vue')['default'] UploadExcel: typeof import('./src/components/UploadExcel.vue')['default']
UploadImage: typeof import('./src/components/UploadImage.vue')['default'] UploadImage: typeof import('./src/components/UploadImage.vue')['default']
......
...@@ -9,7 +9,7 @@ import { AddDeclarationRuleObj } from '@/views/logistics/types/declarationRule' ...@@ -9,7 +9,7 @@ import { AddDeclarationRuleObj } from '@/views/logistics/types/declarationRule'
import { LogisticsQuotation } from '@/views/logistics/types/logisticsQuotation' import { LogisticsQuotation } from '@/views/logistics/types/logisticsQuotation'
import { LogisticsPartitionObj } from '@/views/logistics/types/logisticsPartition' import { LogisticsPartitionObj } from '@/views/logistics/types/logisticsPartition'
import { ShippingAddressObj } from '@/views/logistics/types/shippingAddress' import { ShippingAddressObj } from '@/views/logistics/types/shippingAddress'
import { IsortingInfo } from '@/types/api/logistics'
export interface ILogisticsList { export interface ILogisticsList {
code: string code: string
basicsName: string basicsName: string
...@@ -433,3 +433,37 @@ export function logisticsCompanyAllCodelist() { ...@@ -433,3 +433,37 @@ export function logisticsCompanyAllCodelist() {
'/logisticsCompany/allCodelist', '/logisticsCompany/allCodelist',
) )
} }
export function getsortingConfigListApi(
data: IsortingInfo,
currentPage: number,
pageSize: number,
) {
return axios.post<never, BasePaginationData<IsortingInfo>>(
'logistics/sortingConfig/list_page',
{
...data,
currentPage,
pageSize,
},
)
}
export function createSortingApi(data: IsortingInfo) {
return axios.post<never, BaseRespData<never>>(
'logistics/sortingConfig/add',
data,
)
}
export function updateSortingApi(data: IsortingInfo) {
return axios.post<never, BaseRespData<never>>(
'logistics/sortingConfig/update',
data,
)
}
export function deleteSortingApi(ids: string) {
return axios.get<never, BaseRespData<never>>(
'logistics/sortingConfig/delete',
{
params: { ids },
},
)
}
import { BasePaginationData, BaseRespData, RejectParams } from '@/types/api' import { BasePaginationData, BaseRespData } from '@/types/api'
import axios from './axios' import axios from './axios'
import { PaymentForm } from '@/types/api/index.ts'
import { import {
LogListData, LogListData,
OrderData, OrderData,
...@@ -11,6 +10,8 @@ import { ...@@ -11,6 +10,8 @@ import {
ShipmentOrderRes, ShipmentOrderRes,
Tab, Tab,
InspectionData, InspectionData,
PaymentForm,
RejectParams
} from '@/types/api/order' } from '@/types/api/order'
import { import {
apiSubmitPodOrderForm, apiSubmitPodOrderForm,
...@@ -151,7 +152,7 @@ export function apiSetCraftData({ ...@@ -151,7 +152,7 @@ export function apiSetCraftData({
}: { }: {
id: number | undefined id: number | undefined
craftTotalPrice: number | undefined craftTotalPrice: number | undefined
recNumber:string|undefined recNumber: string | undefined
craftPriceList: IUpdatePrice[] craftPriceList: IUpdatePrice[]
}) { }) {
return axios.post<never, BaseRespData<never>>( return axios.post<never, BaseRespData<never>>(
......
...@@ -37,6 +37,12 @@ export function getOrderList( ...@@ -37,6 +37,12 @@ export function getOrderList(
}, },
) )
} }
export function handleExceptionOrderApi(orderIds: number[]) {
return axios.post<never, BaseRespData<never>>(
'factory/podJomallOrderUs/processExceptionOrders',
orderIds,
)
}
export function getCardOrderList( export function getCardOrderList(
params: SearchForm, params: SearchForm,
currentPage: number, currentPage: number,
...@@ -80,14 +86,17 @@ export function updateExceptionOrderApi(data: number[]) { ...@@ -80,14 +86,17 @@ export function updateExceptionOrderApi(data: number[]) {
}, },
) )
} }
export function changeExceptionOrderApi(ids: number[], value: string) { export function changeExceptionOrderApi(
return axios.post<never, BaseRespData<never>>( url: string,
'factory/podJomallOrderUs/exceptionOrders', ids: number[],
{ type: string,
orderIds: ids, value: string,
exceptionReason: value, ) {
}, return axios.post<never, BaseRespData<never>>(url, {
) orderIds: ids,
exceptionType: type,
exceptionReason: value,
})
} }
export function cancelOrderApi(ids: number[], value: string) { export function cancelOrderApi(ids: number[], value: string) {
return axios.post<never, BaseRespData<never>>( return axios.post<never, BaseRespData<never>>(
......
...@@ -314,9 +314,9 @@ export function InRecordBatchCheckPrintApi(ids: string) { ...@@ -314,9 +314,9 @@ export function InRecordBatchCheckPrintApi(ids: string) {
}, },
) )
} }
export function warehouseInRecordInventory(data: ExportInWarehouseInfo) { export function warehouseInRecordExport(data: ExportInWarehouseInfo) {
return axios.post<never, BasePaginationData<never>>( return axios.post<never, BasePaginationData<never>>(
'factory/warehouseInRecord/inventory', 'factory/warehouseInRecord/export',
data, data,
) )
} }
...@@ -438,6 +438,20 @@ export function getInRecordLogApi(inRecordId?: number) { ...@@ -438,6 +438,20 @@ export function getInRecordLogApi(inRecordId?: number) {
) )
} }
// 出库单 // 出库单
export function warehouseOutRecordExport(data: ExportInWarehouseInfo) {
return axios.post<never, BasePaginationData<never>>(
'factory/warehouseOutRecord/export',
data,
)
}
export function OutRecordBatchCheckPrintApi(ids: string) {
return axios.get<never, BaseRespData<never[]>>(
'factory/warehouseOutRecord/batchCheckPrint',
{
params: { ids },
},
)
}
export function getOutRecordStatusTree() { export function getOutRecordStatusTree() {
return axios.get<never, BaseRespData<InterWarehouseTree[]>>( return axios.get<never, BaseRespData<InterWarehouseTree[]>>(
'factory/warehouseOutRecord/status_tree', 'factory/warehouseOutRecord/status_tree',
......
...@@ -2,12 +2,12 @@ import { defineComponent, PropType, ref, computed, h } from 'vue' ...@@ -2,12 +2,12 @@ import { defineComponent, PropType, ref, computed, h } from 'vue'
import type { Component } from 'vue' import type { Component } from 'vue'
import { ElInput, ElForm, ElFormItem } from 'element-plus' import { ElInput, ElForm, ElFormItem } from 'element-plus'
import type { FormInstance } from 'element-plus' import type { FormInstance } from 'element-plus'
import AmountInput from './Form.vue/AmountInput.vue' // 金额输入框 import AmountInput from './Form/AmountInput.vue' // 金额输入框
import DateRangePicker from './Form.vue/DateRangePicker.vue' // 时间范围选择器 import DateRangePicker from './Form/DateRangePicker.vue' // 时间范围选择器
import DatePicker from './Form.vue/DatePicker.vue' // 单个日期选择器 import DatePicker from './Form/DatePicker.vue' // 单个日期选择器
import Select from './Form.vue/Select.vue' // 普通下拉选择框 import Select from './Form/Select.vue' // 普通下拉选择框
import Switch from './Form.vue/Switch .vue' import Switch from './Form/Switch .vue'
import './Form.vue/form.scss' import './Form/form.scss'
import type { FormItemRule } from 'element-plus' import type { FormItemRule } from 'element-plus'
......
...@@ -10,6 +10,7 @@ ...@@ -10,6 +10,7 @@
mode="horizontal" mode="horizontal"
background-color="#001529" background-color="#001529"
text-color="#fff" text-color="#fff"
style="border-bottom: none;"
:default-active="defaultActive" :default-active="defaultActive"
router router
> >
...@@ -86,8 +87,9 @@ ...@@ -86,8 +87,9 @@
> >
<div class="nav-tabs-node_label"> <div class="nav-tabs-node_label">
<span>{{ item.title }}</span> <span>{{ item.title }}</span>
<!-- 首页不可删除 -->
<el-icon <el-icon
v-if="tabs.length > 1" v-if="item.path != '/dashboard' && tabs.length > 1"
class="el-icon-close" class="el-icon-close"
@click.stop="removeTab(item.name)" @click.stop="removeTab(item.name)"
> >
......
import { defineComponent, PropType, ref, computed, watch, h } from 'vue' import { defineComponent, PropType, ref, computed, watch, h } from 'vue'
import type { Component } from 'vue' import type { Component } from 'vue'
import AmountInput from './Form.vue/AmountInput.vue' // 金额输入框 import AmountInput from './Form/AmountInput.vue' // 金额输入框
import DateRangePicker from './Form.vue/DateRangePicker.vue' // 时间范围选择器 import DateRangePicker from './Form/DateRangePicker.vue' // 时间范围选择器
import DatePicker from './Form.vue/DatePicker.vue' // 单个日期选择器 import DatePicker from './Form/DatePicker.vue' // 单个日期选择器
import Select from './Form.vue/Select.vue' // 普通下拉选择框 import Select from './Form/Select.vue' // 普通下拉选择框
import { ElInput, ElForm, ElFormItem, ElButton } from 'element-plus' import { ElInput, ElForm, ElFormItem, ElButton } from 'element-plus'
import { import {
ISearchForm, ISearchForm,
......
<template>
<div
v-show="visible"
class="right-click-menu"
:style="{ left: position.x + 'px', top: position.y + 'px' }"
>
<div class="menu-item" @click="handleSelectAll">全选</div>
<div class="menu-item" @click="handleUnselectAll">取消全选</div>
<div class="menu-item" @click="onChangeCopy('shop-numbers')">
复制店铺单号
</div>
</div>
</template>
<script setup lang="ts">
import { ref, defineExpose, onMounted, onUnmounted } from 'vue'
import type { TableInstance } from 'element-plus'
const visible = ref(false)
const position = ref({ x: 0, y: 0 })
const tableRef = ref<TableInstance>()
const emit = defineEmits(['onChange'])
const setPosition = ({
x,
y,
el,
}: {
x: number
y: number
el: TableInstance
}) => {
position.value = { x, y }
visible.value = true
tableRef.value = el
}
const handleSelectAll = () => {
if (tableRef.value) {
tableRef.value.toggleAllSelection()
}
visible.value = false
}
const handleUnselectAll = () => {
if (tableRef.value) {
tableRef.value.clearSelection()
}
visible.value = false
}
const onChangeCopy = (value: string) => {
emit('onChange', value)
visible.value = false
}
// 点击其他地方关闭菜单
const handleClickOutside = () => {
if (visible.value) {
visible.value = false
}
}
// 监听全局点击事件
onMounted(() => {
document.addEventListener('click', handleClickOutside)
})
onUnmounted(() => {
document.removeEventListener('click', handleClickOutside)
})
defineExpose({
setPosition,
})
</script>
<style scoped>
.right-click-menu {
position: fixed;
background: white;
border: 1px solid #e4e7ed;
border-radius: 4px;
box-shadow: 0 2px 12px 0 rgba(0, 0, 0, 0.1);
z-index: 3000;
}
.menu-item {
padding: 8px 16px;
cursor: pointer;
font-size: 14px;
color: #606266;
}
.menu-item:hover {
background-color: #f5f7fa;
color: #409eff;
}
</style>
<template>
<div
v-if="tableRightMenuVisible"
class="table-right-menu"
:style="{
left: rightMenuOptions.contextMenuX + 'px',
top: rightMenuOptions.contextMenuY + 'px',
}"
>
<div
class="table-right-menu-item"
@click="handleChange('copy_shop_number')"
>
<span>复制店铺单号</span>
</div>
</div>
</template>
<script setup lang="ts">
import { ref } from 'vue'
defineProps({
tableRightMenuVisible: {
type: Boolean,
default: false,
},
})
const emit = defineEmits(['onCopyChange'])
const handleChange = (type: string) => {
emit('onCopyChange', type)
}
const rightMenuOptions = ref({
contextMenuX: 0,
contextMenuY: 0,
})
const setRightMenuOptions = (options: {
contextMenuX: number
contextMenuY: number
}) => {
rightMenuOptions.value = options
}
defineExpose({
setRightMenuOptions,
})
</script>
<style lang="scss" scoped>
.table-right-menu {
position: fixed;
z-index: 1000;
border: 1px solid #ccc;
box-shadow: 0 0 10px 0 rgba(0, 0, 0, 0.1);
padding: 6px;
}
.table-right-menu-item {
padding: 5px;
cursor: pointer;
font-size: 14px;
&:hover {
background-color: #f0f0f0;
}
}
</style>
...@@ -8,6 +8,7 @@ ...@@ -8,6 +8,7 @@
v-bind="attrs" v-bind="attrs"
header-align="center" header-align="center"
height="100%" height="100%"
@contextmenu.prevent="handleContextMenu"
> >
<ElTableColumn <ElTableColumn
v-if="selectionable" v-if="selectionable"
...@@ -57,14 +58,20 @@ ...@@ -57,14 +58,20 @@
</RenderColumn> </RenderColumn>
</template> </template>
</ElTable> </ElTable>
<RightClickMenu ref="rightMenuRef" @on-change="onChange" />
</div> </div>
</template> </template>
<script setup lang="tsx" generic="T"> <script setup lang="tsx" generic="T">
import { type Slot, useAttrs, useSlots, type PropType, shallowRef } from 'vue' import { type Slot, useAttrs, useSlots, type PropType, shallowRef } from 'vue'
import type { CustomColumn } from '@/types/table' import type { CustomColumn } from '@/types/table'
import RenderColumn from './RenderColumn.vue' import RenderColumn from './RenderColumn.vue'
import RightClickMenu from './TableRightClickMenu.vue'
import { ElTable } from 'element-plus' import { ElTable } from 'element-plus'
const tableRef = shallowRef<InstanceType<typeof ElTable>>() import type { TableInstance } from 'element-plus'
const tableRef = shallowRef<TableInstance>()
const rightMenuRef = shallowRef<InstanceType<typeof RightClickMenu>>()
// eslint-disable-next-line @typescript-eslint/no-explicit-any // eslint-disable-next-line @typescript-eslint/no-explicit-any
defineProps({ defineProps({
paginatedData: { paginatedData: {
...@@ -88,14 +95,30 @@ defineProps({ ...@@ -88,14 +95,30 @@ defineProps({
default: false, default: false,
}, },
}) })
const attrs = useAttrs() const attrs = useAttrs()
const slots = useSlots() as Record<string, Slot> const slots = useSlots() as Record<string, Slot>
const emit = defineEmits(['onChange'])
const handleContextMenu = (e: MouseEvent) => {
if (rightMenuRef.value && tableRef.value) {
rightMenuRef.value.setPosition({
x: e.clientX,
y: e.clientY,
el: tableRef.value,
})
}
}
const onChange = (type: string) => {
emit('onChange', type)
}
const setCurrentRow = (row: T) => { const setCurrentRow = (row: T) => {
tableRef.value?.setCurrentRow(row) tableRef.value?.setCurrentRow(row)
} }
const toggleRowSelection = (row: T, selected: boolean = true) => { const toggleRowSelection = (row: T, selected: boolean = true) => {
tableRef.value?.toggleRowSelection(row, selected) tableRef.value?.toggleRowSelection(row, selected)
} }
const clearSelection = () => { const clearSelection = () => {
tableRef.value?.clearSelection() tableRef.value?.clearSelection()
} }
...@@ -112,5 +135,6 @@ defineExpose({ ...@@ -112,5 +135,6 @@ defineExpose({
.table-view { .table-view {
height: 100%; height: 100%;
overflow: hidden; overflow: hidden;
position: relative;
} }
</style> </style>
[
{
"name": "Shopify",
"lowercase": "shopify",
"type": "SHOPIFY",
"icon": "images/icon/logo-1.png",
"cycle": "today",
"route": "store_profits_shopify"
},
{
"name": "AliExpress",
"lowercase": "aliExpress",
"type": "AE",
"icon": "./images/icon/logo-3.png",
"cycle": "today",
"route": "store_profits_aliexpress"
},
{
"name": "Amazon",
"lowercase": "amazon",
"type": "AMAZON",
"icon": "./images/icon/logo-2.png",
"cycle": "yesterday",
"route": "store_profits_amazon"
},
{
"name": "Magento",
"lowercase": "magento",
"type": "MAGENTO",
"icon": "./images/icon/logo-6.png",
"cycle": "today",
"route": "store_profits_magento"
},
{
"name": "SHOPLINE",
"lowercase": "shopline",
"type": "SHOPLINE",
"cycle": "today",
"icon": "./images/icon/logo-4.png",
"route": "store_profits_shopline"
},
{
"name": "Shoplazza",
"lowercase": "shoplazza",
"type": "SHOPLAZZA",
"cycle": "today",
"icon": "./images/icon/logo-5.png",
"route": "store_profits_shoplazza"
},
{
"name": "temu",
"lowercase": "temu",
"type": "TEMU",
"cycle": "today",
"icon": "./images/icon/temu.png",
"route": "store_profits_temu"
},
{
"name": "eBay",
"lowercase": "ebay",
"type": "EBAY",
"cycle": "today",
"icon": "./images/icon/eBay.png",
"route": "store_profits_ebay"
},
{
"name": "Etsy",
"lowercase": "etsy",
"type": "ETSY",
"cycle": "today",
"icon": "./images/icon/etsy.png",
"route": "store_profits_etsy"
},
{
"name": "Alibaba",
"lowercase": "alibaba",
"type": "ALIBABA",
"cycle": "today",
"icon": "./images/icon/alibaba.png",
"route": "store_profits_alibaba"
},
{
"name": "walmart",
"lowercase": "walmart",
"type": "WALMART",
"cycle": "today",
"icon": "images/icon/walmart.png",
"route": "store_profits_walmart"
},
{
"name": "tiktokshop",
"lowercase": "tiktok",
"type": "TIKTOK",
"cycle": "today",
"icon": "images/icon/tiktokshop.png",
"route": "store_profits_tiktokshop"
},
{
"name": "Customize",
"lowercase": "customize",
"type": "CUSTOMIZE",
"cycle": "today",
"icon": "images/icon/customize.png",
"route": "store_profits_customize"
},
{
"name": "1688",
"type": "ALIBABA_DOMESTIC",
"cycle": "today",
"icon": "images/icon/1688.png",
"route": "store_profits_1688"
}
]
...@@ -27,8 +27,8 @@ import WarehouseManage from '@/views/warehouse/manage.vue' ...@@ -27,8 +27,8 @@ import WarehouseManage from '@/views/warehouse/manage.vue'
import WarehouseWarning from '@/views/warehouse/warning.vue' import WarehouseWarning from '@/views/warehouse/warning.vue'
import WarehousePosition from '@/views/warehouse/position.vue' import WarehousePosition from '@/views/warehouse/position.vue'
import receiptDoc from '@/views/warehouse/receiptDoc.vue' import receiptDoc from '@/views/warehouse/receiptDoc.vue'
import issueDoc from '@/views/warehouse/issueDoc.vue'
import ExternalAuthorisationPage from '@/views/system/externalAuthorisationPage.vue' import ExternalAuthorisationPage from '@/views/system/externalAuthorisationPage.vue'
// import issueDoc from '@/views/warehouse/issueDoc.vue'
const router = createRouter({ const router = createRouter({
history: createWebHistory(), history: createWebHistory(),
routes: [ routes: [
...@@ -176,6 +176,13 @@ const router = createRouter({ ...@@ -176,6 +176,13 @@ const router = createRouter({
}, },
component: () => import('@/views/logistics/logisticsCalculate.vue'), component: () => import('@/views/logistics/logisticsCalculate.vue'),
}, },
{
path: '/logistics/sortingConfiguration',
meta: {
title: '分拣配置',
},
component: () => import('@/views/logistics/sortingConfiguration.vue'),
},
{ {
path: '/warehouse/manage', path: '/warehouse/manage',
meta: { meta: {
...@@ -190,13 +197,13 @@ const router = createRouter({ ...@@ -190,13 +197,13 @@ const router = createRouter({
}, },
component: receiptDoc, component: receiptDoc,
}, },
// { {
// path: '/warehouse/issue-doc', path: '/warehouse/issue-doc',
// meta: { meta: {
// title: '出库单', title: '出库单',
// }, },
// component: issueDoc, component: issueDoc,
// }, },
{ {
path: '/warehouse/warning', path: '/warehouse/warning',
meta: { meta: {
......
...@@ -56,6 +56,11 @@ const menu: MenuItem[] = [ ...@@ -56,6 +56,11 @@ const menu: MenuItem[] = [
id: 6, id: 6,
label: '运费试算', label: '运费试算',
}, },
{
index: '/logistics/sortingConfiguration',
id: 7,
label: '分拣配置',
},
], ],
}, },
{ {
...@@ -73,11 +78,11 @@ const menu: MenuItem[] = [ ...@@ -73,11 +78,11 @@ const menu: MenuItem[] = [
id: 123, id: 123,
label: '入库单', label: '入库单',
}, },
// { {
// index: '/warehouse/issue-doc', index: '/warehouse/issue-doc',
// id: 124, id: 124,
// label: '出库单', label: '出库单',
// }, },
{ {
index: '/warehouse/manage', index: '/warehouse/manage',
......
...@@ -35,17 +35,4 @@ export interface baseRes { ...@@ -35,17 +35,4 @@ export interface baseRes {
code: number code: number
msg: string msg: string
} }
export interface PaymentForm {
waterList: string
id?: number | string
actualAmount?: number | string
payableAmount?: number | string
recNumber?: number | string
}
export interface RejectParams {
id: number
description?: string
ids?: string
pass?: number
}
export interface Ilogistics {
id: number
name: string
warehouseId: number
warehouseName: string
uinuinWarehouseId: number | null
companyId: number | null
company: string | null
serviceCode: string
siteUrl: string
status: number
factoryId: number
createTime: string
updateTime: string | null
}
export interface IsortingInfo {
id?: number
sortingArea: number | null
sortingAreaName?: string | null
serviceCode: string | null
}
...@@ -81,7 +81,7 @@ export interface ProductList { ...@@ -81,7 +81,7 @@ export interface ProductList {
subOrderNumber?: string subOrderNumber?: string
shopNumber?: string shopNumber?: string
material?: string material?: string
materialPrice?: number|null materialPrice?: number | null
count?: number count?: number
baseSku?: string baseSku?: string
erpSubOrderNumber?: string erpSubOrderNumber?: string
...@@ -277,3 +277,16 @@ export interface ICompareObjects { ...@@ -277,3 +277,16 @@ export interface ICompareObjects {
lanshouPost?: string lanshouPost?: string
lanshouRegion?: string lanshouRegion?: string
} }
export interface PaymentForm {
waterList: string
id?: number | string
actualAmount?: number | string
payableAmount?: number | string
recNumber?: number | string
}
export interface RejectParams {
id: number
description?: string
ids?: string
pass?: number
}
...@@ -16,6 +16,9 @@ export interface SearchForm { ...@@ -16,6 +16,9 @@ export interface SearchForm {
customizedQuantity: string customizedQuantity: string
startTime: string | null startTime: string | null
endTime: string | null endTime: string | null
exceptionHandling: number | undefined
platform: string
productionClient:string
} }
export interface PodUsOrderListData { export interface PodUsOrderListData {
id: number id: number
......
...@@ -5,6 +5,8 @@ export interface warehouseSearchForm { ...@@ -5,6 +5,8 @@ export interface warehouseSearchForm {
billStatus?: string billStatus?: string
createTimeEnd?: string createTimeEnd?: string
createTimeStart?: string createTimeStart?: string
startTime?: string
endTime?: string
inNo?: string inNo?: string
outNo?: string outNo?: string
warehouseSku?: string warehouseSku?: string
...@@ -14,6 +16,7 @@ export interface warehouseSearchForm { ...@@ -14,6 +16,7 @@ export interface warehouseSearchForm {
export interface InterProductList { export interface InterProductList {
createTime?: string createTime?: string
id?: number id?: number
inventoryId?: number | null
inId?: number inId?: number
productNo?: string | null //custom的货号 productNo?: string | null //custom的货号
buyStored?: number | null //入库数量 buyStored?: number | null //入库数量
...@@ -42,6 +45,7 @@ export interface InterWarehouseBase { ...@@ -42,6 +45,7 @@ export interface InterWarehouseBase {
total?: number total?: number
totalPrice?: number totalPrice?: number
billStatus?: string billStatus?: string
billStatusTxt?: string
remark?: string | null remark?: string | null
dataVersion?: number dataVersion?: number
createTime?: string | null createTime?: string | null
...@@ -86,6 +90,9 @@ export interface InterProductList { ...@@ -86,6 +90,9 @@ export interface InterProductList {
warehouseSku?: string warehouseSku?: string
locationId?: number | null locationId?: number | null
locationCode?: string | null locationCode?: string | null
inventory?: {
usableInventory?: number
}
} }
export interface InterskuList { export interface InterskuList {
id?: number id?: number
...@@ -101,6 +108,7 @@ export interface InterskuList { ...@@ -101,6 +108,7 @@ export interface InterskuList {
price?: number | null //出库单的 price?: number | null //出库单的
usableInventory?: number | null usableInventory?: number | null
warehouseSku?: string warehouseSku?: string
remark?: string | null
} }
export interface ILocation { export interface ILocation {
id?: number id?: number
......
...@@ -108,7 +108,6 @@ export function checkUpdateParams( ...@@ -108,7 +108,6 @@ export function checkUpdateParams(
removeList = arr1.map((item) => item['id'] as IdType) removeList = arr1.map((item) => item['id'] as IdType)
} }
if (isBackKeyName) { if (isBackKeyName) {
console.log(isBackKeyName)
// 将列表直接添加到 params 顶层 // 将列表直接添加到 params 顶层
if (addList.length > 0) params['addList'] = addList || undefined if (addList.length > 0) params['addList'] = addList || undefined
if (updateList.length > 0) if (updateList.length > 0)
......
...@@ -271,9 +271,11 @@ ...@@ -271,9 +271,11 @@
v-loading="loading" v-loading="loading"
element-loading-text="加载中..." element-loading-text="加载中..."
class="order-list flex-1 overflow-hidden" class="order-list flex-1 overflow-hidden"
@contextmenu.prevent="handleContextMenu"
> >
<ElTable <ElTable
v-show="statusCode !== 6" v-show="statusCode !== 6"
ref="tableRef"
:data="tableData" :data="tableData"
:span-method="arraySpanMethod" :span-method="arraySpanMethod"
default-expand-all default-expand-all
...@@ -597,6 +599,7 @@ ...@@ -597,6 +599,7 @@
</ElTable> </ElTable>
<ElTable <ElTable
v-show="statusCode === 6" v-show="statusCode === 6"
ref="tableQaRef"
:data="tableData" :data="tableData"
:span-method="arraySpanMethod" :span-method="arraySpanMethod"
default-expand-all default-expand-all
...@@ -973,6 +976,12 @@ ...@@ -973,6 +976,12 @@
> >
<OrderDetail :order-detail-data="orderDetailData" /> <OrderDetail :order-detail-data="orderDetailData" />
</ElDrawer> </ElDrawer>
<RightMenu
ref="rightMenuRef"
:show-copy-count="false"
:show-copy-sub-shop-number="statusCode !== 6"
@change="onChange"
/>
</template> </template>
<script setup lang="ts"> <script setup lang="ts">
import Shipment from './Shipment.vue' import Shipment from './Shipment.vue'
...@@ -990,7 +999,12 @@ import type { ...@@ -990,7 +999,12 @@ import type {
} from '@/types/api/order' } from '@/types/api/order'
import { nextTick, onMounted, reactive, ref } from 'vue' import { nextTick, onMounted, reactive, ref } from 'vue'
import useElTableColumnWidth from '@/utils/hooks/useElTableColumnWidth' import useElTableColumnWidth from '@/utils/hooks/useElTableColumnWidth'
import { ArrowDown, ArrowUp, DocumentCopy, EditPen } from '@element-plus/icons-vue' import {
ArrowDown,
ArrowUp,
DocumentCopy,
EditPen,
} from '@element-plus/icons-vue'
import usePageList from '@/utils/hooks/usePageList' import usePageList from '@/utils/hooks/usePageList'
import { import {
getOrderList, getOrderList,
...@@ -1023,6 +1037,7 @@ import OrderDetail from './OrderDetail.vue' ...@@ -1023,6 +1037,7 @@ import OrderDetail from './OrderDetail.vue'
import useShipment from './hook/useShipment' import useShipment from './hook/useShipment'
import useQuarantine from './hook/useQuarantine' import useQuarantine from './hook/useQuarantine'
import Quarantine from './Quarantine.vue' import Quarantine from './Quarantine.vue'
import RightMenu from './pod/rightMenu.vue'
const [searchForm] = useValue<SearchForm>({ const [searchForm] = useValue<SearchForm>({
mainSku: '', mainSku: '',
...@@ -1644,7 +1659,65 @@ const cancelOrder = async (id: number) => { ...@@ -1644,7 +1659,65 @@ const cancelOrder = async (id: number) => {
// showError(e) // showError(e)
} }
} }
const rightMenuRef = ref()
const handleContextMenu = (e: MouseEvent) => {
rightMenuRef.value?.setPosition({
x: e.clientX,
y: e.clientY,
cardItem: e.clientY,
el: e,
})
}
const tableQaRef = ref()
const tableRef = ref()
const onChange = (key: string) => {
if (key === 'check_all') {
if (statusCode.value === 6) {
tableQaRef.value?.toggleAllSelection()
} else {
tableRef.value?.toggleAllSelection()
}
} else if (key === 'clear_check') {
if (statusCode.value === 6) {
tableQaRef.value?.clearSelection()
} else {
tableRef.value?.clearSelection()
}
} else if (key === 'copy_code') {
const shopNumberList: string[] = []
for (const item of selection.value) {
item.productList?.forEach((el) => {
if (el.shopNumber) {
shopNumberList.push(el.shopNumber)
}
})
}
copy(shopNumberList.join(','))
} else if (key === 'copy_shopNumber') {
const subOrderNumber: string[] = []
if (statusCode.value === 6) {
for (const item of selection.value) {
item.detailList?.forEach((el) => {
if (el.shopNumber) {
subOrderNumber.push(el.shopNumber || '')
}
})
}
} else {
for (const item of selection.value) {
item.productList?.forEach((el) => {
if (el.subOrderNumber) {
subOrderNumber.push(el.subOrderNumber)
}
})
}
}
copy(subOrderNumber.join(','))
} else if (key === 'count') {
const count = selection.value.length
copy(count.toString())
}
}
const onChangeCurrentRow = (item: ProductList) => { const onChangeCurrentRow = (item: ProductList) => {
currentRow.value = item currentRow.value = item
} }
......
...@@ -231,7 +231,12 @@ ...@@ -231,7 +231,12 @@
v-if="['TO_BE_CONFIRMED', 'IN_PRODUCTION'].includes(status)" v-if="['TO_BE_CONFIRMED', 'IN_PRODUCTION'].includes(status)"
class="item" class="item"
> >
<ElButton :loading="syncLoading" type="warning" is-dark @click="synchronousPlan"> <ElButton
:loading="syncLoading"
type="warning"
is-dark
@click="synchronousPlan"
>
同步素材图</ElButton 同步素材图</ElButton
> >
</span> </span>
...@@ -481,7 +486,7 @@ ...@@ -481,7 +486,7 @@
" "
> >
{{ cardItem?.processName }} {{ cardItem?.processName }}
</span> </span>
</el-col> </el-col>
<el-col <el-col
:span="12" :span="12"
...@@ -544,11 +549,10 @@ ...@@ -544,11 +549,10 @@
> >
<img width="20" src="@/assets/images/id.png" /> <img width="20" src="@/assets/images/id.png" />
<el-tooltip :content="cardItem?.productionFileId"> <el-tooltip :content="cardItem?.productionFileId">
<span class="over-hidden" title="素材ID"> <span class="over-hidden" title="素材ID">
{{ cardItem?.productionFileId }} {{ cardItem?.productionFileId }}
</span> </span>
</el-tooltip> </el-tooltip>
</a> </a>
</el-col> </el-col>
<el-col <el-col
...@@ -594,7 +598,7 @@ ...@@ -594,7 +598,7 @@
default-expand-all default-expand-all
:span-method="arraySpanMethod" :span-method="arraySpanMethod"
@selection-change="handleSelectionChange" @selection-change="handleSelectionChange"
@contextmenu.prevent="handleContextMenu" @on-change="onChange"
> >
<template #expand="{ row }"> <template #expand="{ row }">
<div v-if="row.productList" class="table-expand"> <div v-if="row.productList" class="table-expand">
...@@ -974,6 +978,9 @@ ...@@ -974,6 +978,9 @@
:show-copy-shop-number=" :show-copy-shop-number="
['IN_PRODUCTION', 'TO_BE_CONFIRMED', 'WAIT_SHIPMENT'].includes(status) ['IN_PRODUCTION', 'TO_BE_CONFIRMED', 'WAIT_SHIPMENT'].includes(status)
" "
:show-copy-count="
['IN_PRODUCTION', 'TO_BE_CONFIRMED', 'WAIT_SHIPMENT'].includes(status)
"
@change="rightChange" @change="rightChange"
/> />
<fastProduction <fastProduction
...@@ -986,11 +993,6 @@ ...@@ -986,11 +993,6 @@
@on-success="handleSuccess" @on-success="handleSuccess"
@close="fastClose" @close="fastClose"
></fastProduction> ></fastProduction>
<table-right-menu
ref="tableRightMenuRef"
:table-right-menu-visible="tableRightMenuVisible"
@on-copy-change="onCopyChange"
/>
<el-dialog <el-dialog
v-model="completeShipmentVisible" v-model="completeShipmentVisible"
title="完成发货" title="完成发货"
...@@ -1105,7 +1107,6 @@ import { ...@@ -1105,7 +1107,6 @@ import {
SearchForm, SearchForm,
Tab, Tab,
LogListData, LogListData,
PodProductList, PodProductList,
cardImages, cardImages,
imageAryInter, imageAryInter,
...@@ -1825,7 +1826,9 @@ const synchronousPlan = async () => { ...@@ -1825,7 +1826,9 @@ const synchronousPlan = async () => {
return return
} }
try { try {
const res = await syncSubOrderDesignImages(selection.value.map(item=>item.id)) const res = await syncSubOrderDesignImages(
selection.value.map((item) => item.id),
)
await loadDiffList() await loadDiffList()
await loadTabData() await loadTabData()
syncLoading.value = false syncLoading.value = false
...@@ -2161,10 +2164,8 @@ const invalidOrder = async (row: ProductList) => { ...@@ -2161,10 +2164,8 @@ const invalidOrder = async (row: ProductList) => {
} }
}) })
} }
const tableRightMenuVisible = ref(false) const onChange = (type: string) => {
const tableRightMenuRef = ref() if (type === 'shop-numbers') {
const onCopyChange = (type: string) => {
if (type === 'copy_shop_number') {
const shopNumberList = [] const shopNumberList = []
for (const item of tableData.value) { for (const item of tableData.value) {
if (item.productList) { if (item.productList) {
...@@ -2174,16 +2175,6 @@ const onCopyChange = (type: string) => { ...@@ -2174,16 +2175,6 @@ const onCopyChange = (type: string) => {
copy(shopNumberList.join(',')) copy(shopNumberList.join(','))
} }
} }
const handleContextMenu = (e: MouseEvent) => {
tableRightMenuVisible.value = true
tableRightMenuRef.value?.setRightMenuOptions({
contextMenuX: e.clientX,
contextMenuY: e.clientY,
})
}
const listenerClick = () => {
tableRightMenuVisible.value = false
}
const getUserMark = async () => { const getUserMark = async () => {
try { try {
...@@ -2208,7 +2199,6 @@ const openMaterial = async (item: PodProductList) => { ...@@ -2208,7 +2199,6 @@ const openMaterial = async (item: PodProductList) => {
} }
onMounted(async () => { onMounted(async () => {
document.addEventListener('keydown', listenerKeydown) document.addEventListener('keydown', listenerKeydown)
document.addEventListener('click', listenerClick)
await loadTabData() await loadTabData()
getUserMark() getUserMark()
getLogisticsList() getLogisticsList()
...@@ -2216,7 +2206,6 @@ onMounted(async () => { ...@@ -2216,7 +2206,6 @@ onMounted(async () => {
}) })
onBeforeUnmount(() => { onBeforeUnmount(() => {
document.removeEventListener('keydown', listenerKeydown) document.removeEventListener('keydown', listenerKeydown)
document.removeEventListener('click', listenerClick)
}) })
</script> </script>
<style lang="scss" scoped> <style lang="scss" scoped>
...@@ -2491,9 +2480,9 @@ onBeforeUnmount(() => { ...@@ -2491,9 +2480,9 @@ onBeforeUnmount(() => {
display: flex; display: flex;
align-items: center; align-items: center;
} }
.over-hidden{ .over-hidden {
width: 150px; width: 150px;
display:inline-block; display: inline-block;
white-space: nowrap; white-space: nowrap;
overflow: hidden; overflow: hidden;
text-overflow: ellipsis; text-overflow: ellipsis;
......
<template> <template>
<!-- <div class="wrap" @click="close"> --> <!-- <div class="wrap" @click="close"> -->
<div v-if="show" ref="right_menu" class="right_menu"> <div v-if="show" ref="right_menu" class="right_menu">
<button @click="$emit('change', 'check_all')"> <button @click="$emit('change', 'check_all')">全部选择</button>
全部选择
</button>
<button @click="$emit('change', 'clear_check')">取消选择</button> <button @click="$emit('change', 'clear_check')">取消选择</button>
<button @click="$emit('change', 'copy_code')">复制选中生产单号</button> <button v-if="showCopySubShopNumber" @click="$emit('change', 'copy_code')">
复制选中生产单号
</button>
<button v-if="showCopyShopNumber" @click="$emit('change', 'copy_shopNumber')">复制选中店铺单号</button> <button
<button v-if="showCopyShopNumber" @click="$emit('change', 'count')">统计数量</button> v-if="showCopyShopNumber"
@click="$emit('change', 'copy_shopNumber')"
>
复制选中店铺单号
</button>
<button v-if="showCopyCount" @click="$emit('change', 'count')">
统计数量
</button>
</div> </div>
<!-- </div> --> <!-- </div> -->
</template> </template>
<script setup lang="ts"> <script setup lang="ts">
import {ref,defineProps,defineExpose} from 'vue' import { ref, defineProps, defineExpose } from 'vue'
interface E{ interface E {
x:number x: number
el:HTMLElement el: HTMLElement
y:number y: number
} }
defineProps({ defineProps({
showCopyShopNumber:{ showCopyShopNumber: {
type:Boolean, type: Boolean,
default:true default: true,
} },
showCopyCount: {
type: Boolean,
default: true,
},
showCopySubShopNumber: {
type: Boolean,
default: true,
},
}) })
const row = ref() const row = ref()
const show = ref(false) const show = ref(false)
const right_menu = ref<HTMLElement>() const right_menu = ref<HTMLElement>()
const close = ()=>{ const close = () => {
show.value = false show.value = false
document.body.onclick = null document.body.onclick = null
} }
const setPosition = (o:E)=> { const setPosition = (o: E) => {
console.log(o) console.log(o)
show.value = true show.value = true
const clientX = o.x const clientX = o.x
...@@ -42,18 +57,17 @@ const setPosition = (o:E)=> { ...@@ -42,18 +57,17 @@ const setPosition = (o:E)=> {
document.body.onclick = function () { document.body.onclick = function () {
close() close()
} }
row.value = row.value = setTimeout(() => {
setTimeout(() => { if (!right_menu.value) return
if(!right_menu.value) return
if (x < 150) { if (x < 150) {
right_menu.value.style.cssText = `top:${o.y}px;right:${x}px` right_menu.value.style.cssText = `top:${o.y}px;right:${x}px`
} else { } else {
right_menu.value.style.cssText = `top:${o.y}px;left:${o.x}px` right_menu.value.style.cssText = `top:${o.y}px;left:${o.x}px`
} }
}, 1) }, 1)
} }
defineExpose({ defineExpose({
setPosition setPosition,
}) })
</script> </script>
<style scoped> <style scoped>
...@@ -89,7 +103,7 @@ defineExpose({ ...@@ -89,7 +103,7 @@ defineExpose({
background: rgb(65, 192, 251); background: rgb(65, 192, 251);
color: white; color: white;
} }
button{ button {
outline: none; outline: none;
border: none; border: none;
} }
......
...@@ -112,18 +112,16 @@ const submitExportForm = async () => { ...@@ -112,18 +112,16 @@ const submitExportForm = async () => {
return ElMessage.error('请选择导出类型') return ElMessage.error('请选择导出类型')
} }
exportLoading.value = true exportLoading.value = true
let purchaseIds = '' let purchaseIds: number[] = []
let exportTotal: number | undefined = undefined let exportTotal: number | undefined = undefined
const params: AnyObject = {} const params: AnyObject = {}
const resourceType = Number(exportForm.value.resource) const resourceType = Number(exportForm.value.resource)
if (resourceType === 0) { if (resourceType === 0) {
purchaseIds = leftData.value.map((el: WarehouseWarning) => el.id).join(',') purchaseIds = leftData.value.map((el: WarehouseWarning) => Number(el.id))
} else if (resourceType === 1) { } else if (resourceType === 1) {
purchaseIds = selections.value purchaseIds = selections.value.map((el: WarehouseWarning) => Number(el.id))
.map((el: WarehouseWarning) => el.id)
.join(',')
} else if (resourceType === 2) { } else if (resourceType === 2) {
purchaseIds = '' purchaseIds = []
exportTotal = pagination.value.total exportTotal = pagination.value.total
} }
params.idList = purchaseIds params.idList = purchaseIds
......
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