Merge remote-tracking branch 'origin/leng_dev' into lei_dev

# Conflicts:
#	src/utils/storage.ts
This commit is contained in:
aeizzz 2023-03-03 17:29:43 +08:00
commit 8d8c47e1da
102 changed files with 5505 additions and 3992 deletions

View File

@ -1,4 +1,5 @@
import request from "/@/utils/request";
import {getDetailsByPhone} from "/@/api/admin/user";
export const pageList = (params?: Object) => {
return request({
@ -47,3 +48,47 @@ export function delObj (ids?:object) {
})
}
export function getDetails(obj: Object) {
return request({
url: '/admin/appmenu/details/' + obj,
method: 'get'
})
}
export function getDetailsByName(obj: Object) {
return request({
url: '/admin/appmenu/detailsByName/' + obj,
method: 'get'
})
}
export function validatePermission(rule: any, value: any, callback: any, isEdit: boolean) {
if (isEdit) {
return callback()
}
getDetails(value).then(response => {
const result = response.data
if (result !== null) {
callback(new Error('权限标识已经存在'))
} else {
callback()
}
})
}
export function validateByName(rule: any, value: any, callback: any, isEdit: boolean) {
if (isEdit) {
return callback()
}
getDetailsByName(value).then(response => {
const result = response.data
if (result !== null) {
callback(new Error('菜单名称已经存在'))
} else {
callback()
}
})
}

View File

@ -63,3 +63,53 @@ export function permissionUpd(roleId: string, menuIds: string) {
}
})
}
export function getDetails(obj: Object) {
return request({
url: '/admin/approle/details/' + obj,
method: 'get'
})
}
export function getDetailsByPhone(obj: Object) {
return request({
url: '/admin/approle/detailsByCode/' + obj,
method: 'get'
})
}
export function validateApproleName(rule: any, value: any, callback: any, isEdit: boolean) {
const flag = new RegExp(/^([a-z\u4e00-\u9fa5\d]+?)$/).test(value)
if (!flag) {
callback(new Error('用户名支持小写英文、数字、中文'))
}
if (isEdit) {
return callback()
}
getDetails(value).then(response => {
const result = response.data
if (result !== null) {
callback(new Error('用户名已经存在'))
} else {
callback()
}
})
}
export function validateAppRoleCode(rule: any, value: any, callback: any, isEdit: boolean) {
if (isEdit) {
return callback()
}
getDetailsByPhone(value).then(response => {
const result = response.data
if (result !== null) {
callback(new Error('角色标识已经存在'))
} else {
callback()
}
})
}

View File

@ -38,3 +38,55 @@ export function putObj(obj: any) {
data: obj
})
}
export function getDetails(obj: Object) {
return request({
url: '/admin/appuser/details/' + obj,
method: 'get'
})
}
export function getDetailsByPhone(obj: Object) {
return request({
url: '/admin/appuser/detailsByPhone/' + obj,
method: 'get'
})
}
export function validateUsername(rule: any, value: any, callback: any, isEdit: boolean) {
const flag = new RegExp(/^([a-z\u4e00-\u9fa5\d]+?)$/).test(value)
if (!flag) {
callback(new Error('用户名支持小写英文、数字、中文'))
}
if (isEdit) {
return callback()
}
getDetails(value).then(response => {
const result = response.data
if (result !== null) {
callback(new Error('用户名已经存在'))
} else {
callback()
}
})
}
export function validatePhone(rule: any, value: any, callback: any, isEdit: boolean) {
if (isEdit) {
return callback()
}
getDetailsByPhone(value).then(response => {
const result = response.data
if (result !== null) {
callback(new Error('手机号已经存在'))
} else {
callback()
}
})
}

46
src/api/oa/leave-bill.ts Normal file
View File

@ -0,0 +1,46 @@
import request from '/@/utils/request';
export function fetchList(query) {
return request({
url: '/admin/leave-bill/page',
method: 'get',
params: query
})
}
export function addObj(obj) {
return request({
url: '/admin/leave-bill',
method: 'post',
data: obj
})
}
export function getObj(id) {
return request({
url: '/admin/leave-bill/' + id,
method: 'get'
})
}
export function submit(id) {
return request({
url: '/admin/leave-bill/submit/' + id,
method: 'get'
})
}
export function delObj(id) {
return request({
url: '/admin/leave-bill/' + id,
method: 'delete'
})
}
export function putObj(obj) {
return request({
url: '/admin/leave-bill/',
method: 'put',
data: obj
})
}

46
src/api/oa/model.ts Normal file
View File

@ -0,0 +1,46 @@
import request from '/@/utils/request';
export function fetchList(query) {
return request({
url: '/admin/model',
method: 'get',
params: query
})
}
export function delObj(id) {
return request({
url: '/admin/model/' + id,
method: 'delete'
})
}
export function deploy(id) {
return request({
url: '/admin/model/deploy/' + id,
method: 'post'
})
}
export function addObj(obj) {
return request({
url: '/admin/model/insert',
method: 'post',
data: obj
})
}
export function getObj(id) {
return request({
url: '/admin/log/' + id,
method: 'get'
})
}
export function putObj(obj) {
return request({
url: '/admin/log/',
method: 'put',
data: obj
})
}

23
src/api/oa/process.ts Normal file
View File

@ -0,0 +1,23 @@
import request from '/@/utils/request';
export function fetchList(query) {
return request({
url: '/admin/process',
method: 'get',
params: query
})
}
export function delObj(id) {
return request({
url: '/admin/process/' + id,
method: 'delete'
})
}
export function status(id, type) {
return request({
url: '/admin/process/status/' + id + '/' + type,
method: 'put'
})
}

31
src/api/oa/task.ts Normal file
View File

@ -0,0 +1,31 @@
import request from '/@/utils/request';
export function fetchList(query) {
return request({
url: '/admin/task/todo',
method: 'get',
params: query
})
}
export function fetchDetail(id) {
return request({
url: '/admin/task/' + id,
method: 'get'
})
}
export function fetchComment(id) {
return request({
url: '/admin/task/comment/' + id,
method: 'get'
})
}
export function doTask(obj) {
return request({
url: '/admin/task',
method: 'post',
data: obj
})
}

View File

@ -13,6 +13,7 @@ export default {
resetBtn: 'reset',
action:'action',
optSuccessText: 'operation success',
optConfirmText: 'Confirm this operation ',
editSuccessText: 'edit success',
addSuccessText: 'add success',
delSuccessText: 'delete success',

View File

@ -16,6 +16,7 @@ export default {
addSuccessText: '添加成功',
delSuccessText: '删除成功',
delConfirmText: '此操作将永久删除',
optConfirmText: '是否确认本操作',
confirmButtonText: '确认',
cancelButtonText: '取消',
download: '下载'

View File

@ -10,7 +10,7 @@ export default {
one3: 'Third party login',
two4: 'Links',
},
account: {
password: {
accountPlaceholder1: 'The user name admin or not is common',
accountPlaceholder2: 'Password: 123456',
accountPlaceholder3: 'Please enter the verification code',
@ -23,11 +23,10 @@ export default {
placeholder2: 'Please enter the verification code',
codeText: 'Get code',
btnText: 'Sign in',
msgText:
'Warm tip: it is recommended to use Google, Microsoft edge, version 79.0.1072.62 and above browsers, and 360 browser, please use speed mode',
},
scan: {
text: 'Open the mobile phone to scan and quickly log in / register',
},
signInText: 'welcome back!',
browserMsgText: 'Warm tip: it is recommended to use Google, Microsoft edge, version 79.0.1072.62 and above browsers, and 360 browser, please use speed mode',
};

View File

@ -10,7 +10,7 @@ export default {
one3: '第三方登录',
two4: '友情链接',
},
account: {
password: {
accountPlaceholder1: '请输入用户名',
accountPlaceholder2: '请输入密码',
accountPlaceholder3: '请输入验证码',
@ -23,10 +23,10 @@ export default {
placeholder2: '请输入验证码',
codeText: '获取验证码',
btnText: '登 录',
msgText: '* 温馨提示建议使用谷歌、Microsoft Edge版本 79.0.1072.62 及以上浏览器360浏览器请使用极速模式',
},
scan: {
text: '打开手机扫一扫,快速登录/注册',
},
signInText: '欢迎回来!',
browserMsgText: '* 温馨提示建议使用谷歌、Microsoft Edge版本 79.0.1072.62 及以上浏览器360浏览器请使用极速模式',
};

View File

@ -101,7 +101,7 @@ const GlobalWebsocket = defineAsyncComponent(() => import('/@/components/Websock
const UserNews = defineAsyncComponent(() => import('/@/layout/navBars/breadcrumb/userNews.vue'));
const Search = defineAsyncComponent(() => import('/@/layout/navBars/breadcrumb/search.vue'));
const personalDrawer = defineAsyncComponent(() => import("/@/views/personal/index.vue"))
const personalDrawer = defineAsyncComponent(() => import("/@/views/admin/user/personal.vue"))
//
const { locale, t } = useI18n();

View File

@ -101,7 +101,7 @@ export const staticConfigRoutes: Array<RouteRecordRaw> = [
{
path: '/personal',
name: 'personal',
component: () => import('/@/views/personal/index.vue'),
component: () => import('/@/views/admin/user/personal.vue'),
meta: {
"title": "router.personal",
"isHide": true

View File

@ -133,11 +133,11 @@ export const useThemeConfig = defineStore('themeConfig', {
* /
*/
// 网站主标题菜单导航、浏览器当前网页标题、登录form顶部右侧
globalTitle: 'PigX 快速开发框架1',
globalTitle: 'PigX 快速开发框架',
// 网站副标题(登录左侧底部页顶部文字)
globalViceTitle: 'PigX 快速开发框架2',
globalViceTitle: 'PigX 快速开发框架',
// 网站副标题(登录页顶部文字)
globalViceTitleMsg: '专注、免费、开源、维护、解疑3',
globalViceTitleMsg: '专注、免费、开源、维护、解疑',
// 默认初始语言,可选值"<zh-cn|en|zh-tw>",默认 zh-cn
globalI18n: 'zh-cn',
// 默认全局组件大小,可选值"<large|'default'|small>",默认 'large'

View File

@ -93,11 +93,13 @@ body,
position: absolute;
left: 0;
top: 0;
height: 100%;
overflow: hidden;
@extend .layout-flex;
&-auto {
height: inherit;
@extend .layout-flex;
padding: 10px;
}
&-view {
background: var(--el-color-white);

View File

@ -41,24 +41,27 @@ export const Local = {
*/
export const Session = {
// 设置临时缓存
set<T>(key: string, val: T) {
if (key === 'token') return Cookies.set(key, val);
window.sessionStorage.setItem(Local.setKey(key), JSON.stringify(val));
set(key: string, val: any) {
if (key === 'token' || key === 'refresh_token') {
Cookies.set(key, val)
}
window.sessionStorage.setItem(key, JSON.stringify(val));
},
// 获取临时缓存
get(key: string) {
if (key === 'token') return Cookies.get(key);
let json = <string>window.sessionStorage.getItem(Local.setKey(key));
if (key === 'token' || key === 'refresh_token') return Cookies.get(key);
let json = <string>window.sessionStorage.getItem(key);
return JSON.parse(json);
},
// 移除临时缓存
remove(key: string) {
if (key === 'token') return Cookies.remove(key);
window.sessionStorage.removeItem(Local.setKey(key));
if (key === 'token' || key === 'refresh_token') return Cookies.remove(key);
window.sessionStorage.removeItem(key);
},
// 移除全部临时缓存
clear() {
Cookies.remove('token');
Cookies.remove('refresh_token');
window.sessionStorage.clear();
},
};

View File

@ -1,6 +1,6 @@
<template>
<div class="layout-padding">
<el-card class="layout-padding-auto">
<div class="layout-padding-auto layout-padding-view">
<el-row v-show="showSearch" class="mb8">
<el-form :model="state.queryForm" ref="queryRef" :inline="true" @keyup.enter="getDataList">
<el-form-item :label="$t('audit.auditName')" prop="auditName">
@ -57,7 +57,7 @@
</el-table-column>
</el-table>
<pagination @size-change="sizeChangeHandle" @current-change="currentChangeHandle" v-bind="state.pagination" />
</el-card>
</div>
</div>
</template>

View File

@ -1,26 +1,26 @@
<template>
<el-dialog v-model="visible" :close-on-click-modal="false"
:title="form.id ? $t('common.editBtn') : $t('common.addBtn')" draggable>
<el-form ref="dataFormRef" :model="form" :rules="dataRules" formDialogRef label-width="120px">
<el-dialog :close-on-click-modal="false" :title="form.id ? $t('common.editBtn') : $t('common.addBtn')"
draggable v-model="visible">
<el-form :model="form" :rules="dataRules" formDialogRef label-width="120px" ref="dataFormRef">
<el-row :gutter="20">
<el-col :span="12" class="mb20">
<el-form-item :label="t('client.clientId')" prop="clientId">
<el-input v-model="form.clientId" :placeholder="t('client.inputClientIdTip')"/>
<el-input :placeholder="t('client.inputClientIdTip')" v-model="form.clientId"/>
</el-form-item>
</el-col>
<el-col :span="12" class="mb20">
<el-form-item :label="t('client.clientSecret')" prop="clientSecret">
<el-input v-model="form.clientSecret" :placeholder="t('client.inputClientSecretTip')"/>
<el-input :placeholder="t('client.inputClientSecretTip')" v-model="form.clientSecret"/>
</el-form-item>
</el-col>
<el-col :span="12" class="mb20">
<el-form-item :label="t('client.scope')" prop="scope">
<el-input v-model="form.scope" :placeholder="t('client.inputScopeTip')"/>
<el-input :placeholder="t('client.inputScopeTip')" v-model="form.scope"/>
</el-form-item>
</el-col>
@ -28,8 +28,8 @@
<el-col :span="24" class="mb20">
<el-form-item :label="t('client.authorizedGrantTypes')" prop="authorizedGrantTypes">
<el-checkbox-group v-model="form.authorizedGrantTypes">
<el-checkbox v-for="(item, index) in grant_types" :key="index"
:label="item.value">{{ item.label }}
<el-checkbox :key="index" :label="item.value"
v-for="(item, index) in grant_types">{{ item.label }}
</el-checkbox>
</el-checkbox-group>
</el-form-item>
@ -38,28 +38,31 @@
<el-col :span="12" class="mb20">
<el-form-item :label="t('client.webServerRedirectUri')" prop="webServerRedirectUri">
<el-input v-model="form.webServerRedirectUri" :placeholder="t('client.inputWebServerRedirectUriTip')"/>
<el-input :placeholder="t('client.inputWebServerRedirectUriTip')"
v-model="form.webServerRedirectUri"/>
</el-form-item>
</el-col>
<el-col :span="12" class="mb20">
<el-form-item :label="t('client.authorities')" prop="authorities">
<el-input v-model="form.authorities" :placeholder="t('client.inputAuthoritiesTip')"/>
<el-input :placeholder="t('client.inputAuthoritiesTip')" v-model="form.authorities"/>
</el-form-item>
</el-col>
<el-col :span="12" class="mb20">
<el-form-item :label="t('client.accessTokenValidity')" prop="accessTokenValidity">
<el-input v-model="form.accessTokenValidity" :placeholder="t('client.inputAccessTokenValidityTip')"/>
<el-input :placeholder="t('client.inputAccessTokenValidityTip')"
v-model="form.accessTokenValidity"/>
</el-form-item>
</el-col>
<el-col :span="12" class="mb20">
<el-form-item :label="t('client.refreshTokenValidity')" prop="refreshTokenValidity">
<el-input v-model="form.refreshTokenValidity" :placeholder="t('client.inputRefreshTokenValidityTip')"/>
<el-input :placeholder="t('client.inputRefreshTokenValidityTip')"
v-model="form.refreshTokenValidity"/>
</el-form-item>
</el-col>
@ -67,7 +70,8 @@
<el-col :span="12" class="mb20">
<el-form-item :label="t('client.autoapprove')" prop="autoapprove">
<el-radio-group v-model="form.autoapprove">
<el-radio v-for="(item, index) in common_status" :key="index" :label="item.value" border>{{ item.label }}
<el-radio :key="index" :label="item.value" border v-for="(item, index) in common_status">{{
item.label }}
</el-radio>
</el-radio-group>
</el-form-item>
@ -75,14 +79,14 @@
<el-col :span="24" class="mb20">
<el-form-item :label="t('client.additionalInformation')" prop="additionalInformation">
<el-input type="textarea" v-model="form.additionalInformation"
:placeholder="t('client.inputAdditionalInformationTip')"/>
<el-input :placeholder="t('client.inputAdditionalInformationTip')" type="textarea"
v-model="form.additionalInformation"/>
</el-form-item>
</el-col>
</el-row>
<el-collapse v-model="collapseActive">
<el-collapse-item title="安全属性" name="1">
<el-collapse-item name="1" title="安全属性">
<template #title>
<el-icon class="header-icon">
<info-filled/>
@ -94,7 +98,8 @@
<el-col :span="12" class="mb20">
<el-form-item :label="t('client.captchaFlag')" prop="captchaFlag">
<el-radio-group v-model="form.captchaFlag">
<el-radio v-for="(item, index) in captcha_flag_types" :key="index" :label="item.value" border>
<el-radio :key="index" :label="item.value"
border v-for="(item, index) in captcha_flag_types">
{{ item.label }}
</el-radio>
</el-radio-group>
@ -103,7 +108,8 @@
<el-col :span="12" class="mb20">
<el-form-item :label="t('client.encFlag')" prop="encFlag">
<el-radio-group v-model="form.encFlag">
<el-radio v-for="(item, index) in enc_flag_types" :key="index" :label="item.value" border>
<el-radio :key="index" :label="item.value" border
v-for="(item, index) in enc_flag_types">
{{ item.label }}
</el-radio>
</el-radio-group>
@ -112,7 +118,8 @@
<el-col :span="12" class="mb20">
<el-form-item :label="t('client.onlineQuantity')" prop="onlineQuantity">
<el-radio-group v-model="form.onlineQuantity">
<el-radio v-for="(item, index) in enc_flag_types" :key="index" :label="item.value" border>
<el-radio :key="index" :label="item.value" border
v-for="(item, index) in enc_flag_types">
{{ item.label }}
</el-radio>
</el-radio-group>
@ -126,8 +133,8 @@
</el-form>
<template #footer>
<span class="dialog-footer">
<el-button formDialogRef @click="visible = false">{{ $t('common.cancelButtonText') }}</el-button>
<el-button formDialogRef type="primary" @click="onSubmit">{{ $t('common.confirmButtonText') }}</el-button>
<el-button @click="visible = false" formDialogRef>{{ $t('common.cancelButtonText') }}</el-button>
<el-button @click="onSubmit" formDialogRef type="primary">{{ $t('common.confirmButtonText') }}</el-button>
</span>
</template>
</el-dialog>
@ -139,6 +146,7 @@ import {useDict} from '/@/hooks/dict';
import {useMessage} from "/@/hooks/message";
import {addObj, getObj, putObj} from '/@/api/admin/client'
import {useI18n} from "vue-i18n"
import {rule} from "/@/utils/validate";
const emit = defineEmits(['refresh']);
@ -189,6 +197,10 @@ const dataRules = ref({
captchaFlag: [{required: true, message: '是否开启验证码校验', trigger: 'blur'}],
encFlag: [{required: true, message: '是否开启密码加密传输', trigger: 'blur'}],
onlineQuantity: [{required: true, message: '是否允许同时在线', trigger: 'blur'}],
authorities: [{required: true, message: '权限不能为空', trigger: 'blur'}],
autoapprove: [{required: true, message: '自动放行不能为空', trigger: 'blur'}],
webServerRedirectUri: [{required: true, message: '回调地址不能为空', trigger: 'blur'}
, {validator: rule.url, trigger: 'blur'}],
})
//

View File

@ -1,6 +1,6 @@
<template>
<div class="layout-padding">
<el-card class="layout-padding-auto">
<div class="layout-padding-auto layout-padding-view">
<el-row v-show="showSearch" class="mb8">
<el-form :model="state.queryForm" ref="queryRef" :inline="true" @keyup.enter="getDataList">
<el-form-item :label="$t('client.clientId')" prop="clientId">
@ -65,8 +65,7 @@
</el-table-column>
</el-table>
<pagination v-bind="state.pagination" @size-change="sizeChangeHandle" @current-change="currentChangeHandle" />
</el-card>
</div>
<!-- 编辑新增 -->
<form-dialog ref="formDialogRef" @refresh="getDataList()" />
</div>

View File

@ -1,6 +1,6 @@
<template>
<div class="layout-padding">
<el-card shadow="hover" class="layout-padding-auto">
<div class="layout-padding-auto layout-padding-view">
<div class="mb15">
<el-form :model="state.queryForm" ref="queryRef" :inline="true" @keyup.enter="getDataList">
<el-form-item prop="deptName">
@ -44,7 +44,7 @@
</template>
</el-table-column>
</el-table>
</el-card>
</div>
<dept-form ref="deptDialogRef" @refresh="getDataList()" />
<upload-excel ref="excelUploadRef" :title="$t('sysdept.importTip')" url="/admin/dept/import"
temp-url="/admin/sys-file/local/file/dept.xlsx" @refreshDataList="getDataList" />
@ -72,7 +72,8 @@ const state: BasicTableProps = reactive<BasicTableProps>({
queryForm: {
deptName: ''
},
isPage: false
isPage: false,
descs: ['create_time']
});

View File

@ -1,6 +1,6 @@
<template>
<el-drawer v-model="visible" :title="$t('sysdict.dictItem')" size="80%">
<el-card shadow="hover" class="layout-padding-auto">
<div class="layout-padding-auto layout-padding-view">
<el-row>
<div class="mb8" style="width: 100%">
<el-button icon="folder-add" type="primary" class="ml10" @click="dictformRef.openDialog(null,state.queryForm)">
@ -31,7 +31,7 @@
<pagination @size-change="sizeChangeHandle" @current-change="currentChangeHandle" v-bind="state.pagination">
</pagination>
</el-row>
</el-card>
</div>
<dict-form ref="dictformRef" @refresh="getDataList"></dict-form>
</el-drawer>

View File

@ -1,28 +1,33 @@
<template>
<div class="system-dic-dialog-container">
<el-dialog v-model="visible" :title="dataForm.id ? $t('common.editBtn') : $t('common.addBtn')" width="60%">
<el-form ref="dicDialogFormRef" :model="dataForm" label-width="100px" :rules="dataRules">
<el-dialog :title="dataForm.id ? $t('common.editBtn') : $t('common.addBtn')" v-model="visible" width="60%">
<el-form :model="dataForm" :rules="dataRules" label-width="100px" ref="dicDialogFormRef">
<el-row :gutter="35">
<el-col :lg="12" :md="12" :sm="12" :xl="12" :xs="24" class="mb20">
<el-form-item :label="$t('sysdict.dictType')" prop="dictType">
<el-input v-model="dataForm.dictType" clearable :placeholder="$t('sysdict.inputDictTypeTip')"></el-input>
<el-input :placeholder="$t('sysdict.inputDictTypeTip')" clearable
v-model="dataForm.dictType"></el-input>
</el-form-item>
</el-col>
<el-col :lg="12" :md="12" :sm="12" :xl="12" :xs="24" class="mb20">
<el-form-item :label="$t('sysdict.description')" prop="description">
<el-input v-model="dataForm.description" :placeholder="$t('sysdict.inputDescriptionTip')" clearable></el-input>
<el-input :placeholder="$t('sysdict.inputDescriptionTip')" clearable
v-model="dataForm.description"></el-input>
</el-form-item>
</el-col>
<el-col :lg="12" :md="12" :sm="12" :xl="12" :xs="24" class="mb20">
<el-form-item :label="$t('sysdict.systemFlag')" prop="systemFlag">
<el-radio-group v-model="dataForm.systemFlag">
<el-radio-button :label="item.value" v-for="(item,index) in dict_type" :key="index">{{item.label}}</el-radio-button>
<el-radio-button :key="index" :label="item.value" v-for="(item,index) in dict_type">
{{item.label}}
</el-radio-button>
</el-radio-group>
</el-form-item>
</el-col>
<el-col :lg="12" :md="12" :sm="12" :xl="12" :xs="24" class="mb20">
<el-form-item :label="$t('sysdict.remarks')" prop="remarks">
<el-input v-model="dataForm.remarks" type="textarea" :placeholder="$t('sysdict.inputRemarksTip')" maxlength="150"></el-input>
<el-input :placeholder="$t('sysdict.inputRemarksTip')" maxlength="150"
type="textarea" v-model="dataForm.remarks"></el-input>
</el-form-item>
</el-col>
</el-row>
@ -30,17 +35,18 @@
<template #footer>
<span class="dialog-footer">
<el-button @click="onCancel">{{ $t('common.cancelButtonText') }}</el-button>
<el-button type="primary" @click="onSubmit" >{{ $t('common.confirmButtonText') }}</el-button>
<el-button @click="onSubmit" type="primary">{{ $t('common.confirmButtonText') }}</el-button>
</span>
</template>
</el-dialog>
</div>
</template>
<script setup lang="ts" name="systemDicDialog">
import { getObj, addObj, putObj } from '/@/api/admin/dict'
<script lang="ts" name="systemDicDialog" setup>
import {addObj, getObj, putObj} from '/@/api/admin/dict'
import {useDict} from "/@/hooks/dict";
import {useMessage} from "/@/hooks/message";
import {rule} from "/@/utils/validate";
// /
@ -62,7 +68,8 @@ const dataForm = reactive({
const dataRules = reactive({
dictType: [{ required: true, message: '类型不能为空', trigger: 'blur' }],
dictType: [{required: true, message: '类型不能为空', trigger: 'blur'}
, {validator: rule.validatorNameCn, trigger: 'blur'}],
systemFlag: [{required: true, message: '字典类型不能为空', trigger: 'blur'}],
description: [{required: true, message: '描述不能为空', trigger: 'blur'}],
})

View File

@ -1,10 +1,11 @@
<template>
<div class="layout-padding">
<el-card shadow="hover" class="layout-padding-auto">
<div class="layout-padding-auto layout-padding-view">
<el-row v-show="showSearch" class="mb8">
<el-form :model="state.queryForm" ref="queryRef" :inline="true" @keyup.enter="getDataList">
<el-form-item :label="$t('sysdict.dictType')" prop="dictType">
<el-input :placeholder="$t('sysdict.inputDictTypeTip')" v-model="state.queryForm.dictType" style="max-width: 180px" />
<el-input :placeholder="$t('sysdict.inputDictTypeTip')" v-model="state.queryForm.dictType"
style="max-width: 180px"/>
</el-form-item>
<el-form-item :label="$t('sysdict.systemFlag')" prop="systemFlag">
<el-select v-model="state.queryForm.systemFlag" clearable>
@ -46,18 +47,23 @@
<el-button text type="primary" @click="showDictITem(scope.row)">{{ scope.row.dictType }}</el-button>
</template>
</el-table-column>
<el-table-column prop="description" :label="$t('sysdict.description')" show-overflow-tooltip sortable></el-table-column>
<el-table-column prop="description" :label="$t('sysdict.description')" show-overflow-tooltip
sortable></el-table-column>
<el-table-column prop="systemFlag" :label="$t('sysdict.systemFlag')" show-overflow-tooltip>
<template #default="scope">
<dict-tag :options="dict_type" :value="scope.row.systemFlag"></dict-tag>
</template>
</el-table-column>
<el-table-column prop="remarks" :label="$t('sysdict.remarks')" show-overflow-tooltip></el-table-column>
<el-table-column prop="createTime" :label="$t('sysdict.createTime')" show-overflow-tooltip sortable></el-table-column>
<el-table-column prop="createTime" :label="$t('sysdict.createTime')" show-overflow-tooltip
sortable></el-table-column>
<el-table-column :label="$t('common.action')" width="200">
<template #default="scope">
<el-button text type="primary" @click="showDictITem(scope.row)">{{ $t('sysdict.dictItem') }}</el-button>
<el-button text type="primary" @click="onOpenEditDic('edit', scope.row)">{{ $t('common.editBtn') }}</el-button>
<el-button text type="primary" @click="onOpenEditDic('edit', scope.row)">{{
$t('common.editBtn')
}}
</el-button>
<el-tooltip :content="$t('sysdict.deleteDisabledTip')" :disabled="scope.row.systemFlag === 1"
placement="top">
<span style="margin-left: 12px">
@ -71,7 +77,7 @@
</el-table-column>
</el-table>
<pagination @size-change="sizeChangeHandle" @current-change="currentChangeHandle" v-bind="state.pagination"/>
</el-card>
</div>
<DicDialog ref="dicDialogRef" @refresh="getDataList()"/>
<dict-item-dialog ref="dictItemDialogRef"></dict-item-dialog>
</div>
@ -83,6 +89,7 @@ import { delObj, fetchList, refreshCache } from "/@/api/admin/dict";
import {useMessage, useMessageBox} from "/@/hooks/message";
import {useDict} from "/@/hooks/dict";
import {useI18n} from "vue-i18n";
const {dict_type} = useDict('dict_type')
//
const DicDialog = defineAsyncComponent(() => import('./form.vue'));
@ -100,7 +107,8 @@ const multiple = ref(true)
const state: BasicTableProps = reactive<BasicTableProps>({
queryForm: {},
pageList: fetchList
pageList: fetchList,
descs: ['create_time']
})
const {
getDataList,

View File

@ -1,6 +1,6 @@
<template>
<div class="layout-padding">
<el-card class="layout-padding-auto">
<div class="layout-padding-auto layout-padding-view">
<el-row v-show="showSearch" class="mb8">
<el-form :model="state.queryForm" ref="queryRef" :inline="true" @keyup.enter="getDataList">
<el-form-item :label="$t('file.fileName')" prop="original">
@ -49,7 +49,7 @@
</el-table-column>
</el-table>
<pagination @size-change="sizeChangeHandle" @current-change="currentChangeHandle" v-bind="state.pagination" />
</el-card>
</div>
<!-- 编辑新增 -->
<form-dialog ref="formDialogRef" @refresh="getDataList()" />
</div>
@ -77,7 +77,8 @@ const multiple = ref(true)
const state: BasicTableProps = reactive<BasicTableProps>({
queryForm: {},
pageList: fetchList
pageList: fetchList,
descs: ['create_time']
})
// table hook

View File

@ -1,21 +1,21 @@
<template>
<el-dialog v-model="visible" :close-on-click-modal="false"
:title="form.id ? $t('common.editBtn') : $t('common.addBtn')" draggable>
<el-form ref="dataFormRef" :model="form" :rules="dataRules" formDialogRef label-width="90px">
<el-dialog :close-on-click-modal="false" :title="form.id ? $t('common.editBtn') : $t('common.addBtn')"
draggable v-model="visible">
<el-form :model="form" :rules="dataRules" formDialogRef label-width="90px" ref="dataFormRef">
<el-row :gutter="20">
<el-col :span="24" class="mb20">
<el-form-item :label="t('i18n.name')" prop="name">
<el-input v-model="form.name" :placeholder="t('i18n.inputKeyTip')"/>
<el-input :placeholder="t('i18n.inputKeyTip')" v-model="form.name"/>
</el-form-item>
</el-col>
<el-col :span="24" class="mb20">
<el-form-item :label="t('i18n.zhCn')" prop="zhCn">
<el-input v-model="form.zhCn" :placeholder="t('i18n.inputZhCnTip')"/>
<el-input :placeholder="t('i18n.inputZhCnTip')" v-model="form.zhCn"/>
</el-form-item>
</el-col>
<el-col :span="24" class="mb20">
<el-form-item :label="t('i18n.en')" prop="en">
<el-input v-model="form.en" :placeholder="t('i18n.inputEnTip')"/>
<el-input :placeholder="t('i18n.inputEnTip')" v-model="form.en"/>
</el-form-item>
</el-col>
</el-row>
@ -23,7 +23,7 @@
<template #footer>
<span class="dialog-footer">
<el-button @click="visible = false">{{ $t('common.cancelButtonText') }}</el-button>
<el-button type="primary" @click="onSubmit">{{ $t('common.confirmButtonText') }}</el-button>
<el-button @click="onSubmit" type="primary">{{ $t('common.confirmButtonText') }}</el-button>
</span>
</template>
</el-dialog>
@ -34,6 +34,7 @@
import {useMessage} from "/@/hooks/message";
import {addObj, getObj, putObj} from '/@/api/admin/i18n'
import {useI18n} from "vue-i18n"
import {rule} from "/@/utils/validate";
const emit = defineEmits(['refresh']);
@ -54,9 +55,12 @@ const form = reactive({
//
const dataRules = ref({
name: [{required: true, message: 'name不能为空', trigger: 'blur'}],
zhCn: [{required: true, message: '中文不能为空', trigger: 'blur'}],
en: [{required: true, message: '英文不能为空', trigger: 'blur'}],
name: [{required: true, message: 'name不能为空', trigger: 'blur'}
, {validator: rule.noChinese, trigger: 'blur'}],
zhCn: [{required: true, message: '中文不能为空', trigger: 'blur'},
{validator: rule.chinese, trigger: 'blur'}],
en: [{required: true, message: '英文不能为空', trigger: 'blur'}
, {validator: rule.letter, trigger: 'blur'}],
})
//

View File

@ -1,6 +1,6 @@
<template>
<div class="layout-padding">
<el-card class="layout-padding-auto">
<div class="layout-padding-auto layout-padding-view">
<el-row class="mb8" v-show="showSearch">
<el-form :inline="true" :model="state.queryForm" @keyup.enter="getDataList" ref="queryRef">
<el-form-item :label="$t('i18n.name')" prop="name">
@ -27,16 +27,15 @@
<el-row>
<div class="mb8" style="width: 100%">
<el-button @click="formDialogRef.openDialog()" class="ml10" formDialogRef icon="folder-add"
type="primary"
v-auth="'admin_i18n_add'">
type="primary" v-auth="'admin_i18n_add'">
{{ $t('common.addBtn') }}
</el-button>
<el-button @click="exportExcel" class="ml10" formDialogRef icon="Download" type="primary"
v-auth="'admin_i18n_export'">
{{ $t('common.exportBtn') }}
</el-button>
<el-button :disabled="multiple" @click="handleDelete(selectObjs)" class="ml10" formDialogRef icon="Delete"
type="primary" v-auth="'admin_i18n_del'">
<el-button :disabled="multiple" @click="handleDelete(selectObjs)" class="ml10" formDialogRef
icon="Delete" type="primary" v-auth="'admin_i18n_del'">
{{ $t('common.delBtn') }}
</el-button>
<right-toolbar @queryTable="getDataList" class="ml10" style="float: right;margin-right: 20px"
@ -46,6 +45,7 @@
<el-table :data="state.dataList" @selection-change="handleSelectionChange" @sort-change="sortChangeHandle"
style="width: 100%" v-loading="state.loading">
<el-table-column align="center" type="selection" width="60" />
<el-table-column type="index" :label="t('file.index')" width="80" />
<el-table-column :label="t('i18n.name')" prop="name" show-overflow-tooltip />
<el-table-column :label="t('i18n.zhCn')" prop="zhCn" show-overflow-tooltip />
<el-table-column :label="t('i18n.en')" prop="en" show-overflow-tooltip />
@ -66,9 +66,8 @@
</template>
</el-table-column>
</el-table>
<pagination @current-change="currentChangeHandle" @size-change="sizeChangeHandle"
v-bind="state.pagination"/>
</el-card>
<pagination @current-change="currentChangeHandle" @size-change="sizeChangeHandle" v-bind="state.pagination" />
</div>
<!-- 编辑新增 -->
<form-dialog @refresh="getDataList()" ref="formDialogRef" />
@ -101,7 +100,8 @@
zhCn: '',
en: ''
},
pageList: fetchList
pageList: fetchList,
descs: ['create_time']
})
// table hook

View File

@ -1,22 +1,18 @@
<template>
<div class="layout-padding">
<el-card class="layout-padding-auto" shadow="hover">
<div class="layout-padding-auto layout-padding-view">
<el-row class="mb8" v-show="showSearch">
<el-form :inline="true" :model="state.queryForm" @keyup.enter="getDataList" ref="queryRef">
<el-form-item :label="$t('syslog.logType')" prop="logType">
<el-select :placeholder="$t('syslog.inputLogTypeTip')" class="w100"
clearable
<el-select :placeholder="$t('syslog.inputLogTypeTip')" class="w100" clearable
v-model="state.queryForm.logType">
<el-option :key="item.value" :label="item.label" :value="item.value"
v-for="item in log_type"/>
<el-option :key="item.value" :label="item.label" :value="item.value" v-for="item in log_type" />
</el-select>
</el-form-item>
<el-form-item :label="$t('syslog.createTime')" prop="createTime">
<el-date-picker :end-placeholder="$t('syslog.inputEndPlaceholderTip')" :start-placeholder="$t('syslog.inputStartPlaceholderTip')"
range-separator="To"
type="datetimerange" v-model="state.queryForm.createTime"
value-format="YYYY-MM-DD HH:mm:ss"/>
<el-date-picker :end-placeholder="$t('syslog.inputEndPlaceholderTip')"
:start-placeholder="$t('syslog.inputStartPlaceholderTip')" range-separator="To"
type="datetimerange" v-model="state.queryForm.createTime" value-format="YYYY-MM-DD HH:mm:ss" />
</el-form-item>
<el-form-item>
<el-button @click="getDataList(true)" icon="Search" type="primary">{{ $t('common.queryBtn') }}
@ -27,8 +23,7 @@
</el-row>
<el-row>
<div class="mb8" style="width: 100%">
<el-button @click="exportExcel" class="ml10" icon="Download" type="primary"
v-auth="'sys_user_export'">
<el-button @click="exportExcel" class="ml10" icon="Download" type="primary" v-auth="'sys_user_export'">
{{ $t('common.exportBtn') }}
</el-button>
<el-button :disabled="multiple" @click="handleDelete(selectObjs)" class="ml10" icon="Delete"
@ -49,11 +44,9 @@
</template>
</el-table-column>
<el-table-column :label="$t('syslog.title')" prop="title" show-overflow-tooltip></el-table-column>
<el-table-column :label="$t('syslog.remoteAddr')" prop="remoteAddr"
show-overflow-tooltip></el-table-column>
<el-table-column :label="$t('syslog.remoteAddr')" prop="remoteAddr" show-overflow-tooltip></el-table-column>
<el-table-column :label="$t('syslog.method')" prop="method" show-overflow-tooltip></el-table-column>
<el-table-column :label="$t('syslog.serviceId')" prop="serviceId"
show-overflow-tooltip></el-table-column>
<el-table-column :label="$t('syslog.serviceId')" prop="serviceId" show-overflow-tooltip></el-table-column>
<el-table-column :label="$t('syslog.time')" prop="time" show-overflow-tooltip></el-table-column>
<el-table-column :label="$t('syslog.createTime')" prop="createTime" show-overflow-tooltip sortable="custom"
width="200"></el-table-column>
@ -69,7 +62,7 @@
<pagination @current-change="currentChangeHandle" @size-change="sizeChangeHandle" v-bind="state.pagination">
</pagination>
</el-card>
</div>
</div>
</template>
@ -100,7 +93,8 @@
createTime: ''
},
selectObjs: [],
pageList: pageList
pageList: pageList,
descs: ['create_time']
});
// table hook
@ -145,7 +139,3 @@
})
};
</script>
<style scoped>
</style>

View File

@ -1,17 +1,18 @@
<template>
<div class="layout-padding">
<el-card shadow="hover">
<div class="layout-padding-auto layout-padding-view">
<div class="mb15">
<el-form :model="state.queryForm" ref="queryRef" :inline="true" @keyup.enter="getDataList">
<el-form-item :label="$t('sysmenu.name')" prop="menuName">
<el-input :placeholder="$t('sysmenu.inputNameTip')" style="max-width: 180px"
clearable v-model="state.queryForm.menuName"/>
<el-input :placeholder="$t('sysmenu.inputNameTip')" style="max-width: 180px" clearable
v-model="state.queryForm.menuName" />
</el-form-item>
<el-form-item>
<el-button icon="search" type="primary" class="ml10" @click="getDataList">
{{ $t('common.queryBtn') }}
</el-button>
<el-button icon="folder-add" type="primary" class="ml10" @click="onOpenAddMenu" v-auth="'sys_menu_add'">
<el-button icon="folder-add" type="primary" class="ml10" @click="onOpenAddMenu"
v-auth="'sys_menu_add'">
{{ $t('common.addBtn') }}
</el-button>
</el-form-item>
@ -20,8 +21,7 @@
<el-table :data="state.dataList" v-loading="state.loading" style="width: 100%" row-key="path"
:tree-props="{ children: 'children', hasChildren: 'hasChildren' }">
<el-table-column prop="name" :label="$t('sysmenu.name')" show-overflow-tooltip></el-table-column>
<el-table-column prop="sortOrder" :label="$t('sysmenu.sortOrder')"
show-overflow-tooltip></el-table-column>
<el-table-column prop="sortOrder" :label="$t('sysmenu.sortOrder')" show-overflow-tooltip></el-table-column>
<el-table-column prop="icon" :label="$t('sysmenu.icon')" show-overflow-tooltip>
<template #default="scope">
<SvgIcon :name="scope.row.icon" />
@ -51,8 +51,8 @@
<el-button text type="primary" @click="onOpenEditMenu('edit', scope.row)"
v-auth="'sys_menu_edit'">{{ $t('common.editBtn') }}</el-button>
<el-tooltip :content="$t('sysmenu.deleteDisabledTip')"
:disabled="!deleteMenuDisabled(scope.row)" placement="top">
<el-tooltip :content="$t('sysmenu.deleteDisabledTip')" :disabled="!deleteMenuDisabled(scope.row)"
placement="top">
<span style="margin-left: 12px">
<el-button text type="primary" :disabled="deleteMenuDisabled(scope.row)"
@click="onTabelRowDel(scope.row)" v-auth="'sys_menu_del'">
@ -63,7 +63,7 @@
</template>
</el-table-column>
</el-table>
</el-card>
</div>
<MenuDialog ref="menuDialogRef" @refresh="getDataList()" />
</div>
</template>

View File

@ -1,55 +1,55 @@
<template>
<el-dialog v-model="visible" :close-on-click-modal="false"
:title="form.publicId ? $t('common.editBtn') : $t('common.addBtn')" draggable>
<el-form ref="dataFormRef" :model="form" :rules="dataRules" formDialogRef label-width="90px">
<el-dialog :close-on-click-modal="false" :title="form.publicId ? $t('common.editBtn') : $t('common.addBtn')"
draggable v-model="visible">
<el-form :model="form" :rules="dataRules" formDialogRef label-width="90px" ref="dataFormRef">
<el-row :gutter="20">
<el-col :span="24" class="mb20">
<el-form-item :label="t('param.publicName')" prop="publicName">
<el-input v-model="form.publicName" :placeholder="t('param.inputpublicNameTip')"/>
<el-input :placeholder="t('param.inputpublicNameTip')" v-model="form.publicName"/>
</el-form-item>
</el-col>
<el-col :span="24" class="mb20">
<el-form-item :label="t('param.publicKey')" prop="publicKey">
<el-input v-model="form.publicKey" :placeholder="t('param.inputpublicKeyTip')"/>
<el-input :placeholder="t('param.inputpublicKeyTip')" v-model="form.publicKey"/>
</el-form-item>
</el-col>
<el-col :span="24" class="mb20">
<el-form-item :label="t('param.publicValue')" prop="publicValue">
<el-input v-model="form.publicValue" :placeholder="t('param.inputpublicValueTip')"/>
<el-input :placeholder="t('param.inputpublicValueTip')" v-model="form.publicValue"/>
</el-form-item>
</el-col>
<el-col :span="24" class="mb20">
<el-form-item :label="t('param.status')" prop="status">
<el-select v-model="form.status" :placeholder="t('param.inputstatusTip')">
<el-option v-for="(item, index) in status_type" :key="index" :label="item.label"
:value="item.value"></el-option>
<el-select :placeholder="t('param.inputstatusTip')" v-model="form.status">
<el-option :key="index" :label="item.label" :value="item.value"
v-for="(item, index) in status_type"></el-option>
</el-select>
</el-form-item>
</el-col>
<el-col :span="24" class="mb20">
<el-form-item :label="t('param.validateCode')" prop="validateCode">
<el-input v-model="form.validateCode" :placeholder="t('param.inputvalidateCodeTip')"/>
<el-input :placeholder="t('param.inputvalidateCodeTip')" v-model="form.validateCode"/>
</el-form-item>
</el-col>
<el-col :span="24" class="mb20">
<el-form-item :label="t('param.publicType')" prop="publicType">
<el-select v-model="form.publicType" :placeholder="t('param.inputpublicTypeTip')">
<el-option v-for="(item, index) in param_type" :key="index" :label="item.label"
:value="item.value"></el-option>
<el-select :placeholder="t('param.inputpublicTypeTip')" v-model="form.publicType">
<el-option :key="index" :label="item.label" :value="item.value"
v-for="(item, index) in param_type"></el-option>
</el-select>
</el-form-item>
</el-col>
<el-col :span="24" class="mb20">
<el-form-item :label="t('param.systemFlag')" prop="systemFlag">
<el-select v-model="form.systemFlag" :placeholder="t('param.inputsystemFlagTip')">
<el-option v-for="(item, index) in dict_type" :key="index" :label="item.label"
:value="item.value"></el-option>
<el-select :placeholder="t('param.inputsystemFlagTip')" v-model="form.systemFlag">
<el-option :key="index" :label="item.label" :value="item.value"
v-for="(item, index) in dict_type"></el-option>
</el-select>
</el-form-item>
</el-col>
@ -58,8 +58,8 @@
</el-form>
<template #footer>
<span class="dialog-footer">
<el-button formDialogRef @click="visible = false">{{ $t('common.cancelButtonText') }}</el-button>
<el-button formDialogRef type="primary" @click="onSubmit">{{ $t('common.confirmButtonText') }}</el-button>
<el-button @click="visible = false" formDialogRef>{{ $t('common.cancelButtonText') }}</el-button>
<el-button @click="onSubmit" formDialogRef type="primary">{{ $t('common.confirmButtonText') }}</el-button>
</span>
</template>
</el-dialog>
@ -71,6 +71,7 @@ import {useDict} from '/@/hooks/dict';
import {useMessage} from "/@/hooks/message";
import {addObj, getObj, putObj} from '/@/api/admin/param'
import {useI18n} from "vue-i18n"
import {rule} from "/@/utils/validate";
const emit = defineEmits(['refresh']);
@ -97,11 +98,13 @@ const form = reactive({
//
const dataRules = reactive({
publicName: [{required: true, message: '名称不能为空', trigger: 'blur'}],
publicKey: [{ required: true, message: '参数键不能为空', trigger: 'blur' }],
publicKey: [{required: true, message: '参数键不能为空', trigger: 'blur'}
, {validator: rule.validatorKey, trigger: 'blur'}],
publicValue: [{required: true, message: '参数值不能为空', trigger: 'blur'}],
status: [{required: true, message: '状态不能为空', trigger: 'blur'}],
validateCode: [{required: true, message: '编码不能为空', trigger: 'blur'}],
publicType: [{required: true, message: '类型不能为空', trigger: 'blur'}],
systemFlag: [{required: true, message: '类型不能为空', trigger: 'blur'}],
})
//

View File

@ -1,6 +1,6 @@
<template>
<div class="layout-padding">
<el-card class="layout-padding-auto">
<div class="layout-padding-auto layout-padding-view">
<el-row class="mb8" v-show="showSearch">
<el-form :inline="true" :model="state.queryForm" ref="queryRef">
<el-form-item :label="t('param.systemFlag')" class="ml2" prop="systemFlag">
@ -20,8 +20,7 @@
</el-row>
<el-row>
<div class="mb8" style="width: 100%">
<el-button @click="formDialogRef.openDialog()" class="ml10" icon="folder-add"
type="primary">
<el-button @click="formDialogRef.openDialog()" class="ml10" icon="folder-add" type="primary">
{{ $t('common.addBtn') }}
</el-button>
<el-button @click="exportExcel" class="ml10" icon="Download" type="primary">
@ -31,8 +30,7 @@
type="primary">
{{ $t('common.delBtn') }}
</el-button>
<el-button @click="handleRefreshCache()" class="ml10" icon="refresh-left"
type="primary">
<el-button @click="handleRefreshCache()" class="ml10" icon="refresh-left" type="primary">
{{ $t('common.refreshCacheBtn') }}
</el-button>
<right-toolbar @queryTable="getDataList" class="ml10" style="float: right;margin-right: 20px"
@ -68,8 +66,8 @@
<el-tooltip :content="$t('sysdict.deleteDisabledTip')" :disabled="scope.row.systemFlag === 1"
placement="top">
<span style="margin-left: 12px">
<el-button :disabled="scope.row.systemFlag !== 1" @click="handleDelete([scope.row.publicId])" text
type="primary">
<el-button :disabled="scope.row.systemFlag !== 1"
@click="handleDelete([scope.row.publicId])" text type="primary">
{{ $t('common.delBtn') }}
</el-button>
</span>
@ -77,9 +75,8 @@
</template>
</el-table-column>
</el-table>
<pagination @current-change="currentChangeHandle" @size-change="sizeChangeHandle"
v-bind="state.pagination"/>
</el-card>
<pagination @current-change="currentChangeHandle" @size-change="sizeChangeHandle" v-bind="state.pagination" />
</div>
<!-- 编辑新增 -->
<form-dialog @refresh="getDataList()" ref="formDialogRef" />
@ -112,7 +109,8 @@
queryForm: {
systemFlag: ''
},
pageList: fetchList
pageList: fetchList,
descs: ['create_time']
})
// table hook

View File

@ -1,6 +1,6 @@
<template>
<div class="layout-padding">
<el-card class="layout-padding-auto">
<div class="layout-padding-auto layout-padding-view">
<el-row class="mb8" v-show="showSearch">
<el-form :inline="true" :model="state.queryForm" @keyup.enter="getDataList" ref="queryRef">
<el-form-item :label="$t('post.postName')" prop="postName">
@ -25,12 +25,11 @@
v-auth="'sys_post_add'">
{{ $t('common.importBtn') }}
</el-button>
<el-button @click="exportExcel" class="ml10" icon="Download" type="primary"
v-auth="'sys_post_export'">
<el-button @click="exportExcel" class="ml10" icon="Download" type="primary" v-auth="'sys_post_export'">
{{ $t('common.exportBtn') }}
</el-button>
<el-button :disabled="multiple" @click="handleDelete(selectObjs)" class="ml10" icon="Delete" type="primary"
v-auth="'sys_post_del'">
<el-button :disabled="multiple" @click="handleDelete(selectObjs)" class="ml10" icon="Delete"
type="primary" v-auth="'sys_post_del'">
{{ $t('common.delBtn') }}
</el-button>
<right-toolbar @queryTable="getDataList" class="ml10" style="float: right;margin-right: 20px"
@ -51,17 +50,15 @@
v-auth="'sys_post_edit'">{{ $t('common.editBtn') }}
</el-button>
<el-button @click="handleDelete([scope.row.postId])" text type="primary"
v-auth="'sys_post_del'">{{
<el-button @click="handleDelete([scope.row.postId])" text type="primary" v-auth="'sys_post_del'">{{
$t('common.delBtn')
}}
</el-button>
</template>
</el-table-column>
</el-table>
<pagination @current-change="currentChangeHandle" @size-change="sizeChangeHandle"
v-bind="state.pagination"/>
</el-card>
<pagination @current-change="currentChangeHandle" @size-change="sizeChangeHandle" v-bind="state.pagination" />
</div>
<!-- 编辑新增 -->
<form-dialog @refresh="getDataList()" ref="formDialogRef" />

View File

@ -1,35 +1,42 @@
<template>
<el-dialog :title="form.roleId ? $t('common.editBtn') : $t('common.addBtn')" v-model="visible"
:close-on-click-modal="false" draggable>
<el-form ref="dataFormRef" :model="form" :rules="dataRules" label-width="90px">
<el-dialog :close-on-click-modal="false" :title="form.roleId ? $t('common.editBtn') : $t('common.addBtn')"
draggable v-model="visible">
<el-form :model="form" :rules="dataRules" label-width="90px" ref="dataFormRef">
<el-row :gutter="35">
<el-col :span="12" class="mb20">
<el-form-item :label="$t('sysrole.roleName')" prop="roleName">
<el-input v-model="form.roleName" :placeholder="$t('sysrole.please_enter_a_role_name')" clearable></el-input>
<el-input :placeholder="$t('sysrole.please_enter_a_role_name')" clearable
v-model="form.roleName"></el-input>
</el-form-item>
</el-col>
<el-col :span="12" class="mb20">
<el-form-item :label="$t('sysrole.roleCode')" prop="roleCode">
<el-input v-model="form.roleCode" :placeholder="$t('sysrole.please_enter_the_role_Code')" clearable></el-input>
<el-input :placeholder="$t('sysrole.please_enter_the_role_Code')" clearable
v-model="form.roleCode"></el-input>
</el-form-item>
</el-col>
<el-col :xs="24" :sm="24" :md="24" :lg="24" :xl="24" class="mb20">
<el-col :lg="24" :md="24" :sm="24" :xl="24" :xs="24" class="mb20">
<el-form-item :label="$t('sysrole.roleDesc')" prop="roleDesc">
<el-input v-model="form.roleDesc" type="textarea" :placeholder="$t('sysrole.please_enter_the_role_description')" maxlength="150"></el-input>
<el-input :placeholder="$t('sysrole.please_enter_the_role_description')" maxlength="150"
type="textarea"
v-model="form.roleDesc"></el-input>
</el-form-item>
</el-col>
<el-col :xs="24" :sm="24" :md="24" :lg="24" :xl="24" class="mb20">
<el-col :lg="24" :md="24" :sm="24" :xl="24" :xs="24" class="mb20">
<el-form-item :label="$t('sysrole.menu_authority')" prop="dsType">
<el-select v-model="form.dsType" :placeholder="$t('sysrole.please_select')" clearable class="w100">
<el-option v-for="item in dictType" :key="item.value" :label="item.label" :value="item.value" />
<el-select :placeholder="$t('sysrole.please_select')" class="w100" clearable
v-model="form.dsType">
<el-option :key="item.value" :label="item.label" :value="item.value"
v-for="item in dictType"/>
</el-select>
</el-form-item>
</el-col>
<el-col :span="24" class="mb20" v-if="form.dsType === 1">
<el-form-item>
<el-tree show-checkbox ref="deptTreeRef" :check-strictly="true" :data="dataForm.deptData"
:props="dataForm.deptProps" :default-checked-keys="dataForm.checkedDsScope" node-key="id"
highlight-current default-expand-all />
<el-tree :check-strictly="true" :data="dataForm.deptData" :default-checked-keys="dataForm.checkedDsScope" :props="dataForm.deptProps"
default-expand-all highlight-current
node-key="id"
ref="deptTreeRef" show-checkbox/>
</el-form-item>
</el-col>
</el-row>
@ -37,21 +44,21 @@
<template #footer>
<span class="dialog-footer">
<el-button @click="visible = false">{{ $t('common.cancelButtonText') }}</el-button>
<el-button type="primary" @click="onSubmit" >{{ $t('common.confirmButtonText') }}</el-button>
<el-button @click="onSubmit" type="primary">{{ $t('common.confirmButtonText') }}</el-button>
</span>
</template>
</el-dialog>
</template>
<script setup lang="ts" name="systemRoleDialog">
<script lang="ts" name="systemRoleDialog" setup>
import {rule} from '/@/utils/validate';
import {depttree} from '/@/api/admin/dept'
import {useMessage} from "/@/hooks/message";
import {addObj, getObj, getObjByCode, putObj} from '/@/api/admin/role'
import {useI18n} from "vue-i18n"
// /
const emit = defineEmits(['refresh']);
import { depttree } from '/@/api/admin/dept'
import { useMessage } from "/@/hooks/message";
import { getObj, addObj, putObj, getObjByCode } from '/@/api/admin/role'
import { useI18n } from "vue-i18n"
const {t} = useI18n();
@ -107,7 +114,8 @@ const dataRules = ref(
{validator: validateRoleCode, trigger: 'blur'}
],
roleDesc: [{max: 128, message: '长度在 128 个字符内', trigger: 'blur'}],
dsType: [{ required: true, message: "请选择数据权限类型", trigger: "blur" }]
dsType: [{required: true, message: "请选择数据权限类型", trigger: "blur"}],
menu_authority: [{required: true, message: "菜单权限不能为空", trigger: "blur"}]
}
)

View File

@ -1,6 +1,6 @@
<template>
<div class="layout-padding">
<el-card shadow="hover" class="layout-padding-auto">
<div class="layout-padding-auto layout-padding-view">
<el-row shadow="hover" v-show="showSearch" class="mb8">
<el-form :model="state.queryForm" ref="queryRef" :inline="true" @keyup.enter="getDataList">
<el-form-item :label="$t('sysrole.roleName')" prop="roleName">
@ -51,8 +51,8 @@
<el-table-column prop="createTime" :label="$t('sysrole.createTime')" show-overflow-tooltip></el-table-column>
<el-table-column :label="$t('common.action')" width="150">
<template #default="scope">
<el-button text type="primary" v-auth="'sys_role_edit'"
@click="roleDialogRef.openDialog(scope.row.roleId)">{{ $t('common.editBtn') }}</el-button>
<el-button text type="primary" v-auth="'sys_role_edit'" @click="roleDialogRef.openDialog(scope.row.roleId)">{{
$t('common.editBtn') }}</el-button>
<el-button text type="primary" v-auth="'sys_role_del'" @click="permessionRef.openDialog(scope.row)">{{
$t('sysrole.permissionTip')
@ -72,7 +72,7 @@
</el-table-column>
</el-table>
<pagination @size-change="sizeChangeHandle" @current-change="currentChangeHandle" v-bind="state.pagination" />
</el-card>
</div>
<!-- 角色编辑新增 -->
<role-dialog ref="roleDialogRef" @refresh="getDataList()" />
@ -110,7 +110,8 @@ const state: BasicTableProps = reactive<BasicTableProps>({
queryForm: {
roleName: ''
},
pageList: pageList // H
pageList: pageList, // H
descs: ['create_time']
});
const dictType = ref([{

View File

@ -1,12 +1,13 @@
<template>
<el-dialog v-model="visible" :close-on-click-modal="false"
:title="form.id ? $t('common.editBtn') : $t('common.addBtn')" draggable>
<el-form ref="dataFormRef" :model="form" :rules="dataRules" formDialogRef label-width="90px">
<el-dialog :close-on-click-modal="false" :title="form.id ? $t('common.editBtn') : $t('common.addBtn')"
draggable v-model="visible">
<el-form :model="form" :rules="dataRules" formDialogRef label-width="90px" ref="dataFormRef">
<el-row :gutter="20">
<el-col :span="12" class="mb20">
<el-form-item :label="t('social.type')" prop="type">
<el-select v-model="form.type" :placeholder="t('social.inputTypeTip')">
<el-option v-for="(item, index) in social_type" :key="index" :label="item.label" :value="item.value">
<el-select :placeholder="t('social.inputTypeTip')" v-model="form.type">
<el-option :key="index" :label="item.label" :value="item.value"
v-for="(item, index) in social_type">
{{ item.label }}
</el-option>
</el-select>
@ -14,35 +15,36 @@
</el-col>
<el-col :span="12" class="mb20">
<el-form-item :label="t('social.remark')" prop="remark">
<el-input v-model="form.remark" :placeholder="t('social.inputRemarkTip')" />
<el-input :placeholder="t('social.inputRemarkTip')" v-model="form.remark"/>
</el-form-item>
</el-col>
<el-col :span="12" class="mb20">
<el-form-item :label="t('social.appId')" prop="appId">
<el-input v-model="form.appId" :placeholder="t('social.inputAppIdTip')" />
<el-input :placeholder="t('social.inputAppIdTip')" v-model="form.appId"/>
</el-form-item>
</el-col>
<el-col :span="12" class="mb20">
<el-form-item :label="t('social.appSecret')" prop="appSecret">
<el-input v-model="form.appSecret" :placeholder="t('social.inputAppSecretTip')" />
<el-input :placeholder="t('social.inputAppSecretTip')" v-model="form.appSecret"/>
</el-form-item>
</el-col>
<el-col :span="24" class="mb20">
<el-form-item :label="t('social.redirectUrl')" prop="redirectUrl">
<el-input v-model="form.redirectUrl" :placeholder="t('social.inputRedirectUrlTip')" type="textarea" />
<el-input :placeholder="t('social.inputRedirectUrlTip')" type="textarea"
v-model="form.redirectUrl"/>
</el-form-item>
</el-col>
<el-col :span="24" class="mb20">
<el-form-item :label="t('social.ext')" prop="ext">
<el-input v-model="form.ext" :placeholder="t('social.inputExtTip')" type="textarea" />
<el-input :placeholder="t('social.inputExtTip')" type="textarea" v-model="form.ext"/>
</el-form-item>
</el-col>
</el-row>
</el-form>
<template #footer>
<span class="dialog-footer">
<el-button formDialogRef @click="visible = false">{{ $t('common.cancelButtonText') }}</el-button>
<el-button formDialogRef type="primary" @click="onSubmit">{{ $t('common.confirmButtonText') }}</el-button>
<el-button @click="visible = false" formDialogRef>{{ $t('common.cancelButtonText') }}</el-button>
<el-button @click="onSubmit" formDialogRef type="primary">{{ $t('common.confirmButtonText') }}</el-button>
</span>
</template>
</el-dialog>
@ -54,6 +56,7 @@ import { useDict } from '/@/hooks/dict';
import {useMessage} from "/@/hooks/message";
import {addObj, getObj, putObj} from '/@/api/admin/social'
import {useI18n} from "vue-i18n"
import {rule} from "/@/utils/validate";
const emit = defineEmits(['refresh']);
@ -80,6 +83,9 @@ const form = reactive({
const dataRules = ref({
type: [{required: true, message: '类型不能为空', trigger: 'blur'}],
appId: [{required: true, message: 'appId不能为空', trigger: 'blur'}],
remark: [{required: true, message: '描述不能为空', trigger: 'blur'}],
redirectUrl: [{required: true, message: '回调地址不能为空', trigger: 'blur'}
, {validator: rule.url, trigger: 'blur'}],
appSecret: [{required: true, message: 'appSecret不能为空', trigger: 'blur'}],
})

View File

@ -1,6 +1,6 @@
<template>
<div class="layout-padding">
<el-card class="layout-padding-auto">
<div class="layout-padding-auto layout-padding-view">
<el-row v-show="showSearch" class="mb8">
<el-form ref="queryRef" :inline="true" :model="state.queryForm">
<el-form-item :label="t('social.type')" class="ml2" prop="type">
@ -26,8 +26,8 @@
<el-button class="ml10" icon="Download" type="primary" @click="exportExcel">
{{ $t('common.exportBtn') }}
</el-button>
<el-button v-auth="'sys_social_details_del'" :disabled="multiple" class="ml10" icon="Delete"
type="primary" @click="handleDelete(selectObjs)">
<el-button v-auth="'sys_social_details_del'" :disabled="multiple" class="ml10" icon="Delete" type="primary"
@click="handleDelete(selectObjs)">
{{ $t('common.delBtn') }}
</el-button>
<right-toolbar v-model:showSearch="showSearch" class="ml10" style="float: right;margin-right: 20px"
@ -60,7 +60,7 @@
</el-table-column>
</el-table>
<pagination v-bind="state.pagination" @size-change="sizeChangeHandle" @current-change="currentChangeHandle" />
</el-card>
</div>
<!-- 编辑新增 -->
<form-dialog ref="formDialogRef" @refresh="getDataList()" />
@ -91,7 +91,8 @@ const multiple = ref(true)
const state: BasicTableProps = reactive<BasicTableProps>({
queryForm: {},
pageList: fetchList
pageList: fetchList,
descs: ['create_time']
})
// table hook

View File

@ -1,6 +1,6 @@
<template>
<div class="layout-padding">
<el-card class="layout-padding-auto" shadow="hover">
<div class="layout-padding-auto layout-padding-view">
<el-row class="mb8" shadow="hover" v-show="showSearch">
<el-form :inline="true" :model="state.queryForm" @keyup.enter="getDataList" ref="queryRef">
<el-form-item :label="$t('tenant.name')" prop="name">
@ -28,8 +28,7 @@
</el-button>
<el-button :disabled="multiple" @click="handleDelete(selectObjs)" class="ml10" icon="Delete"
type="primary"
v-auth="'admin_systenant_del'">
type="primary" v-auth="'admin_systenant_del'">
{{ $t('common.delBtn') }}
</el-button>
@ -74,8 +73,8 @@
<el-tooltip :content="$t('tenant.deleteDisabledTip')" :disabled="scope.row.id !== '1'"
placement="top">
<span style="margin-left: 12px">
<el-button :disabled="scope.row.id === '1'" @click="handleDelete([scope.row.id])" text type="primary"
v-auth="'admin_systenant_del'">{{
<el-button :disabled="scope.row.id === '1'" @click="handleDelete([scope.row.id])" text
type="primary" v-auth="'admin_systenant_del'">{{
$t('common.delBtn')
}}
</el-button>
@ -84,9 +83,8 @@
</template>
</el-table-column>
</el-table>
<pagination @current-change="currentChangeHandle" @size-change="sizeChangeHandle"
v-bind="state.pagination"/>
</el-card>
<pagination @current-change="currentChangeHandle" @size-change="sizeChangeHandle" v-bind="state.pagination" />
</div>
<!-- 编辑新增 -->
<form-dialog @refresh="getDataList()" ref="formDialogRef" />

View File

@ -1,6 +1,6 @@
<template>
<el-drawer v-model="visible" title="租户套餐" size="80%">
<el-card shadow="hover" class="layout-padding-auto">
<div class="layout-padding-auto layout-padding-view">
<el-row>
<div class="mb8" style="width: 100%">
<el-button icon="folder-add" type="primary" class="ml10" @click="tenantMenuDialogRef.openDialog()"
@ -20,8 +20,7 @@
<dict-tag :options="status_type" :value="scope.row.status"></dict-tag>
</template>
</el-table-column>
<el-table-column prop="createTime" :label="$t('tenantmenu.createTime')"
show-overflow-tooltip></el-table-column>
<el-table-column prop="createTime" :label="$t('tenantmenu.createTime')" show-overflow-tooltip></el-table-column>
<el-table-column :label="$t('common.action')" width="150">
<template #default="scope">
<el-button text type="primary" @click="tenantMenuDialogRef.openDialog(scope.row.id)"
@ -38,7 +37,7 @@
<pagination @size-change="sizeChangeHandle" @current-change="currentChangeHandle" v-bind="state.pagination">
</pagination>
<tenant-menu-dialog ref="tenantMenuDialogRef" @refresh="getDataList"></tenant-menu-dialog>
</el-card>
</div>
</el-drawer>
</template>
@ -86,6 +85,4 @@ defineExpose({
});
</script>
<style scoped>
</style>
<style scoped></style>

View File

@ -1,7 +1,6 @@
<template>
<div class="layout-padding">
<el-card class="layout-padding-auto" shadow="hover">
<div class="layout-padding-auto layout-padding-view">
<el-row class="mb8" v-show="showSearch">
<el-form :inline="true" :model="state.queryForm" @keyup.enter="getDataList" ref="queryRef">
<el-form-item :label="$t('systoken.username')" prop="username">
@ -53,7 +52,7 @@
<pagination @current-change="currentChangeHandle" @size-change="sizeChangeHandle" v-bind="state.pagination">
</pagination>
</el-card>
</div>
</div>
</template>
@ -78,7 +77,8 @@ const state: BasicTableProps = reactive<BasicTableProps>({
queryForm: {
username: ''
},
pageList: fetchList
pageList: fetchList,
});
// table hook

View File

@ -1,66 +1,72 @@
<template>
<div class="system-user-dialog-container">
<el-dialog :title="dataForm.userId ? $t('common.editBtn') : $t('common.addBtn')" v-model="visible"
:close-on-click-modal="false" draggable>
<el-form ref="dataFormRef" :model="dataForm" :rules="dataRules" label-width="90px" v-loading="loading">
<el-dialog :close-on-click-modal="false" :title="dataForm.userId ? $t('common.editBtn') : $t('common.addBtn')"
draggable v-model="visible">
<el-form :model="dataForm" :rules="dataRules" label-width="90px" ref="dataFormRef" v-loading="loading">
<el-row :gutter="20">
<el-col :span="12" class="mb20">
<el-form-item :label="$t('sysuser.username')" prop="username">
<el-input v-model="dataForm.username" placeholder="请输入用户名" :disabled="dataForm.userId !== ''"></el-input>
<el-input :disabled="dataForm.userId !== ''" placeholder="请输入用户名"
v-model="dataForm.username"></el-input>
</el-form-item>
</el-col>
<el-col :span="12" class="mb20">
<el-form-item :label="$t('sysuser.password')" prop="password">
<el-input v-model="dataForm.password" type="password" placeholder="请输入密码" clearable></el-input>
<el-input clearable placeholder="请输入密码" type="password"
v-model="dataForm.password"></el-input>
</el-form-item>
</el-col>
<el-col :span="12" class="mb20">
<el-form-item :label="$t('sysuser.name')" prop="name">
<el-input v-model="dataForm.name" placeholder="请输入姓名" clearable></el-input>
<el-input clearable placeholder="请输入姓名" v-model="dataForm.name"></el-input>
</el-form-item>
</el-col>
<el-col :span="12" class="mb20">
<el-form-item :label="$t('sysuser.phone')" prop="phone">
<el-input v-model="dataForm.phone" placeholder="请输入手机号" clearable></el-input>
<el-input clearable placeholder="请输入手机号" v-model="dataForm.phone"></el-input>
</el-form-item>
</el-col>
<el-col :span="12" class="mb20">
<el-form-item :label="$t('sysuser.role')" prop="role">
<el-select v-model="dataForm.role" placeholder="请选择角色" clearable class="w100" multiple>
<el-option v-for="item in roleData" :key="item.roleId" :label="item.roleName" :value="item.roleId" />
<el-select class="w100" clearable multiple placeholder="请选择角色" v-model="dataForm.role">
<el-option :key="item.roleId" :label="item.roleName" :value="item.roleId"
v-for="item in roleData"/>
</el-select>
</el-form-item>
</el-col>
<el-col :span="12" class="mb20">
<el-form-item :label="$t('sysuser.post')" prop="post">
<el-select v-model="dataForm.post" placeholder="请选择岗位" clearable class="w100" multiple>
<el-option v-for="item in postData" :key="item.postId" :label="item.postName" :value="item.postId" />
<el-select class="w100" clearable multiple placeholder="请选择岗位" v-model="dataForm.post">
<el-option :key="item.postId" :label="item.postName" :value="item.postId"
v-for="item in postData"/>
</el-select>
</el-form-item>
</el-col>
<el-col :span="12" class="mb20">
<el-form-item :label="$t('sysuser.dept')" prop="dept">
<el-tree-select v-model="dataForm.deptId" :data="deptData"
:props="{ value: 'id', label: 'name', children: 'children' }" class="w100" clearable check-strictly
placeholder="请选择所属部门">
<el-tree-select :data="deptData" :props="{ value: 'id', label: 'name', children: 'children' }"
check-strictly class="w100"
clearable placeholder="请选择所属部门"
v-model="dataForm.deptId">
</el-tree-select>
</el-form-item>
</el-col>
<el-col :span="12" class="mb20">
<el-form-item :label="$t('sysuser.email')" prop="email">
<el-input v-model="dataForm.email" placeholder="请输入邮箱" clearable></el-input>
<el-input clearable placeholder="请输入邮箱" v-model="dataForm.email"></el-input>
</el-form-item>
</el-col>
<el-col :span="12" class="mb20">
<el-form-item :label="$t('sysuser.nickname')" prop="nickname">
<el-input v-model="dataForm.nickname" placeholder="请输入昵称" clearable></el-input>
<el-input clearable placeholder="请输入昵称" v-model="dataForm.nickname"></el-input>
</el-form-item>
</el-col>
<el-col :span="12" class="mb20">
<el-form-item :label="$t('sysuser.lockFlag')" prop="lockFlag">
<el-radio-group v-model="dataForm.lockFlag">
<el-radio :label="item.value" v-for="(item, index) in lock_flag" border :key="index">{{ item.label }}
<el-radio :key="index" :label="item.value" border v-for="(item, index) in lock_flag">{{
item.label }}
</el-radio>
</el-radio-group>
</el-form-item>
@ -70,15 +76,15 @@
<template #footer>
<span class="dialog-footer">
<el-button @click="visible = false">{{ $t('common.cancelButtonText') }}</el-button>
<el-button type="primary" @click="onSubmit">{{ $t('common.confirmButtonText') }}</el-button>
<el-button @click="onSubmit" type="primary">{{ $t('common.confirmButtonText') }}</el-button>
</span>
</template>
</el-dialog>
</div>
</template>
<script setup lang="ts" name="systemUserDialog">
import { getObj, addObj, putObj, validateUsername, validatePhone } from '/@/api/admin/user'
<script lang="ts" name="systemUserDialog" setup>
import {addObj, getObj, putObj, validatePhone, validateUsername} from '/@/api/admin/user'
import {list as roleList} from '/@/api/admin/role'
import {list as postList} from '/@/api/admin/post'
import {depttree} from '/@/api/admin/dept'
@ -131,7 +137,12 @@ const dataRules = ref(
validateUsername(rule, value, callback, dataForm.userId !== '')
}, trigger: 'blur'
}],
password: [{ required: true, message: "密码不能为空", trigger: "blur" }, { min: 6, max: 20, message: "用户密码长度必须介于 5 和 20 之间", trigger: "blur" }],
password: [{required: true, message: "密码不能为空", trigger: "blur"}, {
min: 6,
max: 20,
message: "用户密码长度必须介于 5 和 20 之间",
trigger: "blur"
}],
//
name: [{required: true, message: "姓名不能为空", trigger: "blur"}
, {validator: rule.chinese, trigger: 'blur'}
@ -147,7 +158,8 @@ const dataRules = ref(
validatePhone(rule, value, callback, dataForm.userId !== '')
}, trigger: 'blur'
}],
email: [{ type: "email", message: "请输入正确的邮箱地址", trigger: ["blur", "change"] }]
email: [{type: "email", message: "请输入正确的邮箱地址", trigger: ["blur", "change"]}],
lockFlag: [{required: true, message: "状态不能为空", trigger: "blur"}],
}
)

View File

@ -17,5 +17,9 @@ export default {
inputNameTip: 'input name',
importUserTip: 'user import',
deleteDisabledTip: 'admin are not allowed to delete',
},
personal: {
name: 'personal info',
passwordRule: 'The two passwords are inconsistent'
}
}

View File

@ -18,5 +18,8 @@ export default {
importUserTip: '用户导入',
deleteDisabledTip: 'admin 不允许被删除',
},
personal: {
name: '个人信息',
passwordRule: '两次输入密码不一致'
}
}

View File

@ -8,7 +8,7 @@
</el-card>
</el-col>
<el-col :span="20" :xs="24">
<el-card shadow="hover" class="layout-padding-auto">
<div class="layout-padding-auto layout-padding-view">
<el-row v-show="showSearch" class="mb8">
<el-form :model="state.queryForm" ref="queryRef" :inline="true" @keyup.enter="getDataList">
<el-form-item :label="$t('sysuser.username')" prop="username">
@ -70,8 +70,7 @@
<dict-tag :options="lock_flag" :value="scope.row.lockFlag"></dict-tag>
</template>
</el-table-column>
<el-table-column prop="createTime" :label="$t('sysuser.createTime')"
show-overflow-tooltip></el-table-column>
<el-table-column prop="createTime" :label="$t('sysuser.createTime')" show-overflow-tooltip></el-table-column>
<el-table-column :label="$t('common.action')" width="150">
<template #default="scope">
<el-button text type="primary" @click="userDialogRef.openDialog(scope.row.userId)"
@ -95,8 +94,7 @@
<pagination @size-change="sizeChangeHandle" @current-change="currentChangeHandle" v-bind="state.pagination">
</pagination>
</el-card>
</div>
</el-col>
</el-row>
@ -141,7 +139,8 @@ const state: BasicTableProps = reactive<BasicTableProps>({
username: '',
phone: ''
},
pageList: pageList
pageList: pageList,
descs: ['create_time']
});
// 使

View File

@ -180,8 +180,6 @@ const passwordRuleForm = reactive({
})
//
const handleAvatarSuccess = (url: any) => {
formData.avatar = url;
@ -258,7 +256,7 @@ defineExpose({
</script>
<style scoped lang="scss">
@import '../../theme/mixins/index.scss';
@import '/@/theme/mixins/index.scss';
.personal {
.personal-user {

View File

@ -1,6 +1,8 @@
<template>
<el-dialog :title="state.ruleForm.menuId ? $t('common.editBtn') : $t('common.addBtn')" v-model="visible" :close-on-click-modal="false" draggable>
<el-form ref="menuDialogFormRef" :model="state.ruleForm" :rules="dataRules" label-width="90px" v-loading="loading">
<el-dialog :close-on-click-modal="false" :title="state.ruleForm.menuId ? $t('common.editBtn') : $t('common.addBtn')"
draggable v-model="visible">
<el-form :model="state.ruleForm" :rules="dataRules" label-width="90px" ref="menuDialogFormRef"
v-loading="loading">
<el-row :gutter="20">
<el-col :span="12" class="mb20">
<el-form-item :label="$t('sysmenu.menuType')" prop="menType">
@ -12,30 +14,31 @@
</el-col>
<el-col :span="12" class="mb20">
<el-form-item :label="$t('sysmenu.parentId')" prop="parentId">
<el-tree-select v-model="state.ruleForm.parentId" :data="state.parentData" default-expand-all
:props="{ value: 'id', label: 'name', children: 'children' }" class="w100" clearable check-strictly
placeholder="请选择上级菜单">
<el-tree-select :data="state.parentData" :props="{ value: 'id', label: 'name', children: 'children' }" check-strictly
class="w100" clearable
default-expand-all placeholder="请选择上级菜单"
v-model="state.ruleForm.parentId">
</el-tree-select>
</el-form-item>
</el-col>
<el-col :span="12" class="mb20">
<el-form-item :label="$t('sysmenu.name')" prop="name">
<el-input v-model="state.ruleForm.name" clearable placeholder="请输入菜单名称"></el-input>
<el-input clearable placeholder="请输入菜单名称" v-model="state.ruleForm.name"></el-input>
</el-form-item>
</el-col>
<el-col :span="12" class="mb20" v-if="state.ruleForm.menuType !== '1'">
<el-form-item :label="$t('sysmenu.path')" prop="path">
<el-input v-model="state.ruleForm.path" placeholder="请输入路由地址" />
<el-input placeholder="请输入路由地址" v-model="state.ruleForm.path"/>
</el-form-item>
</el-col>
<el-col :span="12" class="mb20">
<el-form-item :label="$t('sysmenu.permission')" prop="permission">
<el-input v-model="state.ruleForm.permission" maxlength="50" placeholder="请权限标识" />
<el-input maxlength="50" placeholder="请权限标识" v-model="state.ruleForm.permission"/>
</el-form-item>
</el-col>
<el-col :span="12" class="mb20">
<el-form-item :label="$t('sysmenu.sortOrder')" prop="sortOrder">
<el-input-number v-model="state.ruleForm.sortOrder" :min="0" controls-position="right" />
<el-input-number :min="0" controls-position="right" v-model="state.ruleForm.sortOrder"/>
</el-form-item>
</el-col>
<el-col :span="12" class="mb20" v-if="state.ruleForm.menuType !== '1'">
@ -51,15 +54,16 @@
<template #footer>
<span class="dialog-footer">
<el-button @click="visible = false">{{ $t('common.cancelButtonText') }}</el-button>
<el-button type="primary" @click="onSubmit" >{{ $t('common.confirmButtonText') }}</el-button>
<el-button @click="onSubmit" type="primary">{{ $t('common.confirmButtonText') }}</el-button>
</span>
</template>
</el-dialog>
</template>
<script setup lang="ts" name="systemMenuDialog">
import { info, pageList, update, addObj } from "/@/api/app/appmenu";
<script lang="ts" name="systemMenuDialog" setup>
import {addObj, info, pageList, update, validateByName, validatePermission} from "/@/api/app/appmenu";
import {useMessage} from "/@/hooks/message";
import {rule} from "/@/utils/validate";
// /
const emit = defineEmits(['refresh']);
@ -116,13 +120,23 @@ const getMenuData = () => {
};
const dataRules = reactive({
menType: [{ required: true, message: "姓名不能为空", trigger: "blur" }],
parentId: [{ required: true, message: "姓名不能为空", trigger: "blur" }],
name: [{ required: true, message: "姓名不能为空", trigger: "blur" }],
path: [{ required: true, message: "姓名不能为空", trigger: "blur" }],
permission: [{ required: true, message: "姓名不能为空", trigger: "blur" }],
sortOrder: [{ required: true, message: "姓名不能为空", trigger: "blur" }],
keepAlive: [{ required: true, message: "姓名不能为空", trigger: "blur" }]
name: [{required: true, message: "菜单名称不能为空", trigger: "blur"}
, {
validator: (rule: any, value: any, callback: any) => {
validateByName(rule, value, callback, state.ruleForm.menuId !== '')
}, trigger: 'blur'
}],
path: [{required: true, message: "路由路径不能为空", trigger: "blur"}
, {validate: rule.noChinese, trigger: "blur"}],
permission: [{required: true, message: "权限标识不能为空", trigger: "blur"},
{validator: rule.validatorKey, trigger: 'blur'},
{min: 3, max: 20, message: '长度在 3 到 20 个字符', trigger: 'blur'}
, {
validator: (rule: any, value: any, callback: any) => {
validatePermission(rule, value, callback, state.ruleForm.menuId !== '')
}, trigger: 'blur'
}],
})
//
const openDialog = (type: string, row?: any) => {

View File

@ -1,6 +1,6 @@
<template>
<div class="layout-padding">
<el-card shadow="hover">
<div class="layout-padding-auto layout-padding-view">
<div @keyup.enter="getDataList" class="mb15">
<el-input :placeholder="$t('appmenu.inputNameTip')" style="max-width: 180px"
v-model="state.queryForm.menuName"></el-input>
@ -16,13 +16,11 @@
</el-button>
</div>
<el-table :data="state.dataList" :tree-props="{ children: 'children', hasChildren: 'hasChildren' }" @selection-change="handleSelectionChange" row-key="path"
style="width: 100%"
v-loading="state.loading">
<el-table :data="state.dataList" :tree-props="{ children: 'children', hasChildren: 'hasChildren' }"
@selection-change="handleSelectionChange" row-key="path" style="width: 100%" v-loading="state.loading">
<el-table-column align="center" type="selection" width="50" />
<el-table-column :label="$t('appmenu.name')" prop="name" show-overflow-tooltip></el-table-column>
<el-table-column :label="$t('appmenu.sortOrder')" prop="sortOrder"
show-overflow-tooltip></el-table-column>
<el-table-column :label="$t('appmenu.sortOrder')" prop="sortOrder" show-overflow-tooltip></el-table-column>
<el-table-column :label="$t('appmenu.path')" prop="path" show-overflow-tooltip></el-table-column>
<el-table-column :label="$t('appmenu.menuType')" show-overflow-tooltip>
<template #default="scope">
@ -55,7 +53,7 @@
</template>
</el-table-column>
</el-table>
</el-card>
</div>
<MenuDialog @refresh="getDataList()" ref="menuDialogRef" />
</div>
</template>

View File

@ -1,21 +1,25 @@
<template>
<el-dialog :title="form.roleId ? $t('common.editBtn') : $t('common.addBtn')" v-model="visible"
:close-on-click-modal="false" draggable>
<el-form ref="dataFormRef" :model="form" :rules="dataRules" label-width="90px">
<el-dialog :close-on-click-modal="false" :title="form.roleId ? $t('common.editBtn') : $t('common.addBtn')"
draggable v-model="visible">
<el-form :model="form" :rules="dataRules" label-width="90px" ref="dataFormRef">
<el-row :gutter="35">
<el-col :span="12" class="mb20">
<el-form-item :label="$t('approle.roleName')" prop="roleName">
<el-input v-model="form.roleName" :placeholder="$t('approle.please_enter_a_role_name')" clearable></el-input>
<el-input :placeholder="$t('approle.please_enter_a_role_name')" clearable
v-model="form.roleName"></el-input>
</el-form-item>
</el-col>
<el-col :span="12" class="mb20">
<el-form-item :label="$t('approle.roleCode')" prop="roleCode">
<el-input v-model="form.roleCode" :placeholder="$t('approle.please_enter_the_role_Code')" clearable></el-input>
<el-input :placeholder="$t('approle.please_enter_the_role_Code')" clearable
v-model="form.roleCode"></el-input>
</el-form-item>
</el-col>
<el-col :xs="24" :sm="24" :md="24" :lg="24" :xl="24" class="mb20">
<el-col :lg="24" :md="24" :sm="24" :xl="24" :xs="24" class="mb20">
<el-form-item :label="$t('approle.roleDesc')" prop="roleDesc">
<el-input v-model="form.roleDesc" type="textarea" :placeholder="$t('approle.please_enter_the_role_description')" maxlength="150"></el-input>
<el-input :placeholder="$t('approle.please_enter_the_role_description')" maxlength="150"
type="textarea"
v-model="form.roleDesc"></el-input>
</el-form-item>
</el-col>
</el-row>
@ -23,19 +27,19 @@
<template #footer>
<span class="dialog-footer">
<el-button @click="visible = false">{{ $t('common.cancelButtonText') }}</el-button>
<el-button type="primary" @click="onSubmit" >{{ $t('common.confirmButtonText') }}</el-button>
<el-button @click="onSubmit" type="primary">{{ $t('common.confirmButtonText') }}</el-button>
</span>
</template>
</el-dialog>
</template>
<script setup lang="ts" name="systemRoleDialog">import { rule } from '/@/utils/validate';
<script lang="ts" name="systemRoleDialog" setup>import {rule} from '/@/utils/validate';
import {useMessage} from "/@/hooks/message";
import {addObj, getObj, putObj, validateAppRoleCode, validateApproleName} from '/@/api/app/approle'
import {useI18n} from "vue-i18n"
// /
const emit = defineEmits(['refresh']);
import { useMessage } from "/@/hooks/message";
import { getObj, addObj, putObj } from '/@/api/app/approle'
import { useI18n } from "vue-i18n"
const {t} = useI18n();
@ -71,11 +75,21 @@ const dataRules = ref(
roleName: [
{required: true, message: '角色名称不能为空', trigger: 'blur'},
{min: 3, max: 20, message: '长度在 3 到 20 个字符', trigger: 'blur'}
, {
validator: (rule: any, value: any, callback: any) => {
validateApproleName(rule, value, callback, form.roleId !== '')
}, trigger: 'blur'
}
],
roleCode: [
{required: true, message: '角色标识不能为空', trigger: 'blur'},
{min: 3, max: 20, message: '长度在 3 到 20 个字符', trigger: 'blur'},
{validator: rule.validatorKey, trigger: 'blur'}
, {
validator: (rule: any, value: any, callback: any) => {
validateAppRoleCode(rule, value, callback, form.roleId !== '')
}, trigger: 'blur'
}
],
roleDesc: [{max: 128, message: '长度在 128 个字符内', trigger: 'blur'}],
dsType: [{required: true, message: "请选择数据权限类型", trigger: "blur"}]

View File

@ -1,6 +1,6 @@
<template>
<div class="layout-padding">
<el-card class="layout-padding-auto" shadow="hover">
<div class="layout-padding-auto layout-padding-view">
<el-row class="mb8" shadow="hover" v-show="showSearch">
<el-form :inline="true" :model="state.queryForm" @keyup.enter="getDataList" ref="queryRef">
<el-form-item :label="$t('approle.roleName')" prop="roleName">
@ -28,8 +28,8 @@
<el-button @click="exportExcel" class="ml10" icon="Download" type="primary">
{{ $t('common.exportBtn') }}
</el-button>
<el-button :disabled="multiple" @click="handleDelete(selectObjs)" class="ml10" icon="Delete" type="primary"
v-auth="'app_approle_del'">
<el-button :disabled="multiple" @click="handleDelete(selectObjs)" class="ml10" icon="Delete"
type="primary" v-auth="'app_approle_del'">
{{ $t('common.delBtn') }}
</el-button>
<right-toolbar @queryTable="getDataList" class="ml10" style="float: right;margin-right: 20px"
@ -40,12 +40,9 @@
v-loading="state.loading">
<el-table-column align="center" type="selection" width="50" />
<el-table-column :label="$t('approle.index')" type="index" width="80" />
<el-table-column :label="$t('approle.roleName')" prop="roleName"
show-overflow-tooltip></el-table-column>
<el-table-column :label="$t('approle.roleCode')" prop="roleCode"
show-overflow-tooltip></el-table-column>
<el-table-column :label="$t('approle.roleDesc')" prop="roleDesc"
show-overflow-tooltip></el-table-column>
<el-table-column :label="$t('approle.roleName')" prop="roleName" show-overflow-tooltip></el-table-column>
<el-table-column :label="$t('approle.roleCode')" prop="roleCode" show-overflow-tooltip></el-table-column>
<el-table-column :label="$t('approle.roleDesc')" prop="roleDesc" show-overflow-tooltip></el-table-column>
<el-table-column :label="$t('approle.createTime')" prop="createTime"
show-overflow-tooltip></el-table-column>
<el-table-column :label="$t('common.action')" width="150">
@ -68,10 +65,8 @@
</template>
</el-table-column>
</el-table>
<pagination @current-change="currentChangeHandle" @size-change="sizeChangeHandle"
v-bind="state.pagination"/>
</el-card>
<pagination @current-change="currentChangeHandle" @size-change="sizeChangeHandle" v-bind="state.pagination" />
</div>
<!-- 角色编辑新增 -->
<role-dialog @refresh="getDataList()" ref="roleDialogRef" />
<!-- 导入角色 -->
@ -109,7 +104,8 @@
queryForm: {
roleName: ''
},
pageList: fetchList // H
pageList: fetchList,// H
descs: ['create_time']
});

View File

@ -1,43 +1,44 @@
<template>
<el-dialog v-model="visible" :close-on-click-modal="false"
:title="form.id ? $t('common.editBtn') : $t('common.addBtn')" draggable>
<el-form ref="dataFormRef" :model="form" :rules="dataRules" formDialogRef label-width="90px">
<el-dialog :close-on-click-modal="false" :title="form.id ? $t('common.editBtn') : $t('common.addBtn')"
draggable v-model="visible">
<el-form :model="form" :rules="dataRules" formDialogRef label-width="90px" ref="dataFormRef">
<el-row :gutter="20">
<el-col :span="12" class="mb20">
<el-form-item :label="t('appsocial.type')" prop="type">
<el-select v-model="form.type" :placeholder="t('appsocial.inputTypeTip')">
<el-option v-for="(item, index) in app_social_type" :key="index" :label="item.label"
:value="item.value"></el-option>
<el-select :placeholder="t('appsocial.inputTypeTip')" v-model="form.type">
<el-option :key="index" :label="item.label" :value="item.value"
v-for="(item, index) in app_social_type"></el-option>
</el-select>
</el-form-item>
</el-col>
<el-col :span="12" class="mb20">
<el-form-item :label="t('appsocial.remark')" prop="remark">
<el-input v-model="form.remark" :placeholder="t('appsocial.inputRemarkTip')"/>
<el-input :placeholder="t('appsocial.inputRemarkTip')" v-model="form.remark"/>
</el-form-item>
</el-col>
<el-col :span="12" class="mb20">
<el-form-item :label="t('appsocial.appId')" prop="appId">
<el-input v-model="form.appId" :placeholder="t('appsocial.inputAppIdTip')"/>
<el-input :placeholder="t('appsocial.inputAppIdTip')" v-model="form.appId"/>
</el-form-item>
</el-col>
<el-col :span="12" class="mb20">
<el-form-item :label="t('appsocial.appSecret')" prop="appSecret">
<el-input v-model="form.appSecret" :placeholder="t('appsocial.inputAppSecretTip')"/>
<el-input :placeholder="t('appsocial.inputAppSecretTip')" v-model="form.appSecret"/>
</el-form-item>
</el-col>
<el-col :span="24" class="mb20">
<el-form-item :label="t('appsocial.redirectUrl')" prop="redirectUrl">
<el-input v-model="form.redirectUrl" :placeholder="t('appsocial.inputRedirectUrlTip')" type="textarea"/>
<el-input :placeholder="t('appsocial.inputRedirectUrlTip')" type="textarea"
v-model="form.redirectUrl"/>
</el-form-item>
</el-col>
<el-col :span="24" class="mb20">
<el-form-item :label="t('appsocial.ext')" prop="ext">
<el-input v-model="form.ext" :placeholder="t('appsocial.inputExtTip')" type="textarea"/>
<el-input :placeholder="t('appsocial.inputExtTip')" type="textarea" v-model="form.ext"/>
</el-form-item>
</el-col>
@ -45,8 +46,8 @@
</el-form>
<template #footer>
<span class="dialog-footer">
<el-button formDialogRef @click="visible = false">{{ $t('common.cancelButtonText') }}</el-button>
<el-button formDialogRef type="primary" @click="onSubmit">{{ $t('common.confirmButtonText') }}</el-button>
<el-button @click="visible = false" formDialogRef>{{ $t('common.cancelButtonText') }}</el-button>
<el-button @click="onSubmit" formDialogRef type="primary">{{ $t('common.confirmButtonText') }}</el-button>
</span>
</template>
</el-dialog>
@ -58,6 +59,7 @@ import {useDict} from '/@/hooks/dict';
import {useMessage} from "/@/hooks/message";
import {addObj, getObj, putObj} from '/@/api/app/appsocial'
import {useI18n} from "vue-i18n"
import {rule} from "/@/utils/validate";
const emit = defineEmits(['refresh']);
@ -83,8 +85,13 @@ const form = reactive({
//
const dataRules = ref({
type: [{required: true, message: '类型不能为空', trigger: 'blur'}],
appId: [{required: true, message: 'appId不能为空', trigger: 'blur'}],
appSecret: [{required: true, message: 'appSecret不能为空', trigger: 'blur'}],
appId: [{required: true, message: 'appId不能为空', trigger: 'blur'},
{validator: rule.letterAndNumber, trigger: 'blur'}],
appSecret: [{required: true, message: 'app秘钥不能为空', trigger: 'blur'},
{validator: rule.letterAndNumber, trigger: 'blur'}],
redirectUrl: [{required: true, message: '回调地址不能为空', trigger: 'blur'},
{validator: rule.url, trigger: 'blur'}],
})
//

View File

@ -6,7 +6,7 @@ export default {
type: '类型',
remark: '描述',
appId: 'appId',
appSecret: 'appSecret',
appSecret: 'app秘钥',
redirectUrl: '回调地址',
ext: '拓展字段',
createBy: '创建人',

View File

@ -1,6 +1,6 @@
<template>
<div class="layout-padding">
<el-card class="layout-padding-auto">
<div class="layout-padding-auto layout-padding-view">
<el-row class="mb8" v-show="showSearch">
<el-form :inline="true" :model="state.queryForm" @keyup.enter="getDataList" ref="queryRef">
<el-form-item :label="t('appsocial.type')" class="ml2" prop="type">
@ -21,15 +21,14 @@
<el-row>
<div class="mb8" style="width: 100%">
<el-button @click="formDialogRef.openDialog()" class="ml10" formDialogRef icon="folder-add"
type="primary"
v-auth="'app_social_details_add'">
type="primary" v-auth="'app_social_details_add'">
{{ $t('common.addBtn') }}
</el-button>
<el-button @click="exportExcel" class="ml10" formDialogRef icon="Download" type="primary">
{{ $t('common.exportBtn') }}
</el-button>
<el-button :disabled="multiple" @click="handleDelete(selectObjs)" class="ml10" formDialogRef icon="Delete"
type="primary" v-auth="'app_social_details_del'">
<el-button :disabled="multiple" @click="handleDelete(selectObjs)" class="ml10" formDialogRef
icon="Delete" type="primary" v-auth="'app_social_details_del'">
{{ $t('common.delBtn') }}
</el-button>
<right-toolbar @queryTable="getDataList" class="ml10" style="float: right;margin-right: 20px"
@ -62,9 +61,8 @@
</template>
</el-table-column>
</el-table>
<pagination @current-change="currentChangeHandle" @size-change="sizeChangeHandle"
v-bind="state.pagination"/>
</el-card>
<pagination @current-change="currentChangeHandle" @size-change="sizeChangeHandle" v-bind="state.pagination" />
</div>
<!-- 编辑新增 -->
<form-dialog @refresh="getDataList()" ref="formDialogRef" />
@ -97,7 +95,8 @@
queryForm: {
type: ''
},
pageList: fetchList
pageList: fetchList,
descs: ['create_time']
})
// table hook

View File

@ -1,50 +1,54 @@
<template>
<div class="system-user-dialog-container">
<el-dialog :title="dataForm.userId ? $t('common.editBtn') : $t('common.addBtn')" v-model="visible"
:close-on-click-modal="false" draggable>
<el-form ref="dataFormRef" :model="dataForm" :rules="dataRules" label-width="90px" v-loading="loading">
<el-dialog :close-on-click-modal="false" :title="dataForm.userId ? $t('common.editBtn') : $t('common.addBtn')"
draggable v-model="visible">
<el-form :model="dataForm" :rules="dataRules" label-width="90px" ref="dataFormRef" v-loading="loading">
<el-row :gutter="20">
<el-col :span="12" class="mb20">
<el-form-item :label="$t('appuser.username')" prop="username">
<el-input v-model="dataForm.username" placeholder="请输入用户名" :disabled="dataForm.userId !== ''"></el-input>
<el-input :disabled="dataForm.userId !== ''" placeholder="请输入用户名"
v-model="dataForm.username"></el-input>
</el-form-item>
</el-col>
<el-col :span="12" class="mb20">
<el-form-item :label="$t('appuser.password')" prop="password">
<el-input v-model="dataForm.password" type="password" placeholder="请输入密码" clearable></el-input>
<el-input clearable placeholder="请输入密码" type="password"
v-model="dataForm.password"></el-input>
</el-form-item>
</el-col>
<el-col :span="12" class="mb20">
<el-form-item :label="$t('appuser.name')" prop="name">
<el-input v-model="dataForm.name" placeholder="请输入姓名" clearable></el-input>
<el-input clearable placeholder="请输入姓名" v-model="dataForm.name"></el-input>
</el-form-item>
</el-col>
<el-col :span="12" class="mb20">
<el-form-item :label="$t('appuser.phone')" prop="phone">
<el-input v-model="dataForm.phone" placeholder="请输入手机号" clearable></el-input>
<el-input clearable placeholder="请输入手机号" v-model="dataForm.phone"></el-input>
</el-form-item>
</el-col>
<el-col :span="12" class="mb20">
<el-form-item :label="$t('appuser.role')" prop="role">
<el-select v-model="dataForm.role" placeholder="请选择角色" clearable class="w100" multiple>
<el-option v-for="item in roleData" :key="item.roleId" :label="item.roleName" :value="item.roleId" />
<el-select class="w100" clearable multiple placeholder="请选择角色" v-model="dataForm.role">
<el-option :key="item.roleId" :label="item.roleName" :value="item.roleId"
v-for="item in roleData"/>
</el-select>
</el-form-item>
</el-col>
<el-col :span="12" class="mb20">
<el-form-item :label="$t('appuser.email')" prop="email">
<el-input v-model="dataForm.email" placeholder="请输入邮箱" clearable></el-input>
<el-input clearable placeholder="请输入邮箱" v-model="dataForm.email"></el-input>
</el-form-item>
</el-col>
<el-col :span="12" class="mb20">
<el-form-item :label="$t('appuser.nickname')" prop="nickname">
<el-input v-model="dataForm.nickname" placeholder="请输入昵称" clearable></el-input>
<el-input clearable placeholder="请输入昵称" v-model="dataForm.nickname"></el-input>
</el-form-item>
</el-col>
<el-col :span="12" class="mb20">
<el-form-item :label="$t('appuser.lockFlag')" prop="lockFlag">
<el-radio-group v-model="dataForm.lockFlag">
<el-radio :label="item.value" v-for="(item, index) in lock_flag" border :key="index">{{ item.label }}
<el-radio :key="index" :label="item.value" border v-for="(item, index) in lock_flag">{{
item.label }}
</el-radio>
</el-radio-group>
</el-form-item>
@ -54,19 +58,20 @@
<template #footer>
<span class="dialog-footer">
<el-button @click="visible = false">{{ $t('common.cancelButtonText') }}</el-button>
<el-button type="primary" @click="onSubmit" >{{ $t('common.confirmButtonText') }}</el-button>
<el-button @click="onSubmit" type="primary">{{ $t('common.confirmButtonText') }}</el-button>
</span>
</template>
</el-dialog>
</div>
</template>
<script setup lang="ts" name="systemUserDialog">
import { getObj, addObj, putObj } from '/@/api/app/appuser'
<script lang="ts" name="systemUserDialog" setup>
import {addObj, getObj, putObj, validatePhone, validateUsername} from '/@/api/app/appuser'
import {list as roleList} from '/@/api/app/approle'
import {useDict} from "/@/hooks/dict";
import {useI18n} from "vue-i18n";
import {useMessage} from '/@/hooks/message';
import {rule} from "/@/utils/validate";
const {t} = useI18n()
@ -103,26 +108,36 @@ const dataForm = reactive({
const dataRules = ref(
{
username: [{ required: true, message: "用户名不能为空", trigger: "blur" }, {
min: 5,
max: 20,
message: "用户名称长度必须介于 5 和 20 之间",
trigger: "blur"
username: [{required: true, message: "用户名不能为空", trigger: "blur"},
{min: 3, max: 20, message: "用户名称长度必须介于 3 和 20 之间", trigger: "blur"},
{
validator: (rule: any, value: any, callback: any) => {
validateUsername(rule, value, callback, dataForm.userId !== '')
}, trigger: "blur"
}],
password: [{required: true, message: "密码不能为空", trigger: "blur"}, {
min: 6,
max: 20,
message: "用户密码长度必须介于 6 和 20 之间",
trigger: "blur"
}],
name: [{ required: true, message: "姓名不能为空", trigger: "blur" }],
name: [{required: true, message: "姓名不能为空", trigger: "blur"}
, {validator: rule.chinese, trigger: "blur"}],
role: [{required: true, message: "角色不能为空", trigger: "blur"}],
phone: [{required: true, message: "手机号不能为空", trigger: "blur"}, {
pattern: /^1[3|4|5|6|7|8|9][0-9]\d{8}$/,
message: "请输入正确的手机号码",
trigger: "blur"
},
{
validator: (rule: any, value: any, callback: any) => {
validatePhone(rule, value, callback, dataForm.userId !== '')
}, trigger: "blur"
}],
email: [{ type: "email", message: "请输入正确的邮箱地址", trigger: ["blur", "change"] }]
email: [{type: "email", message: "请输入正确的邮箱地址", trigger: ["blur", "change"]}],
nickname: [{required: true, message: "姓名不能为空", nickname: "blur"}],
}
)

View File

@ -1,11 +1,10 @@
<template>
<div class="layout-padding">
<el-card class="layout-padding-auto" shadow="hover">
<div class="layout-padding-auto layout-padding-view">
<el-row class="mb8" v-show="showSearch">
<el-form :inline="true" :model="state.queryForm" @keyup.enter="getDataList" ref="queryRef">
<el-form-item :label="$t('appuser.username')" prop="username">
<el-input :placeholder="$t('appuser.inputUsernameTip')" @keyup.enter="getDataList"
clearable
<el-input :placeholder="$t('appuser.inputUsernameTip')" @keyup.enter="getDataList" clearable
style="width: 240px" v-model="state.queryForm.username" />
</el-form-item>
<el-form-item :label="$t('appuser.phone')" prop="phone">
@ -29,12 +28,11 @@
v-auth="'sys_user_add'">
{{ $t('common.importBtn') }}
</el-button>
<el-button @click="exportExcel" class="ml10" icon="Download" type="primary"
v-auth="'sys_user_export'">
<el-button @click="exportExcel" class="ml10" icon="Download" type="primary" v-auth="'sys_user_export'">
{{ $t('common.exportBtn') }}
</el-button>
<el-button :disabled="multiple" @click="handleDelete(selectObjs)" class="ml10" icon="Delete" type="primary"
v-auth="'sys_user_del'">
<el-button :disabled="multiple" @click="handleDelete(selectObjs)" class="ml10" icon="Delete"
type="primary" v-auth="'sys_user_del'">
{{ $t('common.delBtn') }}
</el-button>
<right-toolbar @queryTable="getDataList" class="ml10" style="float: right;margin-right: 20px"
@ -45,8 +43,7 @@
v-loading="state.loading">
<el-table-column align="center" type="selection" width="50" />
<el-table-column :label="$t('appuser.index')" type="index" width="80" />
<el-table-column :label="$t('appuser.username')" prop="username"
show-overflow-tooltip></el-table-column>
<el-table-column :label="$t('appuser.username')" prop="username" show-overflow-tooltip></el-table-column>
<el-table-column :label="$t('appuser.name')" prop="name" show-overflow-tooltip></el-table-column>
<el-table-column :label="$t('appuser.phone')" prop="phone" show-overflow-tooltip></el-table-column>
<el-table-column :label="$t('appuser.role')" show-overflow-tooltip>
@ -70,8 +67,7 @@
$t('common.editBtn')
}}
</el-button>
<el-button @click="handleDelete([scope.row.userId])" text type="primary"
v-auth="'sys_user_del'">
<el-button @click="handleDelete([scope.row.userId])" text type="primary" v-auth="'sys_user_del'">
{{ $t('common.delBtn') }}
</el-button>
</template>
@ -81,7 +77,7 @@
<pagination @current-change="currentChangeHandle" @size-change="sizeChangeHandle" v-bind="state.pagination">
</pagination>
</el-card>
</div>
<user-form @refresh="getDataList()" ref="userDialogRef" />
<upload-excel :title="$t('appuser.importUserTip')" @refreshDataList="getDataList" ref="excelUploadRef"
@ -120,7 +116,8 @@
username: '',
phone: ''
},
pageList: fetchList
pageList: fetchList,
descs: ['create_time']
});

View File

@ -1,6 +1,6 @@
<template>
<div class="layout-padding">
<el-card class="layout-padding-auto">
<div class="layout-padding-auto layout-padding-view">
<el-row v-show="showSearch" class="mb8">
<el-form :model="state.queryForm" ref="queryRef" :inline="true">
<el-form-item :label="$t('job.jobName')" prop="jobName">
@ -39,8 +39,7 @@
<el-button class="ml10" icon="Download" type="primary" @click="exportExcel">
{{ $t('common.exportBtn') }}
</el-button>
<el-button :disabled="multiple" class="ml10" icon="Delete" type="primary"
@click="handleDelete(undefined)">
<el-button :disabled="multiple" class="ml10" icon="Delete" type="primary" @click="handleDelete(undefined)">
{{ $t('common.delBtn') }}
</el-button>
<right-toolbar v-model:showSearch="showSearch" class="ml10" style="float: right;margin-right: 20px"
@ -92,17 +91,19 @@
<el-button size="small" text type="primary" @click="handleShutDownJob(scope.row)">暂停</el-button>
<el-button size="small" text type="primary" @click="handleEditJob(scope.row)">{{ $t('common.editBtn') }}</el-button>
<el-button size="small" text type="primary" @click="handleEditJob(scope.row)">{{ $t('common.editBtn')
}}</el-button>
<el-button size="small" text type="primary" @click="handleRunJob(scope.row)">执行</el-button>
<el-button size="small" text type="primary" @click="handleDelete(scope.row)">{{$t('common.delBtn') }}</el-button>
<el-button size="small" text type="primary" @click="handleDelete(scope.row)">{{ $t('common.delBtn')
}}</el-button>
</template>
</el-table-column>
</el-table>
<pagination v-bind="state.pagination" @size-change="sizeChangeHandle" @current-change="currentChangeHandle" />
</el-card>
</div>
<!-- 编辑新增 -->
<form-dialog ref="formDialogRef" @refresh="getDataList()" />

View File

@ -1,6 +1,6 @@
<template>
<el-dialog v-model="visible" :close-on-click-modal="false" fullscreen title="运行日志" draggable>
<el-card class="layout-padding-auto">
<div class="layout-padding-auto layout-padding-view">
<el-row>
<div class="mb8" style="width: 100%">
<el-button formDialogRef :disabled="multiple" icon="Delete" type="primary" class="ml10" v-auth="'sys_log_del'"
@ -38,7 +38,7 @@
</el-table-column>
</el-table>
<pagination @size-change="sizeChangeHandle" @current-change="currentChangeHandle" v-bind="state.pagination" />
</el-card>
</div>
</el-dialog>
</template>
@ -111,6 +111,4 @@ defineExpose({
});
</script>
<style scoped>
</style>
<style scoped></style>

View File

@ -1,59 +0,0 @@
<template>
<div class="layout-padding">
<el-card shadow="hover">
<el-form ref="dataFormRef" :model="dataForm" label-width="100px">
<el-row :gutter="20">
<el-col :span="12" class="mb20">
<el-form-item label="用户名" prop="username">
<el-input v-model="dataForm.username" placeholder="请输入用户名"></el-input>
</el-form-item>
</el-col>
<el-col :span="12" class="mb20">
<el-form-item label="图片" prop="username">
<upload-img v-model="dataForm.image"></upload-img>
</el-form-item>
</el-col>
<el-col :span="12" class="mb20">
<el-form-item label="文件" prop="username">
<upload-file v-model="dataForm.fileList"></upload-file>
</el-form-item>
</el-col>
<el-col :span="12" class="mb20">
<el-form-item label="文件" prop="username">
<upload-file v-model="dataForm.fileList" type="simple"></upload-file>
</el-form-item>
</el-col>
<el-col :span="24" class="mb20">
<el-form-item label="富文本" prop="text">
<editor v-model:get-html="dataForm.text"></editor>
</el-form-item>
</el-col>
</el-row>
</el-form>
{{dataForm}}
</el-card>
</div>
</template>
<script setup lang="ts" name="form-demo">
const dataForm = reactive({
username: '',
fileList: '',
image: '',
text: ''
})
onMounted(() => {
Object.assign(dataForm,{
"username": "123123",
"fileList": "/admin/sys-file/local/f3f2513c46e74448b33f8fbc54a079ec.pdf",
"image": "/admin/sys-file/local/b7d73a0fb7404ab9baf09a496291bec6.jpg"
})
})
</script>
<style scoped>
</style>

View File

@ -14,8 +14,7 @@
</div>
<div class="right">
<img
src="https://img-blog.csdnimg.cn/3333f265772a4fa89287993500ecbf96.png?x-oss-process=image/watermark,type_d3F5LXplbmhlaQ,shadow_50,text_Q1NETiBAbHl0LXRvcA==,size_16,color_FFFFFF,t_70,g_se,x_16"
/>
src="https://img-blog.csdnimg.cn/3333f265772a4fa89287993500ecbf96.png?x-oss-process=image/watermark,type_d3F5LXplbmhlaQ,shadow_50,text_Q1NETiBAbHl0LXRvcA==,size_16,color_FFFFFF,t_70,g_se,x_16" />
</div>
</div>
</div>
@ -36,16 +35,19 @@ const onSetAuth = () => {
<style scoped lang="scss">
.error {
height: 100%;
.error-flex {
margin: auto;
display: flex;
height: 350px;
width: 900px;
.left {
flex: 1;
height: 100%;
align-items: center;
display: flex;
.left-item {
.left-item-animation {
opacity: 0;
@ -53,33 +55,39 @@ const onSetAuth = () => {
animation-duration: 0.5s;
animation-fill-mode: forwards;
}
.left-item-num {
color: var(--el-color-info);
font-size: 55px;
}
.left-item-title {
font-size: 20px;
color: var(--el-text-color-primary);
margin: 15px 0 5px 0;
animation-delay: 0.1s;
}
.left-item-msg {
color: var(--el-text-color-secondary);
font-size: 12px;
margin-bottom: 30px;
animation-delay: 0.2s;
}
.left-item-btn {
animation-delay: 0.2s;
}
}
}
.right {
flex: 1;
opacity: 0;
animation-name: error-img;
animation-duration: 2s;
animation-fill-mode: forwards;
img {
width: 100%;
height: 100%;

View File

@ -14,8 +14,7 @@
</div>
<div class="right">
<img
src="https://img-blog.csdnimg.cn/9eb1d85a417f4ed1ba7107f149ce3da1.png?x-oss-process=image/watermark,type_d3F5LXplbmhlaQ,shadow_50,text_Q1NETiBAbHl0LXRvcA==,size_16,color_FFFFFF,t_70,g_se,x_16"
/>
src="https://img-blog.csdnimg.cn/9eb1d85a417f4ed1ba7107f149ce3da1.png?x-oss-process=image/watermark,type_d3F5LXplbmhlaQ,shadow_50,text_Q1NETiBAbHl0LXRvcA==,size_16,color_FFFFFF,t_70,g_se,x_16" />
</div>
</div>
</div>
@ -37,16 +36,19 @@ const onGoHome = () => {
<style scoped lang="scss">
.error {
height: 100%;
.error-flex {
margin: auto;
display: flex;
height: 350px;
width: 900px;
.left {
flex: 1;
height: 100%;
align-items: center;
display: flex;
.left-item {
.left-item-animation {
opacity: 0;
@ -54,33 +56,39 @@ const onGoHome = () => {
animation-duration: 0.5s;
animation-fill-mode: forwards;
}
.left-item-num {
color: var(--el-color-info);
font-size: 55px;
}
.left-item-title {
font-size: 20px;
color: var(--el-text-color-primary);
margin: 15px 0 5px 0;
animation-delay: 0.1s;
}
.left-item-msg {
color: var(--el-text-color-secondary);
font-size: 12px;
margin-bottom: 30px;
animation-delay: 0.2s;
}
.left-item-btn {
animation-delay: 0.2s;
}
}
}
.right {
flex: 1;
opacity: 0;
animation-name: error-img;
animation-duration: 2s;
animation-fill-mode: forwards;
img {
width: 100%;
height: 100%;

View File

@ -1,6 +1,6 @@
<template>
<div class="layout-padding">
<el-card class="layout-padding-auto">
<div class="layout-padding-auto layout-padding-view">
<el-row class="mb8" v-show="showSearch">
<el-form :inline="true" :model="state.queryForm" @keyup.enter="getDataList" ref="queryRef">
<el-form-item :label="$t('datasourceconf.dsName')" prop="dsName">
@ -59,7 +59,7 @@
</el-table-column>
</el-table>
<pagination @current-change="currentChangeHandle" @size-change="sizeChangeHandle" v-bind="state.pagination" />
</el-card>
</div>
<!-- 编辑新增 -->
<form-dialog @refresh="getDataList()" ref="formDialogRef" />
@ -88,7 +88,8 @@ const multiple = ref(true)
const state: BasicTableProps = reactive<BasicTableProps>({
queryForm: {},
pageList: fetchList
pageList: fetchList,
descs: ['create_time']
})
// table hook

View File

@ -1,6 +1,6 @@
<template>
<div class="layout-padding">
<el-card class="layout-padding-auto">
<div class="layout-padding-auto layout-padding-view">
<v-form-designer ref="vfDesignerRef" :banned-widgets="bannedWidgets" :designer-config="designerConfig">
<template #customToolButtons>
<el-button link type="primary" @click="exportJsonConfig">
@ -8,7 +8,7 @@
</el-button>
</template>
</v-form-designer>
</el-card>
</div>
</div>
</template>

View File

@ -1,11 +1,11 @@
<template>
<div class="layout-padding">
<el-card class="layout-padding-auto">
<div class="layout-padding-auto layout-padding-view">
<el-row class="mb8" v-show="showSearch">
<el-form :inline="true" :model="state.queryForm" @keyup.enter="getDataList" ref="queryRef">
<el-form-item :label="$t('fieldtype.columnType')" prop="columnType">
<el-input :placeholder="$t('fieldtype.inputcolumnTypeTip')" formDialogRef
style="max-width: 180px" v-model="state.queryForm.columnType"/>
<el-input :placeholder="$t('fieldtype.inputcolumnTypeTip')" formDialogRef style="max-width: 180px"
v-model="state.queryForm.columnType" />
</el-form-item>
<el-form-item class="ml2">
<el-button @click="getDataList" icon="search" type="primary">
@ -54,9 +54,8 @@
</template>
</el-table-column>
</el-table>
<pagination @current-change="currentChangeHandle" @size-change="sizeChangeHandle"
v-bind="state.pagination"/>
</el-card>
<pagination @current-change="currentChangeHandle" @size-change="sizeChangeHandle" v-bind="state.pagination" />
</div>
<!-- 编辑新增 -->
<form-dialog @refresh="getDataList()" ref="formDialogRef" />
@ -84,7 +83,8 @@
const state: BasicTableProps = reactive<BasicTableProps>({
queryForm: {},
pageList: fetchList
pageList: fetchList,
descs: ['create_time']
})
// table hook

View File

@ -1,11 +1,11 @@
<template>
<div class="layout-padding">
<el-card class="layout-padding-auto" shadow="hover">
<div class="layout-padding-auto layout-padding-view">
<el-steps :active="active" finish-status="success" simple style="margin-top: 20px">
<el-step title="基础信息" />
<el-step title="数据修改" />
</el-steps>
</el-card>
</div>
<el-card class="layout-padding-auto" style="margin-top: 20px" shadow="hover" v-if="active === 0">
<generator ref="generatorRef" :tableName="tableName" :dsName="dsName"></generator>
</el-card>

View File

@ -1,6 +1,6 @@
<template>
<div class="layout-padding">
<el-card class="layout-padding-auto">
<div class="layout-padding-auto layout-padding-view">
<el-row class="mb8" v-show="showSearch">
<el-form :inline="true" :model="state.queryForm" @keyup.enter="getDataList" ref="queryRef">
<el-form-item :label="$t('group.id')" prop="id">
@ -23,16 +23,15 @@
<el-row>
<div class="mb8" style="width: 100%">
<el-button @click="formDialogRef.openDialog()" class="ml10" formDialogRef icon="folder-add"
type="primary"
v-auth="'codegen_group_add'">
type="primary" v-auth="'codegen_group_add'">
{{ $t('common.addBtn') }}
</el-button>
<el-button @click="exportExcel" class="ml10" formDialogRef icon="Download" type="primary"
v-auth="'codegen_group_export'">
{{ $t('common.exportBtn') }}
</el-button>
<el-button :disabled="multiple" @click="handleDelete(selectObjs)" class="ml10" formDialogRef icon="Delete"
type="primary" v-auth="'codegen_group_del'">
<el-button :disabled="multiple" @click="handleDelete(selectObjs)" class="ml10" formDialogRef
icon="Delete" type="primary" v-auth="'codegen_group_del'">
{{ $t('common.delBtn') }}
</el-button>
<right-toolbar @queryTable="getDataList" class="ml10" style="float: right;margin-right: 20px"
@ -50,17 +49,15 @@
<el-button @click="formDialogRef.openDialog(scope.row.id)" text type="primary"
v-auth="'codegen_group_edit'">{{ $t('common.editBtn') }}
</el-button>
<el-button @click="handleDelete([scope.row.id])" text type="primary"
v-auth="'codegen_group_del'">{{
<el-button @click="handleDelete([scope.row.id])" text type="primary" v-auth="'codegen_group_del'">{{
$t('common.delBtn')
}}
</el-button>
</template>
</el-table-column>
</el-table>
<pagination @current-change="currentChangeHandle" @size-change="sizeChangeHandle"
v-bind="state.pagination"/>
</el-card>
<pagination @current-change="currentChangeHandle" @size-change="sizeChangeHandle" v-bind="state.pagination" />
</div>
<!-- 编辑新增 -->
<form-dialog @refresh="getDataList()" ref="formDialogRef" />

View File

@ -1,6 +1,6 @@
<template>
<div class="layout-padding">
<el-card class="layout-padding-auto">
<div class="layout-padding-auto layout-padding-view">
<el-row class="mb8" v-show="showSearch">
<el-form :inline="true" :model="state.queryForm" @keyup.enter="getDataList" ref="queryRef">
<el-form-item label="数据源" prop="name">
@ -55,10 +55,8 @@
</template>
</el-table-column>
</el-table>
<pagination @current-change="currentChangeHandle" @size-change="sizeChangeHandle"
v-bind="state.pagination"/>
</el-card>
<pagination @current-change="currentChangeHandle" @size-change="sizeChangeHandle" v-bind="state.pagination" />
</div>
</div>
</template>
@ -88,6 +86,7 @@
},
pageList: fetchList,
createdIsNeed: false,
descs: ['create_time']
})
// table hook

View File

@ -1,6 +1,6 @@
<template>
<div class="layout-padding">
<el-card class="layout-padding-auto">
<div class="layout-padding-auto layout-padding-view">
<el-row class="mb8" v-show="showSearch">
<el-form :inline="true" :model="state.queryForm" ref="queryRef" @keyup.enter="getDataList">
<el-form-item :label="$t('template.id')" prop="id">
@ -22,16 +22,16 @@
</el-row>
<el-row>
<div class="mb8" style="width: 100%">
<el-button @click="formDialogRef.openDialog()" class="ml10" icon="folder-add"
type="primary" v-auth="'codegen_template_add'">
<el-button @click="formDialogRef.openDialog()" class="ml10" icon="folder-add" type="primary"
v-auth="'codegen_template_add'">
{{ $t('common.addBtn') }}
</el-button>
<el-button @click="exportExcel" class="ml10" icon="Download" type="primary"
v-auth="'codegen_template_export'">
{{ $t('common.exportBtn') }}
</el-button>
<el-button :disabled="multiple" @click="handleDelete(selectObjs)" class="ml10"
icon="Delete" type="primary" v-auth="'codegen_template_del'">
<el-button :disabled="multiple" @click="handleDelete(selectObjs)" class="ml10" icon="Delete"
type="primary" v-auth="'codegen_template_del'">
{{ $t('common.delBtn') }}
</el-button>
<right-toolbar @queryTable="getDataList" class="ml10" style="float: right;margin-right: 20px"
@ -59,7 +59,7 @@
</el-table-column>
</el-table>
<pagination @current-change="currentChangeHandle" @size-change="sizeChangeHandle" v-bind="state.pagination" />
</el-card>
</div>
<!-- 编辑新增 -->
<form-dialog @refresh="getDataList()" ref="formDialogRef" />

View File

@ -10,7 +10,8 @@
<div class="flex-warp-item-box">
<div class="flex-margin">
<i :class="v.meta.icon"></i>
<el-tag :key="v.path" @click="HandleRoute(v)" class="mx-1" closable :type="v.path" @close="handleCloseFavorite(v)">{{ $t(v.name) }}</el-tag>
<el-tag :key="v.path" @click="HandleRoute(v)" class="mx-1" closable :type="v.path"
@close="handleCloseFavorite(v)">{{ $t(v.name) }}</el-tag>
</div>
</div>
</div>
@ -25,16 +26,8 @@
</el-col>
</el-row>
<el-row :gutter="15" class="home-card-one mb15">
<el-col
:xs="24"
:sm="12"
:md="12"
:lg="6"
:xl="6"
v-for="(v, k) in state.homeOne"
:key="k"
:class="{ 'home-media home-media-lg': k > 1, 'home-media-sm': k === 1 }"
>
<el-col :xs="24" :sm="12" :md="12" :lg="6" :xl="6" v-for="(v, k) in state.homeOne" :key="k"
:class="{ 'home-media home-media-lg': k > 1, 'home-media-sm': k === 1 }">
<div class="home-card-item flex">
<div class="flex-margin flex w100" :class="` home-one-animation${k}`">
<div class="flex-auto">
@ -497,8 +490,10 @@ watch(
<style scoped lang="scss">
$homeNavLengh: 8;
.home-container {
overflow: hidden;
.home-card-one,
.home-card-two,
.home-card-three {
@ -512,19 +507,23 @@ $homeNavLengh: 8;
background: var(--el-color-white);
color: var(--el-text-color-primary);
border: 1px solid var(--next-border-color-light);
&:hover {
box-shadow: 0 2px 12px var(--next-color-dark-hover);
transition: all ease 0.3s;
}
&-icon {
width: 70px;
height: 70px;
border-radius: 100%;
flex-shrink: 1;
i {
color: var(--el-text-color-placeholder);
}
}
&-title {
font-size: 15px;
font-weight: bold;
@ -532,6 +531,7 @@ $homeNavLengh: 8;
}
}
}
.home-card-one {
@for $i from 0 through 3 {
.home-one-animation#{$i} {
@ -543,18 +543,22 @@ $homeNavLengh: 8;
}
}
}
.home-card-two,
.home-card-three {
.home-card-item {
height: 400px;
width: 100%;
overflow: hidden;
.home-monitor {
height: 100%;
.flex-warp-item {
width: 25%;
height: 56px;
display: flex;
.flex-warp-item-box {
margin: auto;
text-align: center;
@ -564,11 +568,13 @@ $homeNavLengh: 8;
background: var(--next-bg-color);
cursor: pointer;
transition: all 0.3s ease;
&:hover {
background: var(--el-color-primary-light-9);
transition: all 0.3s ease;
}
}
@for $i from 0 through $homeNavLengh {
.home-animation#{$i} {
opacity: 0;

View File

@ -1,7 +1,7 @@
<template>
<el-form size="large" class="login-content-form" ref="loginFormRef" :rules="loginRules" :model="state.ruleForm">
<el-form-item class="login-animation1">
<el-input text :placeholder="$t('account.accountPlaceholder1')" v-model="state.ruleForm.username" clearable
<el-input text :placeholder="$t('password.accountPlaceholder1')" v-model="state.ruleForm.username" clearable
autocomplete="off">
<template #prefix>
<el-icon class="el-input__icon">
@ -11,8 +11,8 @@
</el-input>
</el-form-item>
<el-form-item class="login-animation2">
<el-input :type="state.isShowPassword ? 'text' : 'password'"
:placeholder="$t('account.accountPlaceholder2')" v-model="state.ruleForm.password" autocomplete="off">
<el-input :type="state.isShowPassword ? 'text' : 'password'" :placeholder="$t('password.accountPlaceholder2')"
v-model="state.ruleForm.password" autocomplete="off">
<template #prefix>
<el-icon class="el-input__icon">
<ele-Unlock />
@ -31,12 +31,11 @@
:imgSize="{ width: '330px', height: '155px' }" ref="verifyref" />
</el-form-item>
<el-form-item class="login-animation4">
<el-button type="primary" class="login-content-submit" round v-waves @click="handleVerify"
:loading="loading">
<span>{{ $t('account.accountBtnText') }}</span>
<el-button type="primary" class="login-content-submit" round v-waves @click="handleVerify" :loading="loading">
<span>{{ $t('password.accountBtnText') }}</span>
</el-button>
</el-form-item>
<div class="font12 mt30 login-animation4 login-msg">{{ $t('mobile.msgText') }}</div>
<div class="font12 mt30 login-animation4 login-msg">{{ $t('browserMsgText') }}</div>
</el-form>
</template>
@ -64,8 +63,8 @@ const state = reactive({
});
const loginRules = reactive({
username: [{required: true, trigger: "blur", message: t('account.accountPlaceholder1')}],
password: [{required: true, trigger: "blur", message: t('account.accountPlaceholder2')}],
username: [{ required: true, trigger: "blur", message: t('password.accountPlaceholder1') }],
password: [{ required: true, trigger: "blur", message: t('password.accountPlaceholder2') }],
})
// @ts-ignore

View File

@ -1,7 +1,7 @@
<template>
<el-form size="large" class="login-content-form" :rules="dataRules" ref="dataFormRef" :model="state.ruleForm">
<el-form-item class="login-animation1" prop="username">
<el-input text :placeholder="$t('account.accountPlaceholder1')" v-model="state.ruleForm.username" clearable
<el-input text :placeholder="$t('password.accountPlaceholder1')" v-model="state.ruleForm.username" clearable
autocomplete="off">
<template #prefix>
<el-icon class="el-input__icon">
@ -12,7 +12,7 @@
</el-form-item>
<el-form-item class="login-animation2" prop="password">
<el-input :type="state.isShowPassword ? 'text' : 'password'"
:placeholder="$t('account.accountPlaceholder2')" v-model="state.ruleForm.password" autocomplete="off">
:placeholder="$t('password.accountPlaceholder2')" v-model="state.ruleForm.password" autocomplete="off">
<template #prefix>
<el-icon class="el-input__icon">
<ele-Unlock/>
@ -27,7 +27,7 @@
</el-input>
</el-form-item>
<el-form-item class="login-animation3" prop="phone">
<el-input text :placeholder="$t('account.phonePlaceholder4')" v-model="state.ruleForm.phone" clearable
<el-input text :placeholder="$t('password.phonePlaceholder4')" v-model="state.ruleForm.phone" clearable
autocomplete="off">
<template #prefix>
<el-icon class="el-input__icon">
@ -39,7 +39,7 @@
<el-form-item class="login-animation4">
<el-button type="primary" class="login-content-submit" round v-waves @click="handleRegister"
:loading="loading">
<span>{{ $t('account.registerBtnText') }}</span>
<span>{{ $t('password.registerBtnText') }}</span>
</el-button>
</el-form-item>
</el-form>

View File

@ -1,14 +1,14 @@
<template>
<div class="layout-padding">
<el-card class="layout-padding-auto">
<div class="layout-padding-auto layout-padding-view">
<el-row v-show="showSearch" class="mb8">
<el-form ref="queryRef" :inline="true" :model="state.queryForm" @keyup.enter="getDataList">
<el-form-item :label="$t('fans.nickname')" prop="nickname">
<el-input v-model="state.queryForm.nickname"
style="max-width: 180px"/>
<el-input v-model="state.queryForm.nickname" style="max-width: 180px" />
</el-form-item>
<el-form-item :label="$t('fans.wxAccountName')" prop="wxAccountAppid">
<el-select v-model="state.queryForm.wxAccountAppid" :placeholder="$t('fans.wxAccountName')" clearable class="w100">
<el-select v-model="state.queryForm.wxAccountAppid" :placeholder="$t('fans.wxAccountName')" clearable
class="w100">
<el-option v-for="item in accountList" :key="item.appid" :label="item.name" :value="item.appid" />
</el-select>
</el-form-item>
@ -56,8 +56,8 @@
<el-table-column :label="t('fans.wxAccountName')" prop="wxAccountName" show-overflow-tooltip />
<el-table-column :label="$t('common.action')" width="150">
<template #default="scope">
<el-button text type="primary"
@click="formDialogRef.openDialog(scope.row,state.queryForm.wxAccountAppid)">{{ $t('common.editBtn') }}
<el-button text type="primary" @click="formDialogRef.openDialog(scope.row, state.queryForm.wxAccountAppid)">{{
$t('common.editBtn') }}
</el-button>
<el-button text type="primary" @click="handleDelete([scope.row.id])">{{
$t('common.delBtn')
@ -68,7 +68,7 @@
</el-table>
<pagination v-bind="state.pagination" @size-change="sizeChangeHandle" @current-change="currentChangeHandle" />
<form-dialog ref="formDialogRef" @refresh="getDataList"></form-dialog>
</el-card>
</div>
</div>
</template>

View File

@ -1,6 +1,6 @@
<template>
<div class="layout-padding">
<el-card class="layout-padding-auto">
<div class="layout-padding-auto layout-padding-view">
<el-row v-show="showSearch" class="mb8">
<el-form ref="queryRef" :inline="true" :model="state.queryForm" @keyup.enter="getDataList">
<el-form-item :label="$t('wxAccountTag.tag')" prop="tag">
@ -8,7 +8,8 @@
style="max-width: 180px" />
</el-form-item>
<el-form-item :label="$t('wxAccountTag.wxAccountAppid')" prop="wxAccountAppid">
<el-select v-model="state.queryForm.wxAccountAppid" :placeholder="t('wxAccountTag.inputWxAccountAppidTip')" clearable class="w100">
<el-select v-model="state.queryForm.wxAccountAppid" :placeholder="t('wxAccountTag.inputWxAccountAppidTip')"
clearable class="w100">
<el-option v-for="item in accountList" :key="item.appid" :label="item.name" :value="item.appid" />
</el-select>
</el-form-item>
@ -49,13 +50,14 @@
<el-table-column :label="t('wxAccountTag.tagId')" prop="tagId" show-overflow-tooltip />
<el-table-column :label="$t('common.action')" width="150">
<template #default="scope">
<el-button text type="primary" @click="formDialogRef.openDialog(scope.row,state.queryForm.wxAccountAppid)">{{ $t('common.editBtn') }}</el-button>
<el-button text type="primary" @click="formDialogRef.openDialog(scope.row, state.queryForm.wxAccountAppid)">{{
$t('common.editBtn') }}</el-button>
<el-button text type="primary" @click="handleDelete(scope.row)">{{ $t('common.delBtn') }}</el-button>
</template>
</el-table-column>
</el-table>
<pagination v-bind="state.pagination" @size-change="sizeChangeHandle" @current-change="currentChangeHandle" />
</el-card>
</div>
<!-- 编辑新增 -->
<form-dialog ref="formDialogRef" @refresh="getDataList(false)" />

View File

@ -1,11 +1,10 @@
<template>
<div class="layout-padding">
<el-card class="layout-padding-auto">
<div class="layout-padding-auto layout-padding-view">
<el-row v-show="showSearch" class="mb8">
<el-form ref="queryRef" :inline="true" :model="state.queryForm">
<el-form-item :label="$t('account.name')" prop="name">
<el-input v-model="state.queryForm.name" :placeholder="t('account.inputNameTip')"
style="max-width: 180px"/>
<el-input v-model="state.queryForm.name" :placeholder="t('account.inputNameTip')" style="max-width: 180px" />
</el-form-item>
<el-form-item :label="$t('account.account')" prop="account">
<el-input v-model="state.queryForm.account" :placeholder="t('account.inputAccountTip')"
@ -55,8 +54,10 @@
</el-table-column>
<el-table-column :label="$t('common.action')" width="200">
<template #default="scope">
<el-button v-auth="'mp_wxaccount_edit'" text type="primary" @click="formDialogRef.openDialog(scope.row.id)">{{ $t('common.editBtn') }}</el-button>
<el-button v-auth="'mp_wxaccount_del'" text type="primary" @click="handleDelete([scope.row.id])">{{$t('common.delBtn') }}</el-button>
<el-button v-auth="'mp_wxaccount_edit'" text type="primary" @click="formDialogRef.openDialog(scope.row.id)">{{
$t('common.editBtn') }}</el-button>
<el-button v-auth="'mp_wxaccount_del'" text type="primary" @click="handleDelete([scope.row.id])">{{
$t('common.delBtn') }}</el-button>
<el-button text type="primary" @click="access(scope.row, scope.index)">接入</el-button>
<el-button text type="primary" @click="generate(scope.row, scope.index)">二维码</el-button>
<el-button text type="primary" @click="quota(scope.row, scope.index)">quota</el-button>
@ -64,7 +65,7 @@
</el-table-column>
</el-table>
<pagination v-bind="state.pagination" @size-change="sizeChangeHandle" @current-change="currentChangeHandle" />
</el-card>
</div>
<!-- 编辑新增 -->
<form-dialog ref="formDialogRef" @refresh="getDataList(false)" />

View File

@ -3,12 +3,11 @@
<el-row :gutter="20">
<el-col :span="4" :xs="24">
<el-card class="layout-padding-auto" shadow="hover">
<query-tree :query="deptData.queryList"
@node-click="handleNodeClick"/>
<query-tree :query="deptData.queryList" @node-click="handleNodeClick" />
</el-card>
</el-col>
<el-col :md="20">
<el-card class="layout-padding-auto" shadow="hover">
<div class="layout-padding-auto layout-padding-view">
<el-tabs v-model="type" @tab-click="handleClick">
<el-tab-pane name="1" label="1">
<template #label>关注时回复</template>
@ -19,7 +18,8 @@
</el-button>
</div>
</el-row>
<el-table v-loading="state.loading" :data="state.dataList" style="width: 100%" @sort-change="sortChangeHandle">
<el-table v-loading="state.loading" :data="state.dataList" style="width: 100%"
@sort-change="sortChangeHandle">
<el-table-column label="序号" type="index" width="80" />
<el-table-column label="回复消息类型" prop="repType" show-overflow-tooltip>
<template #default="scope">
@ -28,20 +28,15 @@
</el-table-column>
<el-table-column label="操作" prop="action" show-overflow-tooltip>
<template #default="scope">
<el-button
link
icon="el-icon-edit"
@click="handleEdit(scope.row)">编辑
<el-button link icon="el-icon-edit" @click="handleEdit(scope.row)">编辑
</el-button>
<el-button
link
icon="el-icon-delete"
@click="handleDel(scope.row)">删除
<el-button link icon="el-icon-delete" @click="handleDel(scope.row)">删除
</el-button>
</template>
</el-table-column>
</el-table>
<pagination v-bind="state.pagination" @size-change="sizeChangeHandle" @current-change="currentChangeHandle"/>
<pagination v-bind="state.pagination" @size-change="sizeChangeHandle"
@current-change="currentChangeHandle" />
</el-tab-pane>
<el-tab-pane name="2" label="2">
<template #label>消息回复</template>
@ -52,7 +47,8 @@
</el-button>
</div>
</el-row>
<el-table v-loading="state.loading" :data="state.dataList" style="width: 100%" @sort-change="sortChangeHandle">
<el-table v-loading="state.loading" :data="state.dataList" style="width: 100%"
@sort-change="sortChangeHandle">
<el-table-column label="序号" type="index" width="80" />
<el-table-column label="请求消息类型" prop="reqType" show-overflow-tooltip>
<template #default="scope">
@ -66,20 +62,15 @@
</el-table-column>
<el-table-column label="操作" prop="action" show-overflow-tooltip>
<template #default="scope">
<el-button
icon="el-icon-edit"
link
@click="handleEdit(scope.row)">编辑
<el-button icon="el-icon-edit" link @click="handleEdit(scope.row)">编辑
</el-button>
<el-button
icon="el-icon-delete"
link
@click="handleDel(scope.row)">删除
<el-button icon="el-icon-delete" link @click="handleDel(scope.row)">删除
</el-button>
</template>
</el-table-column>
</el-table>
<pagination v-bind="state.pagination" @size-change="sizeChangeHandle" @current-change="currentChangeHandle"/>
<pagination v-bind="state.pagination" @size-change="sizeChangeHandle"
@current-change="currentChangeHandle" />
</el-tab-pane>
<el-tab-pane name="3" label="3">
<template #label>关键词回复</template>
@ -90,7 +81,8 @@
</el-button>
</div>
</el-row>
<el-table v-loading="state.loading" :data="state.dataList" style="width: 100%" @sort-change="sortChangeHandle">
<el-table v-loading="state.loading" :data="state.dataList" style="width: 100%"
@sort-change="sortChangeHandle">
<el-table-column label="序号" type="index" width="80" />
<el-table-column label="关键词" prop="reqKey" show-overflow-tooltip>
</el-table-column>
@ -106,23 +98,18 @@
</el-table-column>
<el-table-column label="操作" prop="action" show-overflow-tooltip>
<template #default="scope">
<el-button
icon="el-icon-edit"
link
@click="handleEdit(scope.row)">编辑
<el-button icon="el-icon-edit" link @click="handleEdit(scope.row)">编辑
</el-button>
<el-button
icon="el-icon-delete"
link
@click="handleDel(scope.row)">删除
<el-button icon="el-icon-delete" link @click="handleDel(scope.row)">删除
</el-button>
</template>
</el-table-column>
</el-table>
<pagination v-bind="state.pagination" @size-change="sizeChangeHandle" @current-change="currentChangeHandle"/>
<pagination v-bind="state.pagination" @size-change="sizeChangeHandle"
@current-change="currentChangeHandle" />
</el-tab-pane>
</el-tabs>
</el-card>
</div>
</el-col>
</el-row>
<el-dialog :title="handleType === 'add' ? '新增回复消息' : '修改回复消息'" v-model="dialog1Visible" width="50%">
@ -130,11 +117,7 @@
<el-form-item v-if="type === '2'" label="请求消息类型">
<el-select v-model="objData.reqType" placeholder="请选择">
<template v-for="item in dicDataReqType">
<el-option
v-if="item.value !== 'event'"
:key="item.value"
:label="item.label"
:value="item.value"
<el-option v-if="item.value !== 'event'" :key="item.value" :label="item.label" :value="item.value"
:disabled="item.disabled">
</el-option>
</template>
@ -143,11 +126,7 @@
</el-form-item>
<el-form-item v-if="type === '3'" label="匹配类型">
<el-select v-model="objData.repMate" placeholder="请选择" style="width: 100px">
<el-option
v-for="item in dicRepMate"
:key="item.value"
:label="item.label"
:value="item.value">
<el-option v-for="item in dicRepMate" :key="item.value" :label="item.label" :value="item.value">
</el-option>
</el-select>
</el-form-item>
@ -342,6 +321,4 @@ const handleAdd = () => {
</script>
<style scoped>
</style>
<style scoped></style>

View File

@ -1,6 +1,6 @@
<template>
<div class="layout-padding">
<el-card class="layout-padding-auto">
<div class="layout-padding-auto layout-padding-view">
<el-row v-show="showSearch" class="mb8">
<el-form ref="queryRef" :inline="true" :model="state.queryForm" @keyup.enter="getDataList">
<el-form-item :label="$t('wxFansMsg.appName')" prop="wxAccountAppid">
@ -31,8 +31,8 @@
@click="exportExcel">
{{ $t('common.exportBtn') }}
</el-button>
<el-button v-auth="'mp_wxmsg_del'" :disabled="multiple" class="ml10" formDialogRef icon="Delete"
type="primary" @click="handleDelete(selectObjs)">
<el-button v-auth="'mp_wxmsg_del'" :disabled="multiple" class="ml10" formDialogRef icon="Delete" type="primary"
@click="handleDelete(selectObjs)">
{{ $t('common.delBtn') }}
</el-button>
<right-toolbar v-model:showSearch="showSearch" class="ml10" style="float: right;margin-right: 20px"
@ -48,17 +48,23 @@
<el-table-column :label="t('wxFansMsg.openId')" prop="openId" show-overflow-tooltip />
<el-table-column :label="t('wxFansMsg.repContent')" prop="repContent" show-overflow-tooltip>
<template #default="scope">
<div v-if="scope.row.repType === 'event' && scope.row.repEvent === 'subscribe'"><el-tag type="success" size="mini">关注</el-tag></div>
<div v-if="scope.row.repType === 'event' && scope.row.repEvent === 'unsubscribe'"><el-tag type="danger" size="mini">取消关注</el-tag></div>
<div v-if="scope.row.repType === 'event' && scope.row.repEvent === 'CLICK'"><el-tag size="mini">点击菜单</el-tag>{{ scope.row.repName }}</div>
<div v-if="scope.row.repType === 'event' && scope.row.repEvent === 'VIEW'"><el-tag size="mini">点击菜单链接</el-tag>{{ scope.row.repUrl }}</div>
<div v-if="scope.row.repType === 'event' && scope.row.repEvent === 'scancode_waitmsg'"><el-tag size="mini">扫码结果</el-tag>{{ scope.row.repContent }}</div>
<div v-if="scope.row.repType === 'event' && scope.row.repEvent === 'subscribe'"><el-tag type="success"
size="mini">关注</el-tag></div>
<div v-if="scope.row.repType === 'event' && scope.row.repEvent === 'unsubscribe'"><el-tag type="danger"
size="mini">取消关注</el-tag></div>
<div v-if="scope.row.repType === 'event' && scope.row.repEvent === 'CLICK'"><el-tag
size="mini">点击菜单</el-tag>{{ scope.row.repName }}</div>
<div v-if="scope.row.repType === 'event' && scope.row.repEvent === 'VIEW'"><el-tag
size="mini">点击菜单链接</el-tag>{{ scope.row.repUrl }}</div>
<div v-if="scope.row.repType === 'event' && scope.row.repEvent === 'scancode_waitmsg'"><el-tag
size="mini">扫码结果</el-tag>{{ scope.row.repContent }}</div>
<div v-if="scope.row.repType === 'text'">{{ scope.row.repContent }}</div>
<div v-if="scope.row.repType === 'image'">
<a target="_blank" :href="scope.row.repUrl"><img :src="scope.row.repUrl" style="width: 100px"></a>
</div>
<div v-if="['video', 'voice', 'link', 'shortvideo'].includes(scope.row.repType)">
<el-tag>链接</el-tag><a :href="scope.row.repUrl" target="_blank">{{ scope.row.repName }}</a></div>
<el-tag>链接</el-tag><a :href="scope.row.repUrl" target="_blank">{{ scope.row.repName }}</a>
</div>
</template>
</el-table-column>
<el-table-column :label="t('wxFansMsg.readFlag')" prop="readFlag" show-overflow-tooltip>
@ -74,7 +80,7 @@
</el-table-column>
</el-table>
<pagination v-bind="state.pagination" @size-change="sizeChangeHandle" @current-change="currentChangeHandle" />
</el-card>
</div>
<wx-msg ref="WxmsgRef"></wx-msg>
</div>
</template>

View File

@ -3,17 +3,17 @@
<el-row :gutter="20">
<el-col :md="4">
<el-card class="layout-padding-auto" shadow="hover">
<query-tree :query="deptData.queryList"
@node-click="handleNodeClick"/>
<query-tree :query="deptData.queryList" @node-click="handleNodeClick" />
</el-card>
</el-col>
<el-col :span="20">
<el-card class="layout-padding-auto" shadow="hover">
<div class="layout-padding-auto layout-padding-view">
<el-tabs v-model="materialType" @tab-click="handleClick">
<el-tab-pane name="image" label="image">
<template #label><i class="el-icon-picture"></i> 图片</template>
<div class="add_but">
<wx-file-upload @success="getDataList" :uploadData="uploadData" :type="['image/jpeg','image/png','image/gif','image/bmp','image/jpg']"></wx-file-upload>
<wx-file-upload @success="getDataList" :uploadData="uploadData"
:type="['image/jpeg', 'image/png', 'image/gif', 'image/bmp', 'image/jpg']"></wx-file-upload>
</div>
<div v-loading="state.loading" class="waterfall">
<div v-for="item in state.dataList" :key="item.id" class="waterfall-item">
@ -29,50 +29,32 @@
<div v-if="state.dataList.length <= 0 && !state.loading" class="el-table__empty-block">
<span class="el-table__empty-text">暂无数据</span>
</div>
<pagination v-bind="state.pagination" @size-change="sizeChangeHandle" @current-change="currentChangeHandle"/>
<pagination v-bind="state.pagination" @size-change="sizeChangeHandle"
@current-change="currentChangeHandle" />
</el-tab-pane>
<el-tab-pane name="voice" label="voice">
<template #label><i class="el-icon-microphone"></i> 语音</template>
<div class="add_but">
<wx-file-upload @success="getDataList" :uploadData="uploadData"></wx-file-upload>
</div>
<el-table
v-loading="state.loading"
:data="state.dataList"
stripe
border>
<el-table-column
prop="mediaId"
label="media_id">
<el-table v-loading="state.loading" :data="state.dataList" stripe border>
<el-table-column prop="mediaId" label="media_id">
</el-table-column>
<el-table-column
prop="name"
label="名称">
<el-table-column prop="name" label="名称">
</el-table-column>
<el-table-column
prop="updateTime"
label="更新时间">
<el-table-column prop="updateTime" label="更新时间">
</el-table-column>
<el-table-column
fixed="right"
label="操作">
<el-table-column fixed="right" label="操作">
<template v-slot="scope">
<el-button
type="text"
icon="el-icon-download"
plain
@click="handleDown(scope.row)">下载
<el-button type="text" icon="el-icon-download" plain @click="handleDown(scope.row)">下载
</el-button>
<el-button
type="text"
icon="el-icon-delete"
plain
@click="delMaterial(scope.row)">删除
<el-button type="text" icon="el-icon-delete" plain @click="delMaterial(scope.row)">删除
</el-button>
</template>
</el-table-column>
</el-table>
<pagination v-bind="state.pagination" @size-change="sizeChangeHandle" @current-change="currentChangeHandle"/>
<pagination v-bind="state.pagination" @size-change="sizeChangeHandle"
@current-change="currentChangeHandle" />
</el-tab-pane>
<el-tab-pane name="video" label="video">
<template #label><i class="el-icon-video-play"></i> 视频</template>
@ -80,20 +62,14 @@
<el-button type="primary" @click="handleAddVideo">新建</el-button>
</div>
<el-dialog title="新建视频" v-model="dialogVideoVisible">
<wx-file-upload @success="getDataList" :uploadData="uploadData" :auto-upload="false" ref="uploadFileVideo" :type="['video/mp4']"></wx-file-upload>
<el-form
ref="uploadForm"
:model="uploadData"
v-loading="addMaterialLoading"
:rules="uploadRules">
<wx-file-upload @success="getDataList" :uploadData="uploadData" :auto-upload="false" ref="uploadFileVideo"
:type="['video/mp4']"></wx-file-upload>
<el-form ref="uploadForm" :model="uploadData" v-loading="addMaterialLoading" :rules="uploadRules">
<el-form-item label="标题" prop="title">
<el-input v-model="uploadData.title" placeholder="标题将展示在相关播放页面,建议填写清晰、准确、生动的标题"></el-input>
</el-form-item>
<el-form-item label="描述" prop="introduction">
<el-input
v-model="uploadData.introduction"
:rows="3"
type="textarea"
<el-input v-model="uploadData.introduction" :rows="3" type="textarea"
placeholder="介绍语将展示在相关播放页面,建议填写简洁明确、有信息量的内容"></el-input>
</el-form-item>
</el-form>
@ -102,26 +78,14 @@
<el-button type="primary" @click="subVideo"> </el-button>
</template>
</el-dialog>
<el-table
v-loading="state.loading"
:data="state.dataList"
stripe
border>
<el-table-column
prop="mediaId"
label="media_id">
<el-table v-loading="state.loading" :data="state.dataList" stripe border>
<el-table-column prop="mediaId" label="media_id">
</el-table-column>
<el-table-column
prop="name"
label="名称">
<el-table-column prop="name" label="名称">
</el-table-column>
<el-table-column
prop="updateTime"
label="更新时间">
<el-table-column prop="updateTime" label="更新时间">
</el-table-column>
<el-table-column
fixed="right"
label="操作">
<el-table-column fixed="right" label="操作">
<template v-slot="scope">
<el-button type="text" icon="el-icon-view" @click="handleInfo(scope.row)">查看
</el-button>
@ -130,7 +94,8 @@
</template>
</el-table-column>
</el-table>
<pagination v-bind="state.pagination" @size-change="sizeChangeHandle" @current-change="currentChangeHandle"/>
<pagination v-bind="state.pagination" @size-change="sizeChangeHandle"
@current-change="currentChangeHandle" />
</el-tab-pane>
<el-tab-pane name="news" label="news">
<template #label><i class="el-icon-news"></i> 图文</template>
@ -139,10 +104,7 @@
</div>
<news-form ref="dialogNewsRef" @ok="getDataList"></news-form>
<div v-loading="state.loading" class="waterfall">
<div
v-for="item in state.dataList"
:key="item.id"
class="waterfall-item">
<div v-for="item in state.dataList" :key="item.id" class="waterfall-item">
<wx-news :obj-data="item.content.newsItem"></wx-news>
<el-row class="ope-row">
<el-button type="primary" icon="el-icon-edit" circle @click="handleEditNews(item)"></el-button>
@ -155,12 +117,10 @@
</div>
</el-tab-pane>
</el-tabs>
</el-card>
</div>
</el-col>
</el-row>
</div>
</template>
<script setup lang="ts" name="wx-material">
@ -424,6 +384,7 @@ p {
.waterfall {
column-count: 3;
}
p {
color: red;
}
@ -433,6 +394,7 @@ p {
.waterfall {
column-count: 2;
}
p {
color: orange;
}

View File

@ -3,12 +3,11 @@
<el-row :gutter="20">
<el-col :span="4" :xs="24">
<el-card class="layout-padding-auto" shadow="hover">
<query-tree :query="deptData.queryList"
@node-click="handleNodeClick"/>
<query-tree :query="deptData.queryList" @node-click="handleNodeClick" />
</el-card>
</el-col>
<el-col :span="20">
<el-card class="layout-padding-auto" shadow="hover">
<div class="layout-padding-auto layout-padding-view">
<div v-loading="loading" class="public-account-management clearfix">
<div class="left">
<div class="weixin-hd">
@ -79,7 +78,8 @@
<div class="configur_content" v-if="tempObj.type === 'miniprogram'">
<div class="applet">
<span>小程序的 appid </span>
<el-input class="input_width" v-model="tempObj.miniProgramAppId" placeholder="请输入小程序的appid" clearable />
<el-input class="input_width" v-model="tempObj.miniProgramAppId" placeholder="请输入小程序的appid"
clearable />
</div>
<div class="applet">
<span>小程序的页面路径</span>
@ -120,7 +120,7 @@
</div>
</div>
</div>
</el-card>
</div>
</el-col>
</el-row>
</div>
@ -448,6 +448,7 @@ div {
padding: 518px 25px 88px;
position: relative;
box-sizing: border-box;
/*第一级菜单*/
.menu_main {
.menu_bottom {
@ -517,6 +518,7 @@ div {
}
}
}
/*右边菜单内容*/
.right {
float: left;
@ -526,14 +528,17 @@ div {
margin-left: 20px;
-webkit-box-sizing: border-box;
box-sizing: border-box;
.configure_page {
.delete_btn {
text-align: right;
margin-bottom: 15px;
}
.menu_content {
margin-top: 20px;
}
.configur_content {
margin-top: 20px;
background-color: #fff;
@ -569,6 +574,7 @@ div {
}
}
}
.el-input {
width: 70%;
margin-right: 2%;
@ -581,21 +587,25 @@ div {
text-align: right;
margin-right: 25px;
}
.select-item {
width: 280px;
padding: 10px;
margin: 0 auto 10px auto;
border: 1px solid #eaeaea;
}
.select-item2 {
padding: 10px;
margin: 0 auto 10px auto;
border: 1px solid #eaeaea;
}
.ope-row {
padding-top: 10px;
text-align: center;
}
.item-name {
font-size: 12px;
overflow: hidden;

View File

@ -1,26 +1,17 @@
<template>
<div class="layout-padding">
<el-card class="layout-padding-auto">
<div class="layout-padding-auto layout-padding-view">
<el-row>
<div class="mb8" style="width: 100%">
<el-date-picker
v-model="beginTime"
class="input_width"
placeholder="选择开始时间"
@change="check">
<el-date-picker v-model="beginTime" class="input_width" placeholder="选择开始时间" @change="check">
</el-date-picker>
<el-date-picker
v-model="endTime"
class="input_width"
placeholder="选择结束时间"
@change="check">
<el-date-picker v-model="endTime" class="input_width" placeholder="选择结束时间" @change="check">
</el-date-picker>
</div>
</el-row>
<el-row>
<el-col :span="4" :xs="24">
<query-tree :query="deptData.queryList"
@node-click="handleNodeClick"/>
<query-tree :query="deptData.queryList" @node-click="handleNodeClick" />
</el-col>
<el-col :span="20">
<el-row :gutter="15" class="home-card-two mb15">
@ -51,7 +42,7 @@
</el-row>
</el-col>
</el-row>
</el-card>
</div>
</div>
</template>
@ -234,5 +225,4 @@ const initdata = () => {
border: 1px solid var(--next-border-color-light);
margin-top: 20px;
}
</style>

View File

@ -0,0 +1,144 @@
<template>
<el-dialog :title="form.leaveId ? $t('common.editBtn') : $t('common.addBtn')" v-model="visible"
:close-on-click-modal="false" draggable>
<el-form ref="dataFormRef" :model="form" :rules="dataRules" formDialogRef label-width="90px" v-loading="loading">
<el-row :gutter="24">
<el-col :span="24" class="mb20">
<el-form-item :label="t('leave.username')" prop="username">
<el-input v-model="form.username" :placeholder="t('leave.inputUsernameTip')" disabled />
</el-form-item>
</el-col>
<el-col :span="12" class="mb20">
<el-form-item :label="t('leave.days')" prop="days">
<el-input-number :min="1" :max="1000" v-model="form.days"
:placeholder="t('leave.inputDaysTip')"></el-input-number>
</el-form-item>
</el-col>
<el-col :span="12" class="mb20">
<el-form-item :label="t('leave.leaveTime')" prop="leaveTime">
<el-date-picker type="datetime" :placeholder="t('leave.inputLeaveTimeTip')" v-model="form.leaveTime"
:value-format="dateTimeStr"></el-date-picker>
</el-form-item>
</el-col>
<el-col :span="24" class="mb20">
<el-form-item :label="t('leave.content')" prop="content">
<editor v-model:get-html="form.content" :placeholder="t('leave.inputContentTip')" />
</el-form-item>
</el-col>
</el-row>
</el-form>
<template #footer>
<span class="dialog-footer">
<el-button @click="visible = false">{{ $t('common.cancelButtonText') }}</el-button>
<el-button type="primary" @click="onSubmit">{{ $t('common.confirmButtonText') }}</el-button>
</span>
</template>
</el-dialog>
</template>
<script setup lang="ts" name="OaLeaveBillDialog">
import { useMessage } from "/@/hooks/message";
import { getObj, addObj, putObj } from '../../../api/oa/leave-bill'
import { useI18n } from "vue-i18n"
import { useUserInfo } from "/@/stores/userInfo";
const emit = defineEmits(['refresh']);
const { t } = useI18n();
//
const dataFormRef = ref();
const visible = ref(false)
const loading = ref(false)
//
const form = reactive({
leaveId: '',
username: '',
days: 0,
content: '',
leaveTime: '',
});
//
const dataRules = ref({
username: [{ required: true, message: '用户名不能为空', trigger: 'blur' }],
days: [{ required: true, message: '请假天数不能为空', trigger: 'blur' }],
content: [{ required: true, message: '备注不能为空', trigger: 'blur' }],
leaveTime: [{ required: true, message: '时间不能为空', trigger: 'blur' }],
})
//
const openDialog = (id: string) => {
visible.value = true
form.leaveId = ''
//
if (dataFormRef.value) {
dataFormRef.value.resetFields()
}
// oaLeaveBill
if (id) {
form.leaveId = id
getoaLeaveBillData(id)
} else {
form.username = useUserInfo().userInfos.user.username
}
};
//
const onSubmit = () => {
dataFormRef.value.validate((valid: boolean) => {
if (!valid) {
return false
}
//
if (form.leaveId) {
loading.value = true
putObj(form).then(() => {
useMessage().success(t('common.editSuccessText'))
visible.value = false //
emit('refresh')
}).catch((err: any) => {
useMessage().error(err.msg)
}).finally(() => {
loading.value = false
})
} else {
loading.value = true
addObj(form).then(() => {
useMessage().success(t('common.addSuccessText'))
visible.value = false //
emit('refresh')
}).catch((err: any) => {
useMessage().error(err.msg)
}).finally(() => {
loading.value = false
})
}
})
}
//
const getoaLeaveBillData = (id: string) => {
//
loading.value = true
getObj(id).then((res: any) => {
Object.assign(form, res.data)
}).finally(() => {
loading.value = false
})
};
//
defineExpose({
openDialog
});
</script>

View File

@ -0,0 +1,26 @@
export default {
leave: {
index: 'index',
importoaLeaveBillTip: 'import OaLeaveBill',
leaveId: 'leaveId',
username: 'username',
days: 'days',
content: 'content',
state: 'state',
leaveTime: 'leaveTime',
createTime: 'createTime',
updateTime: 'updateTime',
delFlag: 'delFlag',
tenantId: 'tenantId',
inputLeaveIdTip: 'input leaveId',
inputUsernameTip: 'input username',
inputDaysTip: 'input days',
inputContentTip: 'input content',
inputStateTip: 'input state',
inputLeaveTimeTip: 'input leaveTime',
inputCreateTimeTip: 'input createTime',
inputUpdateTimeTip: 'input updateTime',
inputDelFlagTip: 'input delFlag',
inputTenantIdTip: 'input tenantId',
}
}

View File

@ -0,0 +1,26 @@
export default {
leave: {
index: '序号',
importoaLeaveBillTip: '导入请假表',
leaveId: '主键',
username: '用户名',
days: '请假天数',
content: '备注',
state: '状态',
leaveTime: '请假时间',
createTime: '创建时间',
updateTime: '更新时间',
delFlag: '删除标识',
tenantId: '所属租户',
inputLeaveIdTip: '请输入主键',
inputUsernameTip: '请输入用户名',
inputDaysTip: '请输入请假天数',
inputContentTip: '请输入备注',
inputStateTip: '请输入状态',
inputLeaveTimeTip: '请输入请假时间',
inputCreateTimeTip: '请输入创建时间',
inputUpdateTimeTip: '请输入更新时间',
inputDelFlagTip: '请输入删除标识',
inputTenantIdTip: '请输入所属租户',
}
}

View File

@ -0,0 +1,154 @@
<template>
<div class="layout-padding">
<el-card class="layout-padding-auto">
<el-row v-show="showSearch" class="mb8">
<el-form :model="state.queryForm" ref="queryRef" :inline="true" @keyup.enter="getDataList">
<el-form-item :label="$t('leave.username')" prop="username">
<el-input :placeholder="t('leave.inputUsernameTip')" v-model="state.queryForm.username"
style="max-width: 180px" />
</el-form-item>
<el-form-item :label="t('leave.state')" prop="state" class="ml2">
<el-select v-model="state.queryForm.state" :placeholder="t('leave.inputStateTip')">
<el-option :label="item.label" :value="item.value" v-for="(item, index) in leave_status"
:key="index"></el-option>
</el-select>
</el-form-item>
<el-form-item class="ml2">
<el-button formDialogRef icon="search" type="primary" @click="getDataList">
{{ $t('common.queryBtn') }}
</el-button>
<el-button icon="Refresh" formDialogRef @click="resetQuery">{{ $t('common.resetBtn') }}</el-button>
</el-form-item>
</el-form>
</el-row>
<el-row>
<div class="mb8" style="width: 100%">
<el-button formDialogRef icon="folder-add" type="primary" class="ml10" @click="formDialogRef.openDialog()">
{{ $t('common.addBtn') }}
</el-button>
<el-button formDialogRef icon="Download" type="primary" class="ml10" @click="exportExcel">
{{ $t('common.exportBtn') }}
</el-button>
<el-button formDialogRef :disabled="multiple" icon="Delete" type="primary" class="ml10"
@click="handleDelete(selectObjs)">
{{ $t('common.delBtn') }}
</el-button>
<right-toolbar v-model:showSearch="showSearch" class="ml10" style="float: right;margin-right: 20px"
@queryTable="getDataList"></right-toolbar>
</div>
</el-row>
<el-table :data="state.dataList" v-loading="state.loading" style="width: 100%"
@selection-change="handleSelectionChange" @sort-change="sortChangeHandle">
<el-table-column type="selection" width="60" align="center" />
<el-table-column type="index" :label="t('leave.index')" width="80" />
<el-table-column prop="leaveId" :label="t('leave.leaveId')" show-overflow-tooltip />
<el-table-column prop="username" :label="t('leave.username')" show-overflow-tooltip />
<el-table-column prop="days" :label="t('leave.days')" show-overflow-tooltip />
<el-table-column prop="state" :label="t('leave.state')" show-overflow-tooltip>
<template #default="scope">
<dict-tag :options="leave_status" :value="scope.row.state"></dict-tag>
</template>
</el-table-column>
<el-table-column prop="leaveTime" :label="t('leave.leaveTime')" show-overflow-tooltip />
<el-table-column :label="$t('common.action')" width="150">
<template #default="scope">
<el-button text type="primary" @click="handleSubmit(scope.row)" v-if="scope.row.state === '0'">提交</el-button>
<el-button text type="primary" @click="formDialogRef.openDialog(scope.row.leaveId)">{{ $t('common.editBtn')
}}</el-button>
<el-button text type="primary" @click="handleDelete([scope.row.leaveId])">{{
$t('common.delBtn')
}}</el-button>
</template>
</el-table-column>
</el-table>
<pagination @size-change="sizeChangeHandle" @current-change="currentChangeHandle" v-bind="state.pagination" />
</el-card>
<!-- 编辑新增 -->
<form-dialog ref="formDialogRef" @refresh="getDataList(false)" />
</div>
</template>
<script setup lang="ts" name="systemOaLeaveBill">
import { BasicTableProps, useTable } from "/@/hooks/table";
import { fetchList, delObj, submit } from "/@/api/oa/leave-bill";
import { useMessage, useMessageBox } from "/@/hooks/message";
import { useDict } from '/@/hooks/dict';
import { useI18n } from "vue-i18n";
//
const FormDialog = defineAsyncComponent(() => import('./form.vue'));
const { t } = useI18n()
//
const { leave_status } = useDict('leave_status')
//
const formDialogRef = ref()
//
const queryRef = ref()
const showSearch = ref(true)
//
const selectObjs = ref([]) as any
const multiple = ref(true)
const state: BasicTableProps = reactive<BasicTableProps>({
queryForm: {},
pageList: fetchList
})
// table hook
const {
getDataList,
currentChangeHandle,
sizeChangeHandle,
sortChangeHandle,
downBlobFile
} = useTable(state)
//
const resetQuery = () => {
//
queryRef.value.resetFields()
//
selectObjs.value = []
getDataList()
}
// excel
const exportExcel = () => {
downBlobFile('/admin/leave/export', state.queryForm, 'leave.xlsx')
}
//
const handleSelectionChange = (objs: any) => {
objs.forEach((val: any) => {
selectObjs.value.push(val.leaveId)
});
multiple.value = !objs.length
}
//
const handleDelete = (ids: string[]) => {
useMessageBox().confirm(t('common.delConfirmText'))
.then(() => {
delObj(ids).then(() => {
getDataList(false);
useMessage().success(t('common.delSuccessText'));
}).catch((err: any) => {
useMessage().error(err.msg)
})
})
};
const handleSubmit = (row) => {
useMessageBox().confirm(t('common.optConfirmText'))
.then(() => {
submit(row.leaveId).then(() => {
getDataList(false);
useMessage().success(t('common.optSuccessText'));
}).catch((err: any) => {
useMessage().error(err.msg)
})
})
}
</script>

View File

@ -0,0 +1,37 @@
<template>
<div class="layout-padding">
<el-scrollbar class="main">
<iframe :src="src" class="iframe" />
</el-scrollbar>
</div>
</template>
<script lang="ts" name="modelView" setup>
const route = useRoute();
const src = ref('')
watch([route], () => {
init()
})
onMounted(() => {
init()
})
const init = () => {
src.value = "/admin/modeler.html?modelId=" + route.query.id
}
</script>
<style lang="scss" scoped>
.iframe {
width: 100%;
height: 80vh;
border: 0;
overflow: hidden;
box-sizing: border-box;
}
</style>

105
src/views/oa/model/form.vue Normal file
View File

@ -0,0 +1,105 @@
<template>
<el-dialog :title="form.id ? $t('common.editBtn') : $t('common.addBtn')" v-model="visible" :close-on-click-modal="false"
draggable>
<el-form ref="dataFormRef" :model="form" :rules="dataRules" label-width="90px">
<el-row :gutter="35">
<el-col :span="24" class="mb20">
<el-form-item :label="$t('model.name')" prop="name">
<el-input v-model="form.name" :placeholder="$t('model.inputNameTip')" clearable></el-input>
</el-form-item>
</el-col>
<el-col :span="24" class="mb20">
<el-form-item :label="$t('model.key')" prop="key">
<el-input v-model="form.key" :placeholder="$t('model.inputKeyTip')" clearable />
</el-form-item>
</el-col>
<el-col :span="24" class="mb20">
<el-form-item :label="$t('model.category')" prop="category">
<el-input v-model="form.category" :placeholder="$t('model.inputCategoryTip')" clearable />
</el-form-item>
</el-col>
</el-row>
</el-form>
<template #footer>
<span class="dialog-footer">
<el-button @click="visible = false">{{ $t('common.cancelButtonText') }}</el-button>
<el-button type="primary" @click="onSubmit">{{ $t('common.confirmButtonText') }}</el-button>
</span>
</template>
</el-dialog>
</template>
<script setup lang="ts" name="systemRoleDialog">
import { useMessage } from "/@/hooks/message"
import { addObj } from "/@/api/oa/model";
import { useI18n } from "vue-i18n"
const emit = defineEmits(['refresh']);
const { t } = useI18n();
//
const dataFormRef = ref();
const visible = ref(false)
//
const form = reactive({
id: '',
key: '',
name: '',
category: ''
});
//
const dataRules = ref(
{
key: [
{ required: true, message: '模型表示不能为空', trigger: 'blur' },
],
name: [
{ required: true, message: '模型名称不能为空', trigger: 'blur' }
],
category: [
{ required: true, message: '模型分类不能为空', trigger: 'blur' }
]
}
)
//
const openDialog = (id: string) => {
visible.value = true
form.id = ''
//
if (dataFormRef.value) {
dataFormRef.value.resetFields()
}
if (id) {
form.id = id
}
};
//
const onSubmit = () => {
dataFormRef.value.validate((valid: boolean) => {
if (!valid) {
return false
}
addObj(form).then(() => {
useMessage().success(t('common.addSuccessText'))
visible.value = false //
emit('refresh')
}).catch((err: any) => {
useMessage().error(err.msg)
})
})
};
//
defineExpose({
openDialog,
});
</script>

View File

@ -0,0 +1,16 @@
export default {
model: {
index: 'index',
id: 'id',
name: 'name',
key: 'key',
category: 'category',
version: 'version',
createTime: 'createTime',
lastUpdateTime: 'lastUpdateTime',
inputNameTip: 'input model name',
inputModelTip: 'input model name',
inputCategoryTip: 'input category tip',
inputKeyTip: 'input key',
}
}

View File

@ -0,0 +1,16 @@
export default {
model: {
index: '序号',
id: '模型ID',
name: '模型名称',
key: '模型标识',
category: '模型分类',
version: '版本',
createTime: '创建时间',
lastUpdateTime: '更新时间',
inputNameTip: '请输入模型名称',
inputModelTip: '请输入模型名称',
inputCategoryTip: '请输入模型分类',
inputKeyTip: '请输入模型标识',
}
}

View File

@ -0,0 +1,142 @@
<template>
<div class="layout-padding">
<el-card class="layout-padding-auto" shadow="hover">
<el-row class="mb8" shadow="hover" v-show="showSearch">
<el-form :inline="true" :model="state.queryForm" @keyup.enter="getDataList" ref="queryRef">
<el-form-item :label="$t('model.category')" prop="category">
<el-input :placeholder="$t('model.inputCategoryTip')" style="max-width: 180px"
v-model="state.queryForm.category" />
</el-form-item>
<el-form-item class="ml2">
<el-button @click="getDataList" icon="search" type="primary">
{{ $t('common.queryBtn') }}
</el-button>
<el-button @click="resetQuery" icon="Refresh">{{ $t('common.resetBtn') }}</el-button>
</el-form-item>
</el-form>
</el-row>
<el-row>
<div class="mb8" style="width: 100%">
<el-button @click="formDialogRef.openDialog()" class="ml10" icon="folder-add" type="primary"
v-auth="'app_approle_add'">
{{ $t('common.addBtn') }}
</el-button>
<el-button :disabled="multiple" @click="handleDelete(selectObjs)" class="ml10" icon="Delete"
type="primary" v-auth="'app_approle_del'">
{{ $t('common.delBtn') }}
</el-button>
<right-toolbar @queryTable="getDataList" class="ml10" style="float: right;margin-right: 20px"
v-model:showSearch="showSearch"></right-toolbar>
</div>
</el-row>
<el-table :data="state.dataList" @selection-change="handleSelectionChange" style="width: 100%"
v-loading="state.loading">
<el-table-column align="center" type="selection" width="50" />
<el-table-column :label="$t('model.index')" type="index" width="80" />
<el-table-column :label="$t('model.name')" prop="name" show-overflow-tooltip></el-table-column>
<el-table-column :label="$t('model.key')" prop="key" show-overflow-tooltip></el-table-column>
<el-table-column :label="$t('model.category')" prop="category" show-overflow-tooltip></el-table-column>
<el-table-column :label="$t('model.version')" prop="version" show-overflow-tooltip></el-table-column>
<el-table-column :label="$t('model.createTime')" prop="createTime" show-overflow-tooltip></el-table-column>
<el-table-column :label="$t('model.lastUpdateTime')" prop="lastUpdateTime"
show-overflow-tooltip></el-table-column>
<el-table-column :label="$t('common.action')" width="200">
<template #default="scope">
<el-button @click="handleView(scope.row.id)" text type="primary" v-auth="'app_approle_edit'">模型图
</el-button>
<el-button @click="handleDeploy(scope.row.id)" text type="primary" v-auth="'app_approle_edit'">部署
</el-button>
<el-button @click="handleDelete([scope.row.roleId])" text type="primary"
v-auth="'app_approle_del'">{{
$t('common.delBtn')
}}
</el-button>
</template>
</el-table-column>
</el-table>
<pagination @current-change="currentChangeHandle" @size-change="sizeChangeHandle" v-bind="state.pagination" />
</el-card>
<form-dialog @refresh="getDataList()" ref="formDialogRef" />
</div>
</template>
<script lang="ts" name="model" setup>
import { BasicTableProps, useTable } from "/@/hooks/table";
import { delObj, deploy, fetchList } from "/@/api/oa/model";
import { useMessage, useMessageBox } from "/@/hooks/message";
import { useI18n } from "vue-i18n";
//
const FormDialog = defineAsyncComponent(() => import('./form.vue'));
const { t } = useI18n()
const router = useRouter()
//
const formDialogRef = ref()
const queryRef = ref()
const showSearch = ref(true)
// rows
const selectObjs = ref([]) as any
//
const multiple = ref(true)
const state: BasicTableProps = reactive<BasicTableProps>({
queryForm: {
category: ''
},
pageList: fetchList // H
});
// table hook
const {
getDataList,
currentChangeHandle,
sizeChangeHandle,
} = useTable(state)
//
const resetQuery = () => {
queryRef.value.resetFields()
getDataList()
}
//
const handleSelectionChange = (objs: any) => {
selectObjs.value = []
objs.forEach((val: any) => {
selectObjs.value.push(val.roleId)
});
multiple.value = !objs.length
}
//
const handleDelete = (ids: string[]) => {
useMessageBox().confirm(t('common.delConfirmText'))
.then(() => {
delObj(ids).then(() => {
getDataList();
useMessage().success(t('common.delSuccessText'));
}).catch((err: any) => {
useMessage().error(err.msg)
})
})
};
const handleDeploy = (id: string) => {
deploy(id).then(() => {
useMessage().success(t('common.optSuccessText'));
})
}
const handleView = (id: string) => {
router.push({
path: "/oa/model/detail",
query: { id: id },
});
}
</script>

View File

@ -0,0 +1,17 @@
export default {
process: {
index: 'index',
id: 'id',
name: 'name',
key: 'key',
category: 'category',
version: 'version',
status: 'status',
createTime: 'createTime',
lastUpdateTime: 'lastUpdateTime',
inputNameTip: 'input model name',
inputModelTip: 'input model name',
inputCategoryTip: 'input category tip',
inputKeyTip: 'input key',
}
}

View File

@ -0,0 +1,16 @@
export default {
process: {
index: '序号',
processonDefinitionId: '模型ID',
name: '模型名称',
key: '模型标识',
category: '模型分类',
revision: '版本',
status: '状态',
deploymentTime: '部署时间',
inputNameTip: '请输入模型名称',
inputModelTip: '请输入模型名称',
inputCategoryTip: '请输入模型分类',
inputKeyTip: '请输入模型标识',
}
}

View File

@ -0,0 +1,157 @@
<template>
<div class="layout-padding">
<el-card class="layout-padding-auto" shadow="hover">
<el-row class="mb8" shadow="hover" v-show="showSearch">
<el-form :inline="true" :model="state.queryForm" @keyup.enter="getDataList" ref="queryRef">
<el-form-item :label="$t('process.category')" prop="category">
<el-input :placeholder="$t('process.inputCategoryTip')" style="max-width: 180px"
v-model="state.queryForm.category" />
</el-form-item>
<el-form-item class="ml2">
<el-button @click="getDataList" icon="search" type="primary">
{{ $t('common.queryBtn') }}
</el-button>
<el-button @click="resetQuery" icon="Refresh">{{ $t('common.resetBtn') }}</el-button>
</el-form-item>
</el-form>
</el-row>
<el-row>
<div class="mb8" style="width: 100%">
<el-button :disabled="multiple" @click="handleDelete(selectObjs)" class="ml10" icon="Delete"
type="primary" v-auth="'app_approle_del'">
{{ $t('common.delBtn') }}
</el-button>
<right-toolbar @queryTable="getDataList" class="ml10" style="float: right;margin-right: 20px"
v-model:showSearch="showSearch"></right-toolbar>
</div>
</el-row>
<el-table :data="state.dataList" @selection-change="handleSelectionChange" style="width: 100%"
v-loading="state.loading">
<el-table-column align="center" type="selection" width="50" />
<el-table-column :label="$t('process.index')" type="index" width="80" />
<el-table-column :label="$t('process.processonDefinitionId')" prop="processonDefinitionId"
show-overflow-tooltip></el-table-column>
<el-table-column :label="$t('process.name')" prop="name" show-overflow-tooltip></el-table-column>
<el-table-column :label="$t('process.key')" prop="key" show-overflow-tooltip></el-table-column>
<el-table-column :label="$t('process.category')" prop="category" show-overflow-tooltip></el-table-column>
<el-table-column :label="$t('process.revision')" prop="revision" show-overflow-tooltip></el-table-column>
<el-table-column :label="$t('process.status')" prop="suspend" show-overflow-tooltip>
<template #default="scope">
<span v-if="scope.row.suspend"><el-tag type="danger">挂起</el-tag></span>
<span v-else><el-tag>有效</el-tag></span>
</template>
</el-table-column>
<el-table-column :label="$t('process.deploymentTime')" prop="deploymentTime" show-overflow-tooltip>
<template #default="scope">
<span>{{ parseTime(scope.row.deploymentTime) }}</span>
</template>
</el-table-column>
<el-table-column :label="$t('common.action')" width="200">
<template #default="scope">
<el-button @click="handleView(scope.row)" text type="primary">流程图
</el-button>
<el-button @click="handleStatus(scope.row, 'suspend')" text type="primary"
v-if="!scope.row.suspend">失效
</el-button>
<el-button @click="handleStatus(scope.row, 'active')" text type="primary"
v-if="scope.row.suspend">激活
</el-button>
<el-button @click="handleDelete([scope.row.roleId])" text type="primary">{{
$t('common.delBtn')
}}
</el-button>
</template>
</el-table-column>
</el-table>
<pagination @current-change="currentChangeHandle" @size-change="sizeChangeHandle" v-bind="state.pagination" />
</el-card>
<el-dialog v-model="showPicDialog" title="流程图">
<img :src="actPicUrl" style="width: 100%;">
</el-dialog>
</div>
</template>
<script lang="ts" name="model" setup>
import { BasicTableProps, useTable } from "/@/hooks/table";
import { delObj, fetchList, status } from "/@/api/oa/process";
import { useMessage, useMessageBox } from "/@/hooks/message";
import { useI18n } from "vue-i18n";
import { parseTime } from "/@/utils/formatTime";
//
const { t } = useI18n()
//
const showPicDialog = ref(false)
const queryRef = ref()
const showSearch = ref(true)
// rows
const selectObjs = ref([]) as any
//
const multiple = ref(true)
// URL
const actPicUrl = ref('')
const state: BasicTableProps = reactive<BasicTableProps>({
queryForm: {
category: ''
},
pageList: fetchList // H
});
// table hook
const {
getDataList,
currentChangeHandle,
sizeChangeHandle,
} = useTable(state)
//
const resetQuery = () => {
queryRef.value.resetFields()
getDataList()
}
//
const handleSelectionChange = (objs: any) => {
selectObjs.value = []
objs.forEach((val: any) => {
selectObjs.value.push(val.roleId)
});
multiple.value = !objs.length
}
//
const handleDelete = (ids: string[]) => {
useMessageBox().confirm(t('common.delConfirmText'))
.then(() => {
delObj(ids).then(() => {
getDataList();
useMessage().success(t('common.delSuccessText'));
}).catch((err: any) => {
useMessage().error(err.msg)
})
})
};
//
const handleView = (row: any) => {
actPicUrl.value = `/admin/process/resource/${row.deploymentId}/${row.processonDefinitionId}/image`
showPicDialog.value = true
}
//
const handleStatus = (row, type) => {
useMessageBox().confirm('是否将此流程设置为 ' + type)
.then(() => {
status(row.processonDefinitionId, type).then(() => {
getDataList();
useMessage().success(t('common.optSuccessText'));
}).catch((err: any) => {
useMessage().error(err.msg)
})
})
}
</script>

View File

@ -0,0 +1,72 @@
<template>
<div class="layout-padding">
<el-dialog title="批注列表" v-model="visible" :close-on-click-modal="false" draggable>
<el-card class="layout-padding-auto">
<el-table :data="state.dataList" v-loading="state.loading" style="width: 100%"
@selection-change="handleSelectionChange" @sort-change="sortChangeHandle">
<el-table-column type="selection" width="60" align="center" />
<el-table-column type="index" :label="t('comment.index')" width="80" />
<el-table-column prop="userId" :label="t('comment.userId')" show-overflow-tooltip />
<el-table-column prop="fullMessage" :label="t('comment.fullMessage')" show-overflow-tooltip>
<template #default="scope">
<span v-html="scope.row.fullMessage"></span>
</template>
</el-table-column>
<el-table-column prop="time" :label="t('comment.time')" show-overflow-tooltip />
</el-table>
</el-card>
</el-dialog>
</div>
</template>
<script setup lang="ts" name="systemTask">
import { BasicTableProps, useTable } from "/@/hooks/table";
import { fetchComment } from "/@/api/oa/task";
import { useI18n } from "vue-i18n";
//
const { t } = useI18n()
//
const visible = ref(false)
const taskId = ref('')
//
const selectObjs = ref([]) as any
const multiple = ref(true)
//
const pageList = () => {
return fetchComment(taskId.value)
}
const state: BasicTableProps = reactive<BasicTableProps>({
isPage: false,
queryForm: {},
pageList: pageList
})
// table hook
const {
getDataList,
sortChangeHandle,
} = useTable(state)
//
const handleSelectionChange = (objs: any) => {
objs.forEach((val: any) => {
selectObjs.value.push(val.leaveId)
});
multiple.value = !objs.length
}
//
const openDialog = (id: string) => {
visible.value = true
taskId.value = id
getDataList()
};
//
defineExpose({
openDialog
});
</script>

136
src/views/oa/task/form.vue Normal file
View File

@ -0,0 +1,136 @@
<template>
<el-dialog :title="form.taskId ? $t('common.editBtn') : $t('common.addBtn')" v-model="visible"
:close-on-click-modal="false" draggable>
<el-form ref="dataFormRef" :model="form" :rules="dataRules" formDialogRef label-width="90px" v-loading="loading">
<el-row :gutter="24">
<el-col :span="24" class="mb20">
<el-form-item :label="t('leave.username')" prop="username">
<el-input v-model="form.username" :placeholder="t('leave.inputUsernameTip')" disabled />
</el-form-item>
</el-col>
<el-col :span="12" class="mb20">
<el-form-item :label="t('leave.days')" prop="days">
<el-input-number :min="1" :max="1000" v-model="form.days" :placeholder="t('leave.inputDaysTip')"
disabled></el-input-number>
</el-form-item>
</el-col>
<el-col :span="12" class="mb20">
<el-form-item :label="t('leave.leaveTime')" prop="leaveTime">
<el-date-picker type="datetime" :placeholder="t('leave.inputLeaveTimeTip')" v-model="form.leaveTime"
:value-format="dateTimeStr" disabled></el-date-picker>
</el-form-item>
</el-col>
<el-col :span="24" class="mb20">
<el-form-item :label="t('task.content')" prop="content">
<div v-html="form.content"></div>
</el-form-item>
</el-col>
<el-col :span="24" class="mb20">
<el-form-item :label="t('task.comment')" prop="comment">
<editor v-model:get-html="form.comment" :placeholder="t('task.inputCommentTip')" />
</el-form-item>
</el-col>
</el-row>
</el-form>
<template #footer>
<span class="dialog-footer">
<el-button type="primary" v-for="flag in form.flagList" :key="flag"
@click="handleTask(flag)">{{ flag }}
</el-button>
</span>
</template>
</el-dialog>
</template>
<script setup lang="ts" name="OaLeaveBillDialog">
import { useMessage } from "/@/hooks/message";
import { doTask, fetchDetail } from '/@/api/oa/task'
import { useI18n } from "vue-i18n"
import { useUserInfo } from "/@/stores/userInfo";
const emit = defineEmits(['refresh']);
const { t } = useI18n();
//
const dataFormRef = ref();
const visible = ref(false)
const loading = ref(false)
//
const form = reactive({
taskId: '',
taskName: '',
username: '',
comment: '',
days: 0,
content: '',
createTime: '',
time: '',
flagList: [],
taskFlag: '',
});
//
const dataRules = ref({
comment: [{ required: true, message: '批注不能为空', trigger: 'blur' }]
})
//
const openDialog = (id: string) => {
visible.value = true
form.taskId = ''
//
if (dataFormRef.value) {
dataFormRef.value.resetFields()
}
// oaLeaveBill
if (id) {
form.taskId = id
getTaskById(id)
} else {
form.username = useUserInfo().userInfos.user.username
}
};
//
const handleTask = (result) => {
dataFormRef.value.validate((valid: boolean) => {
if (!valid) {
return false
}
loading.value = true
form.taskFlag = result
doTask(form).then(() => {
useMessage().success(t('common.optSuccessText'))
visible.value = false
emit('refresh')
})
})
}
//
const getTaskById = (id: string) => {
//
loading.value = true
fetchDetail(id).then((res: any) => {
Object.assign(form, res.data)
form.comment = res.data.comment ? res.data.comment : ''
}).catch((err) => {
useMessage().error('操作失败')
}).finally(() => {
loading.value = false
})
};
//
defineExpose({
openDialog
});
</script>

View File

@ -0,0 +1,18 @@
export default {
task: {
index: 'index',
taskId: 'taskId',
taskName: 'taskName',
time: 'time',
comment: 'comment',
content: 'content',
inputTaskNameTip: 'input Task Name',
inputCommentTip: 'input comment'
},
comment: {
index: 'index',
userId: 'userId',
fullMessage: 'fullMessage',
time: 'time'
}
}

View File

@ -0,0 +1,18 @@
export default {
task: {
index: '序号',
taskId: 'ID',
taskName: '任务名称',
time: '提交时间',
comment: '批注',
content: '事由',
inputTaskNameTip: '请输入任务名称',
inputCommentTip: '请输入批注名称'
},
comment: {
index: '序号',
userId: '用户',
fullMessage: '批注',
time: '时间'
}
}

131
src/views/oa/task/index.vue Normal file
View File

@ -0,0 +1,131 @@
<template>
<div class="layout-padding">
<el-card class="layout-padding-auto">
<el-row v-show="showSearch" class="mb8">
<el-form :model="state.queryForm" ref="queryRef" :inline="true" @keyup.enter="getDataList">
<el-form-item :label="$t('task.taskName')" prop="taskName">
<el-input :placeholder="t('task.inputTaskNameTip')" v-model="state.queryForm.taskName"
style="max-width: 180px" />
</el-form-item>
<el-form-item class="ml2">
<el-button formDialogRef icon="search" type="primary" @click="getDataList">
{{ $t('common.queryBtn') }}
</el-button>
<el-button icon="Refresh" formDialogRef @click="resetQuery">{{ $t('common.resetBtn') }}</el-button>
</el-form-item>
</el-form>
</el-row>
<el-row>
<div class="mb8" style="width: 100%">
<el-button formDialogRef icon="Download" type="primary" class="ml10" @click="exportExcel">
{{ $t('common.exportBtn') }}
</el-button>
<el-button formDialogRef :disabled="multiple" icon="Delete" type="primary" class="ml10"
@click="handleDelete(selectObjs)">
{{ $t('common.delBtn') }}
</el-button>
<right-toolbar v-model:showSearch="showSearch" class="ml10" style="float: right;margin-right: 20px"
@queryTable="getDataList"></right-toolbar>
</div>
</el-row>
<el-table :data="state.dataList" v-loading="state.loading" style="width: 100%"
@selection-change="handleSelectionChange" @sort-change="sortChangeHandle">
<el-table-column type="selection" width="60" align="center" />
<el-table-column type="index" :label="t('task.index')" width="80" />
<el-table-column prop="taskId" :label="t('task.taskId')" show-overflow-tooltip />
<el-table-column prop="taskName" :label="t('task.taskName')" show-overflow-tooltip />
<el-table-column prop="time" :label="t('task.time')" show-overflow-tooltip />
<el-table-column :label="$t('common.action')" width="200">
<template #default="scope">
<el-button text type="primary" @click="handleView(scope.row)">流程图
</el-button>
<el-button text type="primary" @click="formDialogRef.openDialog(scope.row.taskId)">审批
</el-button>
<el-button text type="primary" @click="commentDialogRef.openDialog(scope.row.taskId)">批注
</el-button>
</template>
</el-table-column>
</el-table>
<pagination @size-change="sizeChangeHandle" @current-change="currentChangeHandle" v-bind="state.pagination" />
</el-card>
<!-- 编辑新增 -->
<form-dialog ref="formDialogRef" @refresh="getDataList(false)" />
<comment-dialog ref="commentDialogRef" @refresh="getDataList(false)" />
<el-dialog v-model="showPicDialog" title="流程图">
<img :src="actPicUrl" style="width: 100%;">
</el-dialog>
</div>
</template>
<script setup lang="ts" name="systemTask">
import { BasicTableProps, useTable } from "/@/hooks/table";
import { fetchList } from "/@/api/oa/task";
import { useI18n } from "vue-i18n";
//
const FormDialog = defineAsyncComponent(() => import('./form.vue'));
const CommentDialog = defineAsyncComponent(() => import('./comment.vue'));
const { t } = useI18n()
//
const formDialogRef = ref()
const commentDialogRef = ref()
//
const queryRef = ref()
const showSearch = ref(true)
//
const selectObjs = ref([]) as any
const multiple = ref(true)
// URL
const actPicUrl = ref('')
//
const showPicDialog = ref(false)
const state: BasicTableProps = reactive<BasicTableProps>({
queryForm: {},
pageList: fetchList
})
// table hook
const {
getDataList,
currentChangeHandle,
sizeChangeHandle,
sortChangeHandle,
downBlobFile
} = useTable(state)
//
const resetQuery = () => {
//
queryRef.value.resetFields()
//
selectObjs.value = []
getDataList()
}
// excel
const exportExcel = () => {
downBlobFile('/admin/task/export', state.queryForm, 'task.xlsx')
}
//
const handleSelectionChange = (objs: any) => {
objs.forEach((val: any) => {
selectObjs.value.push(val.leaveId)
});
multiple.value = !objs.length
}
//
const handleDelete = (ids: string[]) => {
};
//
const handleView = (row: any) => {
actPicUrl.value = `/admin/task/view/${row.taskId}`
showPicDialog.value = true
}
</script>

View File

@ -1,7 +1,8 @@
<template>
<el-dialog :close-on-click-modal="false" :title="form.id ? $t('common.editBtn') : $t('common.addBtn')" draggable
v-model="visible">
<el-form :model="form" :rules="dataRules" formDialogRef label-width="90px" ref="dataFormRef" v-loading="loading">
<el-form :model="form" :rules="dataRules" formDialogRef label-width="90px" ref="dataFormRef"
v-loading="loading">
<el-row :gutter="24">
<el-col :span="12" class="mb20">
<el-form-item :label="t('channel.appId')" prop="appId">
@ -89,6 +90,7 @@ import { useDict } from "/@/hooks/dict";
import {useMessage} from "/@/hooks/message";
import {addObj, getObj, putObj} from '/@/api/pay/channel'
import {useI18n} from "vue-i18n"
import {rule} from '/@/utils/validate';
const emit = defineEmits(['refresh']);
@ -118,13 +120,20 @@ const form = reactive({
//
const dataRules = ref({
appId: [{ required: true, message: 'appId不能为空', trigger: 'blur' }],
channelId: [{ required: true, message: '渠道ID不能为空', trigger: 'blur' }],
appId: [{required: true, message: 'appId不能为空', trigger: 'blur'}
, {validator: rule.letterAndNumber, trigger: 'blur'}],
channelName: [{required: true, message: '渠道名称不能为空', trigger: 'blur'}],
channelMchId: [{ required: true, message: '渠道商户ID不能为空', trigger: 'blur' }],
mchId: [{required: true, message: '商户ID不能为空', trigger: 'blur'}
, {validator: rule.letterAndNumber, trigger: 'blur'}],
state: [{required: true, message: '状态不能为空', trigger: 'blur'}],
param: [{ required: true, message: '配置参数不能为空', trigger: 'blur' }],
remark: [{ required: true, message: '备注不能为空', trigger: 'blur' }],
returnUrl: [{required: true, message: '前端回调不能为空', trigger: 'blur'},
{validater: rule.url, trigger: 'blur'}],
notifyUrl: [{required: true, message: '后端回调不能为空', trigger: 'blur'}],
param: [{required: true, message: '参数配置不能为空', trigger: 'blur'}],
})

View File

@ -1,6 +1,6 @@
<template>
<div class="layout-padding">
<el-card class="layout-padding-auto">
<div class="layout-padding-auto layout-padding-view">
<el-row class="mb8" v-show="showSearch">
<el-form :inline="true" :model="state.queryForm" @keyup.enter="getDataList" ref="queryRef">
<el-form-item :label="$t('channel.channelName')" prop="channelName">
@ -26,8 +26,7 @@
<el-row>
<div class="mb8" style="width: 100%">
<el-button @click="formDialogRef.openDialog()" class="ml10" formDialogRef icon="folder-add"
type="primary"
v-auth="'pay_channel_add'">
type="primary" v-auth="'pay_channel_add'">
{{ $t('common.addBtn') }}
</el-button>
<el-button @click="exportExcel" class="ml10" formDialogRef icon="Download" type="primary"
@ -35,8 +34,7 @@
{{ $t('common.exportBtn') }}
</el-button>
<el-button :disabled="multiple" @click="handleDelete(selectObjs)" class="ml10" formDialogRef
icon="Delete"
type="primary" v-auth="'pay_channel_del'">
icon="Delete" type="primary" v-auth="'pay_channel_del'">
{{ $t('common.delBtn') }}
</el-button>
<right-toolbar @queryTable="getDataList" class="ml10" style="float: right;margin-right: 20px"
@ -48,8 +46,7 @@
<el-table-column align="center" type="selection" width="60" />
<el-table-column :label="t('channel.index')" fixed type="index" width="80" />
<el-table-column :label="t('channel.appId')" prop="appId" show-overflow-tooltip width="160" />
<el-table-column :label="t('channel.channelName')" prop="channelName" show-overflow-tooltip
width="100"/>
<el-table-column :label="t('channel.channelName')" prop="channelName" show-overflow-tooltip width="100" />
<el-table-column :label="t('channel.mchId')" prop="mchId" show-overflow-tooltip width="120" />
<el-table-column :label="t('channel.state')" prop="state" show-overflow-tooltip width="100">
<template #default="scope">
@ -75,9 +72,8 @@
</template>
</el-table-column>
</el-table>
<pagination @current-change="currentChangeHandle" @size-change="sizeChangeHandle"
v-bind="state.pagination"/>
</el-card>
<pagination @current-change="currentChangeHandle" @size-change="sizeChangeHandle" v-bind="state.pagination" />
</div>
<!-- 编辑新增 -->
<form-dialog @refresh="getDataList(false)" ref="formDialogRef" />
@ -107,7 +103,8 @@
const state: BasicTableProps = reactive<BasicTableProps>({
queryForm: {},
pageList: fetchList
pageList: fetchList,
descs: ['create_time']
})
// table hook

View File

@ -1,6 +1,6 @@
<template>
<div class="layout-padding">
<el-card class="layout-padding-auto">
<div class="layout-padding-auto layout-padding-view">
<el-row class="mb8" v-show="showSearch">
<el-form :inline="true" :model="state.queryForm" @keyup.enter="getDataList" ref="queryRef">
@ -30,16 +30,16 @@
v-auth="'pay_order_export'">
{{ $t('common.exportBtn') }}
</el-button>
<el-button :disabled="multiple" @click="handleDelete(selectObjs)" class="ml10" formDialogRef
icon="Delete" type="primary" v-auth="'pay_order_del'">
<el-button :disabled="multiple" @click="handleDelete(selectObjs)" class="ml10" formDialogRef icon="Delete"
type="primary" v-auth="'pay_order_del'">
{{ $t('common.delBtn') }}
</el-button>
<right-toolbar @queryTable="getDataList" class="ml10" style="float: right;margin-right: 20px"
v-model:showSearch="showSearch"></right-toolbar>
</div>
</el-row>
<el-table :data="state.dataList" @selection-change="handleSelectionChange" @sort-change="sortChangeHandle"
border style="width: 100%" v-loading="state.loading">
<el-table :data="state.dataList" @selection-change="handleSelectionChange" @sort-change="sortChangeHandle" border
style="width: 100%" v-loading="state.loading">
<el-table-column align="center" type="selection" width="60" />
<el-table-column :label="t('order.index')" type="index" width="80" />
<el-table-column :label="t('order.goodsId')" prop="goodsId" show-overflow-tooltip />
@ -56,8 +56,7 @@
<el-table-column :label="$t('common.action')" width="150">
<template #default="scope">
<el-button @click="handleDelete([scope.row.goodsOrderId])" text type="primary"
v-auth="'pay_order_del'">{{
<el-button @click="handleDelete([scope.row.goodsOrderId])" text type="primary" v-auth="'pay_order_del'">{{
$t('common.delBtn')
}}
</el-button>
@ -65,7 +64,7 @@
</el-table-column>
</el-table>
<pagination @current-change="currentChangeHandle" @size-change="sizeChangeHandle" v-bind="state.pagination" />
</el-card>
</div>
</div>
</template>

View File

@ -1,6 +1,6 @@
<template>
<div class="layout-padding">
<el-card class="layout-padding-auto">
<div class="layout-padding-auto layout-padding-view">
<el-row class="mb8" v-show="showSearch">
<el-form :inline="true" :model="state.queryForm" @keyup.enter="getDataList" ref="queryRef">
<el-form-item :label="$t('record.notifyId')" prop="notifyId">
@ -54,7 +54,7 @@
</el-table-column>
</el-table>
<pagination @current-change="currentChangeHandle" @size-change="sizeChangeHandle" v-bind="state.pagination" />
</el-card>
</div>
</div>
</template>

View File

@ -1,6 +1,6 @@
<template>
<div class="layout-padding">
<el-card class="layout-padding-auto">
<div class="layout-padding-auto layout-padding-view">
<el-row class="mb8" v-show="showSearch">
<el-form :inline="true" :model="state.queryForm" @keyup.enter="getDataList" ref="queryRef">
<el-form-item :label="$t('refund.refundOrderId')" prop="refundOrderId">
@ -60,7 +60,7 @@
</el-table-column>
</el-table>
<pagination @current-change="currentChangeHandle" @size-change="sizeChangeHandle" v-bind="state.pagination" />
</el-card>
</div>
</div>
</template>

View File

@ -1,6 +1,6 @@
<template>
<div class="layout-padding">
<el-card class="layout-padding-auto">
<div class="layout-padding-auto layout-padding-view">
<el-row class="mb8" v-show="showSearch">
<el-form :inline="true" :model="state.queryForm" @keyup.enter="getDataList" ref="queryRef">
<el-form-item :label="$t('trade.orderId')" prop="orderId">
@ -30,23 +30,22 @@
v-auth="'pay_trade_export'">
{{ $t('common.exportBtn') }}
</el-button>
<el-button :disabled="multiple" @click="handleDelete(selectObjs)" class="ml10" formDialogRef
icon="Delete" type="primary" v-auth="'pay_trade_del'">
<el-button :disabled="multiple" @click="handleDelete(selectObjs)" class="ml10" formDialogRef icon="Delete"
type="primary" v-auth="'pay_trade_del'">
{{ $t('common.delBtn') }}
</el-button>
<right-toolbar @queryTable="getDataList" class="ml10" style="float: right;margin-right: 20px"
v-model:showSearch="showSearch"></right-toolbar>
</div>
</el-row>
<el-table :data="state.dataList" @selection-change="handleSelectionChange" @sort-change="sortChangeHandle"
border style="width: 100%" v-loading="state.loading">
<el-table :data="state.dataList" @selection-change="handleSelectionChange" @sort-change="sortChangeHandle" border
style="width: 100%" v-loading="state.loading">
<el-table-column align="center" type="selection" width="60" />
<el-table-column :label="t('trade.index')" fixed type="index" width="80" />
<el-table-column :label="t('trade.orderId')" prop="orderId" show-overflow-tooltip width="120" />
<el-table-column :label="t('trade.channelId')" prop="channelId" show-overflow-tooltip width="120" />
<el-table-column :label="t('trade.channelMchId')" prop="channelMchId" show-overflow-tooltip width="120" />
<el-table-column :label="t('trade.channelOrderNo')" prop="channelOrderNo" show-overflow-tooltip
width="120"/>
<el-table-column :label="t('trade.channelOrderNo')" prop="channelOrderNo" show-overflow-tooltip width="120" />
<el-table-column :label="t('trade.body')" prop="body" show-overflow-tooltip width="120" />
<el-table-column :label="t('trade.amount')" prop="amount" show-overflow-tooltip width="120" />
<el-table-column :label="t('trade.status')" prop="status" show-overflow-tooltip width="120">
@ -61,13 +60,11 @@
<el-table-column :label="$t('common.action')" fixed="right" width="150">
<template #default="scope">
<el-button @click="refundDialogRef.openDialog(scope.row.orderId)" text type="primary"
v-if="scope.row.status === '1'"
v-auth="'pay_trade_del'">{{
v-if="scope.row.status === '1'" v-auth="'pay_trade_del'">{{
$t('trade.refundBtn')
}}
</el-button>
<el-button @click="handleDelete([scope.row.orderId])" text type="primary"
v-auth="'pay_trade_del'">{{
<el-button @click="handleDelete([scope.row.orderId])" text type="primary" v-auth="'pay_trade_del'">{{
$t('common.delBtn')
}}
</el-button>
@ -75,7 +72,7 @@
</el-table-column>
</el-table>
<pagination @current-change="currentChangeHandle" @size-change="sizeChangeHandle" v-bind="state.pagination" />
</el-card>
</div>
<refund-dialog @refresh="getDataList(false)" ref="refundDialogRef" />
</div>

View File

@ -1,6 +0,0 @@
export default {
personal: {
name: 'personal info',
passwordRule: 'The two passwords are inconsistent'
}
}

View File

@ -1,6 +0,0 @@
export default {
personal: {
name: '个人信息',
passwordRule: '两次输入密码不一致'
}
}