Browse Source

update

master
wanggang 1 year ago
parent
commit
0fbf414e14
  1. 5
      code/src/Modules/SettleAccount/host/SettleAccount.HttpApi.Host/wwwroot/models/settle/detail.js
  2. 113
      code/src/Modules/SettleAccount/host/SettleAccount.HttpApi.Host/wwwroot/models/settle/unable-bk.js
  3. 2
      code/src/Modules/SettleAccount/host/SettleAccount.HttpApi.Host/wwwroot/views/settle/unable.js

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

@ -1,3 +1,4 @@
export default function (businessType, type) {
const schema = {
title: "通用代码",
type: "object",
@ -67,7 +68,6 @@ const schema = {
},
};
export default function (businessType, type) {
let service;
if (type === "unable") {
if (businessType === "JisBBAC") {
@ -86,6 +86,7 @@ export default function (businessType, type) {
service = "pub_can_sa_service";
}
}
if (businessType === "JisBBAC" || businessType === "JisHBPO" || businessType === "MaiDanJianBBAC" || businessType === "MaiDanJianHBPO") {
schema.properties.pn.title = "生产码";
} else if (businessType === "ZhiGongJianBBAC" || businessType === "ZhiGongJianHBPO" || businessType === "YinDuJian") {
@ -207,5 +208,3 @@ export default function (businessType, type) {
},
};
}
export { schema };

113
code/src/Modules/SettleAccount/host/SettleAccount.HttpApi.Host/wwwroot/models/settle/unable-bk.js

@ -1,113 +0,0 @@
//不可结算明细
import { version, state } from "../_options.js";
const schema = {
title: "可结算单",
type: "object",
properties: {
version,
state,
billNum: {
title: "结算单据",
type: "string",
oneToMany: "/settle/detail",
config: "/models/settle/detail.js",
},
settleBillNum: {
title: "关联结算单号",
type: "string",
},
invGroupNum: {
title: "发票分组号",
type: "string",
},
},
};
export default function (businessType) {
let service;
if (businessType === "JisBBAC") {
service = "bbac_can_sa_service";
} else if (businessType === "JisHBPO" || businessType === "MaiDanJianHBPO") {
service = "hbpo_can_sa_service";
} else {
service = "pub_can_sa_service";
}
const queryUrl = `settleaccount/${service}/main-query`;
const exportUrl = `settleaccount/${service}/export`;
const addUrl = `settleaccount/${service}/generate-invoice`;
const queryMethod = "POST";
const exportMethod = "POST";
const addMethod = "POST";
return {
query: {
url: queryUrl,
method: queryMethod,
hasFilter: true,
schema: {
title: "发票分组号",
type: "object",
properties: {
filters: {
title: "项目",
type: "array",
hidden: true,
items: {
type: "object",
properties: {
logic: {
type: "int",
},
column: {
type: "string",
},
action: {
type: "int",
},
value: {
type: "string",
},
},
},
default: [
{
logic: "and",
column: "version",
action: "equal",
value: null,
readOnly: true,
},
],
},
skipCount: {
hidden: true,
default: 0,
},
maxResultCount: {
hidden: true,
default: 10,
},
sorting: {
hidden: true,
},
businessType: {
hidden: true,
default: 0,
},
},
},
},
table: {
schema: schema,
},
edit: {
exportUrl,
addUrl,
exportMethod,
addMethod,
schema: schema,
},
};
}

2
code/src/Modules/SettleAccount/host/SettleAccount.HttpApi.Host/wwwroot/views/settle/unable.js

@ -14,6 +14,8 @@ export default {
const route = useRoute();
const businessType = route.meta.businessType;
const config = useConfig(businessType, "unable");
delete config.table.schema.properties["invBillNum"];
delete config.table.schema.properties["billNum"];
const onCommand = async (item) => {
const url = config.edit.addUrl;
if (item.path === "add") {

Loading…
Cancel
Save