zhaoxinyu 8 months ago
parent
commit
3c76643371
  1. 2
      .drone.yml
  2. 15
      code/src/Modules/SettleAccount/host/SettleAccount.HttpApi.Host/wwwroot/models/_options.js
  3. 311
      code/src/Modules/SettleAccount/host/SettleAccount.HttpApi.Host/wwwroot/models/settle/detail.js

2
.drone.yml

@ -24,7 +24,7 @@ steps:
- name: 发布到MinIO - name: 发布到MinIO
image: plugins/s3 image: plugins/s3
settings: settings:
endpoint: http://dev.ccwin-in.com:3008 endpoint: http://dev.ccwin-in.com:3007
path_style: true path_style: true
bucket: default bucket: default
access_key: O222sbIaMKeGfeX18t8K access_key: O222sbIaMKeGfeX18t8K

15
code/src/Modules/SettleAccount/host/SettleAccount.HttpApi.Host/wwwroot/models/_options.js

@ -154,6 +154,19 @@ const enableType = {
], ],
}; };
const site = {
title: "工厂地点",
type: "number",
input: "select",
options: [
{ value: 1040, label: 1040 },
{ value: 1046, label: 1046 },
],
hideForList: true,
default:1040,
};
const codeType = { const codeType = {
title: "生产码类型", title: "生产码类型",
type: "string", type: "string",
@ -208,4 +221,4 @@ const taskState = {
}; };
export default businessType; export default businessType;
export { version, state, state2, state3, transType, deliverBillType, deliverSubBillType, proType, billState, codeType, invState, taskState, enableType }; export { version, state, state2, state3, transType, deliverBillType, deliverSubBillType, proType, billState, codeType, invState, taskState, enableType,site };

311
code/src/Modules/SettleAccount/host/SettleAccount.HttpApi.Host/wwwroot/models/settle/detail.js

@ -1,3 +1,4 @@
import { site } from "../_options.js";
export default function (businessType, type) { export default function (businessType, type) {
const schema = { const schema = {
title: "通用代码", title: "通用代码",
@ -44,11 +45,8 @@ export default function (businessType, type) {
groupNum: { groupNum: {
title: "结算分组号", title: "结算分组号",
type: "decimal", type: "decimal",
}, },
site: { site,
title: "工厂地点",
type: "string",
},
isReturn: { isReturn: {
title: "是否退货", title: "是否退货",
type: "boolean", type: "boolean",
@ -97,7 +95,7 @@ export default function (businessType, type) {
} }
if (businessType !== "JisBBAC") { if (businessType !== "JisBBAC") {
delete schema.properties["site"]; delete schema.properties["site"];
} }
const queryUrl = `settleaccount/${service}/detail-query`; const queryUrl = `settleaccount/${service}/detail-query`;
const addUrl = `settleaccount/${service}/generate-settlement-order`; const addUrl = `settleaccount/${service}/generate-settlement-order`;
@ -106,109 +104,224 @@ export default function (businessType, type) {
const addMethod = "POST"; const addMethod = "POST";
const exportMethod = "POST"; const exportMethod = "POST";
return { if (businessType !== "JisBBAC")
query: { {
url: queryUrl, return {
method: queryMethod, query: {
hasFilter: true, url: queryUrl,
schema: { method: queryMethod,
title: "通用代码", hasFilter: true,
type: "object", schema: {
properties: { title: "通用代码",
filters: { type: "object",
title: "筛选", properties: {
type: "array", filters: {
hidden: true, title: "筛选",
items: { type: "array",
type: "object", hidden: true,
properties: { items: {
logic: { type: "object",
type: "int", properties: {
logic: {
type: "int",
},
column: {
type: "string",
},
action: {
type: "int",
},
value: {
type: "string",
},
},
},
default: [
{
logic: "and",
column: "settleDate",
action: "biggerThanOrEqual",
value: null,
readOnly: true,
clearable: true,
title: "下线开始",
}, },
column: { {
type: "string", logic: "and",
column: "settleDate",
action: "smallThan",
value: null,
readOnly: true,
clearable: true,
title: "下线结束",
},
{
logic: "and",
action: "like",
column: "partCode",
value: null,
readOnly: true,
}, },
action: { {
type: "int", logic: "and",
action: "like",
column: "pn",
value: null,
readOnly: true,
}, },
value: { {
type: "string", logic: "and",
action: "like",
column: "groupNum",
value: null,
readOnly: true,
}, },
}, ],
}, },
default: [ skipCount: {
{ hidden: true,
logic: "and", default: 0,
column: "settleDate", },
action: "biggerThanOrEqual", maxResultCount: {
value: null, hidden: true,
readOnly: true, default: 10,
clearable: true, },
title: "下线开始", sorting: {
}, hidden: true,
{ },
logic: "and", },
column: "settleDate", },
action: "smallThan", },
value: null, table: {
readOnly: true, schema: schema,
clearable: true, },
title: "下线结束", edit: {
}, addUrl,
{ exportUrl,
logic: "and", addMethod,
action: "like", exportUrl,
column: "site", exportMethod,
value: null, schema: schema,
readOnly: true, },
};
}
else
{
const querySchema = {
title: "通用代码",
type: "object",
properties: {
filters: {
title: "筛选",
type: "array",
hidden: true,
items: {
type: "object",
properties: {
logic: {
type: "int",
}, },
{ column: {
logic: "and", type: "string",
action: "like",
column: "partCode",
value: null,
readOnly: true,
}, },
{ action: {
logic: "and", type: "int",
action: "like",
column: "pn",
value: null,
readOnly: true,
}, },
{ value: {
logic: "and", type: "string",
action: "like",
column: "groupNum",
value: null,
readOnly: true,
}, },
], },
},
skipCount: {
hidden: true,
default: 0,
},
maxResultCount: {
hidden: true,
default: 10,
},
sorting: {
hidden: true,
}, },
default: [
{
logic: "and",
column: "settleDate",
action: "biggerThanOrEqual",
value: null,
readOnly: true,
clearable: true,
title: "下线开始",
},
{
logic: "and",
column: "settleDate",
action: "smallThan",
value: null,
readOnly: true,
clearable: true,
title: "下线结束",
},
{
logic: "and",
action: "like",
column: "partCode",
value: null,
readOnly: true,
},
{
logic: "and",
action: "like",
column: "pn",
value: null,
readOnly: true,
},
{
logic: "and",
action: "like",
column: "groupNum",
value: null,
readOnly: true,
},
],
},
skipCount: {
hidden: true,
default: 0,
},
maxResultCount: {
hidden: true,
default: 10,
},
sorting: {
hidden: true,
}, },
}, },
}, };
table: {
schema: schema,
},
edit: {
addUrl, querySchema.properties.filters.default.push({
exportUrl, logic: "and",
addMethod, column: "site",
exportUrl, action: "equal",
exportMethod, value: schema.properties.site.default,
schema: schema, readOnly: true,
}, });
};
return {
query: {
url: queryUrl,
method: queryMethod,
hasFilter: true,
schema: querySchema,
},
table: {
schema: schema,
},
edit: {
addUrl,
exportUrl,
addMethod,
exportUrl,
exportMethod,
schema: schema,
},
};
}
} }

Loading…
Cancel
Save