Commit 7fafea92 authored by xhx's avatar xhx

接口参数调整

parent 7f979919
...@@ -21,17 +21,17 @@ ...@@ -21,17 +21,17 @@
{{ 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>
<!-- 操作 --> <!-- 操作 -->
...@@ -74,7 +74,7 @@ import Vue, { PropType } from "vue" ...@@ -74,7 +74,7 @@ import Vue, { PropType } from "vue"
import { firstLevelManager } from '@/mock/index' import { firstLevelManager } from '@/mock/index'
import { staff } from '@/types/staff' import { staff } from '@/types/staff'
import { eUserStatusAction, eUserStatus } 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'
...@@ -149,17 +149,22 @@ export default Vue.extend({ ...@@ -149,17 +149,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 = {
...@@ -171,7 +176,12 @@ export default Vue.extend({ ...@@ -171,7 +176,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({
...@@ -234,25 +244,28 @@ export default Vue.extend({ ...@@ -234,25 +244,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){
...@@ -262,18 +275,20 @@ export default Vue.extend({ ...@@ -262,18 +275,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