提交
This commit is contained in:
@@ -55,16 +55,7 @@ public class ApplyController {
|
||||
@ViReturn
|
||||
public Object doAdd(@Param("activityBx") ActivityBx activityBx, @Param("sign") String sign) {
|
||||
activityBx.setYear(Calendar.getInstance().get(Calendar.YEAR));
|
||||
if (ShiroUtil.hasAnyRoles(new String[]{"xghhdwy", "A06"}) && activityBx.getActivity_type().equals(2)) {
|
||||
activityBx.setState_id("1020");
|
||||
activityBx.setActivity_type(2);
|
||||
} else if (ShiroUtil.hasAnyRoles(new String[]{"H02"}) && activityBx.getActivity_type().equals(3)) {
|
||||
activityBx.setState_id("1020");
|
||||
activityBx.setActivity_type(3);
|
||||
} else {
|
||||
activityBx.setState_id("1010");
|
||||
activityBx.setActivity_type(1);
|
||||
}
|
||||
activityBx.setState_id("1020");
|
||||
activityBx.setApply_time(DateUtil.getDate());
|
||||
activityBx.setUser_id(ShiroUtil.getPrincipalProperty("id").toString());
|
||||
if (Strings.isNotBlank(sign)) {
|
||||
|
||||
@@ -49,7 +49,7 @@ import java.util.stream.Collectors;
|
||||
*/
|
||||
@IocBean
|
||||
@Ok("json")
|
||||
@At("/platform/jf/activity_bx/recording")
|
||||
@At("/platform/jf/activity_bx/reimbursement")
|
||||
public class ReimbursementCon {
|
||||
|
||||
|
||||
@@ -68,8 +68,8 @@ public class ReimbursementCon {
|
||||
private ActivityFileService activityFileService;
|
||||
|
||||
@At("")
|
||||
@Ok("beetl:/platform/jf/activitybx/recording.html")
|
||||
@RequiresPermissions("sys.jf.activity_bx.recording")
|
||||
@Ok("beetl:/platform/jf/activitybx/reimbursement.html")
|
||||
@RequiresPermissions("sys.jf.activity_bx.reimbursement")
|
||||
public void index() {
|
||||
}
|
||||
|
||||
@@ -120,91 +120,16 @@ public class ReimbursementCon {
|
||||
bxr.unionname bxr_unionname,
|
||||
bxr.unioncode,
|
||||
state.state_name,
|
||||
state.state_color,(
|
||||
CASE
|
||||
state.state_id
|
||||
WHEN @state1 THEN
|
||||
(
|
||||
SELECT
|
||||
GROUP_CONCAT( u.username )
|
||||
FROM
|
||||
sys_user_role sur
|
||||
LEFT JOIN sys_user u ON sur.userId = u.id
|
||||
WHERE
|
||||
sur.roleId = @role1
|
||||
)
|
||||
WHEN @state2 THEN
|
||||
(
|
||||
SELECT
|
||||
GROUP_CONCAT( u.username )
|
||||
FROM
|
||||
sys_user_role sur
|
||||
LEFT JOIN sys_user u ON sur.userId = u.id
|
||||
WHERE
|
||||
sur.unionid = bxr.unionid
|
||||
AND sur.roleId = @role2
|
||||
)
|
||||
WHEN @state3 THEN
|
||||
(
|
||||
SELECT
|
||||
GROUP_CONCAT( u.username )
|
||||
FROM
|
||||
sys_user_role sur
|
||||
LEFT JOIN sys_user u ON sur.userId = u.id
|
||||
WHERE
|
||||
sur.roleId = @role3
|
||||
)
|
||||
WHEN @state4 THEN
|
||||
(
|
||||
SELECT
|
||||
GROUP_CONCAT( u.username )
|
||||
FROM
|
||||
sys_user_role sur
|
||||
LEFT JOIN sys_user u ON sur.userId = u.id
|
||||
WHERE
|
||||
sur.roleId = @role4
|
||||
)
|
||||
WHEN @state5 THEN
|
||||
(
|
||||
SELECT
|
||||
GROUP_CONCAT( u.username )
|
||||
FROM
|
||||
sys_user_role sur
|
||||
LEFT JOIN sys_user u ON sur.userId = u.id
|
||||
WHERE
|
||||
sur.roleId = @role5
|
||||
)
|
||||
WHEN @state6 THEN
|
||||
(
|
||||
SELECT
|
||||
GROUP_CONCAT( u.username )
|
||||
FROM
|
||||
sys_user_role sur
|
||||
LEFT JOIN sys_user u ON sur.userId = u.id
|
||||
WHERE
|
||||
sur.roleId = @role6
|
||||
) ELSE NULL
|
||||
END
|
||||
) shrname
|
||||
state.state_color,
|
||||
abs.`name` absName
|
||||
FROM
|
||||
activity_bx bx
|
||||
LEFT JOIN `user` bxr ON bx.user_id = bxr.id
|
||||
LEFT JOIN state state ON state.state_id = bx.state_id $condition
|
||||
LEFT JOIN state state ON state.state_id = bx.state_id
|
||||
LEFT JOIN activity_basic_settings abs ON abs.`code` = bx.projectTypeCode
|
||||
$condition
|
||||
""");
|
||||
|
||||
sql.setParam("role1", Roles.CLUB_FZR);
|
||||
sql.setParam("role2", Roles.UNION_MANGER);
|
||||
sql.setParam("role3", Roles.XGHKJ);
|
||||
sql.setParam("role4", Roles.GH_WYH_FZX);
|
||||
sql.setParam("role5", Roles.GH_WYH_CWFZX);
|
||||
sql.setParam("role6", Roles.XGHCN);
|
||||
sql.setParam("state1", 1000);
|
||||
sql.setParam("state2", 1010);
|
||||
sql.setParam("state3", 1020);
|
||||
sql.setParam("state4", 1030);
|
||||
sql.setParam("state5", 1040);
|
||||
sql.setParam("state6", 1050);
|
||||
|
||||
|
||||
Cnd cnd = Cnd.NEW();
|
||||
if (!ShiroUtil.hasAnyRoles("sysadmin")) {
|
||||
|
||||
@@ -30,11 +30,22 @@ public class ActivityBx {
|
||||
@ColDefine(type = ColType.VARCHAR, width = 200)
|
||||
private String user_name;
|
||||
|
||||
|
||||
@Column
|
||||
@Comment("联系方式")
|
||||
@ColDefine(type = ColType.VARCHAR, width = 200)
|
||||
private String mobile;
|
||||
|
||||
@Column
|
||||
@Comment("申请时间")
|
||||
@ColDefine(type = ColType.VARCHAR, width = 30)
|
||||
private String apply_time;
|
||||
|
||||
@Column
|
||||
@Comment("申请类型(1.经费申报2.报销申请)")
|
||||
@ColDefine(type = ColType.VARCHAR, width = 30)
|
||||
private String apply_type;
|
||||
|
||||
@Column
|
||||
@Comment("用户id")
|
||||
@ColDefine(type = ColType.VARCHAR, width = 32)
|
||||
@@ -75,6 +86,11 @@ public class ActivityBx {
|
||||
@ColDefine(type = ColType.TEXT)
|
||||
private String activity_content;
|
||||
|
||||
@Column
|
||||
@Comment("活动安排")
|
||||
@ColDefine(type = ColType.TEXT)
|
||||
private String activity_arrange;
|
||||
|
||||
@Column
|
||||
@Comment("报销事由")
|
||||
@ColDefine(type = ColType.TEXT)
|
||||
|
||||
Reference in New Issue
Block a user