Browse Source

提交文件方便部署

master
songguoqiang 1 year ago
parent
commit
9983e80ec1
  1. 12
      src/api/wms/file/index.ts
  2. 70
      src/api/wms/location/index.ts
  3. 51
      src/api/wms/locationcapacity/index.ts
  4. 58
      src/api/wms/locationgroup/index.ts
  5. 14
      src/api/wms/remark/index.ts
  6. 6
      src/views/spc/location/index.vue

12
src/api/wms/file/index.ts

@ -0,0 +1,12 @@
import request from '@/config/axios'
// 查询变更记录列表
export const getFileList = async (params) => {
return await request.get({ url: `/infra/file/list`, params })
}
// 删除库区
export const deleteFile = async (id: number) => {
return await request.delete({ url: `/infra/file/delete?id=` + id })
}

70
src/api/wms/location/index.ts

@ -0,0 +1,70 @@
import request from '@/config/axios'
export interface LocationVO {
code: string
name: string
description: string
warehouseCode: string
areaCode: string
locationGroupCode: string
erpLocationCode: string
type: string
aisle: string
shelf: string
locationRow: number
locationColum: number
pickPriority: number
maxWeight: number
maxArea: number
maxVolume: number
userGroupCode: string
available: number
activeTime: Date
expireTime: Date
remark: string
}
// 查询库位列表
export const getLocationPage = async (params) => {
if (params.isSearch) {
delete params.isSearch
const data = {...params}
return request.post({ url: '/wms/location/senior', data })
} else {
return await request.get({ url: `/wms/location/page`, params })
}
}
// 查询库位所有列表
export const getLocationList = async (params) => {
return await request.get({ url: `/wms/location/list`, params })
}
// 查询库位详情
export const getLocation = async (id: number) => {
return await request.get({ url: `/wms/location/get?id=` + id })
}
// 新增库位
export const createLocation = async (data: LocationVO) => {
return await request.post({ url: `/wms/location/create`, data })
}
// 修改库位
export const updateLocation = async (data: LocationVO) => {
return await request.put({ url: `/wms/location/update`, data })
}
// 删除库位
export const deleteLocation = async (id: number) => {
return await request.delete({ url: `/wms/location/delete?id=` + id })
}
// 导出库位 Excel
export const exportLocation = async (params) => {
return await request.download({ url: `/wms/location/export-excel`, params })
}
// 下载用户导入模板
export const importTemplate = () => {
return request.download({ url: '/wms/location/get-import-template' })
}

51
src/api/wms/locationcapacity/index.ts

@ -0,0 +1,51 @@
import request from '@/config/axios'
export interface LocationcapacityVO {
locationCode: string
warehouseCode: string
usedCapacity: number
availableCapacity: number
bearableOverloadCapacity: number
isInfinity: string
}
// 查询库位容量列表
export const getLocationcapacityPage = async (params) => {
if (params.isSearch) {
delete params.isSearch
const data = {...params}
return await request.post({ url: '/wms/locationcapacity/senior', data })
} else {
return await request.get({ url: `/wms/locationcapacity/page`, params })
}
}
// 查询库位容量详情
export const getLocationcapacity = async (id: number) => {
return await request.get({ url: `/wms/locationcapacity/get?id=` + id })
}
// 新增库位容量
export const createLocationcapacity = async (data: LocationcapacityVO) => {
return await request.post({ url: `/wms/locationcapacity/create`, data })
}
// 修改库位容量
export const updateLocationcapacity = async (data: LocationcapacityVO) => {
return await request.put({ url: `/wms/locationcapacity/update`, data })
}
// 删除库位容量
export const deleteLocationcapacity = async (id: number) => {
return await request.delete({ url: `/wms/locationcapacity/delete?id=` + id })
}
// 导出库位容量 Excel
export const exportLocationcapacity = async (params) => {
return await request.download({ url: `/wms/locationcapacity/export-excel`, params })
}
// 下载用户导入模板
export const importTemplate = () => {
return request.download({ url: '/wms/locationcapacity/get-import-template' })
}

58
src/api/wms/locationgroup/index.ts

@ -0,0 +1,58 @@
import request from '@/config/axios'
export interface LocationgroupVO {
code: string
name: string
description: string
warehouseCode: string
areaCode: string
available: number
activeTime: Date
expireTime: Date
remark: string
}
// 查询库位组列表
export const getLocationgroupPage = async (params) => {
if (params.isSearch) {
delete params.isSearch
const data = {...params}
return request.post({ url: '/wms/locationgroup/senior', data })
} else {
return await request.get({ url: `/wms/locationgroup/page`, params })
}
}
// 查询库位组列表
export const getLocationgroupList = async (params) => {
return await request.get({ url: `/wms/locationgroup/list`, params })
}
// 查询库位组详情
export const getLocationgroup = async (id: number) => {
return await request.get({ url: `/wms/locationgroup/get?id=` + id })
}
// 新增库位组
export const createLocationgroup = async (data: LocationgroupVO) => {
return await request.post({ url: `/wms/locationgroup/create`, data })
}
// 修改库位组
export const updateLocationgroup = async (data: LocationgroupVO) => {
return await request.put({ url: `/wms/locationgroup/update`, data })
}
// 删除库位组
export const deleteLocationgroup = async (id: number) => {
return await request.delete({ url: `/wms/locationgroup/delete?id=` + id })
}
// 导出库位组 Excel
export const exportLocationgroup = async (params) => {
return await request.download({ url: `/wms/locationgroup/export-excel`, params })
}
// 下载用户导入模板
export const importTemplate = () => {
return request.download({ url: '/wms/locationgroup/get-import-template' })
}

14
src/api/wms/remark/index.ts

@ -0,0 +1,14 @@
import request from '@/config/axios'
// 查询备注列表
export const getRemarkPage = async (params) => {
return await request.get({ url: `/infra/remark/list`, params })
}
// 新增备注
export const createRemark= async (data) => {
return await request.post({ url: `/infra/remark/create`, data })
}
// 查询变更记录列表
export const getChangeRecordPage = async (params) => {
return await request.get({ url: `/infra/trends/list`, params })
}

6
src/views/spc/location/index.vue

@ -60,13 +60,9 @@
<script setup lang="ts"> <script setup lang="ts">
import download from '@/utils/download' import download from '@/utils/download'
import * as LocationApi from '@/api/wms/location' import * as LocationApi from '@/api/wms/location'
import BasicForm from '@/components/BasicForm/src/BasicForm.vue'
import { Location, LocationRules } from './location.data' import { Location, LocationRules } from './location.data'
import * as defaultButtons from '@/utils/disposition/defaultButtons' import * as defaultButtons from '@/utils/disposition/defaultButtons'
import TableHead from '@/components/TableHead/src/TableHead.vue'
import ImportForm from '@/components/ImportForm/src/ImportForm.vue'
import Detail from '@/components/Detail/src/Detail.vue'
defineOptions({ name: 'Location' }) defineOptions({ name: 'Location' })
const message = useMessage() // const message = useMessage() //

Loading…
Cancel
Save