代码生成使用简化请求路径时,api文件名中不含模块名。
This commit is contained in:
@@ -4,7 +4,7 @@
|
||||
<template>
|
||||
<name>vueApi</name>
|
||||
<filePath>${frontDir}/packages${modulePath}/api${modulePath}${subModulePath}</filePath>
|
||||
<fileName>${className}.ts</fileName>
|
||||
<fileName>${funName}.ts</fileName>
|
||||
<content><![CDATA[
|
||||
/**
|
||||
* Copyright (c) 2013-Now http://jeesite.com All rights reserved.
|
||||
|
||||
@@ -63,7 +63,7 @@
|
||||
import { Icon } from '@jeesite/core/components/Icon';
|
||||
import { BasicForm, FormSchema, useForm } from '@jeesite/core/components/Form';
|
||||
import { Basic${modalOrDrawer}, use${modalOrDrawer}Inner } from '@jeesite/core/components/${modalOrDrawer}';
|
||||
import { ${ClassName}, ${className}Save, ${className}Form<% if(table.isTreeEntity){ %>, ${className}TreeData<% } %> } from '@jeesite/${moduleMinus}/api${modulePath}${subModulePath}/${className}';
|
||||
import { ${ClassName}, ${className}Save, ${className}Form<% if(table.isTreeEntity){ %>, ${className}TreeData<% } %> } from '@jeesite/${moduleMinus}/api${modulePath}${subModulePath}/${funName}';
|
||||
<%
|
||||
var userselectExists = false;
|
||||
var officeselectExists = false;
|
||||
|
||||
@@ -72,7 +72,7 @@
|
||||
<% if (table.childList.~size > 0){ %>
|
||||
import { BasicTable, useTable } from '@jeesite/core/components/Table';
|
||||
<% } %>
|
||||
import { ${ClassName}, ${className}Save, ${className}Form<% if(table.isTreeEntity){ %>, ${className}TreeData<% } %> } from '@jeesite/${moduleMinus}/api${modulePath}${subModulePath}/${className}';
|
||||
import { ${ClassName}, ${className}Save, ${className}Form<% if(table.isTreeEntity){ %>, ${className}TreeData<% } %> } from '@jeesite/${moduleMinus}/api${modulePath}${subModulePath}/${funName}';
|
||||
<%
|
||||
var userselectExists = false;
|
||||
var officeselectExists = false;
|
||||
|
||||
@@ -51,7 +51,7 @@
|
||||
import { downloadByUrl } from '@jeesite/core/utils/file/download';
|
||||
import { Icon } from '@jeesite/core/components/Icon';
|
||||
import { BasicModal, useModalInner } from '@jeesite/core/components/Modal';
|
||||
import { ${className}ImportData } from '@jeesite/${moduleMinus}/api${modulePath}${subModulePath}/${className}';
|
||||
import { ${className}ImportData } from '@jeesite/${moduleMinus}/api${modulePath}${subModulePath}/${funName}';
|
||||
import { FileType } from 'ant-design-vue/es/upload/interface';
|
||||
import { AxiosProgressEvent } from 'axios';
|
||||
|
||||
|
||||
@@ -33,7 +33,7 @@
|
||||
import { useI18n } from '@jeesite/core/hooks/web/useI18n';
|
||||
import { PageWrapper } from '@jeesite/core/components/Page';
|
||||
import { BasicTree } from '@jeesite/core/components/Tree';
|
||||
import { ${className}TreeData } from '@jeesite/${moduleMinus}/api${modulePath}${subModulePath}/${className}';
|
||||
import { ${className}TreeData } from '@jeesite/${moduleMinus}/api${modulePath}${subModulePath}/${funName}';
|
||||
import ListView from './list.vue';
|
||||
|
||||
const { t } = useI18n('${moduleName}${subModuleNameDot}.${className}');
|
||||
|
||||
@@ -3,7 +3,7 @@
|
||||
No deletion without permission, or be held responsible to law. -->
|
||||
<template>
|
||||
<name>vueList</name>
|
||||
<filePath>${frontDir}/packages/${modulePath}/views/${urlPrefix}</filePath>
|
||||
<filePath>${frontDir}/packages${modulePath}/views/${urlPrefix}</filePath>
|
||||
<fileName>list.vue</fileName>
|
||||
<content><![CDATA[
|
||||
<% var modalOrDrawer = @StringUtils.contains(table.tplCategory, '_modal') ? 'Modal' : 'Drawer'; %>
|
||||
@@ -111,9 +111,9 @@ if(table.isTreeEntity){
|
||||
import { router } from '@jeesite/core/router';
|
||||
import { Icon } from '@jeesite/core/components/Icon';
|
||||
import { BasicTable, BasicColumn, useTable } from '@jeesite/core/components/Table';
|
||||
import { ${className}Delete, ${className}ListData } from '@jeesite/${moduleMinus}/api${modulePath}${subModulePath}/${className}';
|
||||
import { ${className}Delete, ${className}ListData } from '@jeesite/${moduleMinus}/api${modulePath}${subModulePath}/${funName}';
|
||||
<% if(toBoolean(table.optionMap['isHaveDisableEnable'])){ %>
|
||||
import { ${className}Disable, ${className}Enable } from '@jeesite/${moduleMinus}/api${modulePath}${subModulePath}/${className}';
|
||||
import { ${className}Disable, ${className}Enable } from '@jeesite/${moduleMinus}/api${modulePath}${subModulePath}/${funName}';
|
||||
<% } %>
|
||||
<%
|
||||
var userselectExists = false;
|
||||
|
||||
@@ -8,7 +8,7 @@
|
||||
<content><![CDATA[
|
||||
import { useI18n } from '@jeesite/core/hooks/web/useI18n';
|
||||
import { BasicColumn, BasicTableProps, FormProps } from '@jeesite/core/components/Table';
|
||||
import { ${className}ListData } from '@jeesite/${moduleMinus}/api${modulePath}${subModulePath}/${className}';
|
||||
import { ${className}ListData } from '@jeesite/${moduleMinus}/api${modulePath}${subModulePath}/${funName}';
|
||||
<%
|
||||
var userselectExists = false;
|
||||
var officeselectExists = false;
|
||||
|
||||
Reference in New Issue
Block a user