npmapps 1.1.4 → 1.1.6
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/app/wujie-wk/dev.log +1979 -0
- package/app/wujie-wk/t.html +90 -0
- package/app/wujie-wk/wujie-react-child/README.md +126 -0
- package/app/wujie-wk/wujie-react-child/eslint.config.js +28 -0
- package/app/wujie-wk/wujie-react-child/index.html +13 -0
- package/app/wujie-wk/wujie-react-child/package-lock.json +4344 -0
- package/app/wujie-wk/wujie-react-child/package.json +32 -0
- package/app/wujie-wk/wujie-react-child/public/vite.svg +1 -0
- package/app/wujie-wk/wujie-react-child/src/App.css +0 -0
- package/app/wujie-wk/wujie-react-child/src/App.tsx +72 -0
- package/app/wujie-wk/wujie-react-child/src/assets/react.svg +1 -0
- package/app/wujie-wk/wujie-react-child/src/components/FeatureCards.css +63 -0
- package/app/wujie-wk/wujie-react-child/src/components/FeatureCards.tsx +112 -0
- package/app/wujie-wk/wujie-react-child/src/components/LightCard/index.tsx +36 -0
- package/app/wujie-wk/wujie-react-child/src/components/LightCard/style.css +20 -0
- package/app/wujie-wk/wujie-react-child/src/hooks/use3DCard.ts +53 -0
- package/app/wujie-wk/wujie-react-child/src/hooks/useLightCard.ts +141 -0
- package/app/wujie-wk/wujie-react-child/src/index.css +0 -0
- package/app/wujie-wk/wujie-react-child/src/main.tsx +8 -0
- package/app/wujie-wk/wujie-react-child/src/pages/ChildToParent/index.css +55 -0
- package/app/wujie-wk/wujie-react-child/src/pages/ChildToParent/index.tsx +88 -0
- package/app/wujie-wk/wujie-react-child/src/pages/Css.tsx +28 -0
- package/app/wujie-wk/wujie-react-child/src/pages/Home.tsx +72 -0
- package/app/wujie-wk/wujie-react-child/src/pages/ParentToChild.css +85 -0
- package/app/wujie-wk/wujie-react-child/src/pages/ParentToChild.tsx +119 -0
- package/app/wujie-wk/wujie-react-child/src/pages/RouterJump/index.css +61 -0
- package/app/wujie-wk/wujie-react-child/src/pages/RouterJump/index.tsx +87 -0
- package/app/wujie-wk/wujie-react-child/src/router/index.tsx +63 -0
- package/app/wujie-wk/wujie-react-child/src/types/wujie.d.ts +26 -0
- package/app/wujie-wk/wujie-react-child/src/vite-env.d.ts +1 -0
- package/app/wujie-wk/wujie-react-child/tsconfig.app.json +26 -0
- package/app/wujie-wk/wujie-react-child/tsconfig.json +7 -0
- package/app/wujie-wk/wujie-react-child/tsconfig.node.json +24 -0
- package/app/wujie-wk/wujie-react-child/vite.config.ts +10 -0
- package/app/wujie-wk/wujie-vue2-child/.eslintrc.js +19 -0
- package/app/wujie-wk/wujie-vue2-child/README.md +24 -0
- package/app/wujie-wk/wujie-vue2-child/babel.config.js +5 -0
- package/app/wujie-wk/wujie-vue2-child/docs/superpowers/plans/2026-05-29-quill-editor.md +836 -0
- package/app/wujie-wk/wujie-vue2-child/docs/superpowers/specs/2026-05-29-quill-editor-design.md +210 -0
- package/app/wujie-wk/wujie-vue2-child/jsconfig.json +19 -0
- package/app/wujie-wk/wujie-vue2-child/package-lock.json +21333 -0
- package/app/wujie-wk/wujie-vue2-child/package.json +63 -0
- package/app/wujie-wk/wujie-vue2-child/postcss.config.js +10 -0
- package/app/wujie-wk/wujie-vue2-child/public/favicon.ico +0 -0
- package/app/wujie-wk/wujie-vue2-child/public/index.html +17 -0
- package/app/wujie-wk/wujie-vue2-child/public/rili.jpg +0 -0
- package/app/wujie-wk/wujie-vue2-child/public//344/270/200/351/224/256/351/273/221/346/232/227.html +136 -0
- package/app/wujie-wk/wujie-vue2-child/src/App.vue +110 -0
- package/app/wujie-wk/wujie-vue2-child/src/assets/bpmn-camunda.jpg +0 -0
- package/app/wujie-wk/wujie-vue2-child/src/assets/css/diagram.less +17 -0
- package/app/wujie-wk/wujie-vue2-child/src/assets/icon/Icon.less +31 -0
- package/app/wujie-wk/wujie-vue2-child/src/assets/icon/font/app-codes.css +26 -0
- package/app/wujie-wk/wujie-vue2-child/src/assets/icon/font/app.eot +0 -0
- package/app/wujie-wk/wujie-vue2-child/src/assets/icon/font/app.svg +60 -0
- package/app/wujie-wk/wujie-vue2-child/src/assets/icon/font/app.ttf +0 -0
- package/app/wujie-wk/wujie-vue2-child/src/assets/icon/font/app.woff +0 -0
- package/app/wujie-wk/wujie-vue2-child/src/assets/icon/font/app.woff2 +0 -0
- package/app/wujie-wk/wujie-vue2-child/src/assets/icon/font/config.json +248 -0
- package/app/wujie-wk/wujie-vue2-child/src/assets/icon/font/source/raw/align-bottom-tool.svg +30 -0
- package/app/wujie-wk/wujie-vue2-child/src/assets/icon/font/source/raw/align-horizontal-center-tool.svg +85 -0
- package/app/wujie-wk/wujie-vue2-child/src/assets/icon/font/source/raw/align-left-tool.svg +84 -0
- package/app/wujie-wk/wujie-vue2-child/src/assets/icon/font/source/raw/align-right-tool.svg +80 -0
- package/app/wujie-wk/wujie-vue2-child/src/assets/icon/font/source/raw/align-top-tool.svg +84 -0
- package/app/wujie-wk/wujie-vue2-child/src/assets/icon/font/source/raw/align-vertical-center-tool.svg +89 -0
- package/app/wujie-wk/wujie-vue2-child/src/assets/icon/font/source/raw/distribute-horizontally-tool.svg +95 -0
- package/app/wujie-wk/wujie-vue2-child/src/assets/icon/font/source/raw/distribute-vertically-tool.svg +99 -0
- package/app/wujie-wk/wujie-vue2-child/src/assets/icon/font/source/raw/set-color-tool.svg +111 -0
- package/app/wujie-wk/wujie-vue2-child/src/assets/icon/font/source/symbols/align-bottom-tool.svg +30 -0
- package/app/wujie-wk/wujie-vue2-child/src/assets/icon/font/source/symbols/align-horizontal-center-tool.svg +30 -0
- package/app/wujie-wk/wujie-vue2-child/src/assets/icon/font/source/symbols/align-left-tool.svg +30 -0
- package/app/wujie-wk/wujie-vue2-child/src/assets/icon/font/source/symbols/align-right-tool.svg +30 -0
- package/app/wujie-wk/wujie-vue2-child/src/assets/icon/font/source/symbols/align-top-tool.svg +30 -0
- package/app/wujie-wk/wujie-vue2-child/src/assets/icon/font/source/symbols/align-vertical-center-tool.svg +30 -0
- package/app/wujie-wk/wujie-vue2-child/src/assets/icon/font/source/symbols/distribute-horizontally-tool.svg +30 -0
- package/app/wujie-wk/wujie-vue2-child/src/assets/icon/font/source/symbols/distribute-vertically-tool.svg +30 -0
- package/app/wujie-wk/wujie-vue2-child/src/assets/icon/font/source/symbols/set-color-tool.svg +63 -0
- package/app/wujie-wk/wujie-vue2-child/src/assets/logo.png +0 -0
- package/app/wujie-wk/wujie-vue2-child/src/components/EllTable/README.md +70 -0
- package/app/wujie-wk/wujie-vue2-child/src/components/EllTable/article.md +184 -0
- package/app/wujie-wk/wujie-vue2-child/src/components/EllTable/index.js +213 -0
- package/app/wujie-wk/wujie-vue2-child/src/components/EventCalendar/CalendarSkeleton.vue +147 -0
- package/app/wujie-wk/wujie-vue2-child/src/components/EventCalendar/CodeBlock.vue +199 -0
- package/app/wujie-wk/wujie-vue2-child/src/components/EventCalendar/MonthSelect.vue +376 -0
- package/app/wujie-wk/wujie-vue2-child/src/components/EventCalendar/README.md +485 -0
- package/app/wujie-wk/wujie-vue2-child/src/components/EventCalendar/example.vue +1747 -0
- package/app/wujie-wk/wujie-vue2-child/src/components/EventCalendar/index.vue +2720 -0
- package/app/wujie-wk/wujie-vue2-child/src/components/EventCalendar/mockData.js +475 -0
- package/app/wujie-wk/wujie-vue2-child/src/components/EventCalendar/recruitmentAdapter.js +51 -0
- package/app/wujie-wk/wujie-vue2-child/src/components/EventCalendar/utils.js +202 -0
- package/app/wujie-wk/wujie-vue2-child/src/components/FormulaEditor/FunctionSelector.vue +123 -0
- package/app/wujie-wk/wujie-vue2-child/src/components/FormulaEditor/OperatorSelector.vue +184 -0
- package/app/wujie-wk/wujie-vue2-child/src/components/FormulaEditor/ParameterSelector.vue +123 -0
- package/app/wujie-wk/wujie-vue2-child/src/components/FormulaEditor/api.js +69 -0
- package/app/wujie-wk/wujie-vue2-child/src/components/FormulaEditor/index.vue +435 -0
- package/app/wujie-wk/wujie-vue2-child/src/components/HelloWorld.vue +58 -0
- package/app/wujie-wk/wujie-vue2-child/src/components/PageHeader/index.vue +158 -0
- package/app/wujie-wk/wujie-vue2-child/src/components/Splitter/README.md +144 -0
- package/app/wujie-wk/wujie-vue2-child/src/components/Splitter/example.vue +84 -0
- package/app/wujie-wk/wujie-vue2-child/src/components/Splitter/index.vue +203 -0
- package/app/wujie-wk/wujie-vue2-child/src/components/diagram/ToolBar.vue +357 -0
- package/app/wujie-wk/wujie-vue2-child/src/components/diagram/customTranslate/customTranslate.js +12 -0
- package/app/wujie-wk/wujie-vue2-child/src/components/diagram/customTranslate/translationsGerman.js +241 -0
- package/app/wujie-wk/wujie-vue2-child/src/components/diagram/index.vue +261 -0
- package/app/wujie-wk/wujie-vue2-child/src/components/diagram/xmlData.js +29 -0
- package/app/wujie-wk/wujie-vue2-child/src/directives/filldown.js +155 -0
- package/app/wujie-wk/wujie-vue2-child/src/directives/filldownTable.js +291 -0
- package/app/wujie-wk/wujie-vue2-child/src/main.js +40 -0
- package/app/wujie-wk/wujie-vue2-child/src/router/index.js +72 -0
- package/app/wujie-wk/wujie-vue2-child/src/store/index.js +23 -0
- package/app/wujie-wk/wujie-vue2-child/src/utils/winBox.js +23 -0
- package/app/wujie-wk/wujie-vue2-child/src/views/Extend/A.vue +12 -0
- package/app/wujie-wk/wujie-vue2-child/src/views/Extend/B.vue +10 -0
- package/app/wujie-wk/wujie-vue2-child/src/views/Extend/MagicalComponentsForELFormItem.vue +78 -0
- package/app/wujie-wk/wujie-vue2-child/src/views/Extend/index.vue +59 -0
- package/app/wujie-wk/wujie-vue2-child/src/views/Extend/tableMouseHorizontalWheel.vue +184 -0
- package/app/wujie-wk/wujie-vue2-child/src/views/Home.vue +27 -0
- package/app/wujie-wk/wujie-vue2-child/src/views/RouterJump.vue +145 -0
- package/app/wujie-wk/wujie-vue2-child/src/views/calendar/index.vue +19 -0
- package/app/wujie-wk/wujie-vue2-child/src/views/css.vue +57 -0
- package/app/wujie-wk/wujie-vue2-child/src/views/cssComponents/EllipsisText.vue +73 -0
- package/app/wujie-wk/wujie-vue2-child/src/views/cssComponents/HoverCard.vue +69 -0
- package/app/wujie-wk/wujie-vue2-child/src/views/cssComponents/TableHover.vue +130 -0
- package/app/wujie-wk/wujie-vue2-child/src/views/cssComponents/inputSlo.vue +42 -0
- package/app/wujie-wk/wujie-vue2-child/src/views/cssComponents/tableFixed.vue +148 -0
- package/app/wujie-wk/wujie-vue2-child/src/views/echarts/echart-dome.vue +73 -0
- package/app/wujie-wk/wujie-vue2-child/src/views/echarts/index.vue +118 -0
- package/app/wujie-wk/wujie-vue2-child/src/views/echarts/pei3d.vue +658 -0
- package/app/wujie-wk/wujie-vue2-child/src/views/element/bpmn/index.vue +15 -0
- package/app/wujie-wk/wujie-vue2-child/src/views/element/components/attendanceCycle/index.vue +131 -0
- package/app/wujie-wk/wujie-vue2-child/src/views/element/components/attendanceGroup/index.vue +147 -0
- package/app/wujie-wk/wujie-vue2-child/src/views/element/components/attendancePersonnel/index.vue +158 -0
- package/app/wujie-wk/wujie-vue2-child/src/views/element/components/companyCalendar/index.vue +147 -0
- package/app/wujie-wk/wujie-vue2-child/src/views/element/components/shift/index.vue +147 -0
- package/app/wujie-wk/wujie-vue2-child/src/views/element/components/shiftRotationSystem/index.vue +147 -0
- package/app/wujie-wk/wujie-vue2-child/src/views/element/elTableJsx/columnManagement.vue +340 -0
- package/app/wujie-wk/wujie-vue2-child/src/views/element/elTableJsx/dialogInput.vue +71 -0
- package/app/wujie-wk/wujie-vue2-child/src/views/element/elTableJsx/elTableJsx.vue +1826 -0
- package/app/wujie-wk/wujie-vue2-child/src/views/element/elTableJsx/formTable.vue +595 -0
- package/app/wujie-wk/wujie-vue2-child/src/views/element/elTableJsx/index.vue +29 -0
- package/app/wujie-wk/wujie-vue2-child/src/views/element/elTableJsx/simpleTable.vue +189 -0
- package/app/wujie-wk/wujie-vue2-child/src/views/element/elTableJsx.zip +0 -0
- package/app/wujie-wk/wujie-vue2-child/src/views/element/index.vue +39 -0
- package/app/wujie-wk/wujie-vue2-child/src/views/element/quillEditor/README.md +163 -0
- package/app/wujie-wk/wujie-vue2-child/src/views/element/quillEditor/example.vue +307 -0
- package/app/wujie-wk/wujie-vue2-child/src/views/element/quillEditor/index.vue +409 -0
- package/app/wujie-wk/wujie-vue2-child/src/views/element/quillEditor/toolbar.js +122 -0
- package/app/wujie-wk/wujie-vue2-child/vue.config.js +15 -0
- package/app/wujie-wk/wujie-vue3-child/.claude/settings.local.json +8 -0
- package/app/wujie-wk/wujie-vue3-child/.vscode/extensions.json +3 -0
- package/app/wujie-wk/wujie-vue3-child/PROJECT_MEMORY.md +427 -0
- package/app/wujie-wk/wujie-vue3-child/README.md +5 -0
- package/app/wujie-wk/wujie-vue3-child/index.html +13 -0
- package/app/wujie-wk/wujie-vue3-child/package-lock.json +5744 -0
- package/app/wujie-wk/wujie-vue3-child/package.json +28 -0
- package/app/wujie-wk/wujie-vue3-child/public/vite.svg +1 -0
- package/app/wujie-wk/wujie-vue3-child/src/App.vue +130 -0
- package/app/wujie-wk/wujie-vue3-child/src/assets/vue.svg +1 -0
- package/app/wujie-wk/wujie-vue3-child/src/components/HelloWorld.vue +43 -0
- package/app/wujie-wk/wujie-vue3-child/src/components/SmartAnchorTabs/index.jsx +224 -0
- package/app/wujie-wk/wujie-vue3-child/src/components/SmartAnchorTabs/style.css +154 -0
- package/app/wujie-wk/wujie-vue3-child/src/components/tags-view.vue +193 -0
- package/app/wujie-wk/wujie-vue3-child/src/components/tags-view1.vue +131 -0
- package/app/wujie-wk/wujie-vue3-child/src/directives/aiLoading.js +182 -0
- package/app/wujie-wk/wujie-vue3-child/src/hooks/useClickOutside.js +11 -0
- package/app/wujie-wk/wujie-vue3-child/src/hooks/useTableDragSort.js +28 -0
- package/app/wujie-wk/wujie-vue3-child/src/main.js +18 -0
- package/app/wujie-wk/wujie-vue3-child/src/router/index.js +104 -0
- package/app/wujie-wk/wujie-vue3-child/src/store/tagsViewStroe.js +34 -0
- package/app/wujie-wk/wujie-vue3-child/src/style.css +171 -0
- package/app/wujie-wk/wujie-vue3-child/src/views/aiCoach/collapseExpand/index.jsx +108 -0
- package/app/wujie-wk/wujie-vue3-child/src/views/aiCoach/collapseExpand/index.module.scss +97 -0
- package/app/wujie-wk/wujie-vue3-child/src/views/aiCoach/departmentPersonnel/README.md +836 -0
- package/app/wujie-wk/wujie-vue3-child/src/views/aiCoach/departmentPersonnel/REFLEX_EXAMPLES.md +728 -0
- package/app/wujie-wk/wujie-vue3-child/src/views/aiCoach/departmentPersonnel/components/DepartmentPersonnelSelector.jsx +687 -0
- package/app/wujie-wk/wujie-vue3-child/src/views/aiCoach/departmentPersonnel/components/DepartmentPersonnelSelector.module.scss +560 -0
- package/app/wujie-wk/wujie-vue3-child/src/views/aiCoach/departmentPersonnel/components/DepartmentSelector.jsx +570 -0
- package/app/wujie-wk/wujie-vue3-child/src/views/aiCoach/departmentPersonnel/components/DepartmentSelector.module.scss +330 -0
- package/app/wujie-wk/wujie-vue3-child/src/views/aiCoach/departmentPersonnel/components/DepartmentSelectorV2.jsx +378 -0
- package/app/wujie-wk/wujie-vue3-child/src/views/aiCoach/departmentPersonnel/components/DepartmentSelectorV2.module.scss +228 -0
- package/app/wujie-wk/wujie-vue3-child/src/views/aiCoach/departmentPersonnel/components/OptionsSelector.jsx +399 -0
- package/app/wujie-wk/wujie-vue3-child/src/views/aiCoach/departmentPersonnel/components/OptionsSelector.module.scss +252 -0
- package/app/wujie-wk/wujie-vue3-child/src/views/aiCoach/departmentPersonnel/components/PersonnelSelector.jsx +585 -0
- package/app/wujie-wk/wujie-vue3-child/src/views/aiCoach/departmentPersonnel/components/PersonnelSelector.module.scss +331 -0
- package/app/wujie-wk/wujie-vue3-child/src/views/aiCoach/departmentPersonnel/components/PopoverSelector.jsx +392 -0
- package/app/wujie-wk/wujie-vue3-child/src/views/aiCoach/departmentPersonnel/components/PopoverSelector.module.scss +39 -0
- package/app/wujie-wk/wujie-vue3-child/src/views/aiCoach/departmentPersonnel/components/README.md +248 -0
- package/app/wujie-wk/wujie-vue3-child/src/views/aiCoach/departmentPersonnel/components/SelectorTrigger.jsx +194 -0
- package/app/wujie-wk/wujie-vue3-child/src/views/aiCoach/departmentPersonnel/index.jsx +1459 -0
- package/app/wujie-wk/wujie-vue3-child/src/views/aiCoach/departmentPersonnel/mockData.js +301 -0
- package/app/wujie-wk/wujie-vue3-child/src/views/aiCoach/dialogueSegment/index.jsx +182 -0
- package/app/wujie-wk/wujie-vue3-child/src/views/aiCoach/dialogueSegment/index.module.scss +28 -0
- package/app/wujie-wk/wujie-vue3-child/src/views/aiCoach/index.jsx +375 -0
- package/app/wujie-wk/wujie-vue3-child/src/views/aiCoach/practiceStatus/components/ChartsPanel/index.jsx +121 -0
- package/app/wujie-wk/wujie-vue3-child/src/views/aiCoach/practiceStatus/components/ChartsPanel/index.module.scss +76 -0
- package/app/wujie-wk/wujie-vue3-child/src/views/aiCoach/practiceStatus/components/DonutChart/index.jsx +104 -0
- package/app/wujie-wk/wujie-vue3-child/src/views/aiCoach/practiceStatus/components/PracticeTable/index.jsx +75 -0
- package/app/wujie-wk/wujie-vue3-child/src/views/aiCoach/practiceStatus/components/PracticeTable/index.module.scss +12 -0
- package/app/wujie-wk/wujie-vue3-child/src/views/aiCoach/practiceStatus/components/RankBarChart/index.jsx +62 -0
- package/app/wujie-wk/wujie-vue3-child/src/views/aiCoach/practiceStatus/components/RankBarChart/index.module.scss +43 -0
- package/app/wujie-wk/wujie-vue3-child/src/views/aiCoach/practiceStatus/components/RankingGroup/index.jsx +29 -0
- package/app/wujie-wk/wujie-vue3-child/src/views/aiCoach/practiceStatus/components/RankingGroup/index.module.scss +5 -0
- package/app/wujie-wk/wujie-vue3-child/src/views/aiCoach/practiceStatus/components/RankingList/index.jsx +58 -0
- package/app/wujie-wk/wujie-vue3-child/src/views/aiCoach/practiceStatus/components/RankingList/index.module.scss +85 -0
- package/app/wujie-wk/wujie-vue3-child/src/views/aiCoach/practiceStatus/components/ScriptStatsPanel/index.jsx +92 -0
- package/app/wujie-wk/wujie-vue3-child/src/views/aiCoach/practiceStatus/components/ScriptStatsPanel/index.module.scss +56 -0
- package/app/wujie-wk/wujie-vue3-child/src/views/aiCoach/practiceStatus/components/StatCardsRow/index.jsx +40 -0
- package/app/wujie-wk/wujie-vue3-child/src/views/aiCoach/practiceStatus/components/StatCardsRow/index.module.scss +53 -0
- package/app/wujie-wk/wujie-vue3-child/src/views/aiCoach/practiceStatus/components/echarts/EchartsDonut.jsx +106 -0
- package/app/wujie-wk/wujie-vue3-child/src/views/aiCoach/practiceStatus/components/echarts/EchartsRankBar.jsx +132 -0
- package/app/wujie-wk/wujie-vue3-child/src/views/aiCoach/practiceStatus/index.jsx +176 -0
- package/app/wujie-wk/wujie-vue3-child/src/views/aiCoach/practiceStatus/index.module.scss +96 -0
- package/app/wujie-wk/wujie-vue3-child/src/views/aiCoach/reportDetail/components/CoachReport/index.jsx +162 -0
- package/app/wujie-wk/wujie-vue3-child/src/views/aiCoach/reportDetail/components/CoachReport/index.module.scss +16 -0
- package/app/wujie-wk/wujie-vue3-child/src/views/aiCoach/reportDetail/components/ComprehensiveEvaluation/index.jsx +29 -0
- package/app/wujie-wk/wujie-vue3-child/src/views/aiCoach/reportDetail/components/ComprehensiveEvaluation/index.module.scss +25 -0
- package/app/wujie-wk/wujie-vue3-child/src/views/aiCoach/reportDetail/components/DialogueBubble/index.jsx +106 -0
- package/app/wujie-wk/wujie-vue3-child/src/views/aiCoach/reportDetail/components/DialogueBubble/index.module.scss +164 -0
- package/app/wujie-wk/wujie-vue3-child/src/views/aiCoach/reportDetail/components/DialogueRecord/index.jsx +182 -0
- package/app/wujie-wk/wujie-vue3-child/src/views/aiCoach/reportDetail/components/DialogueRecord/index.module.scss +203 -0
- package/app/wujie-wk/wujie-vue3-child/src/views/aiCoach/reportDetail/components/DimensionDetail/index.jsx +145 -0
- package/app/wujie-wk/wujie-vue3-child/src/views/aiCoach/reportDetail/components/DimensionDetail/index.module.scss +126 -0
- package/app/wujie-wk/wujie-vue3-child/src/views/aiCoach/reportDetail/components/DimensionScores/index.jsx +67 -0
- package/app/wujie-wk/wujie-vue3-child/src/views/aiCoach/reportDetail/components/DimensionScores/index.module.scss +105 -0
- package/app/wujie-wk/wujie-vue3-child/src/views/aiCoach/reportDetail/components/ReportHeader/index.jsx +81 -0
- package/app/wujie-wk/wujie-vue3-child/src/views/aiCoach/reportDetail/components/ReportHeader/index.module.scss +47 -0
- package/app/wujie-wk/wujie-vue3-child/src/views/aiCoach/reportDetail/components/RoleInfo/index.jsx +64 -0
- package/app/wujie-wk/wujie-vue3-child/src/views/aiCoach/reportDetail/components/RoleInfo/index.module.scss +85 -0
- package/app/wujie-wk/wujie-vue3-child/src/views/aiCoach/reportDetail/components/ScoreBadge/index.jsx +39 -0
- package/app/wujie-wk/wujie-vue3-child/src/views/aiCoach/reportDetail/components/ScoreBadge/index.module.scss +44 -0
- package/app/wujie-wk/wujie-vue3-child/src/views/aiCoach/reportDetail/components/SubDimensionItem/index.jsx +83 -0
- package/app/wujie-wk/wujie-vue3-child/src/views/aiCoach/reportDetail/components/SubDimensionItem/index.module.scss +101 -0
- package/app/wujie-wk/wujie-vue3-child/src/views/aiCoach/reportDetail/index.jsx +50 -0
- package/app/wujie-wk/wujie-vue3-child/src/views/aiCoach/reportDetail/index.module.scss +25 -0
- package/app/wujie-wk/wujie-vue3-child/src/views/aiCoach/scriptTable/index.jsx +196 -0
- package/app/wujie-wk/wujie-vue3-child/src/views/aiCoach/scriptTable/index.module.scss +41 -0
- package/app/wujie-wk/wujie-vue3-child/src/views/aiCoach/scriptTable/inputColumn/index.jsx +183 -0
- package/app/wujie-wk/wujie-vue3-child/src/views/aiCoach/scriptTable/inputColumn/index.module.scss +115 -0
- package/app/wujie-wk/wujie-vue3-child/src/views/child-to-parent.vue +117 -0
- package/app/wujie-wk/wujie-vue3-child/src/views/home.vue +53 -0
- package/app/wujie-wk/wujie-vue3-child/src/views/jsx/btnSelect/btnSelect.vue +169 -0
- package/app/wujie-wk/wujie-vue3-child/src/views/jsx/btnSelect/index.vue +69 -0
- package/app/wujie-wk/wujie-vue3-child/src/views/jsx/com.vue +44 -0
- package/app/wujie-wk/wujie-vue3-child/src/views/jsx/dialog.jsx +66 -0
- package/app/wujie-wk/wujie-vue3-child/src/views/jsx/index.vue +72 -0
- package/app/wujie-wk/wujie-vue3-child/src/views/jsx/props.vue +33 -0
- package/app/wujie-wk/wujie-vue3-child/src/views/parent-to-child.vue +225 -0
- package/app/wujie-wk/wujie-vue3-child/src/views/phone-code.vue +318 -0
- package/app/wujie-wk/wujie-vue3-child/src/views/router-jump.vue +123 -0
- package/app/wujie-wk/wujie-vue3-child/src/views/test.vue +192 -0
- package/app/wujie-wk/wujie-vue3-child/vite.config.js +15 -0
- package/app/wujie-wk/wujie-vue3-child copy/.vscode/extensions.json +3 -0
- package/app/wujie-wk/wujie-vue3-child copy/README.md +5 -0
- package/app/wujie-wk/wujie-vue3-child copy/index.html +13 -0
- package/app/wujie-wk/wujie-vue3-child copy/package-lock.json +4617 -0
- package/app/wujie-wk/wujie-vue3-child copy/package.json +22 -0
- package/app/wujie-wk/wujie-vue3-child copy/public/vite.svg +1 -0
- package/app/wujie-wk/wujie-vue3-child copy/src/App.vue +124 -0
- package/app/wujie-wk/wujie-vue3-child copy/src/assets/vue.svg +1 -0
- package/app/wujie-wk/wujie-vue3-child copy/src/components/HelloWorld.vue +43 -0
- package/app/wujie-wk/wujie-vue3-child copy/src/main.js +12 -0
- package/app/wujie-wk/wujie-vue3-child copy/src/router/index.js +84 -0
- package/app/wujie-wk/wujie-vue3-child copy/src/style.css +4 -0
- package/app/wujie-wk/wujie-vue3-child copy/src/views/child-to-parent.vue +117 -0
- package/app/wujie-wk/wujie-vue3-child copy/src/views/home.vue +53 -0
- package/app/wujie-wk/wujie-vue3-child copy/src/views/parent-to-child.vue +225 -0
- package/app/wujie-wk/wujie-vue3-child copy/src/views/phone-code.vue +318 -0
- package/app/wujie-wk/wujie-vue3-child copy/src/views/router-jump.vue +115 -0
- package/app/wujie-wk/wujie-vue3-child copy/src/views/test.vue +192 -0
- package/app/wujie-wk/wujie-vue3-child copy/vite.config.js +10 -0
- package/app/wujie-wk/wujie-vue3-main/.vscode/extensions.json +3 -0
- package/app/wujie-wk/wujie-vue3-main/README.md +154 -0
- package/app/wujie-wk/wujie-vue3-main/index.html +13 -0
- package/app/wujie-wk/wujie-vue3-main/package-lock.json +4736 -0
- package/app/wujie-wk/wujie-vue3-main/package.json +25 -0
- package/app/wujie-wk/wujie-vue3-main/public/vite.svg +1 -0
- package/app/wujie-wk/wujie-vue3-main/src/App.vue +879 -0
- package/app/wujie-wk/wujie-vue3-main/src/assets/vue.svg +1 -0
- package/app/wujie-wk/wujie-vue3-main/src/components/HelloWorld.vue +43 -0
- package/app/wujie-wk/wujie-vue3-main/src/components/WujieReact/index.vue +20 -0
- package/app/wujie-wk/wujie-vue3-main/src/components/WujieVue2/index.vue +8 -0
- package/app/wujie-wk/wujie-vue3-main/src/components/WujieVue3/index.vue +8 -0
- package/app/wujie-wk/wujie-vue3-main/src/components/WujieVue3Copy/index.vue +8 -0
- package/app/wujie-wk/wujie-vue3-main/src/main.js +23 -0
- package/app/wujie-wk/wujie-vue3-main/src/router/index.js +88 -0
- package/app/wujie-wk/wujie-vue3-main/src/store/useMicroAppStore.js +66 -0
- package/app/wujie-wk/wujie-vue3-main/src/style.css +3 -0
- package/app/wujie-wk/wujie-vue3-main/src/views/home.vue +103 -0
- package/app/wujie-wk/wujie-vue3-main/src/views/router-jump.vue +159 -0
- package/app/wujie-wk/wujie-vue3-main/src/views/test.vue +125 -0
- package/app/wujie-wk/wujie-vue3-main/src/views/vue3-child-msg.vue +108 -0
- package/app/wujie-wk/wujie-vue3-main/vite.config.js +12 -0
- package/package.json +1 -1
- package/app/check-import-case.js +0 -344
|
@@ -0,0 +1,202 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* EventCalendar 工具函数集
|
|
3
|
+
* ------------------------------------------------------------------
|
|
4
|
+
* 说明:本文件不依赖任何第三方库(含 dayjs / moment / lodash),
|
|
5
|
+
* 仅使用原生 Date,保证组件文件夹可以整体拷贝到任意项目使用。
|
|
6
|
+
*/
|
|
7
|
+
|
|
8
|
+
/** 数字补零:7 -> '07' */
|
|
9
|
+
export function pad2(n) {
|
|
10
|
+
return n < 10 ? '0' + n : String(n)
|
|
11
|
+
}
|
|
12
|
+
|
|
13
|
+
/**
|
|
14
|
+
* 默认字段映射表
|
|
15
|
+
* ------------------------------------------------------------------
|
|
16
|
+
* 后端返回的字段名往往与组件内部约定不一致,
|
|
17
|
+
* 使用者可通过 `field-names` prop 覆盖其中任意一项(支持 'a.b.c' 点路径)。
|
|
18
|
+
*/
|
|
19
|
+
export const DEFAULT_FIELD_NAMES = {
|
|
20
|
+
// —— 月份层(data 数组的每一项)——
|
|
21
|
+
month: 'month', // 月份标识,形如 '2026-09'
|
|
22
|
+
monthLabel: 'monthLabel', // 下拉框显示文案;缺省时自动生成「2026年9月」
|
|
23
|
+
days: 'days', // 该月的日期数组
|
|
24
|
+
|
|
25
|
+
// —— 日期层(days 数组的每一项)——
|
|
26
|
+
date: 'date', // 日期标识,形如 '2026-09-07'
|
|
27
|
+
items: 'items', // 当天的条目数组
|
|
28
|
+
|
|
29
|
+
// —— 条目层(items 数组的每一项)——
|
|
30
|
+
itemKey: 'id', // 条目唯一键(用于 v-for :key)
|
|
31
|
+
itemLabel: 'label', // 条目主文案,如「电子科技大学」
|
|
32
|
+
itemAddress: 'address', // 条目地址;为空时不渲染地址行
|
|
33
|
+
itemBadge: 'badge', // 条目右上角角标文案,如「宣讲」「双选」
|
|
34
|
+
itemType: 'type', // 条目类型,用于匹配 typeColors 配色
|
|
35
|
+
itemDisabled: 'disabled' // 条目是否禁用(禁用后不响应点击)
|
|
36
|
+
}
|
|
37
|
+
|
|
38
|
+
/**
|
|
39
|
+
* 按路径取值,支持 'a.b.c' 形式
|
|
40
|
+
* @param {Object} obj 源对象
|
|
41
|
+
* @param {String} path 字段路径
|
|
42
|
+
*/
|
|
43
|
+
export function getByPath(obj, path) {
|
|
44
|
+
if (obj == null || !path) return undefined
|
|
45
|
+
if (path.indexOf('.') === -1) return obj[path]
|
|
46
|
+
return path.split('.').reduce((acc, key) => (acc == null ? acc : acc[key]), obj)
|
|
47
|
+
}
|
|
48
|
+
|
|
49
|
+
/** 是否为合法 Date 对象 */
|
|
50
|
+
function isValidDate(d) {
|
|
51
|
+
return d instanceof Date && !isNaN(d.getTime())
|
|
52
|
+
}
|
|
53
|
+
|
|
54
|
+
/**
|
|
55
|
+
* 把多种输入统一解析成 Date
|
|
56
|
+
* 支持:Date / '2026-09-07' / '2026/9/7' / 时间戳
|
|
57
|
+
*/
|
|
58
|
+
export function toDate(value) {
|
|
59
|
+
if (isValidDate(value)) return value
|
|
60
|
+
if (value == null || value === '') return null
|
|
61
|
+
|
|
62
|
+
if (typeof value === 'number') {
|
|
63
|
+
const d = new Date(value)
|
|
64
|
+
return isValidDate(d) ? d : null
|
|
65
|
+
}
|
|
66
|
+
|
|
67
|
+
const str = String(value).trim()
|
|
68
|
+
// 手动解析,规避 Safari / iOS 对 '2026-09-07' 的时区差异(会被当成 UTC)
|
|
69
|
+
const m = str.match(/^(\d{4})[-/](\d{1,2})(?:[-/](\d{1,2}))?/)
|
|
70
|
+
if (m) {
|
|
71
|
+
const d = new Date(Number(m[1]), Number(m[2]) - 1, m[3] ? Number(m[3]) : 1)
|
|
72
|
+
return isValidDate(d) ? d : null
|
|
73
|
+
}
|
|
74
|
+
|
|
75
|
+
const fallback = new Date(str)
|
|
76
|
+
return isValidDate(fallback) ? fallback : null
|
|
77
|
+
}
|
|
78
|
+
|
|
79
|
+
/** Date -> 'YYYY-MM-DD' */
|
|
80
|
+
export function formatDateKey(date) {
|
|
81
|
+
const d = toDate(date)
|
|
82
|
+
if (!d) return ''
|
|
83
|
+
return `${d.getFullYear()}-${pad2(d.getMonth() + 1)}-${pad2(d.getDate())}`
|
|
84
|
+
}
|
|
85
|
+
|
|
86
|
+
/** Date -> 'YYYY-MM' */
|
|
87
|
+
export function formatMonthKey(date) {
|
|
88
|
+
const d = toDate(date)
|
|
89
|
+
if (!d) return ''
|
|
90
|
+
return `${d.getFullYear()}-${pad2(d.getMonth() + 1)}`
|
|
91
|
+
}
|
|
92
|
+
|
|
93
|
+
/**
|
|
94
|
+
* 解析月份标识
|
|
95
|
+
* @param {String|Date} monthKey '2026-09' / '2026/9' / Date
|
|
96
|
+
* @returns {{ year: Number, month: Number }} month 为 1~12
|
|
97
|
+
*/
|
|
98
|
+
export function parseMonthKey(monthKey) {
|
|
99
|
+
const d = toDate(monthKey)
|
|
100
|
+
if (!d) {
|
|
101
|
+
const now = new Date()
|
|
102
|
+
return { year: now.getFullYear(), month: now.getMonth() + 1 }
|
|
103
|
+
}
|
|
104
|
+
return { year: d.getFullYear(), month: d.getMonth() + 1 }
|
|
105
|
+
}
|
|
106
|
+
|
|
107
|
+
/** 两个 Date 是否为同一天 */
|
|
108
|
+
export function isSameDay(a, b) {
|
|
109
|
+
const d1 = toDate(a)
|
|
110
|
+
const d2 = toDate(b)
|
|
111
|
+
if (!d1 || !d2) return false
|
|
112
|
+
return (
|
|
113
|
+
d1.getFullYear() === d2.getFullYear() &&
|
|
114
|
+
d1.getMonth() === d2.getMonth() &&
|
|
115
|
+
d1.getDate() === d2.getDate()
|
|
116
|
+
)
|
|
117
|
+
}
|
|
118
|
+
|
|
119
|
+
/**
|
|
120
|
+
* 月份偏移,自动跨年
|
|
121
|
+
* @param {String} monthKey '2026-01'
|
|
122
|
+
* @param {Number} offset -1 上个月 / 1 下个月
|
|
123
|
+
* @returns {String} '2025-12'
|
|
124
|
+
*/
|
|
125
|
+
export function shiftMonth(monthKey, offset) {
|
|
126
|
+
const { year, month } = parseMonthKey(monthKey)
|
|
127
|
+
// new Date 的月份允许越界(-1 / 12),会自动进位到上一年 / 下一年
|
|
128
|
+
return formatMonthKey(new Date(year, month - 1 + offset, 1))
|
|
129
|
+
}
|
|
130
|
+
|
|
131
|
+
/**
|
|
132
|
+
* 构建一个月的日历格子矩阵(核心逻辑)
|
|
133
|
+
* ------------------------------------------------------------------
|
|
134
|
+
* 需求要点:
|
|
135
|
+
* 1. 每个月天数不固定(28/29/30/31),且 1 号是星期几也不固定;
|
|
136
|
+
* 2. 需要用「上个月末尾几天」补齐第一行,用「下个月开头几天」补齐最后一行;
|
|
137
|
+
* 3. 跨年(1 月往前补 12 月、12 月往后补次年 1 月)必须正确。
|
|
138
|
+
*
|
|
139
|
+
* 实现方式:先算出本月 1 号相对「一周起始日」的偏移量 leading,
|
|
140
|
+
* 然后以 `new Date(year, month - 1, 1 - leading + i)` 递推生成所有格子。
|
|
141
|
+
* 原生 Date 对天数越界(负数或超出当月天数)会自动进位/借位,
|
|
142
|
+
* 因此跨月、跨年都会被自动处理,无需特判 1 月 / 12 月。
|
|
143
|
+
*
|
|
144
|
+
* @param {String} monthKey '2026-02'
|
|
145
|
+
* @param {Number} firstDayOfWeek 一周起始日,0=周日(设计图)1=周一
|
|
146
|
+
* @param {Date} today 今天(便于测试时注入)
|
|
147
|
+
* @returns {Array} 42 或 35 个格子(始终是 7 的整数倍)
|
|
148
|
+
*/
|
|
149
|
+
export function buildMonthMatrix(monthKey, firstDayOfWeek = 0, today = new Date()) {
|
|
150
|
+
const { year, month } = parseMonthKey(monthKey)
|
|
151
|
+
|
|
152
|
+
const firstDayOfMonth = new Date(year, month - 1, 1)
|
|
153
|
+
// new Date(y, m, 0) 表示「第 m 月的第 0 天」即上个月最后一天,用来取当月总天数
|
|
154
|
+
const daysInMonth = new Date(year, month, 0).getDate()
|
|
155
|
+
|
|
156
|
+
// 本月 1 号是星期几(0=周日),再换算成相对一周起始日的偏移
|
|
157
|
+
const leading = (firstDayOfMonth.getDay() - firstDayOfWeek + 7) % 7
|
|
158
|
+
// 向上取整到 7 的倍数,保证最后一行也被补满
|
|
159
|
+
const totalCells = Math.ceil((leading + daysInMonth) / 7) * 7
|
|
160
|
+
|
|
161
|
+
const cells = []
|
|
162
|
+
for (let i = 0; i < totalCells; i++) {
|
|
163
|
+
const date = new Date(year, month - 1, 1 - leading + i)
|
|
164
|
+
const cellMonth = date.getMonth() + 1
|
|
165
|
+
const isCurrentMonth = date.getFullYear() === year && cellMonth === month
|
|
166
|
+
|
|
167
|
+
cells.push({
|
|
168
|
+
date,
|
|
169
|
+
dateKey: formatDateKey(date),
|
|
170
|
+
monthKey: formatMonthKey(date),
|
|
171
|
+
year: date.getFullYear(),
|
|
172
|
+
month: cellMonth,
|
|
173
|
+
day: date.getDate(),
|
|
174
|
+
weekday: date.getDay(),
|
|
175
|
+
/** 是否属于当前渲染的月份(false 时置灰) */
|
|
176
|
+
isCurrentMonth,
|
|
177
|
+
/** 'prev' 上月补位 | 'current' 当月 | 'next' 下月补位 */
|
|
178
|
+
position: isCurrentMonth ? 'current' : i < leading ? 'prev' : 'next',
|
|
179
|
+
isToday: isSameDay(date, today),
|
|
180
|
+
isWeekend: date.getDay() === 0 || date.getDay() === 6,
|
|
181
|
+
/** 所在行索引,从 0 开始 */
|
|
182
|
+
rowIndex: Math.floor(i / 7),
|
|
183
|
+
colIndex: i % 7
|
|
184
|
+
})
|
|
185
|
+
}
|
|
186
|
+
|
|
187
|
+
return cells
|
|
188
|
+
}
|
|
189
|
+
|
|
190
|
+
/** 默认星期文案,下标即 Date.getDay() 的返回值 */
|
|
191
|
+
export const DEFAULT_WEEK_LABELS = ['周日', '周一', '周二', '周三', '周四', '周五', '周六']
|
|
192
|
+
|
|
193
|
+
/** 默认日期文案格式化:{ month: 9, day: 7 } -> '9月7日' */
|
|
194
|
+
export function defaultDayFormatter(cell) {
|
|
195
|
+
return `${cell.month}月${cell.day}日`
|
|
196
|
+
}
|
|
197
|
+
|
|
198
|
+
/** 默认月份下拉文案:'2026-09' -> '2026年9月' */
|
|
199
|
+
export function defaultMonthFormatter(monthKey) {
|
|
200
|
+
const { year, month } = parseMonthKey(monthKey)
|
|
201
|
+
return `${year}年${month}月`
|
|
202
|
+
}
|
|
@@ -0,0 +1,123 @@
|
|
|
1
|
+
<template>
|
|
2
|
+
<div class="selector-container">
|
|
3
|
+
<div class="header">函数</div>
|
|
4
|
+
<div class="tree-wrapper">
|
|
5
|
+
<el-tree
|
|
6
|
+
:data="treeData"
|
|
7
|
+
:props="defaultProps"
|
|
8
|
+
@node-click="handleNodeClick"
|
|
9
|
+
default-expand-all
|
|
10
|
+
highlight-current
|
|
11
|
+
>
|
|
12
|
+
<span
|
|
13
|
+
class="custom-tree-node"
|
|
14
|
+
slot-scope="{ node, data }"
|
|
15
|
+
:draggable="!onlyLeafClickable || node.isLeaf"
|
|
16
|
+
@dragstart="handleDragStart(node, data, $event)"
|
|
17
|
+
>
|
|
18
|
+
{{ node.label }}
|
|
19
|
+
</span>
|
|
20
|
+
</el-tree>
|
|
21
|
+
</div>
|
|
22
|
+
</div>
|
|
23
|
+
</template>
|
|
24
|
+
|
|
25
|
+
<script>
|
|
26
|
+
import { getFunctions } from "./api";
|
|
27
|
+
|
|
28
|
+
export default {
|
|
29
|
+
name: "FunctionSelector",
|
|
30
|
+
props: {
|
|
31
|
+
onlyLeafClickable: {
|
|
32
|
+
type: Boolean,
|
|
33
|
+
default: true,
|
|
34
|
+
},
|
|
35
|
+
prefix: {
|
|
36
|
+
type: String,
|
|
37
|
+
default: "F_",
|
|
38
|
+
},
|
|
39
|
+
},
|
|
40
|
+
data() {
|
|
41
|
+
return {
|
|
42
|
+
treeData: [],
|
|
43
|
+
defaultProps: {
|
|
44
|
+
children: "children",
|
|
45
|
+
label: "label",
|
|
46
|
+
},
|
|
47
|
+
};
|
|
48
|
+
},
|
|
49
|
+
mounted() {
|
|
50
|
+
this.fetchData();
|
|
51
|
+
},
|
|
52
|
+
methods: {
|
|
53
|
+
async fetchData() {
|
|
54
|
+
this.treeData = await getFunctions();
|
|
55
|
+
},
|
|
56
|
+
handleNodeClick(data, node) {
|
|
57
|
+
if (this.onlyLeafClickable && !node.isLeaf) {
|
|
58
|
+
return;
|
|
59
|
+
}
|
|
60
|
+
this.$emit("select", { ...data, value: `${this.prefix}${data.name}()` });
|
|
61
|
+
},
|
|
62
|
+
handleDragStart(node, data, e) {
|
|
63
|
+
if (this.onlyLeafClickable && !node.isLeaf) {
|
|
64
|
+
e.preventDefault();
|
|
65
|
+
return;
|
|
66
|
+
}
|
|
67
|
+
const value = `${this.prefix}${data.name}()`;
|
|
68
|
+
e.dataTransfer.setData("text/plain", value);
|
|
69
|
+
e.dataTransfer.effectAllowed = "copy";
|
|
70
|
+
|
|
71
|
+
// 设置自定义拖拽镜像
|
|
72
|
+
const div = document.createElement('div');
|
|
73
|
+
div.innerText = value;
|
|
74
|
+
div.style.position = 'absolute';
|
|
75
|
+
div.style.top = '-9999px';
|
|
76
|
+
div.style.padding = '5px 10px';
|
|
77
|
+
div.style.background = '#fff';
|
|
78
|
+
div.style.border = '1px solid #409eff';
|
|
79
|
+
div.style.borderRadius = '4px';
|
|
80
|
+
div.style.fontSize = '14px';
|
|
81
|
+
div.style.color = '#303133';
|
|
82
|
+
div.style.boxShadow = '0 2px 12px 0 rgba(0,0,0,0.1)';
|
|
83
|
+
div.style.zIndex = '9999';
|
|
84
|
+
document.body.appendChild(div);
|
|
85
|
+
|
|
86
|
+
e.dataTransfer.setDragImage(div, 0, 0);
|
|
87
|
+
|
|
88
|
+
setTimeout(() => {
|
|
89
|
+
document.body.removeChild(div);
|
|
90
|
+
}, 0);
|
|
91
|
+
},
|
|
92
|
+
},
|
|
93
|
+
};
|
|
94
|
+
</script>
|
|
95
|
+
|
|
96
|
+
<style scoped>
|
|
97
|
+
.custom-tree-node {
|
|
98
|
+
flex: 1;
|
|
99
|
+
display: flex;
|
|
100
|
+
align-items: center;
|
|
101
|
+
font-size: 14px;
|
|
102
|
+
}
|
|
103
|
+
.selector-container {
|
|
104
|
+
width: 100%;
|
|
105
|
+
height: 100%;
|
|
106
|
+
display: flex;
|
|
107
|
+
flex-direction: column;
|
|
108
|
+
}
|
|
109
|
+
|
|
110
|
+
.header {
|
|
111
|
+
padding: 10px;
|
|
112
|
+
background-color: #f5f7fa;
|
|
113
|
+
border-bottom: 1px solid #ebeef5;
|
|
114
|
+
font-weight: bold;
|
|
115
|
+
text-align: center;
|
|
116
|
+
}
|
|
117
|
+
|
|
118
|
+
.tree-wrapper {
|
|
119
|
+
flex: 1;
|
|
120
|
+
overflow-y: auto;
|
|
121
|
+
padding: 10px;
|
|
122
|
+
}
|
|
123
|
+
</style>
|
|
@@ -0,0 +1,184 @@
|
|
|
1
|
+
<template>
|
|
2
|
+
<div class="selector-container">
|
|
3
|
+
<div class="header">操作符</div>
|
|
4
|
+
<div class="tree-wrapper">
|
|
5
|
+
<el-tree
|
|
6
|
+
:data="operatorData"
|
|
7
|
+
:props="defaultProps"
|
|
8
|
+
@node-click="handleNodeClick"
|
|
9
|
+
default-expand-all
|
|
10
|
+
:expand-on-click-node="false"
|
|
11
|
+
>
|
|
12
|
+
<span
|
|
13
|
+
class="custom-tree-node"
|
|
14
|
+
slot-scope="{ node, data }"
|
|
15
|
+
:draggable="!onlyLeafClickable || !data.children"
|
|
16
|
+
@dragstart="handleDragStart(node, data, $event)"
|
|
17
|
+
>
|
|
18
|
+
<span>{{ node.label }}</span>
|
|
19
|
+
<span v-if="!data.children && data.value" class="node-value">{{ data.value }}</span>
|
|
20
|
+
</span>
|
|
21
|
+
</el-tree>
|
|
22
|
+
</div>
|
|
23
|
+
</div>
|
|
24
|
+
</template>
|
|
25
|
+
|
|
26
|
+
<script>
|
|
27
|
+
export default {
|
|
28
|
+
name: "OperatorSelector",
|
|
29
|
+
props: {
|
|
30
|
+
onlyLeafClickable: {
|
|
31
|
+
type: Boolean,
|
|
32
|
+
default: true,
|
|
33
|
+
},
|
|
34
|
+
prefix: {
|
|
35
|
+
type: String,
|
|
36
|
+
default: "",
|
|
37
|
+
},
|
|
38
|
+
},
|
|
39
|
+
data() {
|
|
40
|
+
return {
|
|
41
|
+
defaultProps: {
|
|
42
|
+
children: "children",
|
|
43
|
+
label: "label",
|
|
44
|
+
},
|
|
45
|
+
operatorData: [
|
|
46
|
+
{
|
|
47
|
+
label: "关键字",
|
|
48
|
+
children: [
|
|
49
|
+
{ label: "如果", value: "if" },
|
|
50
|
+
{ label: "否则", value: "else" },
|
|
51
|
+
],
|
|
52
|
+
},
|
|
53
|
+
{
|
|
54
|
+
label: "计算运算符",
|
|
55
|
+
children: [
|
|
56
|
+
{ label: "加", value: "+" },
|
|
57
|
+
{ label: "减", value: "-" },
|
|
58
|
+
{ label: "乘", value: "*" },
|
|
59
|
+
{ label: "除", value: "/" },
|
|
60
|
+
{ label: "取余", value: "%" },
|
|
61
|
+
{ label: "左括号", value: "(" },
|
|
62
|
+
{ label: "右括号", value: ")" },
|
|
63
|
+
],
|
|
64
|
+
},
|
|
65
|
+
{
|
|
66
|
+
label: "比较运算符",
|
|
67
|
+
children: [
|
|
68
|
+
{ label: "大于", value: ">" },
|
|
69
|
+
{ label: "小于", value: "<" },
|
|
70
|
+
{ label: "等于", value: "==" },
|
|
71
|
+
{ label: "不等于", value: "!=" },
|
|
72
|
+
{ label: "大于等于", value: ">=" },
|
|
73
|
+
{ label: "小于等于", value: "<=" },
|
|
74
|
+
],
|
|
75
|
+
},
|
|
76
|
+
{
|
|
77
|
+
label: "逻辑运算符",
|
|
78
|
+
children: [
|
|
79
|
+
{ label: "并且", value: "&&" },
|
|
80
|
+
{ label: "或者", value: "||" },
|
|
81
|
+
{ label: "非", value: "!" },
|
|
82
|
+
],
|
|
83
|
+
},
|
|
84
|
+
],
|
|
85
|
+
};
|
|
86
|
+
},
|
|
87
|
+
methods: {
|
|
88
|
+
handleNodeClick(data) {
|
|
89
|
+
// 如果配置了只允许点击叶子节点,且当前节点有子节点,则不处理
|
|
90
|
+
if (this.onlyLeafClickable && data.children) {
|
|
91
|
+
return;
|
|
92
|
+
}
|
|
93
|
+
|
|
94
|
+
// 处理特殊关键字
|
|
95
|
+
if (data.value === 'if') {
|
|
96
|
+
this.$emit("select", { label: data.label, value: `${this.prefix}如果(){\n \n}` });
|
|
97
|
+
} else if (data.value === 'else') {
|
|
98
|
+
this.$emit("select", { label: data.label, value: `${this.prefix}否则{\n \n}` });
|
|
99
|
+
} else {
|
|
100
|
+
this.$emit("select", { ...data, value: `${this.prefix}${data.value}` });
|
|
101
|
+
}
|
|
102
|
+
},
|
|
103
|
+
handleDragStart(node, data, e) {
|
|
104
|
+
if (this.onlyLeafClickable && data.children) {
|
|
105
|
+
e.preventDefault();
|
|
106
|
+
return;
|
|
107
|
+
}
|
|
108
|
+
|
|
109
|
+
let value = '';
|
|
110
|
+
if (data.value === 'if') {
|
|
111
|
+
value = `${this.prefix}如果(){\n \n}`;
|
|
112
|
+
} else if (data.value === 'else') {
|
|
113
|
+
value = `${this.prefix}否则{\n \n}`;
|
|
114
|
+
} else {
|
|
115
|
+
value = `${this.prefix}${data.value}`;
|
|
116
|
+
}
|
|
117
|
+
|
|
118
|
+
e.dataTransfer.setData("text/plain", value);
|
|
119
|
+
e.dataTransfer.effectAllowed = "copy";
|
|
120
|
+
|
|
121
|
+
// 设置自定义拖拽镜像
|
|
122
|
+
const div = document.createElement('div');
|
|
123
|
+
div.innerText = value;
|
|
124
|
+
div.style.position = 'absolute';
|
|
125
|
+
div.style.top = '-9999px';
|
|
126
|
+
div.style.padding = '5px 10px';
|
|
127
|
+
div.style.background = '#fff';
|
|
128
|
+
div.style.border = '1px solid #409eff';
|
|
129
|
+
div.style.borderRadius = '4px';
|
|
130
|
+
div.style.fontSize = '14px';
|
|
131
|
+
div.style.color = '#303133';
|
|
132
|
+
div.style.boxShadow = '0 2px 12px 0 rgba(0,0,0,0.1)';
|
|
133
|
+
div.style.zIndex = '9999';
|
|
134
|
+
// 保持换行
|
|
135
|
+
div.style.whiteSpace = 'pre';
|
|
136
|
+
document.body.appendChild(div);
|
|
137
|
+
|
|
138
|
+
e.dataTransfer.setDragImage(div, 0, 0);
|
|
139
|
+
|
|
140
|
+
setTimeout(() => {
|
|
141
|
+
document.body.removeChild(div);
|
|
142
|
+
}, 0);
|
|
143
|
+
},
|
|
144
|
+
},
|
|
145
|
+
};
|
|
146
|
+
</script>
|
|
147
|
+
|
|
148
|
+
<style scoped>
|
|
149
|
+
.selector-container {
|
|
150
|
+
width: 100%;
|
|
151
|
+
height: 100%;
|
|
152
|
+
display: flex;
|
|
153
|
+
flex-direction: column;
|
|
154
|
+
}
|
|
155
|
+
|
|
156
|
+
.header {
|
|
157
|
+
padding: 10px;
|
|
158
|
+
background-color: #f5f7fa;
|
|
159
|
+
border-bottom: 1px solid #ebeef5;
|
|
160
|
+
font-weight: bold;
|
|
161
|
+
text-align: center;
|
|
162
|
+
}
|
|
163
|
+
|
|
164
|
+
.tree-wrapper {
|
|
165
|
+
flex: 1;
|
|
166
|
+
overflow-y: auto;
|
|
167
|
+
padding: 5px;
|
|
168
|
+
}
|
|
169
|
+
|
|
170
|
+
.custom-tree-node {
|
|
171
|
+
flex: 1;
|
|
172
|
+
display: flex;
|
|
173
|
+
align-items: center;
|
|
174
|
+
justify-content: space-between;
|
|
175
|
+
font-size: 14px;
|
|
176
|
+
padding-right: 8px;
|
|
177
|
+
}
|
|
178
|
+
|
|
179
|
+
.node-value {
|
|
180
|
+
color: #909399;
|
|
181
|
+
font-size: 12px;
|
|
182
|
+
font-family: monospace;
|
|
183
|
+
}
|
|
184
|
+
</style>
|
|
@@ -0,0 +1,123 @@
|
|
|
1
|
+
<template>
|
|
2
|
+
<div class="selector-container">
|
|
3
|
+
<div class="header">参数</div>
|
|
4
|
+
<div class="tree-wrapper">
|
|
5
|
+
<el-tree
|
|
6
|
+
:data="treeData"
|
|
7
|
+
:props="defaultProps"
|
|
8
|
+
@node-click="handleNodeClick"
|
|
9
|
+
default-expand-all
|
|
10
|
+
highlight-current
|
|
11
|
+
>
|
|
12
|
+
<span
|
|
13
|
+
class="custom-tree-node"
|
|
14
|
+
slot-scope="{ node, data }"
|
|
15
|
+
:draggable="!onlyLeafClickable || node.isLeaf"
|
|
16
|
+
@dragstart="handleDragStart(node, data, $event)"
|
|
17
|
+
>
|
|
18
|
+
{{ node.label }}
|
|
19
|
+
</span>
|
|
20
|
+
</el-tree>
|
|
21
|
+
</div>
|
|
22
|
+
</div>
|
|
23
|
+
</template>
|
|
24
|
+
|
|
25
|
+
<script>
|
|
26
|
+
import { getParameters } from "./api";
|
|
27
|
+
|
|
28
|
+
export default {
|
|
29
|
+
name: "ParameterSelector",
|
|
30
|
+
props: {
|
|
31
|
+
onlyLeafClickable: {
|
|
32
|
+
type: Boolean,
|
|
33
|
+
default: true,
|
|
34
|
+
},
|
|
35
|
+
prefix: {
|
|
36
|
+
type: String,
|
|
37
|
+
default: "P_",
|
|
38
|
+
},
|
|
39
|
+
},
|
|
40
|
+
data() {
|
|
41
|
+
return {
|
|
42
|
+
treeData: [],
|
|
43
|
+
defaultProps: {
|
|
44
|
+
children: "children",
|
|
45
|
+
label: "label",
|
|
46
|
+
},
|
|
47
|
+
};
|
|
48
|
+
},
|
|
49
|
+
mounted() {
|
|
50
|
+
this.fetchData();
|
|
51
|
+
},
|
|
52
|
+
methods: {
|
|
53
|
+
async fetchData() {
|
|
54
|
+
this.treeData = await getParameters();
|
|
55
|
+
},
|
|
56
|
+
handleNodeClick(data, node) {
|
|
57
|
+
if (this.onlyLeafClickable && !node.isLeaf) {
|
|
58
|
+
return;
|
|
59
|
+
}
|
|
60
|
+
this.$emit("select", { ...data, value: `${this.prefix}${data.name}` });
|
|
61
|
+
},
|
|
62
|
+
handleDragStart(node, data, e) {
|
|
63
|
+
if (this.onlyLeafClickable && !node.isLeaf) {
|
|
64
|
+
e.preventDefault();
|
|
65
|
+
return;
|
|
66
|
+
}
|
|
67
|
+
const value = `${this.prefix}${data.name}`;
|
|
68
|
+
e.dataTransfer.setData("text/plain", value);
|
|
69
|
+
e.dataTransfer.effectAllowed = "copy";
|
|
70
|
+
|
|
71
|
+
// 设置自定义拖拽镜像
|
|
72
|
+
const div = document.createElement('div');
|
|
73
|
+
div.innerText = value;
|
|
74
|
+
div.style.position = 'absolute';
|
|
75
|
+
div.style.top = '-9999px';
|
|
76
|
+
div.style.padding = '5px 10px';
|
|
77
|
+
div.style.background = '#fff';
|
|
78
|
+
div.style.border = '1px solid #409eff';
|
|
79
|
+
div.style.borderRadius = '4px';
|
|
80
|
+
div.style.fontSize = '14px';
|
|
81
|
+
div.style.color = '#303133';
|
|
82
|
+
div.style.boxShadow = '0 2px 12px 0 rgba(0,0,0,0.1)';
|
|
83
|
+
div.style.zIndex = '9999';
|
|
84
|
+
document.body.appendChild(div);
|
|
85
|
+
|
|
86
|
+
e.dataTransfer.setDragImage(div, 0, 0);
|
|
87
|
+
|
|
88
|
+
setTimeout(() => {
|
|
89
|
+
document.body.removeChild(div);
|
|
90
|
+
}, 0);
|
|
91
|
+
},
|
|
92
|
+
},
|
|
93
|
+
};
|
|
94
|
+
</script>
|
|
95
|
+
|
|
96
|
+
<style scoped>
|
|
97
|
+
.custom-tree-node {
|
|
98
|
+
flex: 1;
|
|
99
|
+
display: flex;
|
|
100
|
+
align-items: center;
|
|
101
|
+
font-size: 14px;
|
|
102
|
+
}
|
|
103
|
+
.selector-container {
|
|
104
|
+
width: 100%;
|
|
105
|
+
height: 100%;
|
|
106
|
+
display: flex;
|
|
107
|
+
flex-direction: column;
|
|
108
|
+
}
|
|
109
|
+
|
|
110
|
+
.header {
|
|
111
|
+
padding: 10px;
|
|
112
|
+
background-color: #f5f7fa;
|
|
113
|
+
border-bottom: 1px solid #ebeef5;
|
|
114
|
+
font-weight: bold;
|
|
115
|
+
text-align: center;
|
|
116
|
+
}
|
|
117
|
+
|
|
118
|
+
.tree-wrapper {
|
|
119
|
+
flex: 1;
|
|
120
|
+
overflow-y: auto;
|
|
121
|
+
padding: 10px;
|
|
122
|
+
}
|
|
123
|
+
</style>
|
|
@@ -0,0 +1,69 @@
|
|
|
1
|
+
export const getFunctions = () => {
|
|
2
|
+
return new Promise((resolve) => {
|
|
3
|
+
setTimeout(() => {
|
|
4
|
+
resolve([
|
|
5
|
+
{
|
|
6
|
+
id: 1,
|
|
7
|
+
label: '数学函数',
|
|
8
|
+
children: [
|
|
9
|
+
{ id: 11, label: '求和', name: '求和' },
|
|
10
|
+
{ id: 12, label: '平均值', name: '平均值' },
|
|
11
|
+
{ id: 13, label: '最大值', name: '最大值' },
|
|
12
|
+
{ id: 14, label: '最小值', name: '最小值' }
|
|
13
|
+
]
|
|
14
|
+
},
|
|
15
|
+
{
|
|
16
|
+
id: 2,
|
|
17
|
+
label: '逻辑函数',
|
|
18
|
+
children: [
|
|
19
|
+
{ id: 21, label: '条件判断', name: '条件判断' },
|
|
20
|
+
{ id: 22, label: '与', name: '与' },
|
|
21
|
+
{ id: 23, label: '或', name: '或' }
|
|
22
|
+
]
|
|
23
|
+
},
|
|
24
|
+
{
|
|
25
|
+
id: 3,
|
|
26
|
+
label: '文本函数',
|
|
27
|
+
children: [
|
|
28
|
+
{ id: 31, label: '拼接', name: '拼接' },
|
|
29
|
+
{ id: 32, label: '截取', name: '截取' }
|
|
30
|
+
]
|
|
31
|
+
}
|
|
32
|
+
]);
|
|
33
|
+
}, 500);
|
|
34
|
+
});
|
|
35
|
+
};
|
|
36
|
+
|
|
37
|
+
export const getParameters = () => {
|
|
38
|
+
return new Promise((resolve) => {
|
|
39
|
+
setTimeout(() => {
|
|
40
|
+
resolve([
|
|
41
|
+
{
|
|
42
|
+
id: 100,
|
|
43
|
+
label: '基础信息',
|
|
44
|
+
children: [
|
|
45
|
+
{ id: 101, label: '员工姓名', name: '员工姓名' },
|
|
46
|
+
{ id: 102, label: '入职日期', name: '入职日期' },
|
|
47
|
+
{ id: 103, label: '部门', name: '部门' }
|
|
48
|
+
]
|
|
49
|
+
},
|
|
50
|
+
{
|
|
51
|
+
id: 200,
|
|
52
|
+
label: '薪资数据',
|
|
53
|
+
children: [
|
|
54
|
+
{
|
|
55
|
+
id: 210,
|
|
56
|
+
label: '基本工资',
|
|
57
|
+
children: [
|
|
58
|
+
{ id: 211, label: '岗位工资', name: '岗位工资' },
|
|
59
|
+
{ id: 212, label: '绩效基数', name: '绩效基数' }
|
|
60
|
+
]
|
|
61
|
+
},
|
|
62
|
+
{ id: 220, label: '奖金', name: '奖金' },
|
|
63
|
+
{ id: 230, label: '补贴', name: '补贴' }
|
|
64
|
+
]
|
|
65
|
+
}
|
|
66
|
+
]);
|
|
67
|
+
}, 500);
|
|
68
|
+
});
|
|
69
|
+
};
|