Merge branch 'master' of https://gitee.com/youlaiorg/youlai-boot
This commit is contained in:
@@ -146,12 +146,12 @@ public class SecurityConfig {
|
|||||||
public AuthenticationManager authenticationManager(
|
public AuthenticationManager authenticationManager(
|
||||||
DaoAuthenticationProvider daoAuthenticationProvider,
|
DaoAuthenticationProvider daoAuthenticationProvider,
|
||||||
SmsAuthenticationProvider smsAuthenticationProvider,
|
SmsAuthenticationProvider smsAuthenticationProvider,
|
||||||
WxMaAuthenticationProvider wechatMiniAuthenticationProvider
|
WxMaAuthenticationProvider wxMaAuthenticationProvider
|
||||||
) {
|
) {
|
||||||
return new ProviderManager(
|
return new ProviderManager(
|
||||||
daoAuthenticationProvider,
|
daoAuthenticationProvider,
|
||||||
smsAuthenticationProvider,
|
smsAuthenticationProvider,
|
||||||
wechatMiniAuthenticationProvider
|
wxMaAuthenticationProvider
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
<template>
|
<template>
|
||||||
<div class="app-container h-full flex flex-1 flex-col">
|
<div class="page-container h-full flex flex-1 flex-col">
|
||||||
<!-- 搜索 -->
|
<!-- 搜索 -->
|
||||||
<PageSearch
|
<PageSearch
|
||||||
ref="searchRef"
|
ref="searchRef"
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
<template>
|
<template>
|
||||||
<div class="app-container">
|
<div class="page-container">
|
||||||
<div class="filter-section">
|
<el-card class="page-search" shadow="never">
|
||||||
<el-form ref="queryFormRef" :model="queryParams" :inline="true" label-width="auto">
|
<el-form ref="queryFormRef" :model="queryParams" :inline="true" label-width="auto">
|
||||||
#foreach($fieldConfig in $fieldConfigs)
|
#foreach($fieldConfig in $fieldConfigs)
|
||||||
#if($fieldConfig.isShowInQuery == 1)
|
#if($fieldConfig.isShowInQuery == 1)
|
||||||
@@ -88,16 +88,16 @@
|
|||||||
</el-form-item>
|
</el-form-item>
|
||||||
#end
|
#end
|
||||||
#end
|
#end
|
||||||
<el-form-item class="search-buttons">
|
<el-form-item>
|
||||||
<el-button type="primary" icon="search" @click="handleQuery">搜索</el-button>
|
<el-button type="primary" icon="search" @click="handleQuery">搜索</el-button>
|
||||||
<el-button icon="refresh" @click="handleResetQuery">重置</el-button>
|
<el-button icon="refresh" @click="handleResetQuery">重置</el-button>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
</el-form>
|
</el-form>
|
||||||
</div>
|
</el-card>
|
||||||
|
|
||||||
<el-card shadow="hover" class="table-section">
|
<el-card class="page-content" shadow="never">
|
||||||
<div class="table-section__toolbar">
|
<div class="page-toolbar">
|
||||||
<div class="table-section__toolbar--actions">
|
<div class="page-toolbar__left">
|
||||||
<el-button
|
<el-button
|
||||||
v-hasPerm="['${moduleName}:${entityKebab}:create']"
|
v-hasPerm="['${moduleName}:${entityKebab}:create']"
|
||||||
type="success"
|
type="success"
|
||||||
@@ -121,7 +121,6 @@
|
|||||||
border
|
border
|
||||||
stripe
|
stripe
|
||||||
highlight-current-row
|
highlight-current-row
|
||||||
class="table-section__content"
|
|
||||||
row-key="id"
|
row-key="id"
|
||||||
@selection-change="handleSelectionChange"
|
@selection-change="handleSelectionChange"
|
||||||
>
|
>
|
||||||
@@ -171,6 +170,7 @@
|
|||||||
</el-table-column>
|
</el-table-column>
|
||||||
</el-table>
|
</el-table>
|
||||||
|
|
||||||
|
<div class="page-pagination">
|
||||||
<pagination
|
<pagination
|
||||||
v-if="total > 0"
|
v-if="total > 0"
|
||||||
v-model:total="total"
|
v-model:total="total"
|
||||||
@@ -178,6 +178,7 @@
|
|||||||
v-model:limit="queryParams.pageSize"
|
v-model:limit="queryParams.pageSize"
|
||||||
@pagination="fetchList"
|
@pagination="fetchList"
|
||||||
/>
|
/>
|
||||||
|
</div>
|
||||||
</el-card>
|
</el-card>
|
||||||
|
|
||||||
<!-- $!{businessName}表单弹窗 -->
|
<!-- $!{businessName}表单弹窗 -->
|
||||||
|
|||||||
@@ -2,7 +2,7 @@
|
|||||||
* ${entityName} $!{businessName}类型定义
|
* ${entityName} $!{businessName}类型定义
|
||||||
*/
|
*/
|
||||||
|
|
||||||
import type { BaseQueryParams } from "./common";
|
import type { BaseQueryParams } from "@/api/common";
|
||||||
|
|
||||||
/** $!{businessName}查询参数 */
|
/** $!{businessName}查询参数 */
|
||||||
export interface ${entityName}QueryParams extends BaseQueryParams {
|
export interface ${entityName}QueryParams extends BaseQueryParams {
|
||||||
|
|||||||
@@ -1,5 +1,6 @@
|
|||||||
import request from "@/utils/request";
|
import request from "@/utils/request";
|
||||||
import type { ${entityName}Form, ${entityName}QueryParams, ${entityName}Item } from "@/types/api";
|
import type { ${entityName}Form, ${entityName}QueryParams, ${entityName}Item } from "./types";
|
||||||
|
import type { PageResult } from "@/api/common";
|
||||||
|
|
||||||
const ${entityUpperSnake}_BASE_URL = "/api/v1/${entityKebab}";
|
const ${entityUpperSnake}_BASE_URL = "/api/v1/${entityKebab}";
|
||||||
|
|
||||||
@@ -66,3 +67,6 @@ const ${entityName}API = {
|
|||||||
}
|
}
|
||||||
|
|
||||||
export default ${entityName}API;
|
export default ${entityName}API;
|
||||||
|
|
||||||
|
// 重导出类型
|
||||||
|
export * from "./types";
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
<template>
|
<template>
|
||||||
<div class="app-container h-full flex flex-1 flex-col">
|
<div class="page-container h-full flex flex-1 flex-col">
|
||||||
<!-- 搜索 -->
|
<!-- 搜索 -->
|
||||||
<PageSearch
|
<PageSearch
|
||||||
ref="searchRef"
|
ref="searchRef"
|
||||||
@@ -64,7 +64,7 @@
|
|||||||
defineOptions({ name: "$entityName" });
|
defineOptions({ name: "$entityName" });
|
||||||
|
|
||||||
import ${entityName}API from "@/api/${moduleName}/${entityKebab}";
|
import ${entityName}API from "@/api/${moduleName}/${entityKebab}";
|
||||||
import type { ${entityName}Form, ${entityName}QueryParams } from "@/types/api";
|
import type { ${entityName}Form, ${entityName}QueryParams } from "@/api/${moduleName}/${entityKebab}";
|
||||||
import type { IObject, IModalConfig, IContentConfig, ISearchConfig } from "@/components/CURD/types";
|
import type { IObject, IModalConfig, IContentConfig, ISearchConfig } from "@/components/CURD/types";
|
||||||
import usePage from "@/components/CURD/usePage";
|
import usePage from "@/components/CURD/usePage";
|
||||||
|
|
||||||
@@ -151,8 +151,8 @@ const contentConfig: IContentConfig<${entityName}QueryParams> = reactive({
|
|||||||
// 数据解析函数
|
// 数据解析函数
|
||||||
parseData(res: any) {
|
parseData(res: any) {
|
||||||
return {
|
return {
|
||||||
total: res?.page?.total ?? 0,
|
total: res?.total ?? 0,
|
||||||
list: res?.data ?? [],
|
list: res?.list ?? [],
|
||||||
};
|
};
|
||||||
},
|
},
|
||||||
// 分页配置
|
// 分页配置
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
<template>
|
<template>
|
||||||
<div class="app-container">
|
<div class="page-container">
|
||||||
<div class="filter-section">
|
<el-card class="page-search" shadow="never">
|
||||||
<el-form ref="queryFormRef" :model="queryParams" :inline="true" label-width="auto">
|
<el-form ref="queryFormRef" :model="queryParams" :inline="true" label-width="auto">
|
||||||
#foreach($fieldConfig in $fieldConfigs)
|
#foreach($fieldConfig in $fieldConfigs)
|
||||||
#if($fieldConfig.isShowInQuery == 1)
|
#if($fieldConfig.isShowInQuery == 1)
|
||||||
@@ -88,16 +88,16 @@
|
|||||||
</el-form-item>
|
</el-form-item>
|
||||||
#end
|
#end
|
||||||
#end
|
#end
|
||||||
<el-form-item class="search-buttons">
|
<el-form-item>
|
||||||
<el-button type="primary" icon="search" @click="handleQuery">搜索</el-button>
|
<el-button type="primary" icon="search" @click="handleQuery">搜索</el-button>
|
||||||
<el-button icon="refresh" @click="handleResetQuery">重置</el-button>
|
<el-button icon="refresh" @click="handleResetQuery">重置</el-button>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
</el-form>
|
</el-form>
|
||||||
</div>
|
</el-card>
|
||||||
|
|
||||||
<el-card shadow="hover" class="table-section">
|
<el-card class="page-content" shadow="never">
|
||||||
<div class="table-section__toolbar">
|
<div class="page-toolbar">
|
||||||
<div class="table-section__toolbar--actions">
|
<div class="page-toolbar__left">
|
||||||
<el-button
|
<el-button
|
||||||
v-hasPerm="['${moduleName}:${entityKebab}:create']"
|
v-hasPerm="['${moduleName}:${entityKebab}:create']"
|
||||||
type="success"
|
type="success"
|
||||||
@@ -121,7 +121,6 @@
|
|||||||
border
|
border
|
||||||
stripe
|
stripe
|
||||||
highlight-current-row
|
highlight-current-row
|
||||||
class="table-section__content"
|
|
||||||
row-key="id"
|
row-key="id"
|
||||||
@selection-change="handleSelectionChange"
|
@selection-change="handleSelectionChange"
|
||||||
>
|
>
|
||||||
@@ -171,6 +170,7 @@
|
|||||||
</el-table-column>
|
</el-table-column>
|
||||||
</el-table>
|
</el-table>
|
||||||
|
|
||||||
|
<div class="page-pagination">
|
||||||
<pagination
|
<pagination
|
||||||
v-if="total > 0"
|
v-if="total > 0"
|
||||||
v-model:total="total"
|
v-model:total="total"
|
||||||
@@ -178,6 +178,7 @@
|
|||||||
v-model:limit="queryParams.pageSize"
|
v-model:limit="queryParams.pageSize"
|
||||||
@pagination="fetchList"
|
@pagination="fetchList"
|
||||||
/>
|
/>
|
||||||
|
</div>
|
||||||
</el-card>
|
</el-card>
|
||||||
|
|
||||||
<!-- $!{businessName}表单弹窗 -->
|
<!-- $!{businessName}表单弹窗 -->
|
||||||
@@ -277,7 +278,7 @@
|
|||||||
import { ElMessage, ElMessageBox, type FormInstance, type FormRules } from "element-plus";
|
import { ElMessage, ElMessageBox, type FormInstance, type FormRules } from "element-plus";
|
||||||
import { useTableSelection } from "@/composables";
|
import { useTableSelection } from "@/composables";
|
||||||
import ${entityName}API from "@/api/${moduleName}/${entityKebab}";
|
import ${entityName}API from "@/api/${moduleName}/${entityKebab}";
|
||||||
import type { ${entityName}Item, ${entityName}Form, ${entityName}QueryParams } from "@/types/api";
|
import type { ${entityName}Item, ${entityName}Form, ${entityName}QueryParams } from "@/api/${moduleName}/${entityKebab}";
|
||||||
|
|
||||||
defineOptions({
|
defineOptions({
|
||||||
name: "${entityName}",
|
name: "${entityName}",
|
||||||
|
|||||||
Reference in New Issue
Block a user