diff --git a/src/api/platform/system/entity/gencodeTemplateObj.ts b/src/api/platform/system/entity/gencodeTemplateObj.ts index 24890b3..60a10a3 100644 --- a/src/api/platform/system/entity/gencodeTemplateObj.ts +++ b/src/api/platform/system/entity/gencodeTemplateObj.ts @@ -11,6 +11,7 @@ export interface GencodeTemplateObj extends CommonEntity { defaultContents: string; sort: string; isChild: string; + index?: string; [key: string]: any; } diff --git a/src/components/AceEditor/src/config.ts b/src/components/AceEditor/src/config.ts index 4b9196a..116b7e4 100644 --- a/src/components/AceEditor/src/config.ts +++ b/src/components/AceEditor/src/config.ts @@ -1,3 +1,5 @@ + +// 语言配置 import ace from 'ace-builds'; import modeJsonUrl from 'ace-builds/src-noconflict/mode-json?url'; @@ -12,6 +14,10 @@ ace.config.setModuleUrl('ace/mode/html', modeHtmlUrl); import modeYamlUrl from 'ace-builds/src-noconflict/mode-yaml?url'; ace.config.setModuleUrl('ace/mode/yaml', modeYamlUrl); +import modeVelocityUrl from 'ace-builds/src-noconflict/mode-velocity?url'; +ace.config.setModuleUrl('ace/mode/velocity', modeVelocityUrl); + +// 主题配置 import themeGithubUrl from 'ace-builds/src-noconflict/theme-github?url'; ace.config.setModuleUrl('ace/theme/github', themeGithubUrl); @@ -24,6 +30,7 @@ ace.config.setModuleUrl('ace/theme/monokai', themeMonokaiUrl); import themeDraculaUrl from 'ace-builds/src-noconflict/theme-dracula?url'; ace.config.setModuleUrl('ace/theme/dracula', themeDraculaUrl); +// 浏览器后台多线程配置 import workerBaseUrl from 'ace-builds/src-noconflict/worker-base?url'; ace.config.setModuleUrl('ace/mode/base', workerBaseUrl); @@ -39,6 +46,7 @@ ace.config.setModuleUrl('ace/mode/html_worker', workerHtmlUrl); import workerYamlUrl from 'ace-builds/src-noconflict/worker-yaml?url'; ace.config.setModuleUrl('ace/mode/yaml_worker', workerYamlUrl); +// 快速补全代码段配置 import snippetsHtmlUrl from 'ace-builds/src-noconflict/snippets/html?url'; ace.config.setModuleUrl('ace/snippets/html', snippetsHtmlUrl); diff --git a/src/views/system/devtools/template/TemplateModal.vue b/src/views/system/devtools/template/TemplateModal.vue index 3fd9e92..64d0aa7 100644 --- a/src/views/system/devtools/template/TemplateModal.vue +++ b/src/views/system/devtools/template/TemplateModal.vue @@ -1,27 +1,91 @@ + diff --git a/src/views/system/devtools/template/TemplatePromptModal.vue b/src/views/system/devtools/template/TemplatePromptModal.vue new file mode 100644 index 0000000..dfda8c9 --- /dev/null +++ b/src/views/system/devtools/template/TemplatePromptModal.vue @@ -0,0 +1,81 @@ + + +