Commit 967bb44c authored by chenqikuai's avatar chenqikuai

Merge branch 'dev' of gitlab.33.cn:CassiniatSaturn/fns_backend into dev

parents ba4fb74e 7fafea92
...@@ -21,34 +21,35 @@ ...@@ -21,34 +21,35 @@
{{ record.status | filterStatus }} {{ record.status | filterStatus }}
</span> </span>
<!-- 二级分行管理员 --> <!-- 二级分行管理员 -->
<span slot="secondaryManager" slot-scope="text,record"> <a @click="getSecondaryManageList(record.level, 1)">查看</a> </span> <span slot="secondaryManager" slot-scope="text,record"> <a @click="getSecondaryManageList(record.level, record.uuid, 1)">查看</a> </span>
<!-- 一级支行管理员 --> <!-- 一级支行管理员 -->
<span slot="firstSubManager" slot-scope="text,record"> <a @click="getfirstSubManageList(record.level, 1)">查看</a> </span> <span slot="firstSubManager" slot-scope="text,record"> <a @click="getfirstSubManageList(record.level, record.uuid, 1)">查看</a> </span>
<!-- 一级支行客户经理(无) --> <!-- 一级支行客户经理(无) -->
<span slot="firstSubClientManager" slot-scope="text,record"> <a @click="getFirstSubClientManagerList(record.level)">查看</a> </span> <span slot="firstSubClientManager" slot-scope="text,record"> <a @click="getFirstSubClientManagerList(record.level, record.uuid)">查看</a> </span>
<!-- 一级支行客户 --> <!-- 一级支行客户 -->
<span slot="firstSubClient" slot-scope="text,record"> <a @click="getFirstSubClientList(record.uuid)">查看</a> </span> <span slot="firstSubClient" slot-scope="text,record"> <a @click="getFirstSubClientList(record.uuid)">查看</a> </span>
<!-- 二级支行管理员 --> <!-- 二级支行管理员 -->
<span slot="secondarySubManager" slot-scope="text,record"> <a @click="getSecondarySubManagerList(record.level, 1)">查看</a> </span> <span slot="secondarySubManager" slot-scope="text,record"> <a @click="getSecondarySubManagerList(record.level, record.uuid, 1)">查看</a> </span>
<!-- 二级支行客户经理 --> <!-- 二级支行客户经理 -->
<span slot="secondarySubClientManager" slot-scope="text,record"> <a @click="getSecondarySubClientManageList(record.level)">查看</a> </span> <span slot="secondarySubClientManager" slot-scope="text,record"> <a @click="getSecondarySubClientManageList(record.level, record.uuid)">查看</a> </span>
<!-- 二级支行客户 --> <!-- 二级支行客户 -->
<span slot="secondarySubClient" slot-scope="text,record"> <a @click="getSecondarySubClientList(record.uuid)">查看</a> </span> <span slot="secondarySubClient" slot-scope="text,record"> <a @click="getSecondarySubClientList(record.uuid)">查看</a> </span>
<!-- 操作 --> <!-- 操作 -->
<p slot="action" slot-scope="text,record" > <p slot="action" slot-scope="text,record" >
<span v-if="record.state!='已禁用'"> <a @click="deploy(record)">调配</a>
<a @click="deploy(record)">调配</a> <span v-if="record.status===tableStatus.disable_notOnPosition || record.status===tableStatus.disable_noPosition">
<a-divider type="vertical" /> <a-divider type="vertical" />
<a @click="() => enable(record.uuid)">启用</a> <a @click="() => enable(record.uuid)">启用</a>
</span> </span>
<span v-else> <span v-if="record.status===tableStatus.enable_notOnPosition || record.status===tableStatus.enable_onPosition">
<a-divider type="vertical" />
<a @click="disable(record.uuid)">禁用</a> <a @click="disable(record.uuid)">禁用</a>
</span> </span>
<span v-if="record.state==('启用中/在岗')"> <span v-if="record.status===tableStatus.disable_noPosition || record.status === tableStatus.enable_onPosition">
<a-divider type="vertical" /> <a-divider type="vertical" />
<a @confirm="() => offJob(record.uuid)">不在岗</a> <a @click="offJob(record.uuid)">不在岗</a>
</span> </span>
<span v-else-if="record.state==('启用中/不在岗')"> <span v-if="record.status===tableStatus.disable_notOnPosition || record.status === tableStatus.enable_notOnPosition">
<a-divider type="vertical" /> <a-divider type="vertical" />
<a @click="inJob(record.uuid)">在岗</a> <a @click="inJob(record.uuid)">在岗</a>
</span> </span>
...@@ -71,9 +72,9 @@ ...@@ -71,9 +72,9 @@
<script lang="ts"> <script lang="ts">
import Vue, { PropType } from "vue" import Vue, { PropType } from "vue"
import { firstLevelManager } from '@/mock/index' import { firstLevelManager } from '@/mock/index'
import { iStaffQueryResItem, staff } from '@/types/staff' import { staff , iStaffQueryResItem} from '@/types/staff'
import { eUserStatusAction } from '@/types/user' import { eUserStatusAction, eUserStatus } from '@/types/user'
import { eRole } from "@/types/role" import { eRole, eNewRoleRelatedToBackEnd } from "@/types/role"
import { eLevel } from "@/types/level" import { eLevel } from "@/types/level"
import { getColumns } from '@/const/columns/userManagerCol' import { getColumns } from '@/const/columns/userManagerCol'
import { userModal } from './const' import { userModal } from './const'
...@@ -138,6 +139,9 @@ export default Vue.extend({ ...@@ -138,6 +139,9 @@ export default Vue.extend({
}, },
dataSource() { dataSource() {
return this.$store.state.platformUserManagement.list return this.$store.state.platformUserManagement.list
},
tableStatus() {
return eUserStatus
} }
}, },
methods:{ methods:{
...@@ -146,17 +150,22 @@ export default Vue.extend({ ...@@ -146,17 +150,22 @@ export default Vue.extend({
}), }),
...mapActions('platformUserManagement', { ...mapActions('platformUserManagement', {
platformQuery: 'queryUser', platformQuery: 'queryUser',
platform: 'queryNext'
}), }),
getRouteQuery() { getRouteQuery() {
if (this.$route.query.rankVal) { if (this.$route.query.rankVal) {
const keys = JSON.parse(this.$route.query.rankVal as string) const keys = JSON.parse(this.$route.query.rankVal as string)
const level = this.$route.query.level const level = this.$route.query.level
const uuid = this.$route.query.uuid
const role = this.$route.query.role
this.params = { this.params = {
firstBranch: +keys[0]?.value || undefined, firstBranch: +keys[0]?.value || undefined,
firstSubBranch: +keys[2]?.value || undefined, firstSubBranch: +keys[2]?.value || undefined,
secondBranch: +keys[1]?.value || undefined, secondBranch: +keys[1]?.value || undefined,
secondSubBranch: +keys[3]?.value || undefined, secondSubBranch: +keys[3]?.value || undefined,
level level,
uuid,
role
} }
} else { } else {
this.params = { this.params = {
...@@ -168,7 +177,12 @@ export default Vue.extend({ ...@@ -168,7 +177,12 @@ export default Vue.extend({
this.platformSave({ this.platformSave({
...this.params ...this.params
}) })
this.platformQuery() const uuid = this.$route.query.uuid
if (uuid) {
this.platform()
} else {
this.platformQuery()
}
}, },
changeHandle(e: any) { changeHandle(e: any) {
this.platformSave({ this.platformSave({
...@@ -256,25 +270,28 @@ export default Vue.extend({ ...@@ -256,25 +270,28 @@ export default Vue.extend({
this.show = false this.show = false
}, },
// 二级分行管理员 // 二级分行管理员
getSecondaryManageList(key:string){ getSecondaryManageList(key:string, uuid: string, count: number){
const role = count === 1 ? eNewRoleRelatedToBackEnd.Management : eNewRoleRelatedToBackEnd.ACM
this.platformSave({ this.platformSave({
page: 1 page: 1
}) })
this.$router.push({name:'secondary',query:{level: key, rankVal: this.$route.query.rankVal}}) this.$router.push({name:'secondary',query:{level: key, rankVal: this.$route.query.rankVal, uuid, role}})
}, },
// 一级支行管理员 // 一级支行管理员
getfirstSubManageList(key:string){ getfirstSubManageList(key:string, uuid: string, count: number){
const role = count === 1 ? eNewRoleRelatedToBackEnd.Management : eNewRoleRelatedToBackEnd.ACM
this.platformSave({ this.platformSave({
page: 1 page: 1
}) })
this.$router.push({name:'firstSub',query:{level: key, rankVal: this.$route.query.rankVal}}) this.$router.push({name:'firstSub',query:{level: key, rankVal: this.$route.query.rankVal, uuid, role}})
}, },
// 一级支行客户经理(无) // 一级支行客户经理
getFirstSubClientManagerList(key:string){ getFirstSubClientManagerList(key:string,uuid: string, count: number){
const role = count === 1 ? eNewRoleRelatedToBackEnd.Management : eNewRoleRelatedToBackEnd.ACM
this.platformSave({ this.platformSave({
page: 1 page: 1
}) })
this.$router.push({name:'firstSubClientManager',query:{level: key, rankVal: this.$route.query.rankVal}}) this.$router.push({name:'firstSubClientManager',query:{level: key, rankVal: this.$route.query.rankVal, uuid, role}})
}, },
// 一级支行客户 // 一级支行客户
getFirstSubClientList(uuid:string){ getFirstSubClientList(uuid:string){
...@@ -284,18 +301,20 @@ export default Vue.extend({ ...@@ -284,18 +301,20 @@ export default Vue.extend({
this.$router.push({name:'firstSubClient',query:{uuid}}) this.$router.push({name:'firstSubClient',query:{uuid}})
}, },
// 二级支行管理员 // 二级支行管理员
getSecondarySubManagerList(key:string){ getSecondarySubManagerList(key:string, uuid: string, count: number){
const role = count === 1 ? eNewRoleRelatedToBackEnd.Management : eNewRoleRelatedToBackEnd.ACM
this.platformSave({ this.platformSave({
page: 1 page: 1
}) })
this.$router.push({name:'secondarySub',query:{level: key, rankVal: this.$route.query.rankVal}}) this.$router.push({name:'secondarySub',query:{level: key, rankVal: this.$route.query.rankVal, uuid, role}})
}, },
// 二级支行客户经理 // 二级支行客户经理
getSecondarySubClientManageList(key:string){ getSecondarySubClientManageList(key:string, uuid:string, count: number){
const role = count === 1 ? eNewRoleRelatedToBackEnd.Management : eNewRoleRelatedToBackEnd.ACM
this.platformSave({ this.platformSave({
page: 1 page: 1
}) })
this.$router.push({name:'secondarySubClientManager',query:{level: key, rankVal: this.$route.query.rankVal}}) this.$router.push({name:'secondarySubClientManager',query:{level: key, rankVal: this.$route.query.rankVal, uuid, role}})
}, },
// 二级支行客户 // 二级支行客户
getSecondarySubClientList(uuid:string){ getSecondarySubClientList(uuid:string){
......
...@@ -154,13 +154,24 @@ export default class StaffService { ...@@ -154,13 +154,24 @@ export default class StaffService {
}) })
} }
getNextLevel(data: {
uuid: string,
role: string
}) {
return baseAxios({
url: '/staff/next_level',
method: 'get',
params: data
})
}
getStaffList(data: { getStaffList(data: {
page: number, page: number,
page_size: number, page_size: number,
uuid: string uuid: string
}) { }) {
return baseAxios({ return baseAxios({
url: '/staff/users', url: '/staff/query/users',
method: 'get', method: 'get',
params: data params: data
}) })
......
...@@ -22,6 +22,8 @@ export default <Module<iPlatformModuleState, {}>>{ ...@@ -22,6 +22,8 @@ export default <Module<iPlatformModuleState, {}>>{
userName: '', userName: '',
total: 0, total: 0,
loading: false, loading: false,
uuid: '',
role: ''
}, },
mutations: { mutations: {
save(state, payload) { save(state, payload) {
...@@ -72,6 +74,21 @@ export default <Module<iPlatformModuleState, {}>>{ ...@@ -72,6 +74,21 @@ export default <Module<iPlatformModuleState, {}>>{
} }
state.loading = false state.loading = false
}) })
},
async queryNext({ state, commit }, payload) {
state.loading = true
StaffService.getInstance().getNextLevel({
uuid: state.uuid,
role: state.role
}).then(res => {
if (res.code === 200) {
commit('save', {
list: res.data.item,
total: res.data.total
})
}
state.loading = false
})
} }
}, },
} }
...@@ -31,5 +31,7 @@ export interface iPlatformModuleState { ...@@ -31,5 +31,7 @@ export interface iPlatformModuleState {
start: number | undefined start: number | undefined
userName: string, userName: string,
total: number total: number
loading: boolean loading: boolean,
uuid: string,
role: string
} }
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment