🎨 修改页面逻辑
This commit is contained in:
parent
b2efb54608
commit
deb566c209
@ -3437,8 +3437,8 @@
|
|||||||
]
|
]
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"description": "增加/编辑申请单",
|
"description": "提交申请单",
|
||||||
"name": "saveOrUpdateApply",
|
"name": "saveApply",
|
||||||
"method": "put",
|
"method": "put",
|
||||||
"path": "/apply",
|
"path": "/apply",
|
||||||
"response": {
|
"response": {
|
||||||
@ -3704,120 +3704,6 @@
|
|||||||
]
|
]
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
},
|
|
||||||
{
|
|
||||||
"description": "盘点管理",
|
|
||||||
"name": "stocktaking",
|
|
||||||
"interfaces": [
|
|
||||||
{
|
|
||||||
"description": "增加/编辑盘点",
|
|
||||||
"name": "saveOrUpdateStocktaking",
|
|
||||||
"method": "put",
|
|
||||||
"path": "/stocktaking",
|
|
||||||
"response": {
|
|
||||||
"typeArgs": [],
|
|
||||||
"typeName": "Stocktaking",
|
|
||||||
"isDefsType": true,
|
|
||||||
"templateIndex": -1,
|
|
||||||
"compileTemplateKeyword": "#/definitions/",
|
|
||||||
"enum": [],
|
|
||||||
"typeProperties": []
|
|
||||||
},
|
|
||||||
"parameters": [
|
|
||||||
{
|
|
||||||
"required": true,
|
|
||||||
"in": "body",
|
|
||||||
"name": "requestBody",
|
|
||||||
"dataType": {
|
|
||||||
"typeArgs": [],
|
|
||||||
"typeName": "Stocktaking",
|
|
||||||
"isDefsType": true,
|
|
||||||
"templateIndex": -1,
|
|
||||||
"compileTemplateKeyword": "#/definitions/",
|
|
||||||
"enum": [],
|
|
||||||
"typeProperties": []
|
|
||||||
}
|
|
||||||
}
|
|
||||||
]
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"description": "分页查询盘点列表",
|
|
||||||
"name": "stocktakingList",
|
|
||||||
"method": "get",
|
|
||||||
"path": "/stocktaking-list",
|
|
||||||
"response": {
|
|
||||||
"typeArgs": [],
|
|
||||||
"typeName": "IPageStocktaking",
|
|
||||||
"isDefsType": true,
|
|
||||||
"templateIndex": -1,
|
|
||||||
"compileTemplateKeyword": "#/definitions/",
|
|
||||||
"enum": [],
|
|
||||||
"typeProperties": []
|
|
||||||
},
|
|
||||||
"parameters": [
|
|
||||||
{
|
|
||||||
"description": "页码",
|
|
||||||
"required": false,
|
|
||||||
"in": "query",
|
|
||||||
"name": "page",
|
|
||||||
"dataType": {
|
|
||||||
"typeArgs": [],
|
|
||||||
"typeName": "number",
|
|
||||||
"isDefsType": false,
|
|
||||||
"templateIndex": -1,
|
|
||||||
"compileTemplateKeyword": "#/definitions/",
|
|
||||||
"enum": [],
|
|
||||||
"typeProperties": []
|
|
||||||
}
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"description": "页面大小",
|
|
||||||
"required": false,
|
|
||||||
"in": "query",
|
|
||||||
"name": "size",
|
|
||||||
"dataType": {
|
|
||||||
"typeArgs": [],
|
|
||||||
"typeName": "number",
|
|
||||||
"isDefsType": false,
|
|
||||||
"templateIndex": -1,
|
|
||||||
"compileTemplateKeyword": "#/definitions/",
|
|
||||||
"enum": [],
|
|
||||||
"typeProperties": []
|
|
||||||
}
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"description": "类型",
|
|
||||||
"required": false,
|
|
||||||
"in": "query",
|
|
||||||
"name": "type",
|
|
||||||
"dataType": {
|
|
||||||
"typeArgs": [],
|
|
||||||
"typeName": "number",
|
|
||||||
"isDefsType": false,
|
|
||||||
"templateIndex": -1,
|
|
||||||
"compileTemplateKeyword": "#/definitions/",
|
|
||||||
"enum": [],
|
|
||||||
"typeProperties": []
|
|
||||||
}
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"description": "搜索关键词",
|
|
||||||
"required": false,
|
|
||||||
"in": "query",
|
|
||||||
"name": "key",
|
|
||||||
"dataType": {
|
|
||||||
"typeArgs": [],
|
|
||||||
"typeName": "string",
|
|
||||||
"isDefsType": false,
|
|
||||||
"templateIndex": -1,
|
|
||||||
"compileTemplateKeyword": "#/definitions/",
|
|
||||||
"enum": [],
|
|
||||||
"typeProperties": []
|
|
||||||
}
|
|
||||||
}
|
|
||||||
]
|
|
||||||
}
|
|
||||||
]
|
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
"name": "material",
|
"name": "material",
|
||||||
@ -3939,7 +3825,7 @@
|
|||||||
]
|
]
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"description": "入库/出库 申请单",
|
"description": "入库/出库/盘点 申请单",
|
||||||
"name": "ApplyForm",
|
"name": "ApplyForm",
|
||||||
"templateArgs": [],
|
"templateArgs": [],
|
||||||
"properties": [
|
"properties": [
|
||||||
@ -3971,6 +3857,36 @@
|
|||||||
"description": "申请日期",
|
"description": "申请日期",
|
||||||
"required": false
|
"required": false
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
"dataType": {
|
||||||
|
"typeArgs": [],
|
||||||
|
"typeName": "",
|
||||||
|
"isDefsType": false,
|
||||||
|
"templateIndex": -1,
|
||||||
|
"compileTemplateKeyword": "#/definitions/",
|
||||||
|
"enum": [
|
||||||
|
"'ALL'",
|
||||||
|
"'PARTIAL'"
|
||||||
|
],
|
||||||
|
"typeProperties": []
|
||||||
|
},
|
||||||
|
"name": "auditType",
|
||||||
|
"description": "盘点类型(1: 全盘 2: 部分盘点)",
|
||||||
|
"required": false
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"dataType": {
|
||||||
|
"typeArgs": [],
|
||||||
|
"typeName": "Codebook",
|
||||||
|
"isDefsType": true,
|
||||||
|
"templateIndex": -1,
|
||||||
|
"compileTemplateKeyword": "#/definitions/",
|
||||||
|
"enum": [],
|
||||||
|
"typeProperties": []
|
||||||
|
},
|
||||||
|
"name": "auditTypeInfo",
|
||||||
|
"required": false
|
||||||
|
},
|
||||||
{
|
{
|
||||||
"dataType": {
|
"dataType": {
|
||||||
"typeArgs": [],
|
"typeArgs": [],
|
||||||
@ -3994,8 +3910,40 @@
|
|||||||
"enum": [],
|
"enum": [],
|
||||||
"typeProperties": []
|
"typeProperties": []
|
||||||
},
|
},
|
||||||
"name": "exceptionExplain",
|
"name": "exception",
|
||||||
"description": "异常说明",
|
"description": "异常原因",
|
||||||
|
"required": false
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"dataType": {
|
||||||
|
"typeArgs": [],
|
||||||
|
"typeName": "",
|
||||||
|
"isDefsType": false,
|
||||||
|
"templateIndex": -1,
|
||||||
|
"compileTemplateKeyword": "#/definitions/",
|
||||||
|
"enum": [
|
||||||
|
"'NO_ACTION'",
|
||||||
|
"'IGNORE_AND_SAVE'",
|
||||||
|
"'REPLENISH'",
|
||||||
|
"'OTHER'"
|
||||||
|
],
|
||||||
|
"typeProperties": []
|
||||||
|
},
|
||||||
|
"name": "handle",
|
||||||
|
"description": "处理方式(0-无需处理 1-忽略并修改库存 2-补充库存 3-其他)",
|
||||||
|
"required": false
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"dataType": {
|
||||||
|
"typeArgs": [],
|
||||||
|
"typeName": "Codebook",
|
||||||
|
"isDefsType": true,
|
||||||
|
"templateIndex": -1,
|
||||||
|
"compileTemplateKeyword": "#/definitions/",
|
||||||
|
"enum": [],
|
||||||
|
"typeProperties": []
|
||||||
|
},
|
||||||
|
"name": "handleInfo",
|
||||||
"required": false
|
"required": false
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
@ -4022,21 +3970,53 @@
|
|||||||
"typeProperties": []
|
"typeProperties": []
|
||||||
},
|
},
|
||||||
"name": "isConfirm",
|
"name": "isConfirm",
|
||||||
"description": "是否确认",
|
"description": "是否确认(0: 未确认 1: 已确认)",
|
||||||
"required": false
|
"required": false
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"dataType": {
|
"dataType": {
|
||||||
"typeArgs": [],
|
"typeArgs": [],
|
||||||
"typeName": "number",
|
"typeName": "string",
|
||||||
"isDefsType": false,
|
"isDefsType": false,
|
||||||
"templateIndex": -1,
|
"templateIndex": -1,
|
||||||
"compileTemplateKeyword": "#/definitions/",
|
"compileTemplateKeyword": "#/definitions/",
|
||||||
"enum": [],
|
"enum": [],
|
||||||
"typeProperties": []
|
"typeProperties": []
|
||||||
},
|
},
|
||||||
|
"name": "result",
|
||||||
|
"description": "结果(系统自动生成)",
|
||||||
|
"required": false
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"dataType": {
|
||||||
|
"typeArgs": [],
|
||||||
|
"typeName": "",
|
||||||
|
"isDefsType": false,
|
||||||
|
"templateIndex": -1,
|
||||||
|
"compileTemplateKeyword": "#/definitions/",
|
||||||
|
"enum": [
|
||||||
|
"'PURCHASE_RECEIPT'",
|
||||||
|
"'RETURN_RECEIPT'",
|
||||||
|
"'LOAN_OUT'",
|
||||||
|
"'AUDIT'"
|
||||||
|
],
|
||||||
|
"typeProperties": []
|
||||||
|
},
|
||||||
"name": "type",
|
"name": "type",
|
||||||
"description": "类型",
|
"description": "类型(1: 采购入库申请 2: 归还入库申请 3: 出库外借申请 4: 盘点申请)",
|
||||||
|
"required": false
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"dataType": {
|
||||||
|
"typeArgs": [],
|
||||||
|
"typeName": "Codebook",
|
||||||
|
"isDefsType": true,
|
||||||
|
"templateIndex": -1,
|
||||||
|
"compileTemplateKeyword": "#/definitions/",
|
||||||
|
"enum": [],
|
||||||
|
"typeProperties": []
|
||||||
|
},
|
||||||
|
"name": "typeInfo",
|
||||||
"required": false
|
"required": false
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
@ -4080,6 +4060,7 @@
|
|||||||
"typeProperties": []
|
"typeProperties": []
|
||||||
},
|
},
|
||||||
"name": "applyDetails",
|
"name": "applyDetails",
|
||||||
|
"description": "申请单明细",
|
||||||
"required": false
|
"required": false
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
@ -4094,6 +4075,79 @@
|
|||||||
},
|
},
|
||||||
"name": "applyForm",
|
"name": "applyForm",
|
||||||
"required": false
|
"required": false
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"dataType": {
|
||||||
|
"typeArgs": [
|
||||||
|
{
|
||||||
|
"typeArgs": [],
|
||||||
|
"typeName": "MaterialStockDetail",
|
||||||
|
"isDefsType": true,
|
||||||
|
"templateIndex": -1,
|
||||||
|
"compileTemplateKeyword": "#/definitions/",
|
||||||
|
"enum": [],
|
||||||
|
"typeProperties": []
|
||||||
|
}
|
||||||
|
],
|
||||||
|
"typeName": "Array",
|
||||||
|
"isDefsType": false,
|
||||||
|
"templateIndex": -1,
|
||||||
|
"compileTemplateKeyword": "#/definitions/",
|
||||||
|
"enum": [],
|
||||||
|
"typeProperties": []
|
||||||
|
},
|
||||||
|
"name": "detailList",
|
||||||
|
"description": "扫码的条码集合",
|
||||||
|
"required": false
|
||||||
|
}
|
||||||
|
]
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"description": "枚举码本",
|
||||||
|
"name": "Codebook",
|
||||||
|
"templateArgs": [],
|
||||||
|
"properties": [
|
||||||
|
{
|
||||||
|
"dataType": {
|
||||||
|
"typeArgs": [],
|
||||||
|
"typeName": "string",
|
||||||
|
"isDefsType": false,
|
||||||
|
"templateIndex": -1,
|
||||||
|
"compileTemplateKeyword": "#/definitions/",
|
||||||
|
"enum": [],
|
||||||
|
"typeProperties": []
|
||||||
|
},
|
||||||
|
"name": "code",
|
||||||
|
"description": "码本编码",
|
||||||
|
"required": true
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"dataType": {
|
||||||
|
"typeArgs": [],
|
||||||
|
"typeName": "string",
|
||||||
|
"isDefsType": false,
|
||||||
|
"templateIndex": -1,
|
||||||
|
"compileTemplateKeyword": "#/definitions/",
|
||||||
|
"enum": [],
|
||||||
|
"typeProperties": []
|
||||||
|
},
|
||||||
|
"name": "description",
|
||||||
|
"description": "码本名称",
|
||||||
|
"required": true
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"dataType": {
|
||||||
|
"typeArgs": [],
|
||||||
|
"typeName": "string",
|
||||||
|
"isDefsType": false,
|
||||||
|
"templateIndex": -1,
|
||||||
|
"compileTemplateKeyword": "#/definitions/",
|
||||||
|
"enum": [],
|
||||||
|
"typeProperties": []
|
||||||
|
},
|
||||||
|
"name": "name",
|
||||||
|
"description": "码本值",
|
||||||
|
"required": true
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
@ -4294,87 +4348,6 @@
|
|||||||
}
|
}
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
{
|
|
||||||
"name": "IPageStocktaking",
|
|
||||||
"templateArgs": [],
|
|
||||||
"properties": [
|
|
||||||
{
|
|
||||||
"dataType": {
|
|
||||||
"typeArgs": [],
|
|
||||||
"typeName": "number",
|
|
||||||
"isDefsType": false,
|
|
||||||
"templateIndex": -1,
|
|
||||||
"compileTemplateKeyword": "#/definitions/",
|
|
||||||
"enum": [],
|
|
||||||
"typeProperties": []
|
|
||||||
},
|
|
||||||
"name": "current",
|
|
||||||
"required": false
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"dataType": {
|
|
||||||
"typeArgs": [],
|
|
||||||
"typeName": "number",
|
|
||||||
"isDefsType": false,
|
|
||||||
"templateIndex": -1,
|
|
||||||
"compileTemplateKeyword": "#/definitions/",
|
|
||||||
"enum": [],
|
|
||||||
"typeProperties": []
|
|
||||||
},
|
|
||||||
"name": "pages",
|
|
||||||
"required": false
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"dataType": {
|
|
||||||
"typeArgs": [
|
|
||||||
{
|
|
||||||
"typeArgs": [],
|
|
||||||
"typeName": "Stocktaking",
|
|
||||||
"isDefsType": true,
|
|
||||||
"templateIndex": -1,
|
|
||||||
"compileTemplateKeyword": "#/definitions/",
|
|
||||||
"enum": [],
|
|
||||||
"typeProperties": []
|
|
||||||
}
|
|
||||||
],
|
|
||||||
"typeName": "Array",
|
|
||||||
"isDefsType": false,
|
|
||||||
"templateIndex": -1,
|
|
||||||
"compileTemplateKeyword": "#/definitions/",
|
|
||||||
"enum": [],
|
|
||||||
"typeProperties": []
|
|
||||||
},
|
|
||||||
"name": "records",
|
|
||||||
"required": false
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"dataType": {
|
|
||||||
"typeArgs": [],
|
|
||||||
"typeName": "number",
|
|
||||||
"isDefsType": false,
|
|
||||||
"templateIndex": -1,
|
|
||||||
"compileTemplateKeyword": "#/definitions/",
|
|
||||||
"enum": [],
|
|
||||||
"typeProperties": []
|
|
||||||
},
|
|
||||||
"name": "size",
|
|
||||||
"required": false
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"dataType": {
|
|
||||||
"typeArgs": [],
|
|
||||||
"typeName": "number",
|
|
||||||
"isDefsType": false,
|
|
||||||
"templateIndex": -1,
|
|
||||||
"compileTemplateKeyword": "#/definitions/",
|
|
||||||
"enum": [],
|
|
||||||
"typeProperties": []
|
|
||||||
},
|
|
||||||
"name": "total",
|
|
||||||
"required": false
|
|
||||||
}
|
|
||||||
]
|
|
||||||
},
|
|
||||||
{
|
{
|
||||||
"description": "物料信息",
|
"description": "物料信息",
|
||||||
"name": "Material",
|
"name": "Material",
|
||||||
@ -4383,15 +4356,31 @@
|
|||||||
{
|
{
|
||||||
"dataType": {
|
"dataType": {
|
||||||
"typeArgs": [],
|
"typeArgs": [],
|
||||||
"typeName": "number",
|
"typeName": "",
|
||||||
"isDefsType": false,
|
"isDefsType": false,
|
||||||
"templateIndex": -1,
|
"templateIndex": -1,
|
||||||
"compileTemplateKeyword": "#/definitions/",
|
"compileTemplateKeyword": "#/definitions/",
|
||||||
|
"enum": [
|
||||||
|
"'LOW_VALUE'",
|
||||||
|
"'HIGH_VALUE'"
|
||||||
|
],
|
||||||
|
"typeProperties": []
|
||||||
|
},
|
||||||
|
"name": "assignRule",
|
||||||
|
"description": "赋码规则(0-低值易耗品(不参与赋码) 1-高价值工具类(参与唯一赋码)",
|
||||||
|
"required": false
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"dataType": {
|
||||||
|
"typeArgs": [],
|
||||||
|
"typeName": "Codebook",
|
||||||
|
"isDefsType": true,
|
||||||
|
"templateIndex": -1,
|
||||||
|
"compileTemplateKeyword": "#/definitions/",
|
||||||
"enum": [],
|
"enum": [],
|
||||||
"typeProperties": []
|
"typeProperties": []
|
||||||
},
|
},
|
||||||
"name": "assignRule",
|
"name": "assignRuleInfo",
|
||||||
"description": "赋码规则",
|
|
||||||
"required": false
|
"required": false
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
@ -4520,10 +4509,38 @@
|
|||||||
]
|
]
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"description": "盘点信息",
|
"description": "物料明细数据表",
|
||||||
"name": "Stocktaking",
|
"name": "MaterialStockDetail",
|
||||||
"templateArgs": [],
|
"templateArgs": [],
|
||||||
"properties": [
|
"properties": [
|
||||||
|
{
|
||||||
|
"dataType": {
|
||||||
|
"typeArgs": [],
|
||||||
|
"typeName": "number",
|
||||||
|
"isDefsType": false,
|
||||||
|
"templateIndex": -1,
|
||||||
|
"compileTemplateKeyword": "#/definitions/",
|
||||||
|
"enum": [],
|
||||||
|
"typeProperties": []
|
||||||
|
},
|
||||||
|
"name": "applyId",
|
||||||
|
"description": "入库申请单",
|
||||||
|
"required": false
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"dataType": {
|
||||||
|
"typeArgs": [],
|
||||||
|
"typeName": "string",
|
||||||
|
"isDefsType": false,
|
||||||
|
"templateIndex": -1,
|
||||||
|
"compileTemplateKeyword": "#/definitions/",
|
||||||
|
"enum": [],
|
||||||
|
"typeProperties": []
|
||||||
|
},
|
||||||
|
"name": "barcode",
|
||||||
|
"description": "条码",
|
||||||
|
"required": false
|
||||||
|
},
|
||||||
{
|
{
|
||||||
"dataType": {
|
"dataType": {
|
||||||
"typeArgs": [],
|
"typeArgs": [],
|
||||||
@ -4537,48 +4554,6 @@
|
|||||||
"name": "createdTime",
|
"name": "createdTime",
|
||||||
"required": false
|
"required": false
|
||||||
},
|
},
|
||||||
{
|
|
||||||
"dataType": {
|
|
||||||
"typeArgs": [],
|
|
||||||
"typeName": "string",
|
|
||||||
"isDefsType": false,
|
|
||||||
"templateIndex": -1,
|
|
||||||
"compileTemplateKeyword": "#/definitions/",
|
|
||||||
"enum": [],
|
|
||||||
"typeProperties": []
|
|
||||||
},
|
|
||||||
"name": "date",
|
|
||||||
"description": "盘点日期",
|
|
||||||
"required": false
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"dataType": {
|
|
||||||
"typeArgs": [],
|
|
||||||
"typeName": "string",
|
|
||||||
"isDefsType": false,
|
|
||||||
"templateIndex": -1,
|
|
||||||
"compileTemplateKeyword": "#/definitions/",
|
|
||||||
"enum": [],
|
|
||||||
"typeProperties": []
|
|
||||||
},
|
|
||||||
"name": "exception",
|
|
||||||
"description": "异常原因",
|
|
||||||
"required": false
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"dataType": {
|
|
||||||
"typeArgs": [],
|
|
||||||
"typeName": "string",
|
|
||||||
"isDefsType": false,
|
|
||||||
"templateIndex": -1,
|
|
||||||
"compileTemplateKeyword": "#/definitions/",
|
|
||||||
"enum": [],
|
|
||||||
"typeProperties": []
|
|
||||||
},
|
|
||||||
"name": "exceptionHandle",
|
|
||||||
"description": "异常情况处理方式",
|
|
||||||
"required": false
|
|
||||||
},
|
|
||||||
{
|
{
|
||||||
"dataType": {
|
"dataType": {
|
||||||
"typeArgs": [],
|
"typeArgs": [],
|
||||||
@ -4592,62 +4567,6 @@
|
|||||||
"name": "id",
|
"name": "id",
|
||||||
"required": false
|
"required": false
|
||||||
},
|
},
|
||||||
{
|
|
||||||
"dataType": {
|
|
||||||
"typeArgs": [],
|
|
||||||
"typeName": "string",
|
|
||||||
"isDefsType": false,
|
|
||||||
"templateIndex": -1,
|
|
||||||
"compileTemplateKeyword": "#/definitions/",
|
|
||||||
"enum": [],
|
|
||||||
"typeProperties": []
|
|
||||||
},
|
|
||||||
"name": "operator",
|
|
||||||
"description": "盘点人",
|
|
||||||
"required": false
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"dataType": {
|
|
||||||
"typeArgs": [],
|
|
||||||
"typeName": "string",
|
|
||||||
"isDefsType": false,
|
|
||||||
"templateIndex": -1,
|
|
||||||
"compileTemplateKeyword": "#/definitions/",
|
|
||||||
"enum": [],
|
|
||||||
"typeProperties": []
|
|
||||||
},
|
|
||||||
"name": "result",
|
|
||||||
"description": "盘点结果(系统自动生成)",
|
|
||||||
"required": false
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"dataType": {
|
|
||||||
"typeArgs": [],
|
|
||||||
"typeName": "string",
|
|
||||||
"isDefsType": false,
|
|
||||||
"templateIndex": -1,
|
|
||||||
"compileTemplateKeyword": "#/definitions/",
|
|
||||||
"enum": [],
|
|
||||||
"typeProperties": []
|
|
||||||
},
|
|
||||||
"name": "reviewResult",
|
|
||||||
"description": "盘点审核结果",
|
|
||||||
"required": false
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"dataType": {
|
|
||||||
"typeArgs": [],
|
|
||||||
"typeName": "string",
|
|
||||||
"isDefsType": false,
|
|
||||||
"templateIndex": -1,
|
|
||||||
"compileTemplateKeyword": "#/definitions/",
|
|
||||||
"enum": [],
|
|
||||||
"typeProperties": []
|
|
||||||
},
|
|
||||||
"name": "reviewer",
|
|
||||||
"description": "盘点审核人",
|
|
||||||
"required": false
|
|
||||||
},
|
|
||||||
{
|
{
|
||||||
"dataType": {
|
"dataType": {
|
||||||
"typeArgs": [],
|
"typeArgs": [],
|
||||||
@ -4658,22 +4577,39 @@
|
|||||||
"enum": [],
|
"enum": [],
|
||||||
"typeProperties": []
|
"typeProperties": []
|
||||||
},
|
},
|
||||||
|
"name": "materialId",
|
||||||
|
"description": "物料ID",
|
||||||
|
"required": false
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"dataType": {
|
||||||
|
"typeArgs": [],
|
||||||
|
"typeName": "",
|
||||||
|
"isDefsType": false,
|
||||||
|
"templateIndex": -1,
|
||||||
|
"compileTemplateKeyword": "#/definitions/",
|
||||||
|
"enum": [
|
||||||
|
"'IN'",
|
||||||
|
"'OUT'",
|
||||||
|
"'OFF'"
|
||||||
|
],
|
||||||
|
"typeProperties": []
|
||||||
|
},
|
||||||
"name": "status",
|
"name": "status",
|
||||||
"description": "盘点任务状态",
|
"description": "状态",
|
||||||
"required": false
|
"required": false
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"dataType": {
|
"dataType": {
|
||||||
"typeArgs": [],
|
"typeArgs": [],
|
||||||
"typeName": "number",
|
"typeName": "Codebook",
|
||||||
"isDefsType": false,
|
"isDefsType": true,
|
||||||
"templateIndex": -1,
|
"templateIndex": -1,
|
||||||
"compileTemplateKeyword": "#/definitions/",
|
"compileTemplateKeyword": "#/definitions/",
|
||||||
"enum": [],
|
"enum": [],
|
||||||
"typeProperties": []
|
"typeProperties": []
|
||||||
},
|
},
|
||||||
"name": "type",
|
"name": "statusInfo",
|
||||||
"description": "盘点类型",
|
|
||||||
"required": false
|
"required": false
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
|
82
src/api/material/api.d.ts
vendored
82
src/api/material/api.d.ts
vendored
@ -29,7 +29,7 @@ declare namespace material {
|
|||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 入库/出库 申请单
|
* 入库/出库/盘点 申请单
|
||||||
*/
|
*/
|
||||||
export interface ApplyForm {
|
export interface ApplyForm {
|
||||||
/** 申请人 */
|
/** 申请人 */
|
||||||
@ -38,20 +38,38 @@ declare namespace material {
|
|||||||
/** 申请日期 */
|
/** 申请日期 */
|
||||||
applyDate?: string;
|
applyDate?: string;
|
||||||
|
|
||||||
|
/** 盘点类型(1: 全盘 2: 部分盘点) */
|
||||||
|
auditType?: 'ALL' | 'PARTIAL';
|
||||||
|
|
||||||
|
/** auditTypeInfo */
|
||||||
|
auditTypeInfo?: material.Codebook;
|
||||||
|
|
||||||
/** createdTime */
|
/** createdTime */
|
||||||
createdTime?: string;
|
createdTime?: string;
|
||||||
|
|
||||||
/** 异常说明 */
|
/** 异常原因 */
|
||||||
exceptionExplain?: string;
|
exception?: string;
|
||||||
|
|
||||||
|
/** 处理方式(0-无需处理 1-忽略并修改库存 2-补充库存 3-其他) */
|
||||||
|
handle?: 'NO_ACTION' | 'IGNORE_AND_SAVE' | 'REPLENISH' | 'OTHER';
|
||||||
|
|
||||||
|
/** handleInfo */
|
||||||
|
handleInfo?: material.Codebook;
|
||||||
|
|
||||||
/** id */
|
/** id */
|
||||||
id?: number;
|
id?: number;
|
||||||
|
|
||||||
/** 是否确认 */
|
/** 是否确认(0: 未确认 1: 已确认) */
|
||||||
isConfirm?: boolean;
|
isConfirm?: boolean;
|
||||||
|
|
||||||
/** 类型 */
|
/** 结果(系统自动生成) */
|
||||||
type?: number;
|
result?: string;
|
||||||
|
|
||||||
|
/** 类型(1: 采购入库申请 2: 归还入库申请 3: 出库外借申请 4: 盘点申请) */
|
||||||
|
type?: 'PURCHASE_RECEIPT' | 'RETURN_RECEIPT' | 'LOAN_OUT' | 'AUDIT';
|
||||||
|
|
||||||
|
/** typeInfo */
|
||||||
|
typeInfo?: material.Codebook;
|
||||||
|
|
||||||
/** updatedTime */
|
/** updatedTime */
|
||||||
updatedTime?: string;
|
updatedTime?: string;
|
||||||
@ -61,19 +79,25 @@ declare namespace material {
|
|||||||
* 申请单
|
* 申请单
|
||||||
*/
|
*/
|
||||||
export interface ApplyInfo {
|
export interface ApplyInfo {
|
||||||
/** applyDetails */
|
/** 申请单明细 */
|
||||||
applyDetails?: Array<material.ApplyDetail>;
|
applyDetails?: Array<material.ApplyDetail>;
|
||||||
|
|
||||||
/** applyForm */
|
/** applyForm */
|
||||||
applyForm?: material.ApplyForm;
|
applyForm?: material.ApplyForm;
|
||||||
|
|
||||||
|
/** 扫码的条码集合 */
|
||||||
|
detailList?: Array<material.MaterialStockDetail>;
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 物料信息
|
* 物料信息
|
||||||
*/
|
*/
|
||||||
export interface Material {
|
export interface Material {
|
||||||
/** 赋码规则 */
|
/** 赋码规则(0-低值易耗品(不参与赋码) 1-高价值工具类(参与唯一赋码) */
|
||||||
assignRule?: number;
|
assignRule?: 'LOW_VALUE' | 'HIGH_VALUE';
|
||||||
|
|
||||||
|
/** assignRuleInfo */
|
||||||
|
assignRuleInfo?: material.Codebook;
|
||||||
|
|
||||||
/** 编码 */
|
/** 编码 */
|
||||||
code?: string;
|
code?: string;
|
||||||
@ -104,41 +128,29 @@ declare namespace material {
|
|||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 盘点信息
|
* 物料明细数据表
|
||||||
*/
|
*/
|
||||||
export interface Stocktaking {
|
export interface MaterialStockDetail {
|
||||||
|
/** 入库申请单 */
|
||||||
|
applyId?: number;
|
||||||
|
|
||||||
|
/** 条码 */
|
||||||
|
barcode?: string;
|
||||||
|
|
||||||
/** createdTime */
|
/** createdTime */
|
||||||
createdTime?: string;
|
createdTime?: string;
|
||||||
|
|
||||||
/** 盘点日期 */
|
|
||||||
date?: string;
|
|
||||||
|
|
||||||
/** 异常原因 */
|
|
||||||
exception?: string;
|
|
||||||
|
|
||||||
/** 异常情况处理方式 */
|
|
||||||
exceptionHandle?: string;
|
|
||||||
|
|
||||||
/** id */
|
/** id */
|
||||||
id?: number;
|
id?: number;
|
||||||
|
|
||||||
/** 盘点人 */
|
/** 物料ID */
|
||||||
operator?: string;
|
materialId?: number;
|
||||||
|
|
||||||
/** 盘点结果(系统自动生成) */
|
/** 状态 */
|
||||||
result?: string;
|
status?: 'IN' | 'OUT' | 'OFF';
|
||||||
|
|
||||||
/** 盘点审核结果 */
|
/** statusInfo */
|
||||||
reviewResult?: string;
|
statusInfo?: material.Codebook;
|
||||||
|
|
||||||
/** 盘点审核人 */
|
|
||||||
reviewer?: string;
|
|
||||||
|
|
||||||
/** 盘点任务状态 */
|
|
||||||
status?: number;
|
|
||||||
|
|
||||||
/** 盘点类型 */
|
|
||||||
type?: number;
|
|
||||||
|
|
||||||
/** updatedTime */
|
/** updatedTime */
|
||||||
updatedTime?: string;
|
updatedTime?: string;
|
||||||
|
@ -3,11 +3,11 @@
|
|||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
import applies from './applies';
|
import applies from './applies';
|
||||||
import saveOrUpdateApply from './saveOrUpdateApply';
|
import saveApply from './saveApply';
|
||||||
import detail from './detail';
|
import detail from './detail';
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
applies,
|
applies,
|
||||||
saveOrUpdateApply,
|
saveApply,
|
||||||
detail,
|
detail,
|
||||||
};
|
};
|
||||||
|
@ -1,34 +0,0 @@
|
|||||||
/**
|
|
||||||
* @desc 分页查询申请单列表
|
|
||||||
*/
|
|
||||||
import { defaultSuccess, defaultError, http } from '@/plugins/axios';
|
|
||||||
import type { AxiosResponse } from 'axios';
|
|
||||||
import type { IPage } from '@/api/api';
|
|
||||||
export interface Params {
|
|
||||||
/** 页码 */
|
|
||||||
page?: number;
|
|
||||||
/** 页面大小 */
|
|
||||||
size?: number;
|
|
||||||
/** 搜索关键词 */
|
|
||||||
key?: string;
|
|
||||||
}
|
|
||||||
|
|
||||||
export default async function (
|
|
||||||
/** 类型 */
|
|
||||||
type: number,
|
|
||||||
|
|
||||||
params: Params,
|
|
||||||
success: (data: IPage<material.ApplyForm>) => void = defaultSuccess,
|
|
||||||
fail: (error: { code: string; error?: string }) => void = defaultError,
|
|
||||||
): Promise<void> {
|
|
||||||
return http({
|
|
||||||
method: 'get',
|
|
||||||
url: `/apply/${type}`,
|
|
||||||
|
|
||||||
params,
|
|
||||||
})
|
|
||||||
.then((data: AxiosResponse<IPage<material.ApplyForm>, unknown>) => {
|
|
||||||
success(data.data);
|
|
||||||
})
|
|
||||||
.catch((error: { code: string; error?: string }) => fail(error));
|
|
||||||
}
|
|
@ -1,5 +1,5 @@
|
|||||||
/**
|
/**
|
||||||
* @desc 增加/编辑申请单
|
* @desc 提交申请单
|
||||||
*/
|
*/
|
||||||
import { defaultSuccess, defaultError, http } from '@/plugins/axios';
|
import { defaultSuccess, defaultError, http } from '@/plugins/axios';
|
||||||
import type { AxiosResponse } from 'axios';
|
import type { AxiosResponse } from 'axios';
|
@ -2,10 +2,7 @@ import apply from './apply';
|
|||||||
|
|
||||||
import material from './material';
|
import material from './material';
|
||||||
|
|
||||||
import stocktaking from './stocktaking';
|
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
apply,
|
apply,
|
||||||
material,
|
material,
|
||||||
stocktaking,
|
|
||||||
};
|
};
|
||||||
|
@ -1,21 +0,0 @@
|
|||||||
/**
|
|
||||||
* @desc 删除物料
|
|
||||||
*/
|
|
||||||
import { defaultSuccess, defaultError, http } from '@/plugins/axios';
|
|
||||||
import type { AxiosResponse } from 'axios';
|
|
||||||
export default async function (
|
|
||||||
/** 物料id */
|
|
||||||
id: number,
|
|
||||||
|
|
||||||
success: (data: void) => void = defaultSuccess,
|
|
||||||
fail: (error: { code: string; error?: string }) => void = defaultError,
|
|
||||||
): Promise<void> {
|
|
||||||
return http({
|
|
||||||
method: 'delete',
|
|
||||||
url: `/material/${id}`,
|
|
||||||
})
|
|
||||||
.then((data: AxiosResponse<void, unknown>) => {
|
|
||||||
success(data.data);
|
|
||||||
})
|
|
||||||
.catch((error: { code: string; error?: string }) => fail(error));
|
|
||||||
}
|
|
@ -1,11 +0,0 @@
|
|||||||
/**
|
|
||||||
* @description 盘点管理
|
|
||||||
*
|
|
||||||
*/
|
|
||||||
import saveOrUpdateStocktaking from './saveOrUpdateStocktaking';
|
|
||||||
import stocktakingList from './stocktakingList';
|
|
||||||
|
|
||||||
export default {
|
|
||||||
saveOrUpdateStocktaking,
|
|
||||||
stocktakingList,
|
|
||||||
};
|
|
@ -1,33 +0,0 @@
|
|||||||
/**
|
|
||||||
* @desc 分页查询盘点列表
|
|
||||||
*/
|
|
||||||
import { defaultSuccess, defaultError, http } from '@/plugins/axios';
|
|
||||||
import type { AxiosResponse } from 'axios';
|
|
||||||
import type { IPage } from '@/api/api';
|
|
||||||
export interface Params {
|
|
||||||
/** 页码 */
|
|
||||||
page?: number;
|
|
||||||
/** 页面大小 */
|
|
||||||
size?: number;
|
|
||||||
/** 类型 */
|
|
||||||
type?: number;
|
|
||||||
/** 搜索关键词 */
|
|
||||||
key?: string;
|
|
||||||
}
|
|
||||||
|
|
||||||
export default async function (
|
|
||||||
params: Params,
|
|
||||||
success: (data: IPage<material.Stocktaking>) => void = defaultSuccess,
|
|
||||||
fail: (error: { code: string; error?: string }) => void = defaultError,
|
|
||||||
): Promise<void> {
|
|
||||||
return http({
|
|
||||||
method: 'get',
|
|
||||||
url: `/stocktaking-list`,
|
|
||||||
|
|
||||||
params,
|
|
||||||
})
|
|
||||||
.then((data: AxiosResponse<IPage<material.Stocktaking>, unknown>) => {
|
|
||||||
success(data.data);
|
|
||||||
})
|
|
||||||
.catch((error: { code: string; error?: string }) => fail(error));
|
|
||||||
}
|
|
@ -1,22 +0,0 @@
|
|||||||
/**
|
|
||||||
* @desc 增加/编辑盘点
|
|
||||||
*/
|
|
||||||
import { defaultSuccess, defaultError, http } from '@/plugins/axios';
|
|
||||||
import type { AxiosResponse } from 'axios';
|
|
||||||
export default async function (
|
|
||||||
/** 请求体 */
|
|
||||||
requestBody: material.Stocktaking,
|
|
||||||
|
|
||||||
success: (data: material.Stocktaking) => void = defaultSuccess,
|
|
||||||
fail: (error: { code: string; error?: string }) => void = defaultError,
|
|
||||||
): Promise<void> {
|
|
||||||
return http({
|
|
||||||
method: 'put',
|
|
||||||
url: `/stocktaking`,
|
|
||||||
data: requestBody,
|
|
||||||
})
|
|
||||||
.then((data: AxiosResponse<material.Stocktaking, unknown>) => {
|
|
||||||
success(data.data);
|
|
||||||
})
|
|
||||||
.catch((error: { code: string; error?: string }) => fail(error));
|
|
||||||
}
|
|
@ -1,33 +0,0 @@
|
|||||||
/**
|
|
||||||
* @desc 分页查询盘点列表
|
|
||||||
*/
|
|
||||||
import { defaultSuccess, defaultError, http } from '@/plugins/axios';
|
|
||||||
import type { AxiosResponse } from 'axios';
|
|
||||||
import type { IPage } from '@/api/api';
|
|
||||||
export interface Params {
|
|
||||||
/** 页码 */
|
|
||||||
page?: number;
|
|
||||||
/** 页面大小 */
|
|
||||||
size?: number;
|
|
||||||
/** 类型 */
|
|
||||||
type?: number;
|
|
||||||
/** 搜索关键词 */
|
|
||||||
key?: string;
|
|
||||||
}
|
|
||||||
|
|
||||||
export default async function (
|
|
||||||
params: Params,
|
|
||||||
success: (data: IPage<material.Stocktaking>) => void = defaultSuccess,
|
|
||||||
fail: (error: { code: string; error?: string }) => void = defaultError,
|
|
||||||
): Promise<void> {
|
|
||||||
return http({
|
|
||||||
method: 'get',
|
|
||||||
url: `/stocktaking-list`,
|
|
||||||
|
|
||||||
params,
|
|
||||||
})
|
|
||||||
.then((data: AxiosResponse<IPage<material.Stocktaking>, unknown>) => {
|
|
||||||
success(data.data);
|
|
||||||
})
|
|
||||||
.catch((error: { code: string; error?: string }) => fail(error));
|
|
||||||
}
|
|
@ -12,9 +12,17 @@
|
|||||||
<vxe-column type="seq" width="70" />
|
<vxe-column type="seq" width="70" />
|
||||||
<vxe-column field="id" title="物料id" :visible="false" />
|
<vxe-column field="id" title="物料id" :visible="false" />
|
||||||
<vxe-column field="name" title="物料名称" />
|
<vxe-column field="name" title="物料名称" />
|
||||||
<vxe-column field="scan" title="是否扫码" />
|
<vxe-column field="assignRule" title="是否扫码">
|
||||||
|
<template #default="{ row }">
|
||||||
|
{{ row.assignRule === 'HIGH_VALUE' ? '是' : '否' }}
|
||||||
|
</template>
|
||||||
|
</vxe-column>
|
||||||
<vxe-column field="applyNum" title="申请数量" :edit-render="{ name: 'VxeInput', props: { type: 'integer' } }" />
|
<vxe-column field="applyNum" title="申请数量" :edit-render="{ name: 'VxeInput', props: { type: 'integer' } }" />
|
||||||
<vxe-column field="scanNum" title="扫码数量" :edit-render="{ name: 'VxeInput', props: { type: 'integer' } }" />
|
<vxe-column field="scanNum" title="扫码数量" :edit-render="{ name: 'VxeInput', props: { type: 'integer' } }" >
|
||||||
|
<template #default="{ row }">
|
||||||
|
{{ row.assignRule === 'LOW_VALUE' ? '~' : row.scanNum }}
|
||||||
|
</template>
|
||||||
|
</vxe-column>
|
||||||
<vxe-column field="remark" title="备注" :edit-render="{ name: 'VxeInput' }" />
|
<vxe-column field="remark" title="备注" :edit-render="{ name: 'VxeInput' }" />
|
||||||
|
|
||||||
<vxe-column title="操作">
|
<vxe-column title="操作">
|
||||||
@ -63,7 +71,7 @@
|
|||||||
interface RowVO {
|
interface RowVO {
|
||||||
id: number
|
id: number
|
||||||
name: string
|
name: string
|
||||||
scan: string
|
assignRule: string
|
||||||
applyNum: number
|
applyNum: number
|
||||||
scanNum: number
|
scanNum: number
|
||||||
remark: string
|
remark: string
|
||||||
|
@ -8,9 +8,9 @@
|
|||||||
|
|
||||||
<a-form-item label="申请类型" name="applyType">
|
<a-form-item label="申请类型" name="applyType">
|
||||||
<a-radio-group v-model:value="formData.applyType" button-style="solid" style="width: 40%;">
|
<a-radio-group v-model:value="formData.applyType" button-style="solid" style="width: 40%;">
|
||||||
<a-radio-button value='1' v-if="applyType === '1'">采购入库</a-radio-button>
|
<a-radio-button value='1' v-if="applyType === 'PURCHASE_RECEIPT'">采购入库</a-radio-button>
|
||||||
<a-radio-button value='2' v-if="applyType === '1'">归还入库</a-radio-button>
|
<a-radio-button value='2' v-if="applyType === 'RETURN_RECEIPT'">归还入库</a-radio-button>
|
||||||
<a-radio-button value='3' v-if="applyType === '3'">出库外借</a-radio-button>
|
<a-radio-button value='3' v-if="applyType === 'LOAN_OUT'">出库外借</a-radio-button>
|
||||||
</a-radio-group>
|
</a-radio-group>
|
||||||
</a-form-item>
|
</a-form-item>
|
||||||
<a-form-item label="申请日期" name="applyDate" style="width: 40%;">
|
<a-form-item label="申请日期" name="applyDate" style="width: 40%;">
|
||||||
@ -18,8 +18,7 @@
|
|||||||
</a-form-item>
|
</a-form-item>
|
||||||
<a-form-item label="选择物料" name="selected">
|
<a-form-item label="选择物料" name="selected">
|
||||||
<a-select v-model:value="formData.slectedList" mode="multiple" bordered placeholder="请选择物料" style="width: 40%;"
|
<a-select v-model:value="formData.slectedList" mode="multiple" bordered placeholder="请选择物料" style="width: 40%;"
|
||||||
show-search :options="options" @deselect="removeEvent"
|
show-search :options="options" @deselect="removeEvent" @select="insertEvent"></a-select>
|
||||||
@select="insertEvent"></a-select>
|
|
||||||
</a-form-item>
|
</a-form-item>
|
||||||
</a-form>
|
</a-form>
|
||||||
</div>
|
</div>
|
||||||
@ -34,7 +33,11 @@
|
|||||||
<vxe-column field="code" title="编码" />
|
<vxe-column field="code" title="编码" />
|
||||||
<vxe-column field="spec" title="规格" />
|
<vxe-column field="spec" title="规格" />
|
||||||
<vxe-column field="type" title="类型" />
|
<vxe-column field="type" title="类型" />
|
||||||
<vxe-column field="assignRule" title="赋码规则" />
|
<vxe-column field="assignRule" title="是否赋码">
|
||||||
|
<template #default="{ row }">
|
||||||
|
{{ row.assignRule === 'HIGH_VALUE' ? '是' : '否' }}
|
||||||
|
</template>
|
||||||
|
</vxe-column>
|
||||||
<vxe-column field="quantity" title="申请数量(点击修改)" :edit-render="{ name: 'input', autoSelect: true }"
|
<vxe-column field="quantity" title="申请数量(点击修改)" :edit-render="{ name: 'input', autoSelect: true }"
|
||||||
keyboard-config="{edit: true, del: true}" cell-type="number">
|
keyboard-config="{edit: true, del: true}" cell-type="number">
|
||||||
<template #edit="{ row }">
|
<template #edit="{ row }">
|
||||||
@ -77,7 +80,7 @@ const getApplyForm = () => {
|
|||||||
applicant: formData.value.applicant,
|
applicant: formData.value.applicant,
|
||||||
applyDate: formData.value.applyDate.format('YYYY-MM-DD HH:mm:ss'),
|
applyDate: formData.value.applyDate.format('YYYY-MM-DD HH:mm:ss'),
|
||||||
isConfirm: true,
|
isConfirm: true,
|
||||||
exceptionExplain: ''
|
result: ''
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
defineExpose({ getTableData, getApplyForm })
|
defineExpose({ getTableData, getApplyForm })
|
||||||
@ -93,7 +96,7 @@ const userStore = useUserStore()
|
|||||||
const formData = ref<FormData>({
|
const formData = ref<FormData>({
|
||||||
applicant: userStore.userName,
|
applicant: userStore.userName,
|
||||||
applyDate: dayjs(),
|
applyDate: dayjs(),
|
||||||
applyType: props.applyType, // 1: 采购入库 2: 归还入库 3: 出库外借
|
applyType: props.applyType,
|
||||||
slectedList: []
|
slectedList: []
|
||||||
|
|
||||||
});
|
});
|
||||||
@ -155,7 +158,7 @@ const insertEvent = (value: any) => {
|
|||||||
}
|
}
|
||||||
|
|
||||||
// 取消选中时,删除table中的行
|
// 取消选中时,删除table中的行
|
||||||
const removeEvent = (value : any) => {
|
const removeEvent = (value: any) => {
|
||||||
const $table = tableRef.value
|
const $table = tableRef.value
|
||||||
// 根据value找到对应的行
|
// 根据value找到对应的行
|
||||||
if ($table) {
|
if ($table) {
|
||||||
|
@ -43,7 +43,7 @@
|
|||||||
type: String,
|
type: String,
|
||||||
default: '',
|
default: '',
|
||||||
},
|
},
|
||||||
}, // 申请类型 applyType页面传值的使用1和2,1: 采购入库 和 归还入库 2: 出库外借
|
}, // 申请类型 PURCHASE_RECEIPT 采购入库申请 , RETURN_RECEIPT 归还入库申请 , LOAN_OUT 外借出库申请, AUDIT 盘点申请
|
||||||
)
|
)
|
||||||
// steps
|
// steps
|
||||||
const current = ref<number>(0) // 翻页的引用
|
const current = ref<number>(0) // 翻页的引用
|
||||||
@ -52,7 +52,6 @@
|
|||||||
const applyConfirmRef = ref() // step3表单引用
|
const applyConfirmRef = ref() // step3表单引用
|
||||||
|
|
||||||
const selectData = ref() // step1中用户申请选择的物料数据,存的原始数据
|
const selectData = ref() // step1中用户申请选择的物料数据,存的原始数据
|
||||||
const scanData = ref() // step2中用户扫码的物料数据
|
|
||||||
const totalValue = ref(0) // 传给扫码页面的合计数值
|
const totalValue = ref(0) // 传给扫码页面的合计数值
|
||||||
const conformData = ref<Array<object>>([]) // step3中的待确认数据
|
const conformData = ref<Array<object>>([]) // step3中的待确认数据
|
||||||
const loading = ref(false) // 提交按钮的loading状态
|
const loading = ref(false) // 提交按钮的loading状态
|
||||||
@ -64,10 +63,11 @@
|
|||||||
*/
|
*/
|
||||||
const nextStep = () => {
|
const nextStep = () => {
|
||||||
if (applyFormRef.value && current.value === 0) {
|
if (applyFormRef.value && current.value === 0) {
|
||||||
|
totalValue.value = 0
|
||||||
// 再step1中点击下一步的时候,就去获取step1中的表单数据
|
// 再step1中点击下一步的时候,就去获取step1中的表单数据
|
||||||
selectData.value = applyFormRef.value.getTableData()
|
selectData.value = applyFormRef.value.getTableData()
|
||||||
selectData.value.forEach((item) => {
|
selectData.value.forEach((item) => {
|
||||||
if (item.assignRule === 1) {
|
if (item.assignRule === 'HIGH_VALUE') {
|
||||||
totalValue.value += item.quantity
|
totalValue.value += item.quantity
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
@ -82,7 +82,6 @@
|
|||||||
acc[item.code]++
|
acc[item.code]++
|
||||||
return acc
|
return acc
|
||||||
}, {})
|
}, {})
|
||||||
scanData.value = items
|
|
||||||
// 组装步骤三的原始数据
|
// 组装步骤三的原始数据
|
||||||
conformData.value = selectData.value.map((item) => {
|
conformData.value = selectData.value.map((item) => {
|
||||||
return {
|
return {
|
||||||
@ -90,12 +89,13 @@
|
|||||||
name: item.name,
|
name: item.name,
|
||||||
code: item.code,
|
code: item.code,
|
||||||
applyNum: item.quantity,
|
applyNum: item.quantity,
|
||||||
scan: item.assignRule,
|
assignRule: item.assignRule,
|
||||||
scanNum: groupedSums[item.code] || 0,
|
scanNum: groupedSums[item.code] || 0,
|
||||||
remark: item.quantity != groupedSums[item.code] ? `实际扫码数量与申请数量不一致` : '',
|
remark: (item.quantity != groupedSums[item.code] && item.assignRule === 'HIGH_VALUE') ? `数量不一致` : '',
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
// 切换到下一步
|
// 切换到下一步
|
||||||
current.value++
|
current.value++
|
||||||
}
|
}
|
||||||
@ -110,7 +110,9 @@
|
|||||||
// 获取用户最终确认的数据
|
// 获取用户最终确认的数据
|
||||||
const applyDetails = applyConfirmRef.value.getTableData() // 申请明细数据
|
const applyDetails = applyConfirmRef.value.getTableData() // 申请明细数据
|
||||||
const applyForm = applyFormRef.value.getApplyForm() // 申请表单数据
|
const applyForm = applyFormRef.value.getApplyForm() // 申请表单数据
|
||||||
api.materialApi.apply.saveOrUpdateApply({ applyForm: applyForm, applyDetails: applyDetails }, () => {
|
const detailList = scanFormRef.value.getTableData() // 扫码明细数据
|
||||||
|
|
||||||
|
api.materialApi.apply.saveApply({ applyForm: applyForm, applyDetails: applyDetails, detailList: detailList }, () => {
|
||||||
console.log('申请成功')
|
console.log('申请成功')
|
||||||
// 清理缓存数据
|
// 清理缓存数据
|
||||||
loading.value = false
|
loading.value = false
|
||||||
|
@ -53,7 +53,9 @@ const getTableData = () => {
|
|||||||
const $table = applyDetailTableRef.value
|
const $table = applyDetailTableRef.value
|
||||||
if ($table) {
|
if ($table) {
|
||||||
return $table.getTableData().fullData.map(item => ({
|
return $table.getTableData().fullData.map(item => ({
|
||||||
sn: item.barcode,
|
assignRule: item.assignRule,
|
||||||
|
materialId: item.id,
|
||||||
|
barcode: item.barcode,
|
||||||
code: item.code,
|
code: item.code,
|
||||||
date: item.times
|
date: item.times
|
||||||
}))
|
}))
|
||||||
@ -92,6 +94,7 @@ getCache();
|
|||||||
interface TableRowVO {
|
interface TableRowVO {
|
||||||
id: number
|
id: number
|
||||||
barcode: string
|
barcode: string
|
||||||
|
assignRule: string
|
||||||
name: string
|
name: string
|
||||||
code: string
|
code: string
|
||||||
spec: string
|
spec: string
|
||||||
@ -107,6 +110,11 @@ const removeStep2Row = async (row: TableRowVO) => {
|
|||||||
const $table = applyDetailTableRef.value
|
const $table = applyDetailTableRef.value
|
||||||
if ($table) {
|
if ($table) {
|
||||||
$table.remove(row)
|
$table.remove(row)
|
||||||
|
//删除缓存的sn
|
||||||
|
snListCache.value = snListCache.value.filter(item => item!== row.barcode)
|
||||||
|
|
||||||
|
// 已扫码数量-1
|
||||||
|
remainderValue.value = remainderValue.value - 1
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -150,6 +158,7 @@ const autoInsertOneRow = async () => {
|
|||||||
const row: TableRowVO = {
|
const row: TableRowVO = {
|
||||||
id: materialInfo?.id ?? 0,
|
id: materialInfo?.id ?? 0,
|
||||||
barcode: sn,
|
barcode: sn,
|
||||||
|
assignRule: materialInfo?.assignRule ?? '',
|
||||||
name: materialInfo?.name ?? '',
|
name: materialInfo?.name ?? '',
|
||||||
code: materialInfo?.code ?? '',
|
code: materialInfo?.code ?? '',
|
||||||
spec: materialInfo?.spec ?? '',
|
spec: materialInfo?.spec ?? '',
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
<template>
|
<template>
|
||||||
<apply-modal apply-type='1'></apply-modal>
|
<apply-modal apply-type='PURCHASE_RECEIPT'></apply-modal>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script setup lang="ts">
|
<script setup lang="ts">
|
||||||
|
@ -85,7 +85,7 @@ export const formItems: FormItem[] = [
|
|||||||
size: 'default',
|
size: 'default',
|
||||||
controls: true,
|
controls: true,
|
||||||
placeholder: '请填写赋码规则',
|
placeholder: '请填写赋码规则',
|
||||||
options: [{ label: '低值易耗品', value: 2 }, { label: '高价值工具类', value: 1 }]
|
options: [{ label: '低值易耗品', value: 'LOW_VALUE' }, { label: '高价值工具类', value: 'HIGH_VALUE' }]
|
||||||
},
|
},
|
||||||
rules: [],
|
rules: [],
|
||||||
|
|
||||||
|
@ -36,7 +36,7 @@
|
|||||||
<!-- 操作按钮列 -->
|
<!-- 操作按钮列 -->
|
||||||
<template #bodyCell="{ column, record }">
|
<template #bodyCell="{ column, record }">
|
||||||
<template v-if="column.dataIndex === 'assignRule'">
|
<template v-if="column.dataIndex === 'assignRule'">
|
||||||
{{ record.assignRule === 1 ? '高价值工具类' : '低值易耗品' }} <!-- 这里定义为0和1,0再回显的时候不展示?-->
|
{{ record.assignRule === 'HIGH_VALUE' ? '高价值工具类' : '低值易耗品' }}
|
||||||
</template>
|
</template>
|
||||||
<template v-if="column.dataIndex === 'operation'">
|
<template v-if="column.dataIndex === 'operation'">
|
||||||
<a-button type="link" :style="{ color: token.colorPrimary }" @click="addOrEdit(record)">
|
<a-button type="link" :style="{ color: token.colorPrimary }" @click="addOrEdit(record)">
|
||||||
@ -190,7 +190,6 @@
|
|||||||
|
|
||||||
//保存
|
//保存
|
||||||
const doSave = (_data: FormDataType) => {
|
const doSave = (_data: FormDataType) => {
|
||||||
window.console.log(_data)
|
|
||||||
api.materialApi.material.saveOrUpdateMaterial(_data as unknown as material.Material, () => {
|
api.materialApi.material.saveOrUpdateMaterial(_data as unknown as material.Material, () => {
|
||||||
formDrawer.value?.close()
|
formDrawer.value?.close()
|
||||||
notification.success({
|
notification.success({
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
<template>
|
<template>
|
||||||
<apply-modal apply-type='3'></apply-modal>
|
<apply-modal apply-type='LOAN_OUT'></apply-modal>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script setup lang="ts">
|
<script setup lang="ts">
|
||||||
|
Loading…
x
Reference in New Issue
Block a user