Browse Source

组织增加人员检索功能;

dev
luyan 1 year ago
parent
commit
dba0556a3b
  1. 954
      src/views/modules/base/organization/organization.vue
  2. 75
      src/views/modules/customer/customize/roleList.vue
  3. 73
      src/views/modules/customer/role.vue
  4. 58
      src/views/modules/home/index.vue
  5. 149
      src/views/modules/productConfig/workRoleAuth.vue
  6. 115
      src/views/modules/workSys/role/role.vue

954
src/views/modules/base/organization/organization.vue

File diff suppressed because it is too large

75
src/views/modules/customer/customize/roleList.vue

@ -3,91 +3,57 @@
<el-card class="flex1">
<div class="now-name">
当前客户: {{ customerName }}
<el-button type="primary"
size="small"
@click="handleSaveSort">保存顺序</el-button>
<el-button type="primary" size="small" @click="handleSaveSort">保存顺序</el-button>
</div>
<el-table ref="roleTable"
v-loading="loading1"
:data="roleList"
row-key="roleId"
border
style="width: 100%">
<el-table-column type="index"
width="50"></el-table-column>
<el-table ref="roleTable" v-loading="loading1" :data="roleList" row-key="roleId" border style="width: 100%">
<el-table-column type="index" width="50"></el-table-column>
<!-- <el-table-column prop="roleId" label="角色ID"></el-table-column> -->
<el-table-column prop="roleName"
label="角色名称"
width="160">
<el-table-column prop="roleName" label="角色名称" width="160">
<template slot-scope="scope">
<el-input v-if="scope.row.isEdit"
v-model.trim="scope.row.roleName"
clearable>
<el-input v-if="scope.row.isEdit" v-model.trim="scope.row.roleName" clearable>
</el-input>
<span v-else>{{ scope.row.constName }}</span>
</template>
</el-table-column>
<el-table-column v-if="!funcShow"
prop="roleKey"
label="角色Key"></el-table-column>
<el-table-column v-if="!funcShow" prop="roleKey" label="角色Key"></el-table-column>
<el-table-column label="操作">
<template slot-scope="scope">
<el-button type="primary"
size="mini"
<el-button type="primary" size="mini"
@click="toOperationConfig(scope.row.roleId, scope.row.roleName)">功能权限</el-button>
<span v-if="scope.row.isEdit"
style="display: inline-block; margin-left: 10px;">
<el-button type="primary"
size="small"
@click="handleSaveChange(scope.row)">保存</el-button>
<el-button size="small"
@click="scope.row.isEdit=false">取消</el-button>
<span v-if="scope.row.isEdit" style="display: inline-block; margin-left: 10px;">
<el-button type="primary" size="small" @click="handleSaveChange(scope.row)">保存</el-button>
<el-button size="small" @click="scope.row.isEdit = false">取消</el-button>
</span>
<el-button v-else
type="primary"
size="mini"
<el-button v-else type="primary" size="mini"
@click="handleChangeName(scope.row)">修改名称</el-button>
</template>
</el-table-column>
</el-table>
</el-card>
<el-card v-show="funcShow"
style="flex: 1; margin: 0 10px;">
<el-card v-show="funcShow" style="flex: 1; margin: 0 10px;">
<div class="now-name">当前角色: {{ roleName }}</div>
<el-table v-loading="loading2"
max-height="580"
ref="opeTable"
:data="opeList"
border
style="width: 100%"
<el-table v-loading="loading2" max-height="580" ref="opeTable" :data="opeList" border style="width: 100%"
@select="handleSelectionChange">
<el-table-column type="selection"
width="55"></el-table-column>
<el-table-column type="selection" width="55"></el-table-column>
<!-- <el-table-column prop="operationKey" label="操作Key"></el-table-column> -->
<el-table-column prop="operationName"
label="操作名称"></el-table-column>
<el-table-column prop="operationName" label="操作名称"></el-table-column>
<!-- <el-table-column prop="brief" label="简介"></el-table-column> -->
<el-table-column label="操作">
<template slot-scope="scope">
<el-button type="primary"
size="small"
<el-button type="primary" size="small"
@click="toScopeConfig(scope.row.operationKey, scope.row.operationName)">权限配置</el-button>
</template>
</el-table-column>
</el-table>
</el-card>
<el-card v-show="roleShow"
style="width: 250px;">
<el-card v-show="roleShow" style="width: 250px;">
<div class="now-name">当前功能: {{ funcName }}</div>
<div>
<el-row :gutter="12">
<el-col v-loading="loading3">
<el-card shadow="hover">
<el-checkbox-group class="t"
v-model.trim="checkedScopes"
@change="roleChange">
<el-checkbox v-for="scope in scopeOptions"
:label="scope.scopeKey"
<el-checkbox-group class="t" v-model.trim="checkedScopes" @change="roleChange">
<el-checkbox v-for="scope in scopeOptions" :label="scope.scopeKey"
:key="scope.scopeKey">{{ scope.scopeName }}</el-checkbox>
</el-checkbox-group>
</el-card>
@ -350,14 +316,17 @@ export default {
.role-container {
display: flex;
}
.flex1 {
flex: 1;
}
.now-name {
/* display: flex;
justify-content: space-between; */
margin-bottom: 10px;
}
.aui-wrapper .el-card+.el-card {
margin-top: 0;
}

73
src/views/modules/customer/role.vue

@ -5,33 +5,21 @@
当前客户: {{customerName}}
<el-button type="primary" size="small" @click="handleSaveSort">保存顺序</el-button>
</div> -->
<el-table ref="roleTable"
v-loading="loading1"
:data="roleList"
row-key="roleKey"
border
<el-table ref="roleTable" v-loading="loading1" :data="roleList" row-key="roleKey" border
style="width: 100%">
<el-table-column type="index"
width="50"></el-table-column>
<el-table-column type="index" width="50"></el-table-column>
<!-- <el-table-column prop="roleId" label="角色ID"></el-table-column> -->
<el-table-column prop="roleName"
label="角色名称"
width="160">
<el-table-column prop="roleName" label="角色名称" width="160">
<template slot-scope="scope">
<el-input v-if="scope.row.isEdit"
v-model.trim="scope.row.roleName"
clearable>
<el-input v-if="scope.row.isEdit" v-model.trim="scope.row.roleName" clearable>
</el-input>
<span v-else>{{ scope.row.constName }}</span>
</template>
</el-table-column>
<el-table-column v-if="!funcShow"
prop="roleKey"
label="角色Key"></el-table-column>
<el-table-column v-if="!funcShow" prop="roleKey" label="角色Key"></el-table-column>
<el-table-column label="操作">
<template slot-scope="scope">
<el-button type="primary"
size="mini"
<el-button type="primary" size="mini"
@click="toOperationConfig(scope.row.roleKey, scope.row.roleName)">功能权限</el-button>
<!-- <span v-if="scope.row.isEdit" style="display: inline-block; margin-left: 10px;">
<el-button type="primary" size="small" @click="handleSaveChange(scope.row)">保存</el-button>
@ -42,60 +30,39 @@
</el-table-column>
</el-table>
</el-card>
<el-dialog :visible.sync="funcShow"
:close-on-click-modal="false"
:close-on-press-escape="false"
width="70%"
top="30px"
title="功能列表"
@closed="handleDialogClosed">
<div class="role-flex"
v-if="funcShow">
<el-dialog :visible.sync="funcShow" :close-on-click-modal="false" :close-on-press-escape="false" width="70%"
top="30px" title="功能列表" @closed="handleDialogClosed">
<div class="role-flex" v-if="funcShow">
<el-card class="flex1">
<div class="now-name">当前角色: {{ roleName }}</div>
<div class="now-name">
<el-button type="primary"
size="small"
@click="saveOperations4Role">保存功能</el-button>
<el-button type="primary" size="small" @click="saveOperations4Role">保存功能</el-button>
</div>
<el-table v-loading="loading2"
height="580"
ref="opeTable"
:data="opeList"
border
<el-table v-loading="loading2" height="580" ref="opeTable" :data="opeList" border
@select="handleSelectionChange">
<el-table-column type="selection"
width="55"></el-table-column>
<el-table-column type="selection" width="55"></el-table-column>
<!-- <el-table-column prop="operationKey" label="操作Key"></el-table-column> -->
<el-table-column prop="operationName"
label="操作名称"></el-table-column>
<el-table-column prop="operationName" label="操作名称"></el-table-column>
<!-- <el-table-column prop="brief" label="简介"></el-table-column> -->
<el-table-column label="操作">
<template slot-scope="scope">
<el-button type="primary"
size="small"
<el-button type="primary" size="small"
@click="toScopeConfig(scope.row.operationKey, scope.row.operationName)">范围配置</el-button>
</template>
</el-table-column>
</el-table>
</el-card>
<el-card v-show="roleShow"
style="width: 250px; margin-left: 10px;">
<el-card v-show="roleShow" style="width: 250px; margin-left: 10px;">
<div class="now-name">当前功能: {{ funcName }}</div>
<div class="now-name">
<el-button type="primary"
size="small"
@click="saveSettings">保存范围</el-button>
<el-button type="primary" size="small" @click="saveSettings">保存范围</el-button>
</div>
<div>
<el-row :gutter="12">
<el-col v-loading="loading3">
<el-card shadow="hover">
<el-checkbox-group class="t"
v-model.trim="checkedScopes"
@change="roleChange">
<el-checkbox v-for="scope in scopeOptions"
:label="scope.scopeKey"
<el-checkbox-group class="t" v-model.trim="checkedScopes" @change="roleChange">
<el-checkbox v-for="scope in scopeOptions" :label="scope.scopeKey"
:key="scope.scopeKey">{{ scope.scopeName }}</el-checkbox>
</el-checkbox-group>
</el-card>
@ -374,17 +341,21 @@ export default {
.role-flex {
display: flex;
}
.flex1 {
flex: 1;
}
.now-name {
/* display: flex;
justify-content: space-between; */
margin-bottom: 10px;
}
.aui-wrapper .el-card+.el-card {
margin-top: 0;
}
.role-container .el-dialog__body {
padding: 0 20px 20px;
}

58
src/views/modules/home/index.vue

@ -8,17 +8,20 @@
<span>社区查询</span>
</div> -->
<div class="tabs">
<div :class="{ 'z-on': searchData.type == 'jumin' }" @click="searchDataTab('jumin')">查居民</div>
<div :class="{ 'z-on': searchData.type == 'fangwu' }" @click="searchDataTab('fangwu')">查房屋</div>
<div :class="{ 'z-on': searchData.type == 'jumin' }" @click="searchDataTab('jumin')">查居民
</div>
<div :class="{ 'z-on': searchData.type == 'fangwu' }" @click="searchDataTab('fangwu')">查房屋
</div>
</div>
<div class="search">
<div class="search-input">
<div class="input">
<input type="text" :placeholder="typePlaceholder[searchData.type]" v-model.trim="searchData.searchKey"
@keyup.enter="handleClickSearchBtn" />
<input type="text" :placeholder="typePlaceholder[searchData.type]"
v-model.trim="searchData.searchKey" @keyup.enter="handleClickSearchBtn" />
<div class="close-btn" v-if="searchData.searchKey != ''" @click="searchData.searchKey = ''">
<div class="close-btn" v-if="searchData.searchKey != ''"
@click="searchData.searchKey = ''">
<img src="@/assets/img/shequ/close.png" />
</div>
</div>
@ -39,15 +42,19 @@
</div>
</div>
<div class="boxss">
<div style="margin-top: 10px;" @click="handelClickToResi({residentCategory:'permanentFlag'})">
<span style="color: #2683DB; font-size: 25px;">{{ pandectData.permanentResiCount }}</span>
<div style="margin-top: 10px;"
@click="handelClickToResi({ residentCategory: 'permanentFlag' })">
<span style="color: #2683DB; font-size: 25px;">{{ pandectData.permanentResiCount
}}</span>
<br>
<span style="color: #858585; font-size: 12px;">常住人口</span>
</div>
</div>
<div class="boxss">
<div style="margin-top: 10px;" @click="handelClickToResi({residentCategory:'FLOATING_FLAG'})">
<span style="color: #2683DB; font-size: 25px;">{{ pandectData.floatingResiCount }}</span>
<div style="margin-top: 10px;"
@click="handelClickToResi({ residentCategory: 'FLOATING_FLAG' })">
<span style="color: #2683DB; font-size: 25px;">{{ pandectData.floatingResiCount
}}</span>
<br>
<span style="color: #858585; font-size: 12px;">流动人口</span>
</div>
@ -124,8 +131,9 @@
</div>
<div class="item-title"
style="white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 450px;">
<img v-if="item.msgType == 'resident_category'" class="thumbnail_1" style="width: 17px;"
referrerpolicy="no-referrer" src="~@/assets/images/shuju/renfang/index/zhiding.png" />{{
<img v-if="item.msgType == 'resident_category'" class="thumbnail_1"
style="width: 17px;" referrerpolicy="no-referrer"
src="~@/assets/images/shuju/renfang/index/zhiding.png" />{{
item.content }}
</div>
</div>
@ -144,12 +152,17 @@
</div>
<div class="m-box m-tx" style="position: relative;">
<div class="header" style="display: flex;align-items: center;justify-content: space-between;"> <div class="newqsa"><span >居民信息更新情况</span> <span style="color: #cccccc;">数据截止到{{yesterdayDate}}</span></div> <div class="update-settings" @click="jumpToJuMin()" v-show="showAll"><img referrerpolicy="no-referrer"
src="https://lanhu.oss-cn-beijing.aliyuncs.com/pskhmf0717eflwg54wn73s6spnsg6u48r0f69e94b-2bc8-4156-8330-902087b72e0b" />更新设置</div>
<div class="header" style="display: flex;align-items: center;justify-content: space-between;">
<div class="newqsa"><span>居民信息更新情况</span> <span
style="color: #cccccc;">数据截止到{{ yesterdayDate }}</span></div>
<div class="update-settings" @click="jumpToJuMin()" v-show="showAll"><img
referrerpolicy="no-referrer"
src="https://lanhu.oss-cn-beijing.aliyuncs.com/pskhmf0717eflwg54wn73s6spnsg6u48r0f69e94b-2bc8-4156-8330-902087b72e0b" />更新设置
</div>
</div>
<div style="width: 100%;margin-top:26px;overflow-y: scroll; height:calc(100% - 79px);padding-bottom:15px; box-sizing: border-box" >
<el-table :data="tableList"
border :cell-style="columnbackgroundStyle" class="m-table-item">
<div
style="width: 100%;margin-top:26px;overflow-y: scroll; height:calc(100% - 79px);padding-bottom:15px; box-sizing: border-box">
<el-table :data="tableList" border :cell-style="columnbackgroundStyle" class="m-table-item">
<el-table-column label="居民类别" align="center" width="105">
<template slot-scope="scope">
<span style="color:#989898">{{ scope.row.residentCategoryName }}</span>
@ -157,12 +170,14 @@
</el-table-column>
<el-table-column label="总人数" width="105" align="center">
<template slot-scope="scope">
<span style="color:#006fd6;cursor: pointer;" @click="handelClickToResi(scope.row)">{{scope.row.total}}</span>
<span style="color:#006fd6;cursor: pointer;"
@click="handelClickToResi(scope.row)">{{ scope.row.total }}</span>
</template>
</el-table-column>
<el-table-column label="分类信息不完整数" align="center" :show-overflow-tooltip="true">
<template slot-scope="scope">
<span style="color:#ff1200;cursor: pointer;" @click="handelCLickJump(scope.row,'cateNonIntegrity')">{{scope.row.nonIntegratedNum}}</span>
<span style="color:#ff1200;cursor: pointer;"
@click="handelCLickJump(scope.row, 'cateNonIntegrity')">{{ scope.row.nonIntegratedNum }}</span>
</template>
</el-table-column>
<el-table-column label="更新负责人" :show-overflow-tooltip="true" align="center" v-if="showAll">
@ -173,13 +188,16 @@
<el-table-column label="更新周期" align="center" width="105">
<template slot-scope="scope">
<span style="color:#989898;">{{ scope.row.updatePeriod ? scope.row.updatePeriod
== 'month' ? '每自然月' : scope.row.updatePeriod == 'halfMonth' ? '每半自然月' : scope.row.updatePeriod
== 'month' ? '每自然月' : scope.row.updatePeriod == 'halfMonth' ? '每半自然月' :
scope.row.updatePeriod
== 'week' ? '每周' : '' : '' }}</span>
</template>
</el-table-column>
<el-table-column label="更新人数" align="center" width="105">
<template slot-scope="scope">
<span style="color:#006fd6;cursor: pointer;" @click="handelCLickJump(scope.row,'updateResiList')">{{scope.row.updateResiNum}}</span><span style="color:#989898;">({{scope.row.updatePeriodName?scope.row.updatePeriodName:'--'}})</span>
<span style="color:#006fd6;cursor: pointer;"
@click="handelCLickJump(scope.row, 'updateResiList')">{{ scope.row.updateResiNum }}</span><span
style="color:#989898;">({{ scope.row.updatePeriodName ? scope.row.updatePeriodName : '--' }})</span>
</template>
</el-table-column>
</el-table>

149
src/views/modules/productConfig/workRoleAuth.vue

@ -1,166 +1,97 @@
<template>
<div class="role-container">
<el-card class="flex1">
<el-tabs v-model.trim="activeName"
@tab-click="tabClick"
class="el-tabs">
<el-tab-pane label="工作端"
name="work">
<el-tabs v-model.trim="activeName" @tab-click="tabClick" class="el-tabs">
<el-tab-pane label="工作端" name="work">
<div class="now-name">
上下拖动可改变角色顺序
<el-button type="primary"
size="small"
@click="handleSaveSort">保存顺序</el-button>
<el-button type="primary" size="small" @click="handleSaveSort">保存顺序</el-button>
</div>
<el-table ref="roleTable"
v-loading="loading1"
:data="roleList"
row-key="roleKey"
border
<el-table ref="roleTable" v-loading="loading1" :data="roleList" row-key="roleKey" border
style="width: 100%">
<el-table-column type="index"
header-align="left"
align="left"
width="50"></el-table-column>
<el-table-column prop="roleName"
label="角色名称"
header-align="left"
align="left"
width="180">
<el-table-column type="index" header-align="left" align="left" width="50"></el-table-column>
<el-table-column prop="roleName" label="角色名称" header-align="left" align="left" width="180">
<template slot-scope="scope">
<el-input v-if="scope.row.isEdit"
v-model.trim="scope.row.roleName"
clearable>
<el-input v-if="scope.row.isEdit" v-model.trim="scope.row.roleName" clearable>
</el-input>
<span v-else>{{ scope.row.constName }}</span>
</template>
</el-table-column>
<el-table-column v-if="!funcShow"
prop="roleKey"
header-align="left"
align="left"
label="角色Key"
<el-table-column v-if="!funcShow" prop="roleKey" header-align="left" align="left" label="角色Key"
width="150"></el-table-column>
<el-table-column prop="description"
label="角色职责"
header-align="left"
align="left">
<el-table-column prop="description" label="角色职责" header-align="left" align="left">
<template slot-scope="scope">
<p style="text-align:left;margin:3px 0"
v-for="(item,index) in scope.row.descriptionList"
:key="index">{{item}}</p>
v-for="(item, index) in scope.row.descriptionList" :key="index">{{ item }}</p>
<!-- <p>{{scope.row.description}}</p> -->
</template>
</el-table-column>
<el-table-column width="450"
label="操作">
<el-table-column width="450" label="操作">
<template slot-scope="scope">
<el-button type="primary"
size="mini"
<el-button type="primary" size="mini"
@click="handelChangeDuty(scope.row)">修改职责</el-button>
<el-button type="primary"
size="mini"
<el-button type="primary" size="mini"
@click="toOperationConfig(scope.row.roleKey, scope.row.roleName)">功能权限</el-button>
<span v-if="scope.row.isEdit"
style="display: inline-block; margin-left: 10px;">
<el-button type="primary"
size="small"
@click="saveName(scope.row)">保存</el-button>
<el-button size="small"
@click="scope.row.isEdit=false">取消</el-button>
<span v-if="scope.row.isEdit" style="display: inline-block; margin-left: 10px;">
<el-button type="primary" size="small" @click="saveName(scope.row)">保存</el-button>
<el-button size="small" @click="scope.row.isEdit = false">取消</el-button>
</span>
<el-button v-else
type="primary"
size="mini"
<el-button v-else type="primary" size="mini"
@click="handleChangeName(scope.row)">修改名称</el-button>
</template>
</el-table-column>
</el-table>
</el-tab-pane>
<el-tab-pane label="居民端"
name="resi">
<el-tab-pane label="居民端" name="resi">
</el-tab-pane>
</el-tabs>
</el-card>
<!-- 角色职责弹出框 -->
<el-dialog :visible.sync="dutyShow"
:close-on-click-modal="false"
:close-on-press-escape="false"
title="角色职责"
width="30%"
@closed="handleDutyClosed">
<div class="div_duty"
v-if="dutyShow">
<el-input type="textarea"
:rows="8"
v-model.trim="description"></el-input>
<el-dialog :visible.sync="dutyShow" :close-on-click-modal="false" :close-on-press-escape="false" title="角色职责"
width="30%" @closed="handleDutyClosed">
<div class="div_duty" v-if="dutyShow">
<el-input type="textarea" :rows="8" v-model.trim="description"></el-input>
<div class="div_btn">
<el-button type="primary"
size="small"
@click="updateRole()">保存</el-button>
<el-button size="small"
@click="dutyShow=false">取消</el-button>
<el-button type="primary" size="small" @click="updateRole()">保存</el-button>
<el-button size="small" @click="dutyShow = false">取消</el-button>
</div>
</div>
</el-dialog>
<!-- 功能配置弹出框 -->
<el-dialog :visible.sync="funcShow"
:close-on-click-modal="false"
:close-on-press-escape="false"
width="70%"
top="30px"
title="功能列表"
@closed="handleDialogClosed">
<div class="role-flex"
v-if="funcShow">
<el-dialog :visible.sync="funcShow" :close-on-click-modal="false" :close-on-press-escape="false" width="70%"
top="30px" title="功能列表" @closed="handleDialogClosed">
<div class="role-flex" v-if="funcShow">
<el-card class="flex1">
<div class="now-name">当前角色: {{ roleName }}</div>
<div class="now-name">
<el-button type="primary"
size="small"
@click="saveOperations4Role">保存功能</el-button>
<el-button type="primary" size="small" @click="saveOperations4Role">保存功能</el-button>
</div>
<el-table v-loading="loading2"
height="580"
ref="opeTable"
:data="opeList"
border
<el-table v-loading="loading2" height="580" ref="opeTable" :data="opeList" border
@select="handleSelectionChange">
<el-table-column type="selection"
width="55"></el-table-column>
<el-table-column type="selection" width="55"></el-table-column>
<!-- <el-table-column prop="operationKey" label="操作Key"></el-table-column> -->
<el-table-column prop="operationName"
label="操作名称"></el-table-column>
<el-table-column prop="operationName" label="操作名称"></el-table-column>
<!-- <el-table-column prop="brief" label="简介"></el-table-column> -->
<el-table-column label="操作">
<template slot-scope="scope">
<el-button type="primary"
size="small"
<el-button type="primary" size="small"
@click="toScopeConfig(scope.row.operationKey, scope.row.operationName)">范围配置</el-button>
</template>
</el-table-column>
</el-table>
</el-card>
<el-card v-show="roleShow"
style="width: 250px; margin-left: 10px;">
<el-card v-show="roleShow" style="width: 250px; margin-left: 10px;">
<div class="now-name">当前功能: {{ funcName }}</div>
<div class="now-name">
<el-button type="primary"
size="small"
@click="saveSettings">保存范围</el-button>
<el-button type="primary"
size="small"
@click="toAllClient">同步到所有客户</el-button>
<el-button type="primary" size="small" @click="saveSettings">保存范围</el-button>
<el-button type="primary" size="small" @click="toAllClient">同步到所有客户</el-button>
</div>
<div>
<el-row :gutter="12">
<el-col v-loading="loading3">
<el-card shadow="hover">
<el-checkbox-group class="t"
v-model.trim="checkedScopes"
@change="roleChange">
<el-checkbox v-for="scope in scopeOptions"
:label="scope.scopeKey"
<el-checkbox-group class="t" v-model.trim="checkedScopes" @change="roleChange">
<el-checkbox v-for="scope in scopeOptions" :label="scope.scopeKey"
:key="scope.scopeKey">{{ scope.scopeName }}</el-checkbox>
</el-checkbox-group>
</el-card>
@ -480,24 +411,30 @@ export default {
.role-flex {
display: flex;
}
.flex1 {
flex: 1;
}
.now-name {
/* display: flex;
justify-content: space-between; */
margin-bottom: 10px;
}
.aui-wrapper .el-card+.el-card {
margin-top: 0;
}
.role-container .el-dialog__body {
padding: 0 20px 20px;
}
.div_duty {
height: 300px;
position: relative;
}
.div_btn {
position: absolute;
bottom: 30px;

115
src/views/modules/workSys/role/role.vue

@ -1,16 +1,9 @@
<template>
<div class="g-main">
<div class="m-search">
<el-form :inline="true"
:model="formData"
ref="ref_searchform"
:label-width="'110px'">
<el-form-item label="角色名称"
prop="name">
<el-input v-model.trim="formData.name"
size="small"
class="list_item_width_1"
clearable
<el-form :inline="true" :model="formData" ref="ref_searchform" :label-width="'110px'">
<el-form-item label="角色名称" prop="name">
<el-input v-model.trim="formData.name" size="small" class="list_item_width_1" clearable
placeholder="请输入角色名称">
</el-input>
</el-form-item>
@ -26,114 +19,56 @@
placeholder="创建时间">
</el-date-picker>
</el-form-item> -->
<el-button style="margin-left:10px"
size="small"
class="diy-button--add"
<el-button style="margin-left:10px" size="small" class="diy-button--add"
@click="handleSearch">查询</el-button>
<el-button style="margin-left:30px"
size="small"
class="diy-button--white"
<el-button style="margin-left:30px" size="small" class="diy-button--white"
@click="resetSearch">重置</el-button>
</el-form>
</div>
<div class="m-table">
<div class="div_btn">
<el-button class="diy-button--add"
size="small"
@click="handleAdd">新增</el-button>
<el-button class="diy-button--add" size="small" @click="handleAdd">新增</el-button>
</div>
<el-table class="table"
ref="ref_table"
:data="tableData"
border
:height="tableHeight"
v-loading="tableLoading"
style="width: 100%">
<el-table-column label="序号"
header-align="center"
align="center"
type="index"
<el-table class="table" ref="ref_table" :data="tableData" border :height="tableHeight"
v-loading="tableLoading" style="width: 100%">
<el-table-column label="序号" header-align="center" align="center" type="index"
width="50"></el-table-column>
<el-table-column prop="name"
header-align="center"
align="center"
label="角色名称"
min-width="100">
<el-table-column prop="name" header-align="center" align="center" label="角色名称" min-width="100">
</el-table-column>
<el-table-column prop="defaultRole"
header-align="center"
align="center"
label="默认角色"
in-width="30">
<el-table-column prop="defaultRole" header-align="center" align="center" label="默认角色" in-width="30">
<template slot-scope="scope">
{{ scope.row.defaultRole == '0' ? 'X' : '√' }}
</template>
</el-table-column>
<el-table-column prop="levelName"
header-align="center"
align="center"
label="级别"
in-width="30">
<el-table-column prop="levelName" header-align="center" align="center" label="级别" in-width="30">
</el-table-column>
<el-table-column prop="remark"
header-align="center"
align="center"
label="备注"
min-width="110">
<el-table-column prop="remark" header-align="center" align="center" label="备注" min-width="110">
</el-table-column>
<el-table-column prop="createdTime"
header-align="center"
align="center"
label="创建时间"
min-width="170">
<el-table-column prop="createdTime" header-align="center" align="center" label="创建时间" min-width="170">
</el-table-column>
<el-table-column label="操作"
fixed="right"
width="140"
header-align="center"
align="center"
<el-table-column label="操作" fixed="right" width="140" header-align="center" align="center"
class="operate">
<template slot-scope="scope">
<el-button v-if="true"
type="text"
class="div-table-button--detail"
size="small"
<el-button v-if="true" type="text" class="div-table-button--detail" size="small"
@click="handleDetail(scope.row)">查看</el-button>
<el-button type="text"
class="div-table-button--edit"
size="small"
<el-button type="text" class="div-table-button--edit" size="small"
@click="handleEdit(scope.row)">修改</el-button>
<el-button v-if="scope.row.defaultRole!=='1'"
type="text"
class="div-table-button--delete "
size="small"
@click="handleDelete(scope.row)">删除</el-button>
<el-button v-if="scope.row.defaultRole !== '1'" type="text" class="div-table-button--delete "
size="small" @click="handleDelete(scope.row)">删除</el-button>
</template>
</el-table-column>
</el-table>
<div>
<el-pagination @size-change="handleSizeChange"
@current-change="handleCurrentChange"
:current-page.sync="pageNo"
:page-sizes="[20, 50, 100, 200]"
:page-size="pageSize"
layout="sizes, prev, pager, next, total"
:total="total">
<el-pagination @size-change="handleSizeChange" @current-change="handleCurrentChange"
:current-page.sync="pageNo" :page-sizes="[20, 50, 100, 200]" :page-size="pageSize"
layout="sizes, prev, pager, next, total" :total="total">
</el-pagination>
</div>
</div>
<!-- 修改弹出框 -->
<el-dialog :visible.sync="formShow"
:close-on-click-modal="false"
:close-on-press-escape="false"
:title="formTitle"
width="850px"
top="5vh"
class="dialog-h"
@closed="diaClose">
<role-form ref="ref_form"
@dialogCancle="diaClose"
@dialogOk="addFormOk"></role-form>
<el-dialog :visible.sync="formShow" :close-on-click-modal="false" :close-on-press-escape="false"
:title="formTitle" width="850px" top="5vh" class="dialog-h" @closed="diaClose">
<role-form ref="ref_form" @dialogCancle="diaClose" @dialogOk="addFormOk"></role-form>
</el-dialog>
</div>
</template>

Loading…
Cancel
Save