Merge branch 'master' of https://codeup.aliyun.com/bsdtec/biz-pc-cloud
This commit is contained in:
commit
3dc7a63568
3 files changed
+32
-58
No files matched your search
@@ -1,21 +1,20 @@
|
||||
<template>
|
||||
<div class="system-user-dialog-container">
|
||||
<el-dialog
|
||||
:close-on-click-modal="false"
|
||||
:title="dataForm.userId ? $t('common.editBtn') : $t('common.addBtn')"
|
||||
draggable
|
||||
v-model="visible"
|
||||
>
|
||||
<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 :disabled="dataForm.userId !== ''" placeholder="请输入用户名" v-model.trim="dataForm.username" />
|
||||
<el-input :disabled="dataForm.userId !== '' && !auth('user_sysUser_editUsername')"
|
||||
placeholder="请输入用户名" v-model.trim="dataForm.username" />
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col :span="12" class="mb20">
|
||||
<el-form-item :label="$t('sysuser.password')" prop="password">
|
||||
<el-input clearable placeholder="请输入密码" type="password" v-model="dataForm.password"></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">
|
||||
@@ -31,29 +30,25 @@
|
||||
<el-col :span="12" v-if="!roleCodes.includes('DEPT_ADMIN')" class="mb20">
|
||||
<el-form-item :label="$t('sysuser.role')" prop="role">
|
||||
<el-select clearable multiple placeholder="请选择角色" v-model="dataForm.role">
|
||||
<el-option :key="item.roleId" :label="item.roleName" :value="item.roleId" v-for="item in roleData" />
|
||||
<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" v-if="!roleCodes.includes('DEPT_ADMIN')" class="mb20">
|
||||
<el-form-item :label="$t('sysuser.post')" prop="post">
|
||||
<el-select clearable multiple placeholder="请选择岗位" v-model="dataForm.post">
|
||||
<el-option :key="item.postId" :label="item.postName" :value="item.postId" v-for="item in postData" />
|
||||
<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 v-if="!dataForm.userId" :span="12" class="mb20">
|
||||
<el-form-item :label="$t('sysuser.dept')" prop="deptId">
|
||||
<el-tree-select
|
||||
:data="deptData"
|
||||
<el-tree-select :data="deptData"
|
||||
:props="{ value: 'id', label: 'name', children: 'children', disabled: 'isLock' }"
|
||||
filterable
|
||||
check-strictly
|
||||
class="w100"
|
||||
clearable
|
||||
placeholder="请选择所属部门"
|
||||
v-model="dataForm.deptId"
|
||||
>
|
||||
filterable check-strictly class="w100" clearable placeholder="请选择所属部门"
|
||||
v-model="dataForm.deptId">
|
||||
<template #default="{ node, data }">
|
||||
<el-tooltip v-if="data.isLock" effect="dark" content="无数据权限" placement="right">
|
||||
<span>
|
||||
@@ -79,7 +74,9 @@
|
||||
<el-col :span="12" class="mb20">
|
||||
<el-form-item :label="$t('sysuser.lockFlag')" prop="lockFlag">
|
||||
<el-radio-group v-model="dataForm.lockFlag">
|
||||
<el-radio :key="index" :label="item.value" border v-for="(item, index) in lock_flag">{{ item.label }} </el-radio>
|
||||
<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>
|
||||
</el-col>
|
||||
@@ -88,7 +85,8 @@
|
||||
<template #footer>
|
||||
<span class="dialog-footer">
|
||||
<el-button @click="visible = false">{{ $t("common.cancelButtonText") }}</el-button>
|
||||
<el-button @click="onSubmit" type="primary" :disabled="loading">{{ $t("common.confirmButtonText") }}</el-button>
|
||||
<el-button @click="onSubmit" type="primary" :disabled="loading">{{ $t("common.confirmButtonText")
|
||||
}}</el-button>
|
||||
</span>
|
||||
</template>
|
||||
</el-dialog>
|
||||
@@ -105,6 +103,7 @@ import { useI18n } from "vue-i18n"
|
||||
import { useMessage } from "/@/hooks/message"
|
||||
import { rule } from "/@/utils/validate"
|
||||
import { useUserInfo } from "/@/stores/userInfo"
|
||||
import { auth } from "/@/utils/authFunction"
|
||||
|
||||
const { t } = useI18n()
|
||||
|
||||
@@ -222,7 +221,7 @@ const openDialog = async (id: string) => {
|
||||
|
||||
// 提交
|
||||
const onSubmit = async () => {
|
||||
const valid = await dataFormRef.value.validate().catch(() => {})
|
||||
const valid = await dataFormRef.value.validate().catch(() => { })
|
||||
if (!valid) return false
|
||||
|
||||
try {
|
||||
|
||||
@@ -40,7 +40,6 @@
|
||||
>
|
||||
删除
|
||||
</el-button>
|
||||
|
||||
<div class="flex justify-between items-center">
|
||||
<el-tabs class="flex-1" v-model="activeName" @tab-click="handleClickTabItem">
|
||||
<el-tab-pane v-for="v in tabItems" :key="v.id" :label="v.label" :name="v.value" />
|
||||
@@ -175,7 +174,16 @@
|
||||
>
|
||||
删除
|
||||
</el-button>
|
||||
<el-button icon="printer" text type="primary" @click="previewInvoice(row)">打印发票</el-button>
|
||||
<el-button
|
||||
v-auth="'wallet_walletRechargeApply_print'"
|
||||
v-if="['1'].includes(row.processStatus)"
|
||||
icon="printer"
|
||||
text
|
||||
type="primary"
|
||||
@click="previewInvoice(row)"
|
||||
>
|
||||
打印发票
|
||||
</el-button>
|
||||
</template>
|
||||
</el-table-column>
|
||||
</el-table>
|
||||
|
||||
@@ -9,7 +9,7 @@
|
||||
</el-row>
|
||||
<el-table :data="data.list" v-loading="state.loading" border :header-cell-style="tableStyle.headerCellStyle"
|
||||
show-summary :summary-method="getSummaries">
|
||||
<el-table-column type="index" label="#" align="center" />
|
||||
<el-table-column type="index" label="#" width="250" align="center" />
|
||||
<el-table-column prop="username" label="用户" align="center" />
|
||||
<el-table-column prop="userMobile" label="手机号" align="center" />
|
||||
<el-table-column prop="bizType" label="充值类型" align="center">
|
||||
@@ -24,39 +24,6 @@
|
||||
<div v-if="row.afterBalance < 0" class="color-danger">(余额不足记账扣款)</div>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<!-- <slot>
|
||||
<el-table-column v-if="data.tableList && data.tableList.length" :prop="v"
|
||||
v-for="(v, i) in data.tableList" :key="i" align="center" min-width="250">
|
||||
<template #header>
|
||||
<div>
|
||||
{{ data.tableListStr[i] }}
|
||||
</div>
|
||||
</template>
|
||||
<template #default="{ row }">
|
||||
<div class="change">
|
||||
<div v-if="row[`${v}_price`] >= 0" class="change_price">{{
|
||||
displayPrice(row[`${v}_price`]) }}</div>
|
||||
<div v-else class="change_price">{{ displayPrice(row[`${v}_price`]) }}</div>
|
||||
<div class="change_text">
|
||||
<div v-if="row[`${v}_transaction_price`]">
|
||||
<span>对比上月</span>
|
||||
<span :class="[row[`${v}_transaction_price`] >= 0 ? 'success' : 'error']"
|
||||
style="margin-left: 5px">
|
||||
{{ displayPrice(row[`${v}_transaction_price`]) }}
|
||||
</span>
|
||||
</div>
|
||||
<div v-if="row[`${v}_transaction_percent`]">
|
||||
<span>对比上月</span>
|
||||
<span :class="[row[`${v}_transaction_price`] >= 0 ? 'success' : 'error']"
|
||||
style="margin-left: 5px">
|
||||
{{ row[`${v}_transaction_percent`] }}%
|
||||
</span>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</template>
|
||||
</el-table-column>
|
||||
</slot> -->
|
||||
</el-table>
|
||||
<pagination @size-change="sizeChangeHandle" @current-change="currentChangeHandle"
|
||||
v-bind="state.pagination" />
|
||||
|
||||
Reference in new issue
Block a user