diff --git a/code/WebApp/vanilla/components/form/form-input.js b/code/WebApp/vanilla/components/form/form-input.js
index 87d16b3d..24a7112c 100644
--- a/code/WebApp/vanilla/components/form/form-input.js
+++ b/code/WebApp/vanilla/components/form/form-input.js
@@ -2,14 +2,16 @@ import html from "html";
import { ref, reactive, watch, onMounted } from "vue";
import { dayjs } from "element-plus";
import request, { post } from "../../request/index.js";
+import { importFunction } from "../../utils/index.js";
export default {
template: html`
- {{dayjs(model[prop]).format('YYYY-MM-DD HH:mm:ss')}}
+ {{dayjs(model[prop]).format('YYYY')}}
{{dayjs(model[prop]).format('YYYY-MM-DD')}}
+ {{dayjs(model[prop]).format('YYYY-MM-DD HH:mm:ss')}}
******
{{model[prop]}}
@@ -27,21 +29,24 @@ export default {
+
+
+
-
+
@@ -51,6 +56,7 @@ export default {
-
+
`,
@@ -87,6 +100,22 @@ export default {
const selectProps = ref({});
const selectValues = ref([]);
const options = ref([]);
+ //watch
+
+ watch(
+ () => model[props.prop],
+ async (value) => {
+ if (props.schema.watch) {
+ console.log(value);
+ if (props.schema.watch?.constructor === String) {
+ props.schema.watch = await importFunction(props.schema.watch);
+ }
+ if (props.schema.watch?.constructor === Function) {
+ props.schema.watch(model, value);
+ }
+ }
+ }
+ );
onMounted(async () => {
if (props.schema.options) {
options.value = props.schema.options;
diff --git a/code/WebApp/vanilla/components/form/index.js b/code/WebApp/vanilla/components/form/index.js
index df07298f..9e876e63 100644
--- a/code/WebApp/vanilla/components/form/index.js
+++ b/code/WebApp/vanilla/components/form/index.js
@@ -5,7 +5,7 @@ export default {
components: { AppFormItem: defineAsyncComponent(() => import("./form-item.js")) },
name: "AppForm",
template: html`
-
+
-
+
- $t('confirm')
+
+ $t('confirm')
+
`,
- props: ["modelValue", "schema", "action", "hideButton", "isQueryForm", "mode"],
+ props: ["modelValue", "inline", "schema", "action", "hideButton", "isQueryForm", "mode"],
emits: ["update:modelValue", "submit"],
setup(props, context) {
// init
diff --git a/code/WebApp/vanilla/components/list/index.js b/code/WebApp/vanilla/components/list/index.js
index 802dee6b..a312d55c 100644
--- a/code/WebApp/vanilla/components/list/index.js
+++ b/code/WebApp/vanilla/components/list/index.js
@@ -1,5 +1,5 @@
import html, { getProp } from "html";
-import request, { get, post } from "../../request/index.js";
+import request, { get, getUrl, post } from "../../request/index.js";
import { defineAsyncComponent, ref, reactive, onMounted } from "vue";
import { useRoute, useRouter } from "vue-router";
import { useI18n } from "vue-i18n";
@@ -14,6 +14,7 @@ export default {
name: "AppList",
components: {
AppForm: defineAsyncComponent(() => import("../form/index.js")),
+ AppFormInput: defineAsyncComponent(() => import("../../components/form/form-input.js")),
SvgIcon: defineAsyncComponent(() => import("../../components/icon/index.js")),
AppFormInput: defineAsyncComponent(() => import("../form/form-input.js")),
VueOfficeExcel,
@@ -26,13 +27,18 @@ export default {
inline
mode="query"
label-position="left"
- :schema="querySchema"
+ :schema="config.query.schema"
v-model="queryModel"
@submit="load"
:hideButton="true"
:isQueryForm="true"
- v-if="querySchema"
- />
+ >
+
+
+
+
+
+
@@ -48,7 +54,7 @@ export default {
{{item.meta.title}}
-
+
{{$t('筛选')}}
@@ -231,23 +237,26 @@ export default {
-
-
-
-
-
-
-
+
{{$t('下载')}}
-
+
+
+
+
+
+
+
+
+
+
+
@@ -257,37 +266,33 @@ export default {
-
-
+
+
-
-
+
+
+
+
-
-
-
-
-
-
-
-
-
-
-
+
+
+
-
-
+
+
-
-
-
+
+
@@ -296,7 +301,7 @@ export default {
-
+
@@ -322,6 +327,22 @@ export default {
.el-form.filter .el-col {
padding: 5px;
}
+ dl.upload {
+ min-height: 100%;
+ }
+ dl.upload dt {
+ font-weight: bold;
+ line-height: 3em;
+ }
+ dl.upload dd {
+ line-height: 2em;
+ }
+ dl.upload .el-form-item {
+ width: 300px;
+ }
+ div.upload {
+ width: 100%;
+ }
`,
props: ["modelValue", "config", "querySchema", "controller", "query", "buttons"],
emits: ["command"],
@@ -361,7 +382,7 @@ export default {
const queryModel = ref({});
const sortColumns = ref(new Map());
const querySchema = ref(props.querySchema);
- const queryList = ref([]);
+ const filterList = ref([]);
const tableSchema = ref({});
const tableData = ref([]);
const editFormRef = ref(null);
@@ -375,12 +396,16 @@ export default {
includeDeleted: false,
});
const importModel = reactive({
- partial: true,
- replace: false,
+ // partial: true,
+ // replace: false,
+ factory: "",
+ version: "",
});
+ const factories = ref([]);
+ const versions = ref([]);
const fileList = ref([]);
const getSortModel = (model) => {
- model.orderBy
+ (model.sorting ?? "")
.split(",")
.map((o) => o.trim())
.filter((o) => o)
@@ -393,7 +418,7 @@ export default {
const getColumns = (schema) => {
Object.keys(schema.properties).forEach((propertyName) => {
const property = schema.properties[propertyName];
- if (property.type !== "object" && property.type !== "array" && !property.hidden && property.showForList) {
+ if (property.showForList || (property.type !== "object" && property.type !== "array" && !property.hidden)) {
columns.value.push({ name: propertyName, title: property.title, checked: true });
}
});
@@ -409,39 +434,21 @@ export default {
} else {
sortColumns.value.set(prop, order);
}
- queryModel.value.orderBy = Array.from(sortColumns.value)
+ queryModel.value.sorting = Array.from(sortColumns.value)
.map((o) => capitalize(o[0]) + (o[1] === "ascending" ? "" : ` DESC`))
.join(",");
await load();
};
const showColumn = (item, prop) => {
- return (
- item.type !== "object" &&
- item.type !== "array" &&
- !item.hidden &&
- columns.value.findIndex((o) => o.name === prop && o.checked) >= 0
- );
+ return columns.value.some((o) => o.name === prop && o.checked);
};
-
const handleSelectionChange = (rows) => (selectedRows.value = rows);
const load = async () => {
tableLoading.value = true;
try {
const url = config.query.url;
const method = config.query.method;
- //
- queryModel.value = schemaToModel(config.query.schema);
- queryModel.value.maxResultCount = pageModel.pageSize;
- queryModel.value.skipCount = (pageModel.pageIndex - 1) * pageModel.pageSize;
- //
- const postData = JSON.parse(JSON.stringify(queryModel.value));
- postData.filters = queryList.value.filter((o) => o.property && o.value);
- if (postData.items) {
- delete postData["items"];
- }
- if (postData.query?.id) {
- delete postData.query["id"];
- }
+ const postData = buildQuery();
const listData = (await request(url, postData, { method })).data;
const items = listData.items;
if (tableSchema.value.isTree) {
@@ -462,8 +469,7 @@ export default {
const click = async (item, rows) => {
editFormloading.value = true;
editFormMode.value = item.path ?? item;
- context.emit("command", item, rows);
- if (item.path === "index") {
+ if (item.path === "query") {
//list
await load();
} else if (item.path === "details") {
@@ -485,13 +491,39 @@ export default {
editFormTitle.value = `${t(item.path)}${config.edit.schema.title}`;
dialogVisible.value = true;
} else if (item.path === "delete") {
+ if (!rows.length) {
+ return;
+ }
//delete
+ const url = format(config.edit.deleteUrl, rows[0].id);
if (item.meta.isTop) {
// 批量删除
- return;
+ try {
+ await ElMessageBox.confirm("删除", "提示", {
+ type: "warning",
+ message: format("确认删除选中的%s行数据吗?", rows.length),
+ });
+ const response = await request(
+ url,
+ rows.map((o) => o.id),
+ { method: config.edit.deleteMethod }
+ );
+ if (!response.errors) {
+ ElMessage({
+ type: "info",
+ message: "操作完毕",
+ });
+ }
+ } catch (error) {
+ if (error === "cancel") {
+ ElMessage({
+ type: "info",
+ message: "删除取消",
+ });
+ }
+ }
} else {
// 单个删除
- const url = format(config.edit.deleteUrl, rows[0].id);
try {
await ElMessageBox.confirm("删除", "提示", {
type: "warning",
@@ -511,7 +543,6 @@ export default {
}
}
}
- const url = `${baseUrl}/${item.path}`;
// await post(
// url,
// rows.map((o) => o.id)
@@ -519,17 +550,47 @@ export default {
await load();
} else if (item.path === "export") {
//export
- editFormTitle.value = `${t(item.path)}${querySchema.value?.title}`;
- dialogVisible.value = true;
+ if ((item.pattern = "paged")) {
+ const url = config.edit.exportUrl;
+ const method = config.edit.exportMethod;
+ const postData = buildQuery();
+ const response = await request(url, postData, { method });
+ if (!response.errors) {
+ window.open(getUrl(`settleaccount/getblobfile/download/${response.data}`));
+ }
+ } else {
+ editFormTitle.value = `${t(item.path)}${querySchema.value?.title}`;
+ dialogVisible.value = true;
+ }
} else if (item.path === "import") {
//import
- const url = `${baseUrl}/${item.path}`;
- editFormTitle.value = `${t(item.path)}${querySchema.value?.title}`;
- fileList.value = [];
- dialogVisible.value = true;
+ try {
+ editFormloading.value = true;
+ editFormTitle.value = `${t(item.path)}${config.query.schema.title}`;
+ fileList.value = [];
+ dialogVisible.value = true;
+ versions.value = (
+ await request("settleaccount/centralized-control/get-all", null, { method: "POST" })
+ ).data.items.map((o) => ({
+ value: o.version,
+ label: o.version,
+ }));
+ factories.value = (
+ await request("settleaccount/code-setting/get-all", null, { method: "POST" })
+ ).data.items.map((o) => ({
+ value: o.project,
+ label: o.project,
+ }));
+ } catch (e) {
+ console.log(e);
+ } finally {
+ editFormloading.value = false;
+ }
} else if (item === "filter") {
editFormTitle.value = t("自定义查询");
dialogVisible.value = true;
+ } else {
+ context.emit("command", item, rows, load);
}
editFormloading.value = false;
};
@@ -545,10 +606,10 @@ export default {
url = format(url, editFormModel.value.id);
}
const method = editFormMode.value === "create" ? config.edit.createMethod : config.edit.updateMethod;
- const result = await request(url, editFormModel.value, { method });
- if (result.errors) {
- model.errors = result.errors; //??
- } else {
+ const response = await request(url, editFormModel.value, { method });
+ if (!response.errors) {
+ ElMessageBox.alert(`错误:${response.errors?.error?.message}`, `代码:${response.errors?.error?.code}`);
+ //model.errors = response.errors; //??
await load();
editFormMode.value = null;
dialogVisible.value = false;
@@ -564,7 +625,7 @@ export default {
editFormMode.value = null;
} else if (editFormMode.value === "export") {
const postData = JSON.parse(JSON.stringify(queryModel.value));
- postData.filters = queryList.value.filter((o) => o.property && o.value);
+ postData.filters = filterList.value.filter((o) => o.property && o.value);
delete postData.query["items"];
delete postData.query["id"];
const url = `${baseUrl}/${editFormMode.value}?${qs.stringify(exportModel)}`;
@@ -573,13 +634,14 @@ export default {
dialogVisible.value = false;
} else if (editFormMode.value === "import") {
editFormloading.value = true;
- const url = `${baseUrl}/${editFormMode.value}`;
+ const url = config.edit.importUrl;
const formData = new FormData();
- formData.append("partial", importModel.partial);
- formData.append("replace", importModel.replace);
- formData.append("file", fileList.value[0]?.raw);
- console.log(uploadRef.value);
- const response = await post(url, formData);
+ formData.append("version", importModel.version);
+ formData.append("factory", importModel.factory);
+ for (let i = 0; i < fileList.value.length; i++) {
+ formData.append(`files`, fileList.value[i].raw);
+ }
+ await post(url, formData);
editFormloading.value = false;
dialogVisible.value = false;
await load();
@@ -610,17 +672,8 @@ export default {
subDrawer.value = true;
}
};
- const pushQueryList = () => {
- queryList.value.push({
- property: "",
- operator: "{0}=@0",
- value: "",
- logic: "and",
- });
- };
- const download = (response) => {
- const downloadUrl = window.URL.createObjectURL(response.data);
- const filename = response.filename;
+ const download = (url, filename) => {
+ const downloadUrl = window.URL.createObjectURL(url);
let link = document.createElement("a");
link.href = downloadUrl;
link.download = filename;
@@ -630,7 +683,7 @@ export default {
const getImportTemplate = async () => {
const url = `${baseUrl}/${editFormMode.value}`;
const response = await get(url);
- download(response);
+ download(url, response.filename);
};
const handleChange = (uploadFile, uploadFiles) => {
fileList.value = uploadFiles;
@@ -642,6 +695,87 @@ export default {
}
return false;
};
+ const pushfilterList = () => {
+ filterList.value.push({
+ logic: "and",
+ column: "",
+ action: "equal",
+ value: null,
+ });
+ };
+ const logic = [
+ { value: "and", label: "且" },
+ { value: "or", label: "或" },
+ ];
+ const operators = [
+ {
+ value: "equal",
+ label: "等于",
+ },
+ {
+ value: "notEqual",
+ label: "不等于",
+ },
+ {
+ value: "biggerThan",
+ label: "大于",
+ },
+ {
+ value: "smallThan",
+ label: "小于",
+ },
+ {
+ value: "biggerThanOrEqual",
+ label: "大于等于",
+ },
+ {
+ value: "smallThanOrEqual",
+ label: "小于等于",
+ },
+ {
+ value: "like",
+ label: "类似于",
+ },
+ {
+ value: "notLike",
+ label: "不类似于",
+ },
+ {
+ value: "in",
+ label: "包含于",
+ },
+ {
+ value: "notIn",
+ label: "不包含于",
+ },
+ ];
+ const getOperators = (schema) => {
+ const values = ["equal", "notEqual"];
+ if (schema.type === "string") {
+ values.push("like", "notLike");
+ if (schema.input && ["year", "month", "date", "datetime"].includes(schema.input)) {
+ values.push("biggerThan", "smallThan", "biggerThanOrEqual", "smallThanOrEqual");
+ }
+ } else if (schema.type === "boolean") {
+ } else {
+ values.push("biggerThan", "smallThan", "biggerThanOrEqual", "smallThanOrEqual");
+ }
+ return operators.filter((o) => values.includes(o.value));
+ };
+ function buildQuery() {
+ queryModel.value.maxResultCount = pageModel.pageSize;
+ queryModel.value.skipCount = (pageModel.pageIndex - 1) * pageModel.pageSize;
+ //
+ const postData = JSON.parse(JSON.stringify(queryModel.value));
+ postData.filters = filterList.value.filter((o) => o.column && o.action && (o.value || o.value === false));
+ if (postData.items) {
+ delete postData["items"];
+ }
+ if (postData.query?.id) {
+ delete postData.query["id"];
+ }
+ return postData;
+ }
onMounted(async () => {
if (route.meta.children?.length) {
for (const item of route.meta.children) {
@@ -650,7 +784,11 @@ export default {
}
}
}
- pushQueryList();
+ //
+ queryModel.value = schemaToModel(config.query.schema);
+ getSortModel(queryModel.value);
+ filterList.value = queryModel.value?.filters ?? [];
+ //pushfilterList();
// if (!querySchema.value) {
// const vm = (await get(indexUrl)).data;
// querySchema.value = vm.schema.properties.query;
@@ -662,9 +800,6 @@ export default {
// getSortModel(data.value);
// getColumns(vm.schema.properties.query);
// }
- if (!config) {
- //
- }
getColumns(config.table.schema);
if (props.query) {
Object.assign(queryModel.value.query, props.query);
@@ -673,7 +808,9 @@ export default {
// getColumns(vm.schema.properties.query);
await load();
});
+ context.expose({ load });
return {
+ load,
config,
queryModel,
pageModel,
@@ -689,7 +826,7 @@ export default {
dialogVisible,
selectedRows,
querySchema,
- queryList,
+ filterList,
tableSchema,
buttons,
tableData,
@@ -713,10 +850,13 @@ export default {
submit,
showList,
subListQuery,
- pushQueryList,
fileList,
handleChange,
getButtonDisabled,
+ factories,
+ versions,
+ pushfilterList,
+ getOperators,
};
},
};
diff --git a/code/WebApp/vanilla/models/centralized-control.js b/code/WebApp/vanilla/models/centralized-control.js
new file mode 100644
index 00000000..5e6a6dd2
--- /dev/null
+++ b/code/WebApp/vanilla/models/centralized-control.js
@@ -0,0 +1,137 @@
+const schema = {
+ title: "期间设置",
+ type: "object",
+ properties: {
+ year: {
+ title: "年度",
+ type: "string",
+ hidden: true,
+ showForList: true,
+ rules: [
+ {
+ required: true,
+ },
+ ],
+ },
+ period: {
+ title: "期间",
+ type: "string",
+ hidden: true,
+ showForList: true,
+ rules: [
+ {
+ required: true,
+ },
+ ],
+ },
+ version: {
+ title: "版本",
+ type: "string",
+ input: "month",
+ format: "YYYYMM",
+ showForList: true,
+ watch: "(model,value)=>{model.year=value.substr(0,4);model.period=value.substr(4,2);}",
+ rules: [
+ {
+ required: true,
+ trigger: "blur",
+ },
+ ],
+ },
+ state: {
+ title: "状态",
+ type: "boolean",
+ showForList: true,
+ default: true,
+ rules: [
+ {
+ required: true,
+ },
+ ],
+ },
+ },
+};
+
+const baseUrl = "settleaccount/centralized-control";
+const queryUrl = `${baseUrl}/get-list`;
+const detailsUrl = `${baseUrl}/get/%s`;
+const createUrl = `${baseUrl}/create`;
+const updateUrl = `${baseUrl}/update/%s`;
+const deleteUrl = `${baseUrl}/delete-list`;
+const queryMethod = "POST";
+const detailsMethod = "POST";
+const createMethod = "POST";
+const updateMethod = "POST";
+const deleteMethod = "POST";
+
+export default function () {
+ return {
+ baseUrl,
+ query: {
+ url: queryUrl,
+ method: queryMethod,
+ hasFilter: true,
+ schema: {
+ title: "通用代码",
+ type: "object",
+ properties: {
+ filters: {
+ type: "array",
+ hidden: true,
+ items: {
+ type: "object",
+ properties: {
+ logic: {
+ type: "int",
+ },
+ column: {
+ type: "string",
+ },
+ action: {
+ type: "int",
+ },
+ value: {
+ type: "string",
+ },
+ },
+ },
+ default: [
+ {
+ logic: "and",
+ column: "year",
+ action: "like",
+ value: null,
+ readOnly: true,
+ },
+ ],
+ },
+ skipCount: {
+ hidden: true,
+ default: 0,
+ },
+ maxResultCount: {
+ hidden: true,
+ default: 10,
+ },
+ sorting: {
+ hidden: true,
+ },
+ },
+ },
+ },
+ table: {
+ schema: schema,
+ },
+ edit: {
+ detailsUrl,
+ createUrl,
+ updateUrl,
+ deleteUrl,
+ detailsMethod,
+ createMethod,
+ updateMethod,
+ deleteMethod,
+ schema: schema,
+ },
+ };
+}
diff --git a/code/WebApp/vanilla/models/code-setting.js b/code/WebApp/vanilla/models/code-setting.js
index 1951c934..a6375733 100644
--- a/code/WebApp/vanilla/models/code-setting.js
+++ b/code/WebApp/vanilla/models/code-setting.js
@@ -27,11 +27,13 @@ const schema = {
description: {
title: "描述",
type: "string",
+ input: "textarea",
showForList: true,
rules: [
{
required: true,
},
+ { max: 60 },
],
},
},
@@ -39,37 +41,34 @@ const schema = {
const baseUrl = "settleaccount/code-setting";
const queryUrl = `${baseUrl}/get-list`;
-const detailsUrl = `${baseUrl}/GET/%s`;
-const createUrl = `${baseUrl}/Create`;
-const updateUrl = `${baseUrl}/Update/%s`;
-const deleteUrl = `${baseUrl}/DeleteList`;
+const detailsUrl = `${baseUrl}/get/%s`;
+const createUrl = `${baseUrl}/create`;
+const updateUrl = `${baseUrl}/update/%s`;
+const deleteUrl = `${baseUrl}/delete-list`;
+const importUrl = `${baseUrl}/code-setting-upload-excel-import`;
+const exportUrl = `${baseUrl}/export`;
const queryMethod = "POST";
const detailsMethod = "POST";
const createMethod = "POST";
const updateMethod = "POST";
const deleteMethod = "POST";
+const importMethod = "POST";
+const exportMethod = "POST";
export default function () {
return {
query: {
url: queryUrl,
method: queryMethod,
+ hasFilter: true,
schema: {
title: "通用代码",
type: "object",
properties: {
- project: {
- type: "string",
- },
- value: {
- type: "string",
- },
- description: {
- type: "string",
- },
filters: {
title: "项目",
type: "array",
+ hidden: true,
items: {
type: "object",
properties: {
@@ -87,6 +86,15 @@ export default function () {
},
},
},
+ default: [
+ {
+ logic: "and",
+ column: "project",
+ action: "like",
+ value: null,
+ readOnly: true,
+ },
+ ],
},
skipCount: {
hidden: true,
@@ -110,10 +118,14 @@ export default function () {
createUrl,
updateUrl,
deleteUrl,
+ importUrl,
+ exportUrl,
detailsMethod,
createMethod,
updateMethod,
deleteMethod,
+ importMethod,
+ exportMethod,
schema: schema,
},
};
diff --git a/code/WebApp/vanilla/request/index.js b/code/WebApp/vanilla/request/index.js
index dc9e51e3..a3e4efa6 100644
--- a/code/WebApp/vanilla/request/index.js
+++ b/code/WebApp/vanilla/request/index.js
@@ -3,6 +3,7 @@ import { isLogin } from "../api/user.js";
import { useAppStore } from "../store/index.js";
import { getFileName } from "../utils/index.js";
import settings from "../config/settings.js";
+import { ElMessageBox } from "element-plus";
// const requestSettings = {
// baseURL: "/api",
@@ -47,16 +48,21 @@ const getResult = async (response) => {
status: response.status,
message: messages.get(response.status),
};
- if (response.status == 200) {
+ if (response.status === 200 || response.status === 204) {
const contentType = response.headers.get("Content-Type");
if (contentType.indexOf("application/json") > -1) {
result.data = await response.json();
+ } else if (contentType.indexOf("text/plain") > -1) {
+ result.data = await response.text();
} else if (contentType === "application/vnd.openxmlformats-officedocument.spreadsheetml.sheet") {
result.data = await response.blob();
result.filename = getFileName(response.headers.get("Content-Disposition"));
}
- } else if (response.status === 400 || response.status === 500) {
+ } /*if (response.status === 400 || response.status === 500) */ else {
result.errors = await response.json();
+ if (result.errors) {
+ ElMessageBox.alert(`错误:${result.errors?.error?.message}`, `代码:${result.errors?.error?.code}`);
+ }
}
return result;
};
@@ -141,4 +147,4 @@ async function request(url, data, options, withoutToken = false) {
}
export default request;
-export { get, post };
+export { get, post, getUrl };
diff --git a/code/WebApp/vanilla/router/routes.js b/code/WebApp/vanilla/router/routes.js
index 3ed7a755..6a2777dc 100644
--- a/code/WebApp/vanilla/router/routes.js
+++ b/code/WebApp/vanilla/router/routes.js
@@ -25,6 +25,15 @@ export default [
permission: "AbpIdentity.Users",
},
children: [
+ {
+ path: "query",
+ meta: {
+ type: "button",
+ title: "查询",
+ icon: "file",
+ isTop: true,
+ },
+ },
{
path: "create",
meta: {
@@ -109,12 +118,115 @@ export default [
// },
// ],
// },
+ {
+ path: "centralized-control",
+ meta: {
+ type: "page",
+ title: "期间设置",
+ icon: "file",
+ children: [
+ {
+ path: "query",
+ meta: {
+ type: "button",
+ title: "查询",
+ icon: "file",
+ isTop: true,
+ },
+ },
+ {
+ path: "create",
+ meta: {
+ type: "button",
+ title: "新建",
+ icon: "file",
+ isTop: true,
+ },
+ },
+ {
+ path: "open-version",
+ meta: {
+ type: "button",
+ title: "启用",
+ icon: "file",
+ isTop: true,
+ },
+ },
+ {
+ path: "closed-version",
+ meta: {
+ type: "button",
+ title: "停用",
+ icon: "file",
+ isTop: true,
+ },
+ },
+ {
+ path: "delete",
+ meta: {
+ type: "button",
+ title: "删除",
+ icon: "file",
+ isTop: true,
+ },
+ },
+ ],
+ },
+ },
{
path: "code-setting",
meta: {
type: "page",
title: "通用代码",
icon: "file",
+ children: [
+ {
+ path: "query",
+ meta: {
+ type: "button",
+ title: "查询",
+ icon: "file",
+ isTop: true,
+ },
+ },
+ {
+ path: "create",
+ meta: {
+ type: "button",
+ title: "新建",
+ icon: "file",
+ isTop: true,
+ },
+ },
+ {
+ path: "delete",
+ meta: {
+ type: "button",
+ title: "删除",
+ icon: "file",
+ isTop: true,
+ },
+ },
+ {
+ path: "import",
+ meta: {
+ type: "button",
+ title: "导入",
+ icon: "file",
+ isTop: true,
+ },
+ },
+ {
+ path: "export",
+ meta: {
+ type: "button",
+ title: "导出",
+ icon: "file",
+ isTop: true,
+ pattern: "paged",
+ },
+ },
+ ],
},
},
],
diff --git a/code/WebApp/vanilla/views/base-data/centralized-control.js b/code/WebApp/vanilla/views/base-data/centralized-control.js
new file mode 100644
index 00000000..d96b18c0
--- /dev/null
+++ b/code/WebApp/vanilla/views/base-data/centralized-control.js
@@ -0,0 +1,27 @@
+import html from "html";
+import { ref } from "vue";
+import request from "../../request/index.js";
+import AppList from "../../components/list/index.js";
+import useConfig from "../../models/centralized-control.js";
+
+export default {
+ components: { AppList },
+ template: html``,
+ setup(props, context) {
+ const listRef = ref(null);
+ const config = useConfig();
+ const onCommand = async (item, rows, load) => {
+ if (item.path === "open-version" || item.path === "closed-version") {
+ const url = `${config.baseUrl}/${item.path}`;
+ await request(
+ url,
+ rows.map((o) => o.id),
+ { method: "POST" }
+ );
+ console.log(context);
+ await load();
+ }
+ };
+ return { config, onCommand };
+ },
+};
diff --git a/code/WebApp/vanilla/views/base-data/code-setting.js b/code/WebApp/vanilla/views/base-data/code-setting.js
index bab632ca..d69aaabe 100644
--- a/code/WebApp/vanilla/views/base-data/code-setting.js
+++ b/code/WebApp/vanilla/views/base-data/code-setting.js
@@ -1,27 +1,14 @@
import AppList from "../../components/list/index.js";
import html from "html";
import useConfig from "../../models/code-setting.js";
-import request from "../../request/index.js";
-import { format } from "../../utils/index.js";
-import { ElMessage } from "element-plus";
export default {
components: { AppList },
template: html``,
setup() {
- // 变量定义
const config = useConfig();
- // 函数定义
const onCommand = async (item, rows) => {
console.log(item.path, item, rows);
- if (item.path === "%s/reset-password") {
- const url = format(item.path, rows[0].id);
- await request(`base/user/${url}`, null, { method: item.meta.method });
- ElMessage({
- type: "info",
- message: format("用户%s的密码已经成功重置为123456", rows[0].userName),
- });
- }
};
return { config, onCommand };
},
diff --git a/code/WebApp/vanilla/views/login.js b/code/WebApp/vanilla/views/login.js
index 0f1c2a05..a8d3c28a 100644
--- a/code/WebApp/vanilla/views/login.js
+++ b/code/WebApp/vanilla/views/login.js
@@ -20,7 +20,9 @@ export default {
- {{$t('login')}}
+
+ {{$t('login')}}
+
diff --git a/code/src/Modules/SettleAccount/src/SettleAccount.Application/Entities/BQ/PUB_SA_SERVICE.cs b/code/src/Modules/SettleAccount/src/SettleAccount.Application/Entities/BQ/PUB_SA_SERVICE.cs
index 2527a759..2d562ede 100644
--- a/code/src/Modules/SettleAccount/src/SettleAccount.Application/Entities/BQ/PUB_SA_SERVICE.cs
+++ b/code/src/Modules/SettleAccount/src/SettleAccount.Application/Entities/BQ/PUB_SA_SERVICE.cs
@@ -2,12 +2,14 @@
using Microsoft.AspNetCore.Http;
using Microsoft.AspNetCore.Mvc;
using NPOI.Util;
+using NUglify.Helpers;
using SettleAccount.Bases;
using SettleAccount.Domain.BQ;
using Shouldly;
using System;
using System.Collections.Generic;
using System.Linq;
+using System.Linq.Dynamic.Core;
using System.Threading.Tasks;
using Volo.Abp;
using Volo.Abp.Application.Dtos;
@@ -67,6 +69,9 @@ namespace Win.Sfs.SettleAccount.Entities.BQ
public PUB_SA_SERVICE(INormalEfCoreRepository repository,
INormalEfCoreRepository pubSaDetailRepository,
INormalEfCoreRepository priceListRepository,
+ INormalEfCoreRepository pubCanSaRepository,
+ INormalEfCoreRepository pubCanSaDetailRepository,
+ INormalEfCoreRepository pubNotSaDetailRepository,
IDistributedCache cache,
IExcelImportAppService excelImportService,
ISnowflakeIdGenerator snowflakeIdGenerator,
@@ -75,6 +80,9 @@ namespace Win.Sfs.SettleAccount.Entities.BQ
{
_repository = repository;
_pubSaDetailRepository = pubSaDetailRepository;
+ _pubCanSaRepository = pubCanSaRepository;
+ _pubCanSaDetailRepository = pubCanSaDetailRepository;
+ _pubNotSaDetailRepository = pubNotSaDetailRepository;
_priceListRepository = priceListRepository;
}
@@ -89,9 +97,14 @@ namespace Win.Sfs.SettleAccount.Entities.BQ
[HttpPost]
public async Task ZGJImportAsync([FromForm] IFormFileCollection files)
{
+ //类型(直供件)
+ EnumBusinessType businessType = EnumBusinessType.ZhiGongJian;
ExportImporter _exportImporter = new ExportImporter();
var result = await _exportImporter.UploadExcelImport(files, _excelImportService);
- var _ls = ObjectMapper.Map, List>(result);
+ var importPubSaDetails = ObjectMapper.Map, List>(result);
+
+ //结算分组号
+ var pubSaGroupNums = importPubSaDetails.Select(t => t.GroupNum).Distinct();
//销售价格
var priceListEntitys = await _priceListRepository.GetAllAsync();
@@ -103,63 +116,70 @@ namespace Win.Sfs.SettleAccount.Entities.BQ
State = "1"
};
- _ls.ForEach(s =>
+ importPubSaDetails.ForEach(importPubSaDetail =>
{
- if (s.LU != null)
+ List luList = importPubSaDetail.LU.Split(" ").ToList();
+ if (luList.Count > 1)
{
- List luList = s.LU.Split(" ").ToList();
- s.LU = luList[0].Replace(" ", "");
- if (luList.Count > 1)
- {
- luList.RemoveAt(0);
- luList.Reverse();
- var luAssemble = luList.Select(t => t.Replace(" ", ""));
- s.LU += luAssemble.Aggregate(" ", (current, index) => current + index);
- }
+ importPubSaDetail.LU = luList[0].Replace(" ", "");
+ luList.RemoveAt(0);
+ var luAssemble = luList.Select(t => t.Replace(" ", ""));
+ importPubSaDetail.LU += luAssemble.Aggregate(" ", (current, index) => current + index);
}
- s.LU = s.LU;
- s.BillNum = pubSaBillNum;
- s.Site = "XX工厂";
- s.KeyCode = s.LU + s.PN;
+ importPubSaDetail.BillNum = pubSaBillNum;
+ importPubSaDetail.Site = "XX工厂";
+ importPubSaDetail.KeyCode = importPubSaDetail.PN + importPubSaDetail.LU;
//根据物料号、结算日期获取价格
- var priceListEntity = priceListEntitys.Find(t => t.LU == s.LU && s.SettleDate > t.BeginTime && s.SettleDate < t.EndTime);
- s.Price = priceListEntity?.Price ?? 0;
+ var priceListEntity = priceListEntitys.Find(t => t.LU == importPubSaDetail.LU && importPubSaDetail.SettleDate > t.BeginTime && importPubSaDetail.SettleDate < t.EndTime);
+ importPubSaDetail.Price = priceListEntity?.Price ?? 0;
});
//可结算
- var pubCanSaBillNum = OrderNumberGenerator.GenerateOrderNumber("INV");
+ var pubCanSaBillNum = OrderNumberGenerator.GenerateOrderNumber("C");
var pubCanSa = new PUB_CAN_SA()
{
BillNum = pubCanSaBillNum,
SettleBillNum = pubSaBillNum,
State = SettleBillState.未结状态,
- BusinessType = EnumBusinessType.ZhiGongJian
+ BusinessType = businessType
};
//不可结算 结算分组号码(根据价格区分结算、不可结算)
- var pubNotSaGroupNum = _ls.FindAll(t => t.Price != 0).Select(t => t.GroupNum).Distinct();
- var pubSaDetailsCanSe = _ls.FindAll(t => pubNotSaGroupNum.Contains(t.GroupNum) == false);
- var pubSaDetailsNotCanSe = _ls.FindAll(t => pubNotSaGroupNum.Contains(t.GroupNum) == true);
+ var pubNotSaGroupNums = importPubSaDetails.FindAll(t => t.Price == default(decimal)).Select(t => t.GroupNum).Distinct();
+ var pubSaDetailsCanSes = importPubSaDetails.FindAll(t => pubNotSaGroupNums.Contains(t.GroupNum) == false);
+ var pubSaDetailsNotCanSes = importPubSaDetails.FindAll(t => pubNotSaGroupNums.Contains(t.GroupNum) == true);
//可结算
- var pubCanSaDetails = ObjectMapper.Map, List>(pubSaDetailsCanSe);
+ var pubCanSaDetails = ObjectMapper.Map, List>(pubSaDetailsCanSes);
//不可结算
- var pubNotSaDetails = ObjectMapper.Map, List>(pubSaDetailsNotCanSe);
+ var pubNotSaDetails = ObjectMapper.Map, List>(pubSaDetailsNotCanSes);
//添加入库
await _repository.InsertAsync(pubSa);
- await _pubSaDetailRepository.InsertManyAsync(_ls);
+ await _pubSaDetailRepository.InsertManyAsync(importPubSaDetails);
if (pubCanSaDetails.Count > 0)
{
pubCanSa.InvGroupNum = pubCanSaDetails.Count.ToString();
+ pubCanSaDetails.ForEach(pubCanSaDetail =>
+ {
+ pubCanSaDetail.BillNum = pubCanSaDetail.InvGroupNum = pubCanSaBillNum;
+ pubCanSaDetail.BusinessType = businessType;
+ });
+
await _pubCanSaRepository.InsertAsync(pubCanSa);
await _pubCanSaDetailRepository.InsertManyAsync(pubCanSaDetails);
}
if (pubNotSaDetails.Count > 0)
{
+ pubNotSaDetails.ForEach(pubNotSaDetail =>
+ {
+ pubNotSaDetail.InvGroupNum = pubCanSaBillNum;
+ pubNotSaDetail.BusinessType = businessType;
+ });
+
await _pubNotSaDetailRepository.InsertManyAsync(pubNotSaDetails);
}
return ApplicationConsts.SuccessStr;
@@ -206,30 +226,31 @@ namespace Win.Sfs.SettleAccount.Entities.BQ
//结算主表
PUB_SA pubSaDelEntity;
//结算明细
- IEnumerable pubSaDetailDelEntitys = default;
+ List pubSaDetailDelEntitys;
//可结算主表
- IEnumerable pubCanSaDelEntitys = default;
+ List pubCanSaDelEntitys;
//可结算明细
- IEnumerable pubCanSaDetailDelEntitys = default;
+ List pubCanSaDetailDelEntitys;
//不可结算
- IEnumerable pubNotSaDetailDelEntitys = default;
+ List pubNotSaDetailDelEntitys;
pubSaDelEntity = await _repository.FindAsync(id);
- if (pubSaDelEntity != null) return;
+ if (pubSaDelEntity == null) return;
//结算单据
string pubSaBillNum = pubSaDelEntity.BillNum;
- pubCanSaDelEntitys = _pubCanSaRepository.Where(t => t.SettleBillNum == pubSaBillNum);
+ pubCanSaDelEntitys = await _pubCanSaRepository.GetListAsync(t => t.SettleBillNum == pubSaBillNum);
//验证可结算主表状态
if (pubCanSaDelEntitys.Any(t => t.State != SettleBillState.未结状态))
{
throw new UserFriendlyException($"该单据可结算单状态无法删除!");
}
- pubCanSaDetailDelEntitys = _pubCanSaDetailRepository.Where(t => t.SettleBillNum == pubSaBillNum);
- pubNotSaDetailDelEntitys = _pubNotSaDetailRepository.Where(t => t.SettleBillNum == pubSaBillNum);
+ pubSaDetailDelEntitys = await _pubSaDetailRepository.GetListAsync(t => t.BillNum == pubSaBillNum);
+ pubCanSaDetailDelEntitys = await _pubCanSaDetailRepository.GetListAsync(t => t.SettleBillNum == pubSaBillNum);
+ pubNotSaDetailDelEntitys = await _pubNotSaDetailRepository.GetListAsync(t => t.SettleBillNum == pubSaBillNum);
//删除
await _repository.DeleteAsync(pubSaDelEntity);
diff --git a/code/src/Modules/SettleAccount/src/SettleAccount.Application/SettleAccountApplicationAutoMapperProfile.cs b/code/src/Modules/SettleAccount/src/SettleAccount.Application/SettleAccountApplicationAutoMapperProfile.cs
index 7cb17e0f..05b4780c 100644
--- a/code/src/Modules/SettleAccount/src/SettleAccount.Application/SettleAccountApplicationAutoMapperProfile.cs
+++ b/code/src/Modules/SettleAccount/src/SettleAccount.Application/SettleAccountApplicationAutoMapperProfile.cs
@@ -973,6 +973,11 @@ namespace Win.Sfs.SettleAccount
{
CreateMap();
+ CreateMap()
+ .ForMember(x => x.SettleBillNum, y => y.MapFrom(d => d.BillNum));
+ CreateMap()
+ .ForMember(x => x.SettleBillNum, y => y.MapFrom(d => d.BillNum));
+
CreateMap();
}
diff --git a/code/src/Modules/SettleAccount/src/SettleAccount.EntityFrameworkCore/Repository/SettleAccountEfCoreRepository.cs b/code/src/Modules/SettleAccount/src/SettleAccount.EntityFrameworkCore/Repository/SettleAccountEfCoreRepository.cs
index 6a3edbcf..4256a044 100644
--- a/code/src/Modules/SettleAccount/src/SettleAccount.EntityFrameworkCore/Repository/SettleAccountEfCoreRepository.cs
+++ b/code/src/Modules/SettleAccount/src/SettleAccount.EntityFrameworkCore/Repository/SettleAccountEfCoreRepository.cs
@@ -1,6 +1,7 @@
using System;
using System.Collections.Generic;
using System.Linq;
+using System.Linq.Dynamic.Core;
using System.Linq.Expressions;
using System.Text;
using System.Threading;
@@ -92,45 +93,46 @@ namespace Win.Sfs.SettleAccount.Repository
protected static IQueryable GetSortingQueryable(IQueryable entities, string sorting)
{
- if (string.IsNullOrEmpty(sorting))
- {
- entities = entities.OrderByDescending("Id");
- }
- else
- {
+ return string.IsNullOrEmpty(sorting)?entities:DynamicQueryableExtensions.OrderBy(entities, sorting);
+ //if (string.IsNullOrEmpty(sorting))
+ //{
+ // entities = entities.OrderByDescending("Id");
+ //}
+ //else
+ //{
- var sortParams = sorting?.Split(' ');
- var sortName = sortParams[0];
+ // var sortParams = sorting?.Split(' ');
+ // var sortName = sortParams[0];
- Type t = typeof(TEntity);
- var _first=t.GetProperties().Where(p => p.Name.ToUpper() == sortName.ToUpper()).FirstOrDefault();
- if (_first != null)
- {
- sortName = _first.Name;
- }
+ // Type t = typeof(TEntity);
+ // var _first=t.GetProperties().Where(p => p.Name.ToUpper() == sortName.ToUpper()).FirstOrDefault();
+ // if (_first != null)
+ // {
+ // sortName = _first.Name;
+ // }
- bool isDesc;
- if (sortParams.Length > 1)
- {
- var sortDirection = sortParams[1];
- isDesc = sortDirection.ToUpper().Contains("DESC")?true:false;
- }
- else
- {
- isDesc = true;
- }
+ // bool isDesc;
+ // if (sortParams.Length > 1)
+ // {
+ // var sortDirection = sortParams[1];
+ // isDesc = sortDirection.ToUpper().Contains("DESC")?true:false;
+ // }
+ // else
+ // {
+ // isDesc = true;
+ // }
- entities = isDesc ? entities.OrderByDescending(sortName) : entities.OrderBy(sortName);
- }
+ // entities = isDesc ? entities.OrderByDescending(sortName) : entities.OrderBy(sortName);
+ //}
- return entities;
+ //return entities;
}
diff --git a/docs/demo/src/WTA.Application/Identity/Data/IdentityDbSeed.cs b/docs/demo/src/WTA.Application/Identity/Data/IdentityDbSeed.cs
index 09ed0584..d6a385e9 100644
--- a/docs/demo/src/WTA.Application/Identity/Data/IdentityDbSeed.cs
+++ b/docs/demo/src/WTA.Application/Identity/Data/IdentityDbSeed.cs
@@ -151,8 +151,8 @@ public class IdentityDbSeed : IDbSeed
context.Set().Add(new HBPO_SA { Version = "测试数据", BillNum = "456", DNBillNum = "测试数据", State = "测试数据", RecordCount = "测试数据" });
context.Set().Add(new HBPO_SA_DETAIL { InvGroupNum = "测试数据", KeyCode = "测试数据", Version = "测试数据", BillNum = "123", LU = "测试数据", PN = "测试数据", Site = "测试数据", SettleDate = new DateTime(), GroupNum = "测试数据" });
context.Set().Add(new HBPO_SA_DETAIL { InvGroupNum = "测试数据", KeyCode = "测试数据", Version = "测试数据", BillNum = "456", LU = "测试数据", PN = "测试数据", Site = "测试数据", SettleDate = new DateTime(), GroupNum = "测试数据" });
- context.Set().Add(new BBAC_SA { Version = "测试数据", BillNum = "123", DNBillNum = "测试数据", State = "测试数据", RecordCount = "测试数据" });
- context.Set().Add(new BBAC_SA { Version = "测试数据", BillNum = "456", DNBillNum = "测试数据", State = "测试数据", RecordCount = "测试数据" });
+ context.Set().Add(new BBAC_SA { Version = "测试数据", BillNum = "123", State = "测试数据", RecordCount = "测试数据" });
+ context.Set().Add(new BBAC_SA { Version = "测试数据", BillNum = "456", State = "测试数据", RecordCount = "测试数据" });
context.Set().Add(new BBAC_SA_DETAIL { InvGroupNum = "测试数据", KeyCode = "测试数据", Version = "测试数据", BillNum = "123", LU = "测试数据", PN = "测试数据", Site = "测试数据", SettleDate = new DateTime(), GroupNum = "测试数据", Category = "测试数据", IsReturn = "测试数据" });
context.Set().Add(new BBAC_SA_DETAIL { InvGroupNum = "测试数据", KeyCode = "测试数据", Version = "测试数据", BillNum = "456", LU = "测试数据", PN = "测试数据", Site = "测试数据", SettleDate = new DateTime(), GroupNum = "测试数据", Category = "测试数据", IsReturn = "测试数据" });
context.Set().Add(new HBPO_CAN_SA { SettleBillNum = "测试数据", Version = "测试数据", BillNum = "123", State = "测试数据", InvGroupNum = "测试数据" });
@@ -161,8 +161,8 @@ public class IdentityDbSeed : IDbSeed
context.Set().Add(new HBPO_CAN_SA_DETAIL { SettleBillNum = "测试数据", InvGroupNum = "测试数据", KeyCode = "测试数据", Version = "测试数据", BillNum = "456", LU = "测试数据", PN = "测试数据", Site = "测试数据", SettleDate = new DateTime(), GroupNum = "测试数据" });
context.Set().Add(new BBAC_CAN_SA { SettleBillNum = "测试数据", Version = "测试数据", BillNum = "123", State = "测试数据", InvGroupNum = "测试数据" });
context.Set().Add(new BBAC_CAN_SA { SettleBillNum = "测试数据", Version = "测试数据", BillNum = "456", State = "测试数据", InvGroupNum = "测试数据" });
- context.Set().Add(new BBAC_CAN_SA_DETAIL { SettleBillNum = "测试数据", InvGroupNum = "测试数据", KeyCode = "测试数据", Version = "测试数据", BillNum = "123", LU = "测试数据", PN = "测试数据", Site = "测试数据", SettleDate = new DateTime(), GroupNum = "测试数据", Category = "测试数据", IsReturn = "测试数据" });
- context.Set().Add(new BBAC_CAN_SA_DETAIL { SettleBillNum = "测试数据", InvGroupNum = "测试数据", KeyCode = "测试数据", Version = "测试数据", BillNum = "456", LU = "测试数据", PN = "测试数据", Site = "测试数据", SettleDate = new DateTime(), GroupNum = "测试数据", Category = "测试数据", IsReturn = "测试数据" });
+ context.Set().Add(new BBAC_CAN_SA_DETAIL { InvGroupNum = "测试数据", KeyCode = "测试数据", Version = "测试数据", BillNum = "123", LU = "测试数据", PN = "测试数据", Site = "测试数据", SettleDate = new DateTime(), GroupNum = "测试数据", Category = "测试数据", IsReturn = "测试数据" });
+ context.Set().Add(new BBAC_CAN_SA_DETAIL { InvGroupNum = "测试数据", KeyCode = "测试数据", Version = "测试数据", BillNum = "456", LU = "测试数据", PN = "测试数据", Site = "测试数据", SettleDate = new DateTime(), GroupNum = "测试数据", Category = "测试数据", IsReturn = "测试数据" });
context.Set().Add(new INVOICE_GRP { Version = "测试数据", RealnvBillNum = "测试数据", InvbillNum = "123", InvGroupNum = "分组号测试数据一", FileName = "测试数据", BusinessType = "测试数据" });
context.Set().Add(new INVOICE_GRP { Version = "测试数据", RealnvBillNum = "测试数据", InvbillNum = "456", InvGroupNum = "分组号测试数据二", FileName = "测试数据", BusinessType = "测试数据" });
context.Set().Add(new INVOICE_WAIT_DETAIL { InvbillNum = "待开票明细123", InvGroupNum = "待开票明细分组号测试数据一", Version = "测试数据", LU = "测试数据", BussiessType = "测试数据", Extend1 = "测试数据", Extend2 = "测试数据", Extend3 = "测试数据", Extend4 = "测试数据" });
diff --git a/docs/demo/src/WTA.Application/Identity/Entities/SystemManagement/BBAC_CAN_SA.cs b/docs/demo/src/WTA.Application/Identity/Entities/SystemManagement/BBAC_CAN_SA.cs
index 1d26e962..4b2e4138 100644
--- a/docs/demo/src/WTA.Application/Identity/Entities/SystemManagement/BBAC_CAN_SA.cs
+++ b/docs/demo/src/WTA.Application/Identity/Entities/SystemManagement/BBAC_CAN_SA.cs
@@ -53,8 +53,8 @@ public class BBAC_CAN_SA_DETAIL : BaseEntity
///
[Display(Name = "结算单号")]
public string BillNum { get; set; } = null!;
- [Display(Name = "关联结算单号")]
- public string SettleBillNum { get; set; } = null!;
+ //[Display(Name = "关联结算单号")]
+ //public string SettleBillNum { get; set; } = null!;
///
/// 对应字段Material
///
diff --git a/docs/demo/src/WTA.Application/Identity/Entities/SystemManagement/BBAC_SA.cs b/docs/demo/src/WTA.Application/Identity/Entities/SystemManagement/BBAC_SA.cs
index 0ea044d6..7f3aba68 100644
--- a/docs/demo/src/WTA.Application/Identity/Entities/SystemManagement/BBAC_SA.cs
+++ b/docs/demo/src/WTA.Application/Identity/Entities/SystemManagement/BBAC_SA.cs
@@ -18,8 +18,8 @@ public class BBAC_SA : BaseEntity
[OneToMany]
public string BillNum { get; set; } = null!;
- [Display(Name = "出库单号")]
- public string DNBillNum { get; set; } = null!;
+ //[Display(Name = "出库单号")]
+ //public string DNBillNum { get; set; } = null!;
///
/// 1、新建 2、已有出库3、已有扣减寄售库
diff --git a/docs/demo/src/WTA.Application/Identity/Entities/SystemManagement/BBAC_SE_SA_REPORT.cs b/docs/demo/src/WTA.Application/Identity/Entities/SystemManagement/BBAC_SE_SA_REPORT.cs
index 96746d9d..0080be5d 100644
--- a/docs/demo/src/WTA.Application/Identity/Entities/SystemManagement/BBAC_SE_SA_REPORT.cs
+++ b/docs/demo/src/WTA.Application/Identity/Entities/SystemManagement/BBAC_SE_SA_REPORT.cs
@@ -1,15 +1,16 @@
using System.ComponentModel.DataAnnotations;
-using WTA.Application.Identity.Entities.SystemManagement.Attribute;
using WTA.Shared.Attributes;
using WTA.Shared.Domain;
namespace WTA.Application.Identity.Entities.SystemManagement;
+
[Hidden]
[Display(Name = "BBAC发运数据与结算数据对比实体")]
public class BBAC_SE_SA_REPORT : BaseEntity
{
[Display(Name = "LU+ASN单号")]
public string KeyCode { get; set; } = null!;
+
///
/// 有结算无发货(无EDI数据)
///有结算无发货(有EDI数据)
@@ -26,39 +27,55 @@ public class BBAC_SE_SA_REPORT : BaseEntity
[Display(Name = "Wms发货单号")]
public string WmsBillNum { get; set; } = null!;
+
[Display(Name = "发货时间")]
public DateTime ShippingDate { get; set; }
+
[Display(Name = "生产码")]
public string PN { get; set; } = null!;
+
[Display(Name = "日顺序号")]
public string SeqNumber { get; set; } = null!;
+
[Display(Name = "PJIS日顺序号")]
public string PJISSeqNumber { get; set; } = null!;
+
[Display(Name = "物料号")]
public string MaterialNumber { get; set; } = null!;
+
[Display(Name = "物料描述")]
public string MaterialDes { get; set; } = null!;
+
[Display(Name = "零件号")]
public string LU { get; set; } = null!;
+
///
/// 结算数据中的过账日期
///
[Display(Name = "客户下线时间")]
public DateTime CustomerOfflineTime { get; set; }
+
[Display(Name = "小总成号")]
public string AssemblyCode { get; set; } = null!;
+
[Display(Name = "注塑码")]
public string InjectionCode { get; set; } = null!;
+
[Display(Name = "结算数量")]
public decimal SEQty { get; set; }
+
[Display(Name = "发货数量")]
public decimal WMSQty { get; set; }
+
[Display(Name = "EDI数量")]
public decimal EDIQty { get; set; }
+
[Display(Name = "匹配类型")]
public string MateType { get; set; } = null!;
+
[Display(Name = "定价")]
public decimal FixPrice { get; set; }
+
[Display(Name = "期间")]
public string Version { get; set; } = null!;
}
diff --git a/docs/demo/src/WTA.Application/Identity/Entities/SystemManagement/HBPO_SE_DETAIL.cs b/docs/demo/src/WTA.Application/Identity/Entities/SystemManagement/HBPO_SE_DETAIL.cs
index 2b543d5e..70ca2b0b 100644
--- a/docs/demo/src/WTA.Application/Identity/Entities/SystemManagement/HBPO_SE_DETAIL.cs
+++ b/docs/demo/src/WTA.Application/Identity/Entities/SystemManagement/HBPO_SE_DETAIL.cs
@@ -34,8 +34,8 @@ public class HBPO_SE_DETAIL : BaseEntity
[Display(Name = "发货数量")]
public decimal Qty { get; set; }
- [Display(Name = "订单时间")]
- public DateTime BeginDate { get; set; }
+ //[Display(Name = "订单时间")]
+ //public DateTime BeginDate { get; set; }
[Display(Name = "发货时间")]
public DateTime ShippingDate { get; set; }
diff --git a/docs/demo/src/WTA.Application/Identity/Entities/SystemManagement/HBPO_SE_EDI.cs b/docs/demo/src/WTA.Application/Identity/Entities/SystemManagement/HBPO_SE_EDI.cs
index 5cdcd2db..35da35e9 100644
--- a/docs/demo/src/WTA.Application/Identity/Entities/SystemManagement/HBPO_SE_EDI.cs
+++ b/docs/demo/src/WTA.Application/Identity/Entities/SystemManagement/HBPO_SE_EDI.cs
@@ -10,7 +10,7 @@ namespace WTA.Application.Identity.Entities.SystemManagement;
//HBPO的EDI数据
public class HBPO_SE_EDI : BaseEntity
{
- [Display(Name = "LU+生产码")]
+ [Display(Name = "LU+PN")]
public string KeyCode { get; set; } = null!;
[Display(Name = "期间")]
diff --git a/docs/demo/src/WTA.Application/Identity/Entities/SystemManagement/HBPO_SE_SA_REPORT.cs b/docs/demo/src/WTA.Application/Identity/Entities/SystemManagement/HBPO_SE_SA_REPORT.cs
index 7b42a76f..d573bd71 100644
--- a/docs/demo/src/WTA.Application/Identity/Entities/SystemManagement/HBPO_SE_SA_REPORT.cs
+++ b/docs/demo/src/WTA.Application/Identity/Entities/SystemManagement/HBPO_SE_SA_REPORT.cs
@@ -1,12 +1,11 @@
using System.ComponentModel.DataAnnotations;
-using WTA.Application.Identity.Entities.SystemManagement.Group;
using WTA.Shared.Attributes;
using WTA.Shared.Domain;
namespace WTA.Application.Identity.Entities.SystemManagement;
+
[Hidden]
[Display(Name = "HBPO发运数据与结算数据对比实体")]
-
public class HBPO_SE_SA_REPORT : BaseEntity
{
[Display(Name = "LU+ASN单号")]
diff --git a/docs/demo/src/WTA.Application/Identity/Entities/SystemManagement/PUB_CAN_SA.cs b/docs/demo/src/WTA.Application/Identity/Entities/SystemManagement/PUB_CAN_SA.cs
index 8910a9c5..cf63e4e8 100644
--- a/docs/demo/src/WTA.Application/Identity/Entities/SystemManagement/PUB_CAN_SA.cs
+++ b/docs/demo/src/WTA.Application/Identity/Entities/SystemManagement/PUB_CAN_SA.cs
@@ -52,8 +52,8 @@ public class PUB_CAN_SA_DETAIL : BaseEntity
[Display(Name = "结算单号")]
public string BillNum { get; set; } = null!;
- [Display(Name = "关联结算单号")]
- public string SettleBillNum { get; set; } = null!;
+ //[Display(Name = "关联结算单号")]
+ //public string SettleBillNum { get; set; } = null!;
///
/// 对应字段PartNumber
diff --git a/docs/demo/src/WTA.Application/Identity/Entities/SystemManagement/PUB_SE_DETAIL.cs b/docs/demo/src/WTA.Application/Identity/Entities/SystemManagement/PUB_SE_DETAIL.cs
index 69882f0e..a67b4a9e 100644
--- a/docs/demo/src/WTA.Application/Identity/Entities/SystemManagement/PUB_SE_DETAIL.cs
+++ b/docs/demo/src/WTA.Application/Identity/Entities/SystemManagement/PUB_SE_DETAIL.cs
@@ -1,14 +1,14 @@
using System.ComponentModel.DataAnnotations;
-using WTA.Application.Identity.Entities.SystemManagement.Group;
using WTA.Shared.Attributes;
using WTA.Shared.Domain;
namespace WTA.Application.Identity.Entities.SystemManagement;
+
[Hidden]
[Display(Name = "PUB发运数据")]
public class PUB_SE_DETAIL : BaseEntity
{
- [Display(Name = "LU+生产码")]
+ [Display(Name = "LU+(交付单号、ASN单号等)")]
public string KeyCode { get; set; } = null!;
[Display(Name = "期间")]
@@ -17,7 +17,7 @@ public class PUB_SE_DETAIL : BaseEntity
[Display(Name = "零件号")]
public string LU { get; set; } = null!;
- [Display(Name = "ASN单号")]
+ [Display(Name = "交付单号、ASN单号等")]
public string PN { get; set; } = null!;
[Display(Name = "发货数量")]
@@ -33,7 +33,7 @@ public class PUB_SE_DETAIL : BaseEntity
public string Extend3 { get; set; } = null!;
///
- /// 1、JIT 2、买单件 3、备件 3、印度件
+ /// 1、JIT 2、买单件 3、备件 4、印度件
///
[Display(Name = "业务分类")]
public string BusinessType { get; set; } = null!;
diff --git a/docs/demo/src/WTA.Application/Identity/Entities/SystemManagement/TB_RePartsRelationship.cs b/docs/demo/src/WTA.Application/Identity/Entities/SystemManagement/TB_RePartsRelationship.cs
index a8376669..121bc543 100644
--- a/docs/demo/src/WTA.Application/Identity/Entities/SystemManagement/TB_RePartsRelationship.cs
+++ b/docs/demo/src/WTA.Application/Identity/Entities/SystemManagement/TB_RePartsRelationship.cs
@@ -20,6 +20,7 @@ public class TB_RePartsRelationship : BaseEntity
///
[Display(Name = "替换零件号")]
public string RepLU { set; get; } = null!;
+ //取值字段【客户编码】
[Display(Name = "客户编码")]
public string ClientCode { set; get; } = null!;
diff --git a/docs/ui.rp b/docs/ui.rp
index b66d9440..dbf10740 100644
Binary files a/docs/ui.rp and b/docs/ui.rp differ