diff --git a/src/api/qms/baseMaterialInfo/index.ts b/src/api/qms/baseMaterialInfo/index.ts new file mode 100644 index 0000000..561d279 --- /dev/null +++ b/src/api/qms/baseMaterialInfo/index.ts @@ -0,0 +1,78 @@ +import request from '@/utils/request'; +import { AxiosPromise } from 'axios'; +import { BaseMaterialInfoVO, BaseMaterialInfoForm, BaseMaterialInfoQuery } from '@/api/qms/baseMaterialInfo/types'; + +/** + * 查询物料信息列表 + * @param query + * @returns {*} + */ + +export const listBaseMaterialInfo = (query?: BaseMaterialInfoQuery): AxiosPromise => { + return request({ + url: '/qms/baseMaterialInfo/list', + method: 'get', + params: query + }); +}; + +/** + * 查询物料信息详细 + * @param materialId + */ +export const getBaseMaterialInfo = (materialId: string | number): AxiosPromise => { + return request({ + url: '/qms/baseMaterialInfo/' + materialId, + method: 'get' + }); +}; + +/** + * 新增物料信息 + * @param data + */ +export const addBaseMaterialInfo = (data: BaseMaterialInfoForm) => { + return request({ + url: '/qms/baseMaterialInfo', + method: 'post', + data: data + }); +}; + +/** + * 修改物料信息 + * @param data + */ +export const updateBaseMaterialInfo = (data: BaseMaterialInfoForm) => { + return request({ + url: '/qms/baseMaterialInfo', + method: 'put', + data: data + }); +}; + +/** + * 删除物料信息 + * @param materialId + */ +export const delBaseMaterialInfo = (materialId: string | number | Array) => { + return request({ + url: '/qms/baseMaterialInfo/' + materialId, + method: 'delete' + }); +}; + + +/** + * 下拉框查询物料信息列表 + * @param query + * @returns {*} + */ +export function getBaseMaterialInfoList (query) { + return request({ + url: '/qms/baseMaterialInfo/getBaseMaterialInfoList', + method: 'get', + params: query + }); +}; + diff --git a/src/api/qms/baseMaterialInfo/types.ts b/src/api/qms/baseMaterialInfo/types.ts new file mode 100644 index 0000000..c866317 --- /dev/null +++ b/src/api/qms/baseMaterialInfo/types.ts @@ -0,0 +1,801 @@ +export interface BaseMaterialInfoVO { + /** + * 主键标识 + */ + materialId: string | number; + + /** + * 租户编号 + */ + tenantId: string | number; + + /** + * ERP信息 + */ + erpId: string | number; + + /** + * 物料编码 + */ + materialCode: string; + + /** + * 旧物料编码 + */ + oldMaterialCode: string; + + /** + * 物料名称 + */ + materialName: string; + + /** + * 物料类型ID + */ + materialTypeId: string | number; + + /** + * 物料大类(字典改为从数据库中获得) + */ + materialCategoryId: string; + + /** + * 物料小类 + */ + materialSubclass: string; + + /** + * 批次标识(0否 1是) + */ + batchFlag: string; + + /** + * 小批次数量 + */ + batchAmount: number; + + /** + * 计量单位ID + */ + materialUnitId: string | number; + + /** + * 计量单位名称 + */ + materialUnit: string; + + /** + * 物料组 + */ + materialMatkl: string; + + /** + * 物料规格 + */ + materialSpec: string; + + /** + * 净重 + */ + netWeight: number; + + /** + * 毛重 + */ + grossWeight: number; + + /** + * 绑定标识(1是 0否) + */ + alwaysFlag: string; + + /** + * 所属工厂 + */ + factoryId: string | number; + + /** + * 创建组织 + */ + createOrgId: string | number; + + /** + * 使用组织 + */ + useOrgId: string | number; + + /** + * 所属产线 + */ + prodLineId: string | number; + + /** + * 激活标识(1是 0否) + */ + activeFlag: string; + + /** + * 删除标识(0否 1是) + */ + deletedFlag: string; + + /** + * 采购计价单位 + */ + purchasePriceUnitId: string | number; + + /** + * 审核日期 + */ + approveDate: string; + + /** + * erp最后更新日期 + */ + erpModifyDate: string; + + /** + * 最大库存数量 + */ + maxStockAmount: number; + + /** + * 最小库存数量 + */ + minStockAmount: number; + + /** + * 安全库存数量 + */ + safeStockAmount: number; + + /** + * 申请标识(1是 0否) + */ + applyFlag: string; + + /** + * 物料分类(1ERP同步 2虚拟物料 3MES物料) + */ + materialClassfication: string; + + /** + * 自动出库标识(1是 0否) + */ + autoOutstockFlag: string; + + /** + * 辅料标识(1是 0否) + */ + accessoriesFlag: string; + + /** + * 低值易耗品标识(1是 0否) + */ + lowValueConsumableFlag: string; + + /** + * 品牌 + */ + brand: string; + + /** + * 层级 + */ + plyrating: string; + + /** + * 花纹 + */ + pattern: string; + + /** + * 速度级别 + */ + speedLevel: string; + + /** + * 负荷载重 + */ + load: string; + + /** + * 轮胎标记(1全钢胎 2半钢胎 3工程胎) + */ + tireMarkings: string; + + /** + * 最小停放时间(秒) + */ + minParkingTime: number; + + /** + * 最大停放时间(秒) + */ + maxParkingTime: number; + + /** + * 标准重量 + */ + standardWeight: number; + + /** + * 标准重量上限 + */ + weightUpperLimit: number; + + /** + * 标准重量下限 + */ + weightLowerLimit: number; + + /** + * 内胎标记(0无 1有) + */ + innerTubeFlag: string; + + /** + * 销售类型(0内销 1外销) + */ + saleType: string; + + /** + * 备注 + */ + remark: string; + + /** + * 创建部门 + */ + createDept: number; + + /** + * 创建人 + */ + createBy: number; + + /** + * 创建时间 + */ + createTime: string; + + /** + * 更新人 + */ + updateBy: number; + + /** + * 更新时间 + */ + updateTime: string; + + + /** + * 所属工厂 + */ + factoryName: string;//连表查询映射字段 + + + //注意"e":以下两个物料类型名称!BaseMaterialType实体类中为matrialTypeId,BaseMaterialInfo实体类中为materialTypeId + /** + * 物料类型名称 + */ + matrialTypeName: string;//连表查询映射字段 + + /** + * 物料类型名称 + */ + materialTypeName: string;//连表查询映射字段 + + /** + * 物料大类名称 + */ + materialCategoryName: string; + +} + +export interface BaseMaterialInfoForm extends BaseEntity { + /** + * 主键标识 + */ + materialId?: string | number; + + /** + * ERP信息 + */ + erpId?: string | number; + + /** + * 物料编码 + */ + materialCode?: string; + + /** + * 旧物料编码 + */ + oldMaterialCode?: string; + + /** + * 物料名称 + */ + materialName?: string; + + /** + * 物料类型ID + */ + materialTypeId?: string | number; + + /** + * 物料大类(字典改为从数据库中获得) + */ + materialCategoryId: string; + /** + * 物料小类 + */ + materialSubclass?: string; + + /** + * 批次标识(0否 1是) + */ + batchFlag?: string; + + /** + * 小批次数量 + */ + batchAmount?: number; + + /** + * 计量单位ID + */ + materialUnitId?: string | number; + + /** + * 计量单位名称 + */ + materialUnit?: string; + + /** + * 物料组 + */ + materialMatkl?: string; + + /** + * 物料规格 + */ + materialSpec?: string; + + /** + * 净重 + */ + netWeight?: number; + + /** + * 毛重 + */ + grossWeight?: number; + + /** + * 绑定标识(1是 0否) + */ + alwaysFlag?: string; + + /** + * 所属工厂 + */ + factoryId?: string | number; + + /** + * 创建组织 + */ + createOrgId?: string | number; + + /** + * 使用组织 + */ + useOrgId?: string | number; + + /** + * 所属产线 + */ + prodLineId?: string | number; + + /** + * 激活标识(1是 0否) + */ + activeFlag?: string; + + /** + * 删除标识(0否 1是) + */ + deletedFlag?: string; + + /** + * 采购计价单位 + */ + purchasePriceUnitId?: string | number; + + /** + * 审核日期 + */ + approveDate?: string; + + /** + * erp最后更新日期 + */ + erpModifyDate?: string; + + /** + * 最大库存数量 + */ + maxStockAmount?: number; + + /** + * 最小库存数量 + */ + minStockAmount?: number; + + /** + * 安全库存数量 + */ + safeStockAmount?: number; + + /** + * 申请标识(1是 0否) + */ + applyFlag?: string; + + /** + * 物料分类(1ERP同步 2虚拟物料 3MES物料) + */ + materialClassfication?: string; + + /** + * 自动出库标识(1是 0否) + */ + autoOutstockFlag?: string; + + /** + * 辅料标识(1是 0否) + */ + accessoriesFlag?: string; + + /** + * 低值易耗品标识(1是 0否) + */ + lowValueConsumableFlag?: string; + + /** + * 品牌 + */ + brand?: string; + + /** + * 层级 + */ + plyrating?: string; + + /** + * 花纹 + */ + pattern?: string; + + /** + * 速度级别 + */ + speedLevel?: string; + + /** + * 负荷载重 + */ + load?: string; + + /** + * 轮胎标记(1全钢胎 2半钢胎 3工程胎) + */ + tireMarkings?: string; + + /** + * 最小停放时间(秒) + */ + minParkingTime?: number; + + /** + * 最大停放时间(秒) + */ + maxParkingTime?: number; + + /** + * 标准重量 + */ + standardWeight?: number; + + /** + * 标准重量上限 + */ + weightUpperLimit?: number; + + /** + * 标准重量下限 + */ + weightLowerLimit?: number; + + /** + * 内胎标记(0无 1有) + */ + innerTubeFlag?: string; + + /** + * 销售类型(0内销 1外销) + */ + saleType?: string; + + /** + * 备注 + */ + remark?: string; + + minParkingDays?: number; + minParkingHours?: number; + minParkingMinutes?: number; + + maxParkingDays?: number; + maxParkingHours?: number; + maxParkingMinutes?: number; + + /** + * 物料大类名称 + */ + materialCategoryName: string; + +} + +export interface BaseMaterialInfoQuery extends PageQuery { + + /** + * 主键标识 + */ + materialId?: string | number; + + /** + * ERP信息 + */ + erpId?: string | number; + + /** + * 物料编码 + */ + materialCode?: string; + + /** + * 旧物料编码 + */ + oldMaterialCode?: string; + + /** + * 物料名称 + */ + materialName?: string; + + /** + * 物料类型ID + */ + materialTypeId?: string | number; + + /** + * 物料大类(字典改为从数据库中获得) + */ + materialCategoryId: string; + + /** + * 物料小类 + */ + materialSubclass?: string; + + /** + * 批次标识(0否 1是) + */ + batchFlag?: string; + + /** + * 小批次数量 + */ + batchAmount?: number; + + /** + * 计量单位ID + */ + materialUnitId?: string | number; + + /** + * 计量单位名称 + */ + materialUnit?: string; + + /** + * 物料组 + */ + materialMatkl?: string; + + /** + * 物料规格 + */ + materialSpec?: string; + + /** + * 净重 + */ + netWeight?: number; + + /** + * 毛重 + */ + grossWeight?: number; + + /** + * 绑定标识(1是 0否) + */ + alwaysFlag?: string; + + /** + * 所属工厂 + */ + factoryId?: string | number; + + /** + * 创建组织 + */ + createOrgId?: string | number; + + /** + * 使用组织 + */ + useOrgId?: string | number; + + /** + * 所属产线 + */ + prodLineId?: string | number; + + /** + * 激活标识(1是 0否) + */ + activeFlag?: string; + + /** + * 删除标识(0否 1是) + */ + deletedFlag?: string; + + /** + * 采购计价单位 + */ + purchasePriceUnitId?: string | number; + + /** + * 审核日期 + */ + approveDate?: string; + + /** + * erp最后更新日期 + */ + erpModifyDate?: string; + + /** + * 最大库存数量 + */ + maxStockAmount?: number; + + /** + * 最小库存数量 + */ + minStockAmount?: number; + + /** + * 安全库存数量 + */ + safeStockAmount?: number; + + /** + * 申请标识(1是 0否) + */ + applyFlag?: string; + + /** + * 物料分类(1ERP同步 2虚拟物料 3MES物料) + */ + materialClassfication?: string; + + /** + * 自动出库标识(1是 0否) + */ + autoOutstockFlag?: string; + + /** + * 辅料标识(1是 0否) + */ + accessoriesFlag?: string; + + /** + * 低值易耗品标识(1是 0否) + */ + lowValueConsumableFlag?: string; + + /** + * 品牌 + */ + brand?: string; + + /** + * 层级 + */ + plyrating?: string; + + /** + * 花纹 + */ + pattern?: string; + + /** + * 速度级别 + */ + speedLevel?: string; + + /** + * 负荷载重 + */ + load?: string; + + /** + * 轮胎标记(1全钢胎 2半钢胎 3工程胎) + */ + tireMarkings?: string; + + /** + * 最小停放时间(秒) + */ + minParkingTime?: number; + + /** + * 最大停放时间(秒) + */ + maxParkingTime?: number; + + /** + * 标准重量 + */ + standardWeight?: number; + + /** + * 标准重量上限 + */ + weightUpperLimit?: number; + + /** + * 标准重量下限 + */ + weightLowerLimit?: number; + + /** + * 内胎标记(0无 1有) + */ + innerTubeFlag?: string; + + /** + * 销售类型(0内销 1外销) + */ + saleType?: string; + + /** + * 日期范围参数 + */ + params?: any; + + /** + * 物料大类名称 + */ + materialCategoryName: string; +} + + + diff --git a/src/api/qms/baseProcessInfo/index.ts b/src/api/qms/baseProcessInfo/index.ts new file mode 100644 index 0000000..e5b19cb --- /dev/null +++ b/src/api/qms/baseProcessInfo/index.ts @@ -0,0 +1,88 @@ +import request from '@/utils/request'; +import { AxiosPromise } from 'axios'; +import { BaseProcessInfoVO, BaseProcessInfoForm, BaseProcessInfoQuery } from '@/api/qms/baseProcessInfo/types'; + +/** + * 查询工序信息列表 + * @param query + * @returns {*} + */ + +export const listBaseProcessInfo = (query?: BaseProcessInfoQuery): AxiosPromise => { + return request({ + url: '/qms/baseProcessInfo/list', + method: 'get', + params: query + }); +}; + +/** + * 查询工序信息详细 + * @param processId + */ +export const getBaseProcessInfo = (processId: string | number): AxiosPromise => { + return request({ + url: '/qms/baseProcessInfo/' + processId, + method: 'get' + }); +}; + +/** + * 新增工序信息 + * @param data + */ +export const addBaseProcessInfo = (data: BaseProcessInfoForm) => { + return request({ + url: '/qms/baseProcessInfo', + method: 'post', + data: data + }); +}; + +/** + * 修改工序信息 + * @param data + */ +export const updateBaseProcessInfo = (data: BaseProcessInfoForm) => { + return request({ + url: '/qms/baseProcessInfo/edit', + method: 'put', + data: data + }); +}; + +/** + * 修改工序信息关联用户 + * @param data + */ +export const updateBaseProcessInfoUser = (data: BaseProcessInfoForm) => { + return request({ + url: '/qms/baseProcessInfo/editUser', + method: 'put', + data: data + }); +}; + +/** + * 删除工序信息 + * @param processId + */ +export const delBaseProcessInfo = (processId: string | number | Array) => { + return request({ + url: '/qms/baseProcessInfo/' + processId, + method: 'delete' + }); +}; + +/** + * 查询工序信息下拉框列表 + * @param query + * @returns {*} + */ +export function getProcessInfoList(query) { + return request({ + url: '/qms/baseProcessInfo/getProcessInfoList', + method: 'get', + params: query + }); +}; diff --git a/src/api/qms/baseProcessInfo/types.ts b/src/api/qms/baseProcessInfo/types.ts new file mode 100644 index 0000000..f9c6635 --- /dev/null +++ b/src/api/qms/baseProcessInfo/types.ts @@ -0,0 +1,439 @@ +import { BaseProcessResourceVO } from "../baseProcessResource/types"; + +export interface BaseProcessInfoVO { + /** + * 主键标识 + */ + processId: string | number; + + /** + * 工序编号 + */ + processCode: string; + + /** + * 工序名称 + */ + processName: string; + + /** + * 工序类别(1生产工序 2质检工序) + */ + processType: string; + + /** + * 工序顺序(弃用) + */ + processQueue: number; + + /** + * 单位生产时间(秒);页面显示小时和分钟,就是标准工时,完成一个产品的制造所需的时间 + */ + productionTime: number; + + /** + * 车间ID + */ + workshopId: string | number; + + /** + * 委外标识(1自制 2委外) + */ + outsourcingFlag: string; + + /** + * 工序生产类型(1投料 2加工 3装配) + */ + processProductionType: string; + + /** + * 默认产出率(%),公式:合格数/投入数 + */ + defaultYieldRate: number; + + /** + * 损耗率(%),公式:废品/不可修复不良品占比 + */ + lossRate: number; + + /** + * 返修率(%),公式:返修品/投入数 + */ + reworkRate: number; + + /** + * 领料方式(1领料单 2申请领料 3生产叫料) + */ + materialMethod: string; + + /** + * 委外提前期(秒) + */ + leadTime: number; + + /** + * 准备时间(秒) + */ + setupTime: number; + + /** + * 加工时间(秒) + */ + processingTime: number; + + /** + * 拆卸时间(秒) + */ + disassemblyTime: number; + + /** + * 理论生产节拍(秒/件) + */ + theoreticalCycleTime: number; + + /** + * 质检方式(1免检 2自检 3质量检验) + */ + inspectionMethod: string; + + /** + * 激活标识(1是 0否) + */ + activeFlag: string; + + /** + * 备注 + */ + remark: string; + + /** + * 创建部门 + */ + createDept: number; + + /** + * 创建人 + */ + createBy: number; + + /** + * 创建时间 + */ + createTime: string; + + /** + * 更新人 + */ + updateBy: number; + + /** + * 更新时间 + */ + updateTime: string; + + prodBaseProcessProdlineVoList?: ProdBaseProcessProdLine[]; + prodBaseProcessUserVoList?: ProdBaseProcessUser[]; + prodBaseProcessProdlineBoList?: ProdBaseProcessProdLine[]; + prodBaseProcessUserBoList?: ProdBaseProcessUser[]; + +} + +export interface BaseProcessInfoForm extends BaseEntity { + /** + * 主键标识 + */ + processId?: string | number; + + /** + * 工序编号 + */ + processCode?: string; + + /** + * 工序名称 + */ + processName?: string; + + /** + * 工序类别(1生产工序 2质检工序) + */ + processType?: string; + + /** + * 工序顺序(弃用) + */ + processQueue?: number; + + /** + * 单位生产时间(秒);页面显示小时和分钟,就是标准工时,完成一个产品的制造所需的时间 + */ + productionTime?: number; + + /** + * 车间ID + */ + workshopId?: string | number; + + /** + * 委外标识(1自制 2委外) + */ + outsourcingFlag?: string; + + /** + * 工序生产类型(1投料 2加工 3装配) + */ + processProductionType?: string; + + /** + * 默认产出率(%),公式:合格数/投入数 + */ + defaultYieldRate?: number; + + /** + * 损耗率(%),公式:废品/不可修复不良品占比 + */ + lossRate?: number; + + /** + * 返修率(%),公式:返修品/投入数 + */ + reworkRate?: number; + + /** + * 领料方式(1领料单 2申请领料 3生产叫料) + */ + materialMethod?: string; + + /** + * 委外提前期(秒) + */ + leadTime?: number; + + /** + * 准备时间(秒) + */ + setupTime?: number; + + /** + * 加工时间(秒) + */ + processingTime?: number; + + /** + * 拆卸时间(秒) + */ + disassemblyTime?: number; + + /** + * 理论生产节拍(秒/件) + */ + theoreticalCycleTime?: number; + + /** + * 质检方式(1免检 2自检 3质量检验) + */ + inspectionMethod?: string; + + /** + * 激活标识(1是 0否) + */ + activeFlag?: string; + + /** + * 备注 + */ + remark?: string; + + productionTimeDays?: number; + productionTimeHours?: number; + productionTimeMinutes?: number; + + + prodBaseProcessProdlineVoList?: ProdBaseProcessProdLine[]; + prodBaseProcessUserVoList?: ProdBaseProcessUser[]; + prodBaseProcessProdlineBoList?: ProdBaseProcessProdLine[]; + prodBaseProcessUserBoList?: ProdBaseProcessUser[]; + prodBaseProcessResourceList?: BaseProcessResourceVO[]; +} + +export interface BaseProcessInfoQuery extends PageQuery { + + /** + * 主键标识 + */ + processId?: string | number; + + /** + * 工序编号 + */ + processCode?: string; + + /** + * 工序名称 + */ + processName?: string; + + /** + * 工序类别(1生产工序 2质检工序) + */ + processType?: string; + + /** + * 工序顺序(弃用) + */ + processQueue?: number; + + /** + * 单位生产时间(秒);页面显示小时和分钟,就是标准工时,完成一个产品的制造所需的时间 + */ + productionTime?: number; + + /** + * 车间ID + */ + workshopId?: string | number; + + /** + * 委外标识(1自制 2委外) + */ + outsourcingFlag?: string; + + /** + * 工序生产类型(1投料 2加工 3装配) + */ + processProductionType?: string; + + /** + * 默认产出率(%),公式:合格数/投入数 + */ + defaultYieldRate?: number; + + /** + * 损耗率(%),公式:废品/不可修复不良品占比 + */ + lossRate?: number; + + /** + * 返修率(%),公式:返修品/投入数 + */ + reworkRate?: number; + + /** + * 领料方式(1领料单 2申请领料 3生产叫料) + */ + materialMethod?: string; + + /** + * 委外提前期(秒) + */ + leadTime?: number; + + /** + * 准备时间(秒) + */ + setupTime?: number; + + /** + * 加工时间(秒) + */ + processingTime?: number; + + /** + * 拆卸时间(秒) + */ + disassemblyTime?: number; + + /** + * 理论生产节拍(秒/件) + */ + theoreticalCycleTime?: number; + + /** + * 质检方式(1免检 2自检 3质量检验) + */ + inspectionMethod?: string; + + /** + * 激活标识(1是 0否) + */ + activeFlag?: string; + + /** + * 日期范围参数 + */ + params?: any; + + prodBaseProcessProdlineV0List?: ProdBaseProcessProdLine[]; + prodBaseProcessUserV0List?: ProdBaseProcessUser[]; + prodBaseProcessProdlineBoList?: ProdBaseProcessProdLine[]; + prodBaseProcessUserBoList?: ProdBaseProcessUser[]; +} + +export interface ProdBaseProcessProdLine { + /** + * 工序ID + */ + processId: string | number; + + /** + * 所属产线ID + */ + prodLineId: string | number; + + /** + * 租户编号 + */ + tenantId: string | number; + + /** + * 创建人 + */ + createBy: string; + + /** + * 创建时间 + */ + createTime: string; + +} + + +export interface ProdBaseProcessUser { + /** + * 工序ID + */ + processId: string | number; + + /** + * 用户ID + */ + userId: string | number; + + /** + * 租户编号 + */ + tenantId: string | number; + + /** + * 用户名称 + */ + userName: string; + + /** + * 创建人 + */ + createBy: string; + + /** + * 创建时间 + */ + createTime: string; + +} + + + + + + + diff --git a/src/api/qms/baseStationInfo/index.ts b/src/api/qms/baseStationInfo/index.ts new file mode 100644 index 0000000..35d03ee --- /dev/null +++ b/src/api/qms/baseStationInfo/index.ts @@ -0,0 +1,76 @@ +import request from '@/utils/request'; +import { AxiosPromise } from 'axios'; +import { BaseStationInfoVO, BaseStationInfoForm, BaseStationInfoQuery } from '@/api/qms/baseStationInfo/types'; + +/** + * 查询工位信息列表 + * @param query + * @returns {*} + */ + +export const listBaseStationInfo = (query?: BaseStationInfoQuery): AxiosPromise => { + return request({ + url: '/qms/baseStationInfo/list', + method: 'get', + params: query + }); +}; + +/** + * 查询工位信息详细 + * @param stationId + */ +export const getBaseStationInfo = (stationId: string | number): AxiosPromise => { + return request({ + url: '/qms/baseStationInfo/' + stationId, + method: 'get' + }); +}; + +/** + * 新增工位信息 + * @param data + */ +export const addBaseStationInfo = (data: BaseStationInfoForm) => { + return request({ + url: '/qms/baseStationInfo', + method: 'post', + data: data + }); +}; + +/** + * 修改工位信息 + * @param data + */ +export const updateBaseStationInfo = (data: BaseStationInfoForm) => { + return request({ + url: '/qms/baseStationInfo', + method: 'put', + data: data + }); +}; + +/** + * 删除工位信息 + * @param stationId + */ +export const delBaseStationInfo = (stationId: string | number | Array) => { + return request({ + url: '/qms/baseStationInfo/' + stationId, + method: 'delete' + }); +}; + +/** + * 查询工位信息下拉框列表 + * @param query + * @returns {*} + */ +export function getStationInfoList(query) { + return request({ + url: '/qms/baseStationInfo/getStationInfoList', + method: 'get', + params: query + }); +}; diff --git a/src/api/qms/baseStationInfo/types.ts b/src/api/qms/baseStationInfo/types.ts new file mode 100644 index 0000000..50c24d6 --- /dev/null +++ b/src/api/qms/baseStationInfo/types.ts @@ -0,0 +1,201 @@ +export interface BaseStationInfoVO { + /** + * 主键标识 + */ + stationId: string | number; + + /** + * 租户编号 + */ + tenantId: string | number; + + /** + * 工位编号 + */ + stationCode: string; + + /** + * 工位名称 + */ + stationName: string; + + /** + * 工位类型(1生产工位 2质检工位) + */ + stationType: string; + + /** + * 所属工序 + */ + processId: string | number; + + /** + * 单位生产时间(秒) + */ + productionTime: number; + + /** + * AGV编号 + */ + agvCode: string; + + /** + * IP地址 + */ + ipAddress: string; + + /** + * 激活标识(1是 0否) + */ + activeFlag: string; + + /** + * 备注 + */ + remark: string; + + /** + * 创建部门 + */ + createDept: number; + + /** + * 创建人 + */ + createBy: number; + + /** + * 创建时间 + */ + createTime: string; + + /** + * 更新人 + */ + updateBy: number; + + /** + * 更新时间 + */ + updateTime: string; + +} + +export interface BaseStationInfoForm extends BaseEntity { + /** + * 主键标识 + */ + stationId?: string | number; + + /** + * 工位编号 + */ + stationCode?: string; + + /** + * 工位名称 + */ + stationName?: string; + + /** + * 工位类型(1生产工位 2质检工位) + */ + stationType?: string; + + /** + * 所属工序 + */ + processId?: string | number; + + /** + * 单位生产时间(秒) + */ + productionTime?: number; + + /** + * AGV编号 + */ + agvCode?: string; + + /** + * IP地址 + */ + ipAddress?: string; + + /** + * 激活标识(1是 0否) + */ + activeFlag?: string; + + /** + * 备注 + */ + remark?: string; + + /** + * 机台Id + */ + machineId?: string | number; + + productionTimeDays?: number; + productionTimeHours?: number; + productionTimeMinutes?: number; + + prodBaseStationMaterialtypeList?: []; +} + +export interface BaseStationInfoQuery extends PageQuery { + + /** + * 主键标识 + */ + stationId?: string | number; + + /** + * 工位编号 + */ + stationCode?: string; + + /** + * 工位名称 + */ + stationName?: string; + + /** + * 工位类型(1生产工位 2质检工位) + */ + stationType?: string; + + /** + * 所属工序 + */ + processId?: string | number; + + /** + * 单位生产时间(秒) + */ + productionTime?: number; + + /** + * AGV编号 + */ + agvCode?: string; + + /** + * IP地址 + */ + ipAddress?: string; + + /** + * 激活标识(1是 0否) + */ + activeFlag?: string; + + /** + * 日期范围参数 + */ + params?: any; +} + + + diff --git a/src/api/qms/baseSupplierInfo/index.ts b/src/api/qms/baseSupplierInfo/index.ts new file mode 100644 index 0000000..f6b0b45 --- /dev/null +++ b/src/api/qms/baseSupplierInfo/index.ts @@ -0,0 +1,77 @@ +import request from '@/utils/request'; +import { AxiosPromise } from 'axios'; +import { BaseSupplierInfoVO, BaseSupplierInfoForm, BaseSupplierInfoQuery } from '@/api/qms/baseSupplierInfo/types'; + +/** + * 查询供应商信息列表 + * @param query + * @returns {*} + */ + +export const listBaseSupplierInfo = (query?: BaseSupplierInfoQuery): AxiosPromise => { + return request({ + url: '/qms/baseSupplierInfo/list', + method: 'get', + params: query + }); +}; + +/** + * 查询供应商信息详细 + * @param supplierId + */ +export const getBaseSupplierInfo = (supplierId: string | number): AxiosPromise => { + return request({ + url: '/qms/baseSupplierInfo/' + supplierId, + method: 'get' + }); +}; + +/** + * 新增供应商信息 + * @param data + */ +export const addBaseSupplierInfo = (data: BaseSupplierInfoForm) => { + return request({ + url: '/qms/baseSupplierInfo', + method: 'post', + data: data + }); +}; + +/** + * 修改供应商信息 + * @param data + */ +export const updateBaseSupplierInfo = (data: BaseSupplierInfoForm) => { + return request({ + url: '/qms/baseSupplierInfo', + method: 'put', + data: data + }); +}; + +/** + * 删除供应商信息 + * @param supplierId + */ +export const delBaseSupplierInfo = (supplierId: string | number | Array) => { + return request({ + url: '/qms/baseSupplierInfo/' + supplierId, + method: 'delete' + }); +}; + + +/** + * 下拉框查询供应商信息列表 + * @param query + * @returns {*} + */ +export function getBaseSupplierInfoList (query) { + return request({ + url: '/qms/baseSupplierInfo/getBaseSupplierInfoList', + method: 'get', + params: query + }); +}; diff --git a/src/api/qms/baseSupplierInfo/types.ts b/src/api/qms/baseSupplierInfo/types.ts new file mode 100644 index 0000000..c76c7f6 --- /dev/null +++ b/src/api/qms/baseSupplierInfo/types.ts @@ -0,0 +1,161 @@ +export interface BaseSupplierInfoVO { + /** + * 主键标识 + */ + supplierId: string | number; + + /** + * 租户编号 + */ + tenantId: string | number; + + /** + * 供应商编号 + */ + supplierCode: string; + + /** + * 供应商名称 + */ + supplierName: string; + + /** + * erp的主键 + */ + erpId: string | number; + + /** + * 激活状态(1启用 0停用) + */ + supplierStatus: string; + + /** + * 审核日期 + */ + auditDate: string; + + /** + * erp最后更新时间 + */ + erpModifyDate: string; + + /** + * 备注 + */ + remark: string; + + /** + * 创建部门 + */ + createDept: number; + + /** + * 创建人 + */ + createBy: number; + + /** + * 创建时间 + */ + createTime: string; + + /** + * 更新人 + */ + updateBy: number; + + /** + * 更新时间 + */ + updateTime: string; + +} + +export interface BaseSupplierInfoForm extends BaseEntity { + /** + * 主键标识 + */ + supplierId?: string | number; + + /** + * 供应商编号 + */ + supplierCode?: string; + + /** + * 供应商名称 + */ + supplierName?: string; + + /** + * erp的主键 + */ + erpId?: string | number; + + /** + * 激活状态(1启用 0停用) + */ + supplierStatus?: string; + + /** + * 审核日期 + */ + auditDate?: string; + + /** + * erp最后更新时间 + */ + erpModifyDate?: string; + + /** + * 备注 + */ + remark?: string; + +} + +export interface BaseSupplierInfoQuery extends PageQuery { + + /** + * 主键标识 + */ + supplierId?: string | number; + + /** + * 供应商编号 + */ + supplierCode?: string; + + /** + * 供应商名称 + */ + supplierName?: string; + + /** + * erp的主键 + */ + erpId?: string | number; + + /** + * 激活状态(1启用 0停用) + */ + supplierStatus?: string; + + /** + * 审核日期 + */ + auditDate?: string; + + /** + * erp最后更新时间 + */ + erpModifyDate?: string; + + /** + * 日期范围参数 + */ + params?: any; +} + + + diff --git a/src/api/qms/qcInspectionItem/types.ts b/src/api/qms/qcInspectionItem/types.ts index b5bed4c..2c37b4c 100644 --- a/src/api/qms/qcInspectionItem/types.ts +++ b/src/api/qms/qcInspectionItem/types.ts @@ -94,8 +94,17 @@ export interface QcInspectionItemVO { */ isDefault: string; -} + /** + * 检测类型名称 + */ + typeName: string; + /** + * 检测类型编码 + */ + typeCode: string | number; + +} export interface QcInspectionItemForm extends BaseEntity { /** * 检测项主键 @@ -192,6 +201,16 @@ export interface QcInspectionItemForm extends BaseEntity { */ isDefault?: string; + /** + * 检测类型名称 + */ + typeName?: string; + + /** + * 检测类型编码 + */ + typeCode?: string | number; + } export interface QcInspectionItemQuery extends PageQuery { @@ -291,6 +310,17 @@ export interface QcInspectionItemQuery extends PageQuery { */ isDefault?: string; + /** + * 检测类型名称 + */ + typeName?: string; + + /** + * 检测类型编码 + */ + typeCode?: string | number; + + /** * 日期范围参数 */ diff --git a/src/views/qms/QcInspectionMain/index.vue b/src/views/qms/QcInspectionMain/index.vue index e14a673..d7848b4 100644 --- a/src/views/qms/QcInspectionMain/index.vue +++ b/src/views/qms/QcInspectionMain/index.vue @@ -383,6 +383,7 @@ import { listQcInspectionResult, getQcInspectionResult, delQcInspectionResult, a import { QcInspectionResultVO, QcInspectionResultQuery, QcInspectionResultForm } from '@/api/qms/qcInspectionResult/types'; import { listQcInspectionItem, getQcInspectionItem, delQcInspectionItem, addQcInspectionItem, updateQcInspectionItem, getQcInspectionItemList } from '@/api/qms/qcInspectionItem'; import { getQcInspectionTypeList } from '@/api/qms/qcInspectionType'; +import {getBaseMaterialInfoList} from "@/api/qms/baseMaterialInfo"; const { proxy } = getCurrentInstance() as ComponentInternalInstance; const { qc_result, qc_status } = toRefs(proxy?.useDict('qc_result', 'qc_status')); @@ -655,6 +656,7 @@ const handleRowClick = (row: QcInspectionMainVO) => { /** 新增按钮操作 */ const handleAdd = () => { reset(); + getMaterialList(); dialog.visible = true; dialog.title = "添加质检结果主表"; } @@ -662,6 +664,7 @@ const handleAdd = () => { /** 修改按钮操作 */ const handleUpdate = async (row?: QcInspectionMainVO) => { reset(); + getMaterialList(); const _inspectionId = row?.inspectionId || ids.value[0] const res = await getQcInspectionMain(_inspectionId); Object.assign(form.value, res.data); @@ -749,7 +752,7 @@ const handleExport = () => { /** 导出模板按钮操作 */ const handleExportTemplate = () => { proxy?.download('qms/QcInspectionMain/exportTemplate', { - + }, `QcInspectionMain_${new Date().getTime()}.xlsx`) } @@ -804,6 +807,12 @@ const onFileChange = async (event: Event) => { } } +let materialList = ref([]); +const getMaterialList = async () => { + const res = await getBaseMaterialInfoList(null); + materialList.value = res.data; +} + onMounted(() => { getInspectionItemList(); getInspectionTypeList(); diff --git a/src/views/qms/qcInspectionItem/index.vue b/src/views/qms/qcInspectionItem/index.vue index d0a5125..cfe35d9 100644 --- a/src/views/qms/qcInspectionItem/index.vue +++ b/src/views/qms/qcInspectionItem/index.vue @@ -19,8 +19,8 @@ - - + + --> @@ -110,8 +110,8 @@ - - + +