提交 a1c91de8 编写于 作者: tony001's avatar tony001

update:调整模板目录结构

上级 3ba9615b
{{#*inline "AC"}}{{>@macro/editor/auto-complete.hbs}}{{/inline}}
{{#*inline "AC_FS"}}{{>@macro/editor/auto-complete.hbs}}{{/inline}}
{{#*inline "AC_NOBUTTON"}}{{>@macro/editor/auto-complete.hbs}}{{/inline}}
{{#*inline "AC_FS_NOBUTTON"}}{{>@macro/editor/auto-complete.hbs}}{{/inline}}
{{#*inline "CHECKBOXLIST"}}{{>@macro/editor/checkbox-list.hbs}}{{/inline}}
{{#*inline "CHECKBOX"}}{{>@macro/editor/checkbox.hbs}}{{/inline}}
{{#*inline "LISTBOXPICKUP"}}{{>@macro/editor/list-box.hbs}}{{/inline}}
{{#*inline "LISTBOX"}}{{>@macro/editor/list-box.hbs}}{{/inline}}
{{#*inline "PICKEREX_LINKONLY"}}{{>@macro/editor/data-picker.hbs}}{{/inline}}
{{#*inline "PICKER"}}{{>@macro/editor/data-picker.hbs}}{{/inline}}
{{#*inline "PICKEREX_NOBUTTON"}}{{>@macro/editor/data-picker.hbs}}{{/inline}}
{{#*inline "PICKEREX_NOAC_LINK"}}{{>@macro/editor/data-picker.hbs}}{{/inline}}
{{#*inline "PICKEREX_TRIGGER_LINK"}}{{>@macro/editor/data-picker.hbs}}{{/inline}}
{{#*inline "PICKEREX_TRIGGER"}}{{>@macro/editor/data-picker.hbs}}{{/inline}}
{{#*inline "PICKEREX_NOAC"}}{{>@macro/editor/data-picker.hbs}}{{/inline}}
{{#*inline "PICKEREX_LINK"}}{{>@macro/editor/data-picker.hbs}}{{/inline}}
{{#*inline "PICKEREX_DROPDOWNVIEW"}}{{>@macro/editor/data-picker.hbs}}{{/inline}}
{{#*inline "PICKEREX_DROPDOWNVIEW_LINK"}}{{>@macro/editor/data-picker.hbs}}{{/inline}}
{{#*inline "ADDRESSPICKUP"}}{{>@macro/editor/data-picker.hbs}}{{/inline}}
{{#*inline "ADDRESSPICKUP_AC"}}{{>@macro/editor/data-picker.hbs}}{{/inline}}
{{#*inline "DATEPICKEREX"}}{{>@macro/editor/date-picker.hbs}}{{/inline}}
{{#*inline "DATEPICKEREX_NOTIME"}}{{>@macro/editor/date-picker.hbs}}{{/inline}}
{{#*inline "DATEPICKER"}}{{>@macro/editor/date-picker.hbs}}{{/inline}}
{{#*inline "DATEPICKEREX_HOUR"}}{{>@macro/editor/date-picker.hbs}}{{/inline}}
{{#*inline "DATEPICKEREX_MINUTE"}}{{>@macro/editor/date-picker.hbs}}{{/inline}}
{{#*inline "DATEPICKEREX_SECOND"}}{{>@macro/editor/date-picker.hbs}}{{/inline}}
{{#*inline "DATEPICKEREX_NODAY"}}{{>@macro/editor/date-picker.hbs}}{{/inline}}
{{#*inline "DATEPICKEREX_NODAY_NOSECOND"}}{{>@macro/editor/date-picker.hbs}}{{/inline}}
{{#*inline "DROPDOWNLIST"}}{{>@macro/editor/dropdown-list.hbs}}{{/inline}}
{{#*inline "DROPDOWNLIST_100"}}{{>@macro/editor/dropdown-list.hbs}}{{/inline}}
{{#*inline "MDROPDOWNLIST"}}{{>@macro/editor/dropdown-list.hbs}}{{/inline}}
{{#*inline "IPADDRESSTEXTBOX"}}{{>@macro/editor/input-ip.hbs}}{{/inline}}
{{#*inline "TEXTBOX"}}{{>@macro/editor/input.hbs}}{{/inline}}
{{#*inline "NUMBER"}}{{>@macro/editor/input.hbs}}{{/inline}}
{{#*inline "PASSWORD"}}{{>@macro/editor/input.hbs}}{{/inline}}
{{#*inline "TEXTAREA"}}{{>@macro/editor/input.hbs}}{{/inline}}
{{#*inline "TEXTAREA_10"}}{{>@macro/editor/input.hbs}}{{/inline}}
{{#*inline "RADIOBUTTONLIST"}}{{>@macro/editor/radio-group.hbs}}{{/inline}}
{{#*inline "RATING"}}{{>@macro/editor/rating.hbs}}{{/inline}}
{{#*inline "RAW"}}{{>@macro/editor/raw.hbs}}{{/inline}}
{{#*inline "SLIDER"}}{{>@macro/editor/slider.hbs}}{{/inline}}
{{#*inline "SPAN"}}{{>@macro/editor/span.hbs}}{{/inline}}
{{#*inline "STEPPER"}}{{>@macro/editor/stepper.hbs}}{{/inline}}
{{#*inline "SWITCH"}}{{>@macro/editor/switch.hbs}}{{/inline}}
{{#*inline "FILEUPLOADER"}}{{>@macro/editor/upload.hbs}}{{/inline}}
{{#*inline "FILEUPLOADER_ONE"}}{{>@macro/editor/upload.hbs}}{{/inline}}
{{#*inline "PICTURE"}}{{>@macro/editor/upload.hbs}}{{/inline}}
{{#*inline "PICTURE_ONE"}}{{>@macro/editor/upload.hbs}}{{/inline}}
{{#*inline "PICKUPVIEW"}}{{>@macro/editor/data-picker-view.hbs}}{{/inline}}
{{#*inline "PICKEREX_DROPDOWNVIEW"}}{{>@macro/editor/data-picker-view.hbs}}{{/inline}}
{{#*inline "PICKEREX_DROPDOWNVIEW_LINK"}}{{>@macro/editor/data-picker-view.hbs}}{{/inline}}
\ No newline at end of file
{{#*inline "FORMPAGE"}}{{>@macro/form-detail/form-page.hbs}}{{/inline}}
{{#*inline "GROUPPANEL"}}{{>@macro/form-detail/form-group-panel.hbs}}{{/inline}}
{{#*inline "FORMITEM"}}{{>@macro/form-detail/form-item.hbs}}{{/inline}}
{{#*inline "TABPANEL"}}{{>@macro/form-detail/form-tabpanel.hbs}}{{/inline}}
{{#*inline "BUTTON"}}{{>@macro/form-detail/form-button.hbs}}{{/inline}}
{{#*inline "RAWITEM"}}{{>@macro/form-detail/form-rawitem.hbs}}{{/inline}}
{{#*inline "IFRAME"}}{{>@macro/form-detail/form-iframe.hbs}}{{/inline}}
{{#*inline "FORMPART"}}{{>@macro/form-detail/form-formpart.hbs}}{{/inline}}
{{#*inline "TABPAGE"}}{{>@macro/form-detail/form-tabpage.hbs}}{{/inline}}
{{#*inline "DRUIPART"}}{{>@macro/form-detail/form-druipart.hbs}}{{/inline}}
{{#*inline "FORMDETAILSMODEL"}}{{>@macro/form-detail/form-details-model.hbs}}{{/inline}}
{{#*inline "FORMACTIONMODEL"}}{{>@macro/form-detail/form-action-model.hbs}}{{/inline}}
\ No newline at end of file
{{#*inline "AC"}}{{>@macro/front-end/editors/auto-complete.hbs}}{{/inline}}
{{#*inline "AC_FS"}}{{>@macro/front-end/editors/auto-complete.hbs}}{{/inline}}
{{#*inline "AC_NOBUTTON"}}{{>@macro/front-end/editors/auto-complete.hbs}}{{/inline}}
{{#*inline "AC_FS_NOBUTTON"}}{{>@macro/front-end/editors/auto-complete.hbs}}{{/inline}}
{{#*inline "CHECKBOXLIST"}}{{>@macro/front-end/editors/checkbox-list.hbs}}{{/inline}}
{{#*inline "CHECKBOX"}}{{>@macro/front-end/editors/checkbox.hbs}}{{/inline}}
{{#*inline "LISTBOXPICKUP"}}{{>@macro/front-end/editors/list-box.hbs}}{{/inline}}
{{#*inline "LISTBOX"}}{{>@macro/front-end/editors/list-box.hbs}}{{/inline}}
{{#*inline "PICKEREX_LINKONLY"}}{{>@macro/front-end/editors/data-picker.hbs}}{{/inline}}
{{#*inline "PICKER"}}{{>@macro/front-end/editors/data-picker.hbs}}{{/inline}}
{{#*inline "PICKEREX_NOBUTTON"}}{{>@macro/front-end/editors/data-picker.hbs}}{{/inline}}
{{#*inline "PICKEREX_NOAC_LINK"}}{{>@macro/front-end/editors/data-picker.hbs}}{{/inline}}
{{#*inline "PICKEREX_TRIGGER_LINK"}}{{>@macro/front-end/editors/data-picker.hbs}}{{/inline}}
{{#*inline "PICKEREX_TRIGGER"}}{{>@macro/front-end/editors/data-picker.hbs}}{{/inline}}
{{#*inline "PICKEREX_NOAC"}}{{>@macro/front-end/editors/data-picker.hbs}}{{/inline}}
{{#*inline "PICKEREX_LINK"}}{{>@macro/front-end/editors/data-picker.hbs}}{{/inline}}
{{#*inline "PICKEREX_DROPDOWNVIEW"}}{{>@macro/front-end/editors/data-picker.hbs}}{{/inline}}
{{#*inline "PICKEREX_DROPDOWNVIEW_LINK"}}{{>@macro/front-end/editors/data-picker.hbs}}{{/inline}}
{{#*inline "ADDRESSPICKUP"}}{{>@macro/front-end/editors/data-picker.hbs}}{{/inline}}
{{#*inline "ADDRESSPICKUP_AC"}}{{>@macro/front-end/editors/data-picker.hbs}}{{/inline}}
{{#*inline "DATEPICKEREX"}}{{>@macro/front-end/editors/date-picker.hbs}}{{/inline}}
{{#*inline "DATEPICKEREX_NOTIME"}}{{>@macro/front-end/editors/date-picker.hbs}}{{/inline}}
{{#*inline "DATEPICKER"}}{{>@macro/front-end/editors/date-picker.hbs}}{{/inline}}
{{#*inline "DATEPICKEREX_HOUR"}}{{>@macro/front-end/editors/date-picker.hbs}}{{/inline}}
{{#*inline "DATEPICKEREX_MINUTE"}}{{>@macro/front-end/editors/date-picker.hbs}}{{/inline}}
{{#*inline "DATEPICKEREX_SECOND"}}{{>@macro/front-end/editors/date-picker.hbs}}{{/inline}}
{{#*inline "DATEPICKEREX_NODAY"}}{{>@macro/front-end/editors/date-picker.hbs}}{{/inline}}
{{#*inline "DATEPICKEREX_NODAY_NOSECOND"}}{{>@macro/front-end/editors/date-picker.hbs}}{{/inline}}
{{#*inline "DROPDOWNLIST"}}{{>@macro/front-end/editors/dropdown-list.hbs}}{{/inline}}
{{#*inline "DROPDOWNLIST_100"}}{{>@macro/front-end/editors/dropdown-list.hbs}}{{/inline}}
{{#*inline "MDROPDOWNLIST"}}{{>@macro/front-end/editors/dropdown-list.hbs}}{{/inline}}
{{#*inline "IPADDRESSTEXTBOX"}}{{>@macro/front-end/editors/input-ip.hbs}}{{/inline}}
{{#*inline "TEXTBOX"}}{{>@macro/front-end/editors/input.hbs}}{{/inline}}
{{#*inline "NUMBER"}}{{>@macro/front-end/editors/input.hbs}}{{/inline}}
{{#*inline "PASSWORD"}}{{>@macro/front-end/editors/input.hbs}}{{/inline}}
{{#*inline "TEXTAREA"}}{{>@macro/front-end/editors/input.hbs}}{{/inline}}
{{#*inline "TEXTAREA_10"}}{{>@macro/front-end/editors/input.hbs}}{{/inline}}
{{#*inline "RADIOBUTTONLIST"}}{{>@macro/front-end/editors/radio-group.hbs}}{{/inline}}
{{#*inline "RATING"}}{{>@macro/front-end/editors/rating.hbs}}{{/inline}}
{{#*inline "RAW"}}{{>@macro/front-end/editors/raw.hbs}}{{/inline}}
{{#*inline "SLIDER"}}{{>@macro/front-end/editors/slider.hbs}}{{/inline}}
{{#*inline "SPAN"}}{{>@macro/front-end/editors/span.hbs}}{{/inline}}
{{#*inline "STEPPER"}}{{>@macro/front-end/editors/stepper.hbs}}{{/inline}}
{{#*inline "SWITCH"}}{{>@macro/front-end/editors/switch.hbs}}{{/inline}}
{{#*inline "FILEUPLOADER"}}{{>@macro/front-end/editors/upload.hbs}}{{/inline}}
{{#*inline "FILEUPLOADER_ONE"}}{{>@macro/front-end/editors/upload.hbs}}{{/inline}}
{{#*inline "PICTURE"}}{{>@macro/front-end/editors/upload.hbs}}{{/inline}}
{{#*inline "PICTURE_ONE"}}{{>@macro/front-end/editors/upload.hbs}}{{/inline}}
{{#*inline "PICKUPVIEW"}}{{>@macro/front-end/editors/data-picker-view.hbs}}{{/inline}}
{{#*inline "PICKEREX_DROPDOWNVIEW"}}{{>@macro/front-end/editors/data-picker-view.hbs}}{{/inline}}
{{#*inline "PICKEREX_DROPDOWNVIEW_LINK"}}{{>@macro/front-end/editors/data-picker-view.hbs}}{{/inline}}
\ No newline at end of file
......@@ -23,4 +23,4 @@
{{/items}}
{{/page.viewToolBarItems}}
],
{{> @macro/front-end/view/common/controlAction.hbs}}
\ No newline at end of file
{{> @macro/front-end/views/common/control-action}}
\ No newline at end of file
{{#each items as | formDetail |}}
{{#if (and (eq formDetail.detailType "BUTTON") (formDetail.psUIAction))}}
{{#formDetail.psUIAction}}
{{uIActionTag}}: { disabled: false, visible: true, noPrivDisplayMode: "{{noPrivDisplayMode}}", dataAccessAction: '{{dataAccessAction}}', actionTarget: '{{actionTarget}}' },
'{{uIActionTag}}': { disabled: false, visible: true, noPrivDisplayMode: "{{noPrivDisplayMode}}", dataAccessAction: '{{dataAccessAction}}', actionTarget: '{{actionTarget}}' },
{{/formDetail.psUIAction}}
{{/if}}
{{#if (and (eq formDetail.detailType "GROUPPANEL") (formDetail.psSUIActionGroup.psUIActionGroupDetails))}}
{{#each formDetail.psSUIActionGroup.psUIActionGroupDetails as | detail | }}
{{#detail.psUIAction}}
{{uIActionTag}}: { disabled: false, visible: true, noPrivDisplayMode: "{{noPrivDisplayMode}}", dataAccessAction: '{{dataAccessAction}}', actionTarget: '{{actionTarget}}' },
'{{uIActionTag}}': { disabled: false, visible: true, noPrivDisplayMode: "{{noPrivDisplayMode}}", dataAccessAction: '{{dataAccessAction}}', actionTarget: '{{actionTarget}}' },
{{/detail.psUIAction}}
{{/each}}
{{/if}}
......
......@@ -17,7 +17,7 @@
</div>
{{else}}
<a-col
{{> @macro/front-end/ctrl/common/layoutPos.hbs item=item.psLayoutPos}} >
{{> @macro/front-end/widgets/common/layout-pos.hbs item=item.psLayoutPos}} >
<a-button
type="primary"
v-show="state.detailsModel.{{item.codeName}}.visible"
......
......@@ -30,7 +30,7 @@
</div>
{{else}}
<a-col
{{> @macro/front-end/ctrl/common/layoutPos.hbs item=item.psLayoutPos}} >
{{> @macro/front-end/widgets/common/layout-pos.hbs item=item.psLayoutPos}} >
<IbizFormGroup
v-show="state.detailsModel.{{item.codeName}}.visible"
name="{{item.codeName}}"
......
......@@ -6,7 +6,7 @@
</div>
{{else}}
<a-col
{{> @macro/front-end/ctrl/common/layoutPos.hbs item=item.psLayoutPos}} >
{{> @macro/front-end/widgets/common/layout-pos.hbs item=item.psLayoutPos}} >
<div v-show="state.detailsModel.{{item.codeName}}.visible" class="ibiz-form-iframe" style="{{#if item.contentHeight}}height: {{item.contentHeight}}px;{{/if}}{{#if item.contentWidth}}width: {{item.contentWidth}}px{{/if}}">
<iframe src="{{item.iFrameUrl}}" style="height: 100%;width: 100%;border: 0"></iframe>
</div>
......
{{>@macro/editor/include-editor.hbs}}
{{>@macro/front-end/editors/include-editor.hbs}}
{{#eq item.psLayoutPos 'FLEX'}}
<div style="flex-grow: {{#if item.psLayoutPos.grow}}{{item.psLayoutPos.grow}}{{else}}0{{/if}};">
<IbizFormItem v-show="state.detailsModel.{{item.codeName}}.visible" name="{{item.codeName}}" label="{{item.caption}}">
......@@ -9,7 +9,7 @@
</div>
{{else}}
<a-col
{{> @macro/front-end/ctrl/common/layoutPos.hbs item=item.psLayoutPos}} >
{{> @macro/front-end/widgets/common/layout-pos.hbs item=item.psLayoutPos}} >
<IbizFormItem v-show="state.detailsModel.{{item.codeName}}.visible" name="{{item.codeName}}" label="{{item.caption}}">
{{#if item.psEditor}}
{{>(lookup . 'item.psEditor.editorType') item=item ctrlType="form"}}
......
......@@ -10,7 +10,7 @@
</div>
{{else}}
<a-col
{{> @macro/front-end/ctrl/common/layoutPos.hbs item=item.psLayoutPos}} >
{{> @macro/front-end/widgets/common/layout-pos.hbs item=item.psLayoutPos}} >
<IbizRaw
v-show="state.detailsModel.{{item.codeName}}.visible"
{{#if item.psSysCss}}class="{{item.psSysCss.cssName}}"{{/if}}
......
......@@ -8,7 +8,7 @@
</div>
{{else}}
<a-col
{{> @macro/front-end/ctrl/common/layoutPos.hbs item=item.psLayoutPos}} >
{{> @macro/front-end/widgets/common/layout-pos.hbs item=item.psLayoutPos}} >
<a-tabs class="ibiz-form-page">
{{#each item.psDEFormPages as | formPage | }}
{{>(lookup . 'formPage.detailType') item=formPage }}
......
{{#*inline "FORMPAGE"}}{{>@macro/front-end/widgets/form-detail/form-page.hbs}}{{/inline}}
{{#*inline "GROUPPANEL"}}{{>@macro/front-end/widgets/form-detail/form-group-panel.hbs}}{{/inline}}
{{#*inline "FORMITEM"}}{{>@macro/front-end/widgets/form-detail/form-item.hbs}}{{/inline}}
{{#*inline "TABPANEL"}}{{>@macro/front-end/widgets/form-detail/form-tabpanel.hbs}}{{/inline}}
{{#*inline "BUTTON"}}{{>@macro/front-end/widgets/form-detail/form-button.hbs}}{{/inline}}
{{#*inline "RAWITEM"}}{{>@macro/front-end/widgets/form-detail/form-rawitem.hbs}}{{/inline}}
{{#*inline "IFRAME"}}{{>@macro/front-end/widgets/form-detail/form-iframe.hbs}}{{/inline}}
{{#*inline "FORMPART"}}{{>@macro/front-end/widgets/form-detail/form-formpart.hbs}}{{/inline}}
{{#*inline "TABPAGE"}}{{>@macro/front-end/widgets/form-detail/form-tabpage.hbs}}{{/inline}}
{{#*inline "DRUIPART"}}{{>@macro/front-end/widgets/form-detail/form-druipart.hbs}}{{/inline}}
{{#*inline "FORMDETAILSMODEL"}}{{>@macro/front-end/widgets/form-detail/form-details-model.hbs}}{{/inline}}
{{#*inline "FORMACTIONMODEL"}}{{>@macro/front-end/widgets/form-detail/form-action-model.hbs}}{{/inline}}
\ No newline at end of file
{{>@macro/editor/include-editor.hbs}}
{{>@macro/front-end/editors/include-editor.hbs}}
{{#if (eq item.columnType 'GROUPGRIDCOLUMN')}}
{{#each item.psDEGridColumns as | column |}}
{{>(lookup 'COLUMN') item=column ctrl=ctrl}}
......
{{#*inline "COLUMN"}}{{>@macro/front-end/widgets/grid-detail/grid-column.hbs}}{{/inline}}
{{#*inline "COLUMNMODEL"}}{{>@macro/front-end/widgets/grid-detail/grid-column-model.hbs}}{{/inline}}
{{#*inline "UACOLUMNMODEL"}}{{>@macro/front-end/widgets/grid-detail/grid-uacolumn-model.hbs}}{{/inline}}
\ No newline at end of file
{{#*inline "MENUITEM"}}{{>@macro/front-end/widgets/menu-detail/menu-item.hbs}}{{/inline}}
{{#*inline "COLUMN"}}{{>@macro/grid-detail/grid-column.hbs}}{{/inline}}
{{#*inline "COLUMNMODEL"}}{{>@macro/grid-detail/grid-column-model.hbs}}{{/inline}}
{{#*inline "UACOLUMNMODEL"}}{{>@macro/grid-detail/grid-uacolumn-model.hbs}}{{/inline}}
\ No newline at end of file
......@@ -49,7 +49,7 @@ export class {{pascalCase appEntity.codeName}}ServiceBase extends EntityService
{{#if singleAppMethod.psDEServiceAPIMethod}}
{{! 远端接口 }}
{{> @macro/entity/service-remote-method.hbs singleAppMethod=singleAppMethod}}
{{> @macro/front-end/entity/service-remote-method.hbs singleAppMethod=singleAppMethod}}
{{/if}}
{{/if}}
{{/each}}
......
......@@ -25,7 +25,7 @@ export const AppViewConfig:IParam = {
"iconCls": "{{appView.psSysImage.cssClass}}",
{{/if}}
"viewType": "{{appView.viewType}}",
"fileDir": "@page/{{lowerCase app.codeName}}/{{spinalCase appView.codeName}}"
"fileDir": "@views/{{lowerCase app.codeName}}/{{spinalCase appView.codeName}}"
}{{#unless @last}},{{/unless}}
{{/each}}
}
\ No newline at end of file
......@@ -12,7 +12,7 @@ const routes = [
meta: {
tag: '{{app.defaultPSAppIndexView.codeName}}'
},
component: () => import("@page/{{spinalCase app.defaultPSAppIndexView.psAppModule.codeName}}/{{spinalCase app.defaultPSAppIndexView.codeName}}"),
component: () => import("@views/{{spinalCase app.defaultPSAppIndexView.psAppModule.codeName}}/{{spinalCase app.defaultPSAppIndexView.codeName}}"),
children: [
{{#each app.appEntityResources as |appEntityResource|}}
{{#if appEntityResource.appDataEntity.allPSAppViews}}
......@@ -23,7 +23,7 @@ const routes = [
meta: {
tag:'{{appView.codeName}}'
},
component: () => import("@page/{{spinalCase appView.psAppModule.codeName}}/{{spinalCase appView.codeName}}"),
component: () => import("@views/{{spinalCase appView.psAppModule.codeName}}/{{spinalCase appView.codeName}}"),
},
{{/if}}
{{/each}}
......
......@@ -55,7 +55,7 @@ export class AppDrawer {
try {
let subject: null | Subject<any> = new Subject<any>();
let props = { view: view, context: params.context, viewParams: params.viewParams, isFullscreen: params.isFullscreen, subject: subject, options: options };
let dir = view.fileDir?.replace(/@page/, '');
let dir = view.fileDir?.replace(/@views/, '');
//Vite 支持使用特殊的 import.meta.glob 函数从文件系统导入多个模块
const modules = import.meta.glob('../../page/*/*/index.ts');
const AsyncComp = defineAsyncComponent({
......
......@@ -63,7 +63,7 @@ export class AppModal {
try {
let subject: null | Subject<any> = new Subject<any>();
let props = { view: view, context: params.context, viewParams: params.viewParams, isFullscreen: params.isFullscreen, subject: subject, options: options };
let dir = view.fileDir?.replace(/@page/, '');
let dir = view.fileDir?.replace(/@views/, '');
//Vite 支持使用特殊的 import.meta.glob 函数从文件系统导入多个模块
const modules = import.meta.glob('../../page/*/*/index.ts');
const AsyncComp = defineAsyncComponent({
......
......@@ -109,7 +109,7 @@ export class AppPopover {
let subject: null | Subject<any> = new Subject<any>();
let props = { element: element, view: view, context: params.context, viewParams: params.viewParams, isFullscreen: params.isFullscreen, subject: subject, options: options };
// 解析文件路径
let dir = view.fileDir?.replace(/@page/, '');
let dir = view.fileDir?.replace(/@views/, '');
// Vite 支持使用特殊的 import.meta.glob 函数从文件系统导入多个模块
const modules = import.meta.glob('../../page/*/*/index.ts');
// 创建一个只有在需要时才会加载的异步组件
......
export const ViewConfig = {
gridRowActiveMode: {{page.gridRowActiveMode}},
rowEditState: {{#if page.enableRowEdit}}{{page.rowEditDefault}}{{else}}false{{/if}},
{{> @macro/front-end/view/common/viewBaseConfig.hbs}}
{{> @macro/front-end/views/common/view-base-config.hbs}}
};
\ No newline at end of file
{{>@macro/menu-detail/include-menu.hbs}}
{{>@macro/front-end/widgets/menu-detail/include-menu.hbs}}
export const CtrlConfig = {
controlCodeName: '{{ctrl.codeName}}',
controlName: '{{ctrl.name}}',
......
{{>@macro/form-detail/include-form.hbs}}
{{>@macro/front-end/widgets/form-detail/include-form.hbs}}
import { ControlVOBase, verifyRules, EditFormService } from '@core';
import { {{pascalCase ctrl.psAppDataEntity.codeName}}Service } from '@api/{{spinalCase ctrl.psAppDataEntity.codeName}}/{{spinalCase ctrl.psAppDataEntity.codeName}}-service';
......
{{>@macro/form-detail/include-form.hbs}}
{{>@macro/front-end/widgets/form-detail/include-form.hbs}}
<script setup lang="ts">
import { Subject } from 'rxjs';
import { CtrlConfig } from './{{spinalCase ctrl.codeName}}-form-config';
......
{{>@macro/grid-detail/include-grid.hbs}}
{{>@macro/front-end/widgets/grid-detail/include-grid.hbs}}
import { ControlVOBase, IParam, GridService } from '@core';
import { {{pascalCase ctrl.psAppDataEntity.codeName}}Service } from '@api/{{spinalCase ctrl.psAppDataEntity.codeName}}/{{spinalCase ctrl.psAppDataEntity.codeName}}-service';
......
{{>@macro/grid-detail/include-grid.hbs}}
{{>@macro/front-end/widgets/grid-detail/include-grid.hbs}}
<script setup lang="ts">
import { Subject } from 'rxjs';
import { CtrlConfig } from './{{spinalCase ctrl.codeName}}-grid-config';
......
......@@ -23,8 +23,6 @@
"@components/*":["src/components/*"],
"@views":["src/views"],
"@views/*":["src/views/*"],
"@page":["src/page"],
"@page/*":["src/page/*"],
"@widgets":["src/widgets"],
"@widgets/*":["src/widgets/*"],
"@static":["public"],
......
......@@ -16,7 +16,6 @@ export default defineConfig({
'@api': path.resolve(__dirname, 'src/api'),
'@components': path.resolve(__dirname, 'src/components'),
'@views': path.resolve(__dirname, 'src/views'),
'@page': path.resolve(__dirname, 'src/page'),
'@widgets': path.resolve(__dirname, 'src/widgets'),
'@static': path.resolve(__dirname, 'public'),
'@': path.resolve(__dirname, 'src'),
......
const path = require('path');
const os = require('os');
function resolve(dir) {
return path.join(__dirname, dir)
}
//{{app.codeName}}
module.exports = {
publicPath: './',
// 去除 map 文件 1
productionSourceMap: false,
outputDir:"../{{projectName}}-app/{{projectName}}-app-{{lowerCase app.codeName}}/target/classes/META-INF/resources",
devServer: {
host: '0.0.0.0',
port: 8111,
compress: true,
disableHostCheck: true,
// proxy: "http://127.0.0.1:8080/",
historyApiFallback: {
rewrites: [
]
}
},
pages: {
apiview: {
// page 的入口
entry: 'src/pages/api/{{app.main}}/main.ts',
// 模板来源
template: 'src/template.html',
// 在 dist/index.html 的输出
filename: 'index.html',
// 当使用 title 选项时,
// template 中的 title 标签需要是 <title><%= htmlWebpackPlugin.options.title %></title>
title: '{{app.defaultPSAppIndexView.title}}',
// 在这个页面中包含的块,默认情况下会包含
// 提取出来的通用 chunk 和 vendor chunk。
// chunks: ['chunk-vendors', 'chunk-common', 'index']
},
},
// 多核打包
parallel: os.cpus().length > 1,
chainWebpack: (config) => {
// 删除自动计算预加载资源
config.plugins.delete('preload-apiview')
// 删除预加载资源
config.plugins.delete('prefetch-apiview')
config.resolve.alias
.set('@ibizsys', resolve('src/ibizsys'))
.set('@page', resolve('src/page'))
.set('@components', resolve('src/components'))
.set('@widgets', resolve('src/widgets'))
.set('@engine', resolve('src/engine'))
.set('@interface', resolve('src/interface'))
.set('@locale', resolve('src/locale'))
.set('@mock', resolve('src/mock'))
.set('@ui-service', resolve('src/ui-service'))
.set('@api', resolve('src/api'))
.set('@codelist', resolve('src/codelist'))
},
configureWebpack: config => {
let ForkTsCheckerPlugin;
if(config.plugins.length > 0){
ForkTsCheckerPlugin = config.plugins.find(element =>{
return element.workersNumber && element.memoryLimit;
})
}
if (Object.is(config.mode, 'production')) {
// 最大进程数
ForkTsCheckerPlugin.workersNumber = os.cpus().length > 4 ? 4 : os.cpus().length; // 会占用额外内存不释放,不建议开发阶段使用
// 单个进程最大使用内存
ForkTsCheckerPlugin.memoryLimit = 4096;
} else {
// 最大进程数
// ForkTsCheckerPlugin.workersNumber = os.cpus().length > 4 ? 4 : os.cpus().length; // 会占用额外内存不释放,不建议开发阶段使用
// 单个进程最大使用内存
ForkTsCheckerPlugin.memoryLimit = 4096;
}
},
}
\ No newline at end of file
......@@ -118,6 +118,11 @@
resolved "https://registry.npmmirror.com/@popperjs/core/download/@popperjs/core-2.11.0.tgz#6734f8ebc106a0860dff7f92bf90df193f0935d7"
integrity sha512-zrsUxjLOKAzdewIDRWy9nsV1GQsKBCWaGwsZQlCgr6/q+vjyZhFgqedLfFBuI9anTPEUT4APq9Mu0SZBTzIcGQ==
"@popperjs/core@^2.9.2":
version "2.11.2"
resolved "https://registry.yarnpkg.com/@popperjs/core/-/core-2.11.2.tgz#830beaec4b4091a9e9398ac50f865ddea52186b9"
integrity sha512-92FRmppjjqz29VMJ2dn+xdyXZBrMlE42AV6Kq6BwjWV7CNUW1hs2FtxSNLQE+gJhaZ6AAmYuO9y8dshhcBl7vA==
"@rollup/pluginutils@^4.1.1":
version "4.1.2"
resolved "https://registry.npmmirror.com/@rollup/pluginutils/download/@rollup/pluginutils-4.1.2.tgz#ed5821c15e5e05e32816f5fb9ec607cdf5a75751"
......
Markdown 格式
0% or
您添加了 0 到此讨论。请谨慎行事。
先完成此消息的编辑!
想要评论请 注册