Commit 80481a71 by qinjianhui

feat: 主表和底部明细页面开发

parent dbcacf03
......@@ -54,7 +54,6 @@ declare module 'vue' {
ElTag: typeof import('element-plus/es')['ElTag']
ElTimeline: typeof import('element-plus/es')['ElTimeline']
ElTimelineItem: typeof import('element-plus/es')['ElTimelineItem']
ElTimePicker: typeof import('element-plus/es')['ElTimePicker']
ElTooltip: typeof import('element-plus/es')['ElTooltip']
ElTree: typeof import('element-plus/es')['ElTree']
ElUpload: typeof import('element-plus/es')['ElUpload']
......
......@@ -5,6 +5,7 @@ import { LogisticBill } from '@/types/api/podMakeOrder'
import { userData } from '@/types/api/user'
import { VersionImageList } from '@/types/api/typesetting'
import { WarehouseListData } from '@/types'
// 获取物流公司
export function getLogisticsCompanyList() {
......@@ -49,3 +50,14 @@ export function getLogisticCNApi(content: string) {
`factory/podJomallOrder/getOrderByThirdSubOrderNumber?thirdSubOrderNumber=${content}`,
)
}
// 获取仓库列表
export function loadWarehouseListApi() {
return axios.get<never, BaseRespData<WarehouseListData[]>>(
'factoryWarehouseInfo/getAll',
)
}
// 获取用户列表
export function getEmployeeListApi() {
return axios.get<never, BaseRespData<userData[]>>(`/factory/factoryUser/list`)
}
......@@ -5,7 +5,6 @@ import {
SearchForm,
Tab,
LogListData,
WarehouseListData,
LogisticsData,
ExportParams,
IconfirmSubmit,
......@@ -39,10 +38,6 @@ export function syncReceiverAddress(data: number[]) {
)
}
export function getEmployeeListApi() {
return axios.get(`/factory/factoryUser/list`)
}
// 播种墙配货 扫码放入箱子
export function getPackingCnDataApi(
code: string,
......@@ -419,11 +414,7 @@ export function getLogisticsCalculation(id: number) {
{ params: { id } },
)
}
export function loadWarehouseListApi() {
return axios.get<never, BaseRespData<WarehouseListData[]>>(
'factoryWarehouseInfo/getAll',
)
}
export function refreshMaterialApi(data: {
orderIds?: string
productIds?: string
......
......@@ -6,7 +6,6 @@ import {
Tab,
LogListData,
ProductionClient,
WarehouseListData,
LogisticsData,
ExportParams,
InterceptStateGroupData,
......@@ -310,11 +309,6 @@ export function getLogisticsCalculation(id: number) {
{ params: { id } },
)
}
export function loadWarehouseListApi() {
return axios.get<never, BaseRespData<WarehouseListData[]>>(
'factoryWarehouseInfo/getAll',
)
}
export function refreshMaterialApi(data: {
orderIds?: string
productIds?: string
......@@ -640,11 +634,6 @@ export function getAccountCodeByFactoryIdApi(params: { token: string }) {
export function getLogisticsWayApi() {
return axios.get(`logisticsWay/usableAllList`)
}
export function getEmployeeListApi() {
return axios.get(`/factory/factoryUser/list`)
}
// 打印拣货单item
export function printPickPdfByBatchNumberApi(params: {
batchArrangeNumber: string
......
import axios from './axios'
import { BasePaginationData, BaseRespData } from '@/types/api'
import { SearchForm, TableData, TreeData } from '@/types/api/supply/stockingOrder'
export function getStockingOrderListApi(
data: SearchForm,
currentPage: number,
pageSize: number,
) {
return axios.post<never, BasePaginationData<TableData>>(
'factory/supply/stockingUpManage/list_page',
{ ...data, currentPage, pageSize },
)
}
export function getStockingOrderStatusTreeApi() {
return axios.get<never, BaseRespData<TreeData[]>>(
'factory/supply/stockingUpManage/getStatusTree',
)
}
\ No newline at end of file
......@@ -194,16 +194,7 @@ export interface PodOrderRes extends ProductList {
note?: Array<{ prop: string | number; value: string | number }>
imgList: cardImages[]
}
export interface WarehouseListData {
code?: string
defaulted?: number
factoryCode?: string
factoryId?: number
id: number
name?: string
remarks?: string
sort?: number
}
export interface LogisticsData {
logisticsWayName: string // 物流名称
warehouseName: string // 发货仓库
......
export interface TreeData {
statusName: string
statusCode: string
name: string
code: string
children?: TreeData[]
quantity?: number
countQuantity?: number
id?: number
}
export interface SearchForm {
pageSize: number
currentPage: number
sku: string
}
\ No newline at end of file
endDate?: string
pageSize: number
shippingStatus?: string
startDate?: string
status?: string
stockingUpManageNo?: string
stockingUpUserId?: string
supplierId?: string
warehouseId?: string | number[]
warehouseSku?: string | number[]
warehouseSkuName?: string
remark?: string
}
export interface TableData {}
export interface StockProduct {
skuImage?: string
productName?: string
styleNumber?: string
warehouseSku?: string
stockQuantity?: number
stockUnitPrice?: number
stockAmount?: number
unshippedQuantity?: number
shippedQuantity?: number
inWarehouseQuantity?: number
defectiveQuantity?: number
}
export interface supplierData {}
// 放系统中公共类型
export interface WarehouseListData {
code?: string
defaulted?: number
factoryCode?: string
factoryId?: number
id: number
name?: string
remarks?: string
sort?: number
}
\ No newline at end of file
......@@ -86,10 +86,10 @@ import {
getTiktokCarrier,
} from '@/api/logistics'
import type { FormItemRule } from 'element-plus'
import { WarehouseListData } from '@/types/api/podUsOrder'
import { WarehouseListData } from '@/types'
import { ISeachFormConfig } from '@/types/searchType'
import { TableColumn } from '@/components/VxeTable'
import { loadWarehouseListApi } from '@/api/podUsOrder'
import { loadWarehouseListApi } from '@/api/common'
import type {
LogisticsMethod,
platformObj,
......
......@@ -2812,7 +2812,6 @@ import {
printPrintOrderApi,
stockOutCheckApi,
toBePickingApi,
loadWarehouseListApi,
getLogisticsCalculation,
refreshProductInformationApi,
composingDesignImages,
......@@ -2849,10 +2848,11 @@ import {
getCustomTagListCnApi,
printNormalPdf,
changeLogisticsApi,
getEmployeeListApi,
allErpCodeListApi,
updateProductOutOfStockApi,
} from '@/api/podCnOrder'
import { loadWarehouseListApi, getEmployeeListApi } from '@/api/common'
// import { logisticsCompanyAllCodelist } from '@/api/logistics.ts'
import { BaseRespData } from '@/types/api'
......@@ -2870,7 +2870,6 @@ import {
ProductionClient,
SearchForm,
Tab,
WarehouseListData,
cardImages,
AddressInfo,
LogisticsData,
......@@ -2878,6 +2877,7 @@ import {
CraftListData,
ExportParams,
} from '@/types/api/podCnOrder'
import { WarehouseListData } from '@/types'
import usePageList from '@/utils/hooks/usePageList'
import { useValue } from '@/utils/hooks/useValue'
import { showConfirm } from '@/utils/ui'
......@@ -2904,6 +2904,7 @@ import {
type RouteLocationNormalized,
} from 'vue-router'
import UpdateCustomDeclarationInfoDialog from './components/UpdateCustomDeclarationInfoDialog.vue'
import { userData } from '@/types/api/user.ts'
declare global {
interface Window {
......@@ -2977,7 +2978,7 @@ const sourceList = [
},
]
const sizes = ['FS', 'XS', 'S', 'M', 'L', 'XL', 'XXL', '3XL', '4XL', '5XL']
const employeeList = ref<{ account: string; id: number }[]>([])
const employeeList = ref<userData[]>([])
const exportData = () => {
exportVisible.value = true
......
......@@ -3147,7 +3147,7 @@
</template>
<script setup lang="tsx">
import LogisticsWaySelect from '../../logistics/components/LogisticsWaySelect.tsx'
import { getUserMarkList } from '@/api/common'
import { getUserMarkList, loadWarehouseListApi } from '@/api/common'
// import { AnyObject } from '@/types/api/warehouse'
import uploadBox from '@/components/uploadBox.vue'
import { convertToChinaTime } from '@/utils/index'
......@@ -3180,7 +3180,6 @@ import {
printPrintOrderApi,
stockOutCheckApi,
toBePickingApi,
loadWarehouseListApi,
getLogisticsCalculation,
refreshMaterialApi,
getTrackingNumberApi,
......@@ -3226,7 +3225,6 @@ import {
getLogisticsWayApi,
printNormalPickPdfApi,
updatePRNDownloadStatus,
getEmployeeListApi,
updateProductOutOfStockApi,
} from '@/api/podUsOrder'
import { BaseRespData } from '@/types/api'
......@@ -3234,7 +3232,7 @@ import { BaseRespData } from '@/types/api'
import UpdateAddress from './components/updateAddress.vue'
import { getAllCountryApi } from '@/api/logistics.ts'
import { getEmployeeListApi } from '@/api/common'
import TableView from '@/components/TableView.vue'
import {
LogListData,
......@@ -3243,7 +3241,6 @@ import {
ProductionClient,
SearchForm,
Tab,
WarehouseListData,
cardImages,
AddressInfo,
LogisticsData,
......@@ -3279,6 +3276,7 @@ import platformJson from '../../../json/platform.json'
import { getToken } from '@/api/axios'
import usePermissionBtnStore from '@/store/permission'
import ReissueOrderComponent from './components/ReissueOrder.vue'
import { WarehouseListData } from '@/types'
const permissionBtns = usePermissionBtnStore()
......@@ -3288,6 +3286,7 @@ import {
type RouteLocationNormalized,
} from 'vue-router'
import PrintWarehouseSkuTag from '@/views/order/components/printWarehouseSkuTag.vue'
import { userData } from '@/types/api/user.ts'
declare global {
interface Window {
......@@ -3325,7 +3324,7 @@ const printWarehouseSkuDialogRef = ref()
const isAuto = ref(true)
const countryList = ref([])
const logisticsWayList = ref<{ name: string; id: number }[]>([])
const employeeList = ref<{ account: string; id: number }[]>([])
const employeeList = ref<userData[]>([])
const currentRow = ref<AddressInfo>({
receiverName: '',
receiverPhone: '',
......
......@@ -107,9 +107,9 @@
import { computed, ref, onMounted } from 'vue'
import TableView from '@/components/TableView.vue'
import usePageList from '@/utils/hooks/usePageList'
import { loadWarehouseListApi } from '@/api/podCnOrder'
import type { WarehouseListData } from '@/types/api/podCnOrder'
import { SearchForm, OutOfStockItem } from '@/types/api/outOfStockStatistics'
import { loadWarehouseListApi } from '@/api/common'
import { WarehouseListData } from '@/types'
import { SearchForm, OutOfStockItem } from '@/types/api/supply/outOfStockStatistics'
import {
getOutOfStockStatisticsListApi,
exportOutOfStockStatisticsListApi,
......
<template>
<ElTabs v-model="activeTab" class="detail-tabs">
<ElTabPane name="stockProducts" label="备货商品">
<div class="detail-table-content">
<TableView
:serial-numberable="true"
:columns="stockProductsColumns"
:paginated-data="stockProductsData"
/>
</div>
</ElTabPane>
<ElTabPane name="relatedDocuments" label="关联单据">
<div class="detail-table-content">
<div class="empty-content">暂无数据</div>
</div>
</ElTabPane>
<ElTabPane name="internalMemo" label="内部便签">
<div class="detail-table-content">
<div class="empty-content">暂无数据</div>
</div>
</ElTabPane>
<ElTabPane name="operationLog" label="操作日志">
<div class="detail-table-content">
<div class="empty-content">暂无数据</div>
</div>
</ElTabPane>
</ElTabs>
</template>
<script setup lang="ts">
import { ref } from 'vue'
import TableView from '@/components/TableView.vue'
import { StockProduct } from '@/types/api/supply/stockingOrder'
const stockProductsColumns = computed(() => {
return [
{
label: 'SKU图片',
prop: 'skuImage',
width: 100,
align: 'center',
},
{
label: '商品名称',
prop: 'productName',
minWidth: 200,
align: 'left',
},
{
label: '款号',
prop: 'styleNumber',
width: 120,
align: 'center',
},
{
label: '库存SKU',
prop: 'warehouseSku',
width: 150,
align: 'center',
},
{
label: '备货数量',
prop: 'stockQuantity',
width: 100,
align: 'right',
},
{
label: '备货单价',
prop: 'stockUnitPrice',
width: 100,
align: 'right',
},
{
label: '备货金额',
prop: 'stockAmount',
width: 120,
align: 'right',
},
{
label: '未发货数量',
prop: 'unshippedQuantity',
width: 120,
align: 'right',
},
{
label: '已发货数量',
prop: 'shippedQuantity',
width: 120,
align: 'right',
},
{
label: '已入库数量',
prop: 'inWarehouseQuantity',
width: 120,
align: 'right',
},
{
label: '不良品数量',
prop: 'defectiveQuantity',
width: 120,
align: 'right',
},
]
})
defineProps<{
stockProductsData: StockProduct[]
}>()
const activeTab = ref('stockProducts')
</script>
<style lang="scss" scoped>
.detail-tabs {
height: 100%;
display: flex;
:deep(.el-tab-pane) {
height: 100%;
overflow: hidden;
}
}
.detail-table-content {
height: 100%;
overflow: hidden;
}
.empty-content {
display: flex;
align-items: center;
justify-content: center;
height: 100%;
color: #909399;
font-size: 14px;
}
</style>
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