commit
This commit is contained in:
+1
-1
@@ -102,7 +102,6 @@ public class ActivityBasicScopeController {
|
|||||||
* @return {@link Result}
|
* @return {@link Result}
|
||||||
*/
|
*/
|
||||||
@At
|
@At
|
||||||
@SaCheckPermission("activity.basic")
|
|
||||||
public Result pageData(@Param("data") ActivityUserScopePageParam pageForm) {
|
public Result pageData(@Param("data") ActivityUserScopePageParam pageForm) {
|
||||||
Sql sql = Sqls.create("""
|
Sql sql = Sqls.create("""
|
||||||
SELECT
|
SELECT
|
||||||
@@ -221,6 +220,7 @@ public class ActivityBasicScopeController {
|
|||||||
return Result.success(new NutMap() {{
|
return Result.success(new NutMap() {{
|
||||||
addv("is_A06", StpUtil.hasRole(RoleConstant.SCHOOL_UNION_ADMIN.name()));
|
addv("is_A06", StpUtil.hasRole(RoleConstant.SCHOOL_UNION_ADMIN.name()));
|
||||||
addv("is_H04", StpUtil.hasRole(RoleConstant.BRANCH_UNION_CHAIRMAN.name()));
|
addv("is_H04", StpUtil.hasRole(RoleConstant.BRANCH_UNION_CHAIRMAN.name()));
|
||||||
|
addv("is_H02", StpUtil.hasRole(RoleConstant.SCHOOL_UNION_CLUB_ADMIN.name()));
|
||||||
addv("is_CLUB_PRESIDENT", StpUtil.hasRole(RoleConstant.CLUB_PRESIDENT.name()));
|
addv("is_CLUB_PRESIDENT", StpUtil.hasRole(RoleConstant.CLUB_PRESIDENT.name()));
|
||||||
addv("is_sysadmin", StpUtil.hasRole(RoleConstant.SYSADMIN.name()));
|
addv("is_sysadmin", StpUtil.hasRole(RoleConstant.SYSADMIN.name()));
|
||||||
addv("unionid", SecurityUtil.getUnionId());
|
addv("unionid", SecurityUtil.getUnionId());
|
||||||
|
|||||||
@@ -57,7 +57,7 @@ public class ClubCommonController {
|
|||||||
@SaCheckLogin
|
@SaCheckLogin
|
||||||
public Result listClubByRole() {
|
public Result listClubByRole() {
|
||||||
Cnd cnd = Cnd.NEW();
|
Cnd cnd = Cnd.NEW();
|
||||||
if (!AuthUtil.hasRoleOr(RoleConstant.SYSADMIN.name(), RoleConstant.SCHOOL_UNION_ADMIN.name())) {
|
if (!AuthUtil.hasRoleOr(RoleConstant.SYSADMIN.name(), RoleConstant.SCHOOL_UNION_ADMIN.name(), RoleConstant.SCHOOL_UNION_CLUB_ADMIN.name())) {
|
||||||
// 报销申请只允许选择当前用户已加入的协会,避免看到未加入的协会数据。
|
// 报销申请只允许选择当前用户已加入的协会,避免看到未加入的协会数据。
|
||||||
List<ClubUser> clubUsers = sysClubService.dao().query(ClubUser.class, Cnd.where("userId", "=", SecurityUtil.getUserId()));
|
List<ClubUser> clubUsers = sysClubService.dao().query(ClubUser.class, Cnd.where("userId", "=", SecurityUtil.getUserId()));
|
||||||
List<String> myClubId = clubUsers.stream().map(ClubUser::getClubId).distinct().toList();
|
List<String> myClubId = clubUsers.stream().map(ClubUser::getClubId).distinct().toList();
|
||||||
|
|||||||
@@ -15,6 +15,7 @@
|
|||||||
placeholder="输入工号或者姓名查询"
|
placeholder="输入工号或者姓名查询"
|
||||||
:remote-method="queryUser"
|
:remote-method="queryUser"
|
||||||
@change="doSearch"
|
@change="doSearch"
|
||||||
|
@clear="doSearch"
|
||||||
style="width: 100%"
|
style="width: 100%"
|
||||||
>
|
>
|
||||||
<el-option
|
<el-option
|
||||||
@@ -150,7 +151,7 @@
|
|||||||
<el-col class="query-content">
|
<el-col class="query-content">
|
||||||
<el-select
|
<el-select
|
||||||
v-model="pageForm.unionIds"
|
v-model="pageForm.unionIds"
|
||||||
:clearable="is_A06 || is_sysadmin"
|
clearable
|
||||||
collapse-tags
|
collapse-tags
|
||||||
filterable
|
filterable
|
||||||
multiple
|
multiple
|
||||||
@@ -183,6 +184,7 @@
|
|||||||
placeholder="请选择角色"
|
placeholder="请选择角色"
|
||||||
style="width: 100%"
|
style="width: 100%"
|
||||||
@change="doSearch"
|
@change="doSearch"
|
||||||
|
@clear="doSearch"
|
||||||
>
|
>
|
||||||
<el-option
|
<el-option
|
||||||
v-for="item in roleList"
|
v-for="item in roleList"
|
||||||
@@ -199,6 +201,7 @@
|
|||||||
placeholder="请选择教代会"
|
placeholder="请选择教代会"
|
||||||
style="width: 100%"
|
style="width: 100%"
|
||||||
@change="doSearch"
|
@change="doSearch"
|
||||||
|
@clear="doSearch"
|
||||||
>
|
>
|
||||||
<el-option
|
<el-option
|
||||||
v-for="item in sessionOptions"
|
v-for="item in sessionOptions"
|
||||||
@@ -213,16 +216,17 @@
|
|||||||
</el-row>
|
</el-row>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<el-row class="query-row" v-if="is_A06 || is_sysadmin || is_H02">
|
<el-row class="query-row" v-if="is_A06 || is_sysadmin || is_H02 || is_CLUB_PRESIDENT">
|
||||||
<el-col class="query-title">社团:</el-col>
|
<el-col class="query-title">社团:</el-col>
|
||||||
<el-col class="query-content">
|
<el-col class="query-content">
|
||||||
<el-select
|
<el-select
|
||||||
v-model="pageForm.clubId"
|
v-model="pageForm.clubId"
|
||||||
:clearable="is_A06 || is_sysadmin || (is_H04 && is_H02)"
|
clearable
|
||||||
filterable
|
filterable
|
||||||
placeholder="请选择社团"
|
placeholder="请选择社团"
|
||||||
style="width: 100%"
|
style="width: 100%"
|
||||||
@change="doSearch"
|
@change="doSearch"
|
||||||
|
@clear="doSearch"
|
||||||
>
|
>
|
||||||
<el-option
|
<el-option
|
||||||
v-for="item in clubOptions"
|
v-for="item in clubOptions"
|
||||||
@@ -243,6 +247,7 @@
|
|||||||
placeholder="请选择活动组别范围之外的人员"
|
placeholder="请选择活动组别范围之外的人员"
|
||||||
style="width: 100%"
|
style="width: 100%"
|
||||||
@change="handleActivityGroupChange"
|
@change="handleActivityGroupChange"
|
||||||
|
@clear="handleActivityGroupChange('')"
|
||||||
>
|
>
|
||||||
<el-option
|
<el-option
|
||||||
v-for="item in activityGroupList2"
|
v-for="item in activityGroupList2"
|
||||||
@@ -485,6 +490,9 @@ module.exports = {
|
|||||||
is_H02() {
|
is_H02() {
|
||||||
return this.roleData.is_H02
|
return this.roleData.is_H02
|
||||||
},
|
},
|
||||||
|
is_CLUB_PRESIDENT() {
|
||||||
|
return this.roleData.is_CLUB_PRESIDENT
|
||||||
|
},
|
||||||
is_sysadmin() {
|
is_sysadmin() {
|
||||||
return this.roleData.is_sysadmin
|
return this.roleData.is_sysadmin
|
||||||
},
|
},
|
||||||
@@ -509,7 +517,8 @@ module.exports = {
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
getInitialUnionIds() {
|
getInitialUnionIds() {
|
||||||
if ((this.is_sysadmin || this.is_A06 || this.is_H02) === false && this.is_H04 === true && this.unionid) {
|
// 分工会和社团双身份默认不带分工会筛选,保证初始列表走后端并集逻辑。
|
||||||
|
if ((this.is_sysadmin || this.is_A06 || this.is_H02 || this.is_CLUB_PRESIDENT) === false && this.is_H04 === true && this.unionid) {
|
||||||
return [this.unionid]
|
return [this.unionid]
|
||||||
}
|
}
|
||||||
return []
|
return []
|
||||||
@@ -711,14 +720,15 @@ module.exports = {
|
|||||||
async created() {
|
async created() {
|
||||||
this.listSession()
|
this.listSession()
|
||||||
await this.getRolesAndUnion()
|
await this.getRolesAndUnion()
|
||||||
this.clubOptions = await this.$businessTool.listClubByRole()
|
this.clubOptions = (this.is_sysadmin || this.is_A06)
|
||||||
|
? await this.$businessTool.listClubByRole()
|
||||||
|
: this.is_CLUB_PRESIDENT
|
||||||
|
? await this.$businessTool.listManageClubByRole()
|
||||||
|
: await this.$businessTool.listClubByRole()
|
||||||
this.unions = (this.is_sysadmin || this.is_A06 || this.is_H02)
|
this.unions = (this.is_sysadmin || this.is_A06 || this.is_H02)
|
||||||
? await this.$businessTool.listUnion()
|
? await this.$businessTool.listUnion()
|
||||||
: this.$businessTool.listUnion(this.unionid)
|
: this.$businessTool.listUnion(this.unionid)
|
||||||
this.pageForm.unionIds = this.getInitialUnionIds()
|
this.pageForm.unionIds = this.getInitialUnionIds()
|
||||||
if (!this.is_H04 && this.is_H02 && this.clubOptions.length > 0) {
|
|
||||||
this.$set(this.pageForm, "clubId", this.clubOptions[0].id)
|
|
||||||
}
|
|
||||||
await this.getActivityGroup()
|
await this.getActivityGroup()
|
||||||
this.personTypeOptions = await this.$businessTool.getDictOptions("USER_PERSON_TYPE")
|
this.personTypeOptions = await this.$businessTool.getDictOptions("USER_PERSON_TYPE")
|
||||||
this.userStateOptions = await this.$businessTool.getDictOptions("USER_STATE")
|
this.userStateOptions = await this.$businessTool.getDictOptions("USER_STATE")
|
||||||
|
|||||||
Reference in New Issue
Block a user