diff --git a/.prettierrc b/.prettierrc index b82b0c6..ee44e11 100644 --- a/.prettierrc +++ b/.prettierrc @@ -2,7 +2,6 @@ "tabWidth": 4, "useTabs": true, "semi": true, - "jsxBracketSameLine": true, "singleQuote": false, "printWidth": 100, "trailingComma": "none" diff --git a/build/plugins/cool.ts b/build/plugins/cool.ts index 89fe7e4..5efc6df 100644 --- a/build/plugins/cool.ts +++ b/build/plugins/cool.ts @@ -53,14 +53,13 @@ const handler = { return d; }); - const d = { + const d: any = { table: { label, dict: list }, form: { label, - value: list[0]?.value, component: { name: "", options: list @@ -68,6 +67,11 @@ const handler = { } }; + // 默认值 + if (list[0]) { + d.form.value = list[0].value; + } + // 匹配组件 d.form.component.name = arr.length > 4 ? "el-select" : "el-radio-group"; diff --git a/package.json b/package.json index fa7750f..071cf84 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "front-next", - "version": "4.0.0", + "version": "4.0.1", "scripts": { "dev": "vite --host", "build": "vite build", @@ -13,20 +13,15 @@ "array.prototype.flat": "^1.2.4", "axios": "^0.21.1", "clipboard": "^2.0.8", - "clone-deep": "^4.0.1", "codemirror": "^5.62.0", "core-js": "^3.6.5", "echarts": "^5.0.2", "element-plus": "^1.1.0-beta.20", "file-saver": "^2.0.5", - "glob": "^7.1.6", "js-beautify": "^1.13.5", - "merge": "^2.1.1", - "merge-deep": "^3.0.3", "mitt": "^2.1.0", "mockjs": "^1.1.0", "nprogress": "^0.2.0", - "qrcode": "^1.4.4", "quill": "^1.3.7", "socket.io-client": "^4.1.2", "store": "^2.0.12", diff --git a/src/assets/css/element.scss b/src/assets/css/element.scss index ceaa164..6cea1c0 100644 --- a/src/assets/css/element.scss +++ b/src/assets/css/element.scss @@ -23,10 +23,9 @@ $--colors: ( ); @forward "element-plus/theme-chalk/src/common/var.scss" with ( - $colors: $--colors, + $colors: $--colors ); - :export { colorPrimary: $color-primary; colorSuccess: $color-success; diff --git a/src/cool/core/service/index.ts b/src/cool/core/service/index.ts index 9d2c788..896d41c 100644 --- a/src/cool/core/service/index.ts +++ b/src/cool/core/service/index.ts @@ -129,8 +129,6 @@ function useEps() { }); } - console.log(service); - return res; }) .catch((err: string) => { diff --git a/src/cool/modules/base/components/dept/move.tsx b/src/cool/modules/base/components/dept/move.tsx index a2db123..e519293 100644 --- a/src/cool/modules/base/components/dept/move.tsx +++ b/src/cool/modules/base/components/dept/move.tsx @@ -97,7 +97,8 @@ export default defineComponent({ border: "1px solid #eee", borderRadius: "3px", padding: "2px" - }}> + }} + > { scope["dept"] = e; - }}> + }} + > ); } diff --git a/src/cool/modules/base/components/dept/tree.vue b/src/cool/modules/base/components/dept/tree.vue index 0136e23..0ed867b 100644 --- a/src/cool/modules/base/components/dept/tree.vue +++ b/src/cool/modules/base/components/dept/tree.vue @@ -61,7 +61,7 @@