diff --git a/src/api/eam/fixedAssets/index.ts b/src/api/eam/fixedAssets/index.ts deleted file mode 100644 index 8564b5a..0000000 --- a/src/api/eam/fixedAssets/index.ts +++ /dev/null @@ -1,61 +0,0 @@ -import request from '@/config/axios' - -export interface FixedAssetsVO { - number: string - name: string - specifications: string - locationNumber: string - purchaseDept: string - supplierNumber: string - productionDate: Date - purchasePrice: number - manageDept: string - qty: number - siteId: string - available: string - concurrencyStamp: number - purchaseDate: Date - unit: string - accountingUnit: string -} - -// 查询固定资产列表 -export const getFixedAssetsPage = async (params) => { - if (params.isSearch) { - delete params.isSearch - const data = {...params} - return await request.post({ url: '/eam/fixed-assets/senior', data }) - } else { - return await request.get({ url: `/eam/fixed-assets/page`, params }) - } -} - -// 查询固定资产详情 -export const getFixedAssets = async (id: number) => { - return await request.get({ url: `/eam/fixed-assets/get?id=` + id }) -} - -// 新增固定资产 -export const createFixedAssets = async (data: FixedAssetsVO) => { - return await request.post({ url: `/eam/fixed-assets/create`, data }) -} - -// 修改固定资产 -export const updateFixedAssets = async (data: FixedAssetsVO) => { - return await request.put({ url: `/eam/fixed-assets/update`, data }) -} - -// 删除固定资产 -export const deleteFixedAssets = async (id: number) => { - return await request.delete({ url: `/eam/fixed-assets/delete?id=` + id }) -} - -// 导出固定资产 Excel -export const exportFixedAssets = async (params) => { - return await request.download({ url: `/eam/fixed-assets/export-excel`, params }) -} - -// 下载用户导入模板 -export const importTemplate = () => { - return request.download({ url: '/eam/fixed-assets/get-import-template' }) -} \ No newline at end of file diff --git a/src/views/eam/fixedAssets/fixedAssets.data.ts b/src/views/eam/fixedAssets/fixedAssets.data.ts deleted file mode 100644 index 17c8c49..0000000 --- a/src/views/eam/fixedAssets/fixedAssets.data.ts +++ /dev/null @@ -1,157 +0,0 @@ -import type { CrudSchema } from '@/hooks/web/useCrudSchemas' -import { dateFormatter } from '@/utils/formatTime' - -// 表单校验 -export const FixedAssetsRules = reactive({ - number: [required], - name: [required], - locationNumber: [required], - supplierNumber: [required], - purchasePrice: [required], - qty: [required], - concurrencyStamp: [required] -}) - -export const FixedAssets = useCrudSchemas(reactive([ - { - label: '编号唯一标识', - field: 'number', - sort: 'custom', - isSearch: true - }, - { - label: '资产名称', - field: 'name', - sort: 'custom', - isSearch: true - }, - // { - // label: '规格型号', - // field: 'specifications', - // sort: 'custom', - // isSearch: true - // }, - // { - // label: '库位编号', - // field: 'locationNumber', - // sort: 'custom', - // isSearch: true - // }, - // { - // label: '采购部门', - // field: 'purchaseDept', - // sort: 'custom', - // isSearch: true - // }, - // { - // label: '供应商编号', - // field: 'supplierNumber', - // sort: 'custom', - // isSearch: true - // }, - // { - // label: '出厂日期', - // field: 'productionDate', - // sort: 'custom', - // formatter: dateFormatter, - // isSearch: true, - // search: { - // component: 'DatePicker', - // componentProps: { - // valueFormat: 'YYYY-MM-DD HH:mm:ss', - // type: 'daterange', - // defaultTime: [new Date('1 00:00:00'), new Date('1 23:59:59')] - // } - // }, - // form: { - // component: 'DatePicker', - // componentProps: { - // type: 'datetime', - // valueFormat: 'x' - // } - // } - // }, - // { - // label: '购买价格', - // field: 'purchasePrice', - // sort: 'custom', - // isSearch: true - // }, - // { - // label: '管理部门', - // field: 'manageDept', - // sort: 'custom', - // isSearch: true - // }, - // { - // label: '数量', - // field: 'qty', - // sort: 'custom', - // isSearch: true - // }, - // { - // label: '地点ID', - // field: 'siteId', - // sort: 'custom', - // isSearch: true - // }, - // { - // label: '是否可用', - // field: 'available', - // sort: 'custom', - // isSearch: true - // }, - // { - // label: '并发乐观锁', - // field: 'concurrencyStamp', - // sort: 'custom', - // isSearch: true, - // form: { - // component: 'InputNumber', - // value: 0 - // } - // }, - // { - // label: '购买时间', - // field: 'purchaseDate', - // sort: 'custom', - // formatter: dateFormatter, - // isSearch: true, - // search: { - // component: 'DatePicker', - // componentProps: { - // valueFormat: 'YYYY-MM-DD HH:mm:ss', - // type: 'daterange', - // defaultTime: [new Date('1 00:00:00'), new Date('1 23:59:59')] - // } - // }, - // form: { - // component: 'DatePicker', - // componentProps: { - // type: 'datetime', - // valueFormat: 'x' - // } - // } - // }, - // { - // label: '单位', - // field: 'unit', - // sort: 'custom', - // isSearch: true - // }, - // { - // label: '会计单位', - // field: 'accountingUnit', - // sort: 'custom', - // isSearch: true - // }, - { - label: '操作', - field: 'action', - isForm: false, - table: { - width: 150, - fixed: 'right' - } - } -])) diff --git a/src/views/eam/fixedAssets/index.vue b/src/views/eam/fixedAssets/index.vue deleted file mode 100644 index e79f16b..0000000 --- a/src/views/eam/fixedAssets/index.vue +++ /dev/null @@ -1,244 +0,0 @@ - - -