多语言支持
This commit is contained in:
parent
703de629f9
commit
f51fd4713e
|
|
@ -118,9 +118,9 @@ public class JobBrowserService extends BrowserService {
|
|||
Map<String, List<SearchConditionItem>> apiDatas = new HashMap<>();
|
||||
List<SearchConditionItem> conditions = new ArrayList<>();
|
||||
// 编号
|
||||
SearchConditionItem jobNoItem = OrganizationFormItemUtil.inputItem(user, 2, 16, 2, 50, "编号", "jobNo");
|
||||
SearchConditionItem jobNoItem = OrganizationFormItemUtil.inputItem(user, 2, 16, 2, 50, 547118, "jobNo");
|
||||
// 名称
|
||||
SearchConditionItem jobNameItem = OrganizationFormItemUtil.inputItem(user, 2, 16, 2, 50, "名称", "jobName");
|
||||
SearchConditionItem jobNameItem = OrganizationFormItemUtil.inputItem(user, 2, 16, 2, 50, 547141, "jobName");
|
||||
// 所属分部
|
||||
SearchConditionItem parentCompBrowserItem = OrganizationFormItemUtil.browserItem(user, 2, 16, 2, false, "所属分部", "164", "ecCompany", "");
|
||||
// 所属部门
|
||||
|
|
|
|||
|
|
@ -7,6 +7,7 @@ import java.lang.annotation.*;
|
|||
@Retention(RetentionPolicy.RUNTIME)
|
||||
@Documented
|
||||
public @interface TableTitle {
|
||||
int labelId() default -1;
|
||||
String title();
|
||||
String dataIndex();
|
||||
String key();
|
||||
|
|
|
|||
|
|
@ -2,7 +2,6 @@ package com.engine.organization.entity.company.dto;
|
|||
|
||||
import com.engine.organization.annotation.OrganizationTable;
|
||||
import com.engine.organization.annotation.TableTitle;
|
||||
import com.engine.organization.entity.department.dto.DepartmentListDTO;
|
||||
import lombok.AllArgsConstructor;
|
||||
import lombok.Builder;
|
||||
import lombok.Data;
|
||||
|
|
@ -35,13 +34,13 @@ public class CompListDTO {
|
|||
/**
|
||||
* 名称
|
||||
*/
|
||||
@TableTitle(title = "名称", dataIndex = "subCompanyDesc", key = "subCompanyDesc")
|
||||
@TableTitle(labelId = 547141, title = "名称", dataIndex = "subCompanyDesc", key = "subCompanyDesc")
|
||||
private String subCompanyDesc;
|
||||
|
||||
/**
|
||||
* 编号
|
||||
*/
|
||||
@TableTitle(title = "编号", dataIndex = "subCompanyCode", key = "subCompanyCode")
|
||||
@TableTitle(labelId = 547118, title = "编号", dataIndex = "subCompanyCode", key = "subCompanyCode")
|
||||
private String subCompanyCode;
|
||||
|
||||
/**
|
||||
|
|
@ -65,7 +64,7 @@ public class CompListDTO {
|
|||
/**
|
||||
* 禁用标记
|
||||
*/
|
||||
@TableTitle(title = "启用", dataIndex = "canceled", key = "canceled")
|
||||
@TableTitle(labelId = 547186, title = "启用", dataIndex = "canceled", key = "canceled")
|
||||
private Integer canceled;
|
||||
|
||||
/**
|
||||
|
|
|
|||
|
|
@ -36,13 +36,13 @@ public class DepartmentListDTO {
|
|||
/**
|
||||
* 名称
|
||||
*/
|
||||
@TableTitle(title = "名称", dataIndex = "departmentMark", key = "departmentMark", width = "200")
|
||||
@TableTitle(labelId = 547141, title = "名称", dataIndex = "departmentMark", key = "departmentMark", width = "200")
|
||||
private String departmentMark;
|
||||
|
||||
/**
|
||||
* 编号
|
||||
*/
|
||||
@TableTitle(title = "编号", dataIndex = "departmentCode", key = "departmentCode")
|
||||
@TableTitle(labelId = 547118, title = "编号", dataIndex = "departmentCode", key = "departmentCode")
|
||||
private String departmentCode;
|
||||
|
||||
/**
|
||||
|
|
@ -82,7 +82,7 @@ public class DepartmentListDTO {
|
|||
/**
|
||||
* 禁用标记
|
||||
*/
|
||||
@TableTitle(title = "启用", dataIndex = "canceled", key = "canceled")
|
||||
@TableTitle(labelId = 547186, title = "启用", dataIndex = "canceled", key = "canceled")
|
||||
private int canceled;
|
||||
/**
|
||||
* 操作列
|
||||
|
|
|
|||
|
|
@ -26,7 +26,7 @@ public class SingleDeptTreeVO {
|
|||
|
||||
private Integer id;
|
||||
|
||||
@TableTitle(title = "编号", dataIndex = "departmentCode", key = "departmentCode")
|
||||
@TableTitle(labelId = 547118, title = "编号", dataIndex = "departmentCode", key = "departmentCode")
|
||||
private String departmentCode;
|
||||
|
||||
@TableTitle(title = "部门名称", dataIndex = "departmentMark", key = "departmentMark")
|
||||
|
|
|
|||
|
|
@ -34,8 +34,8 @@ import lombok.NoArgsConstructor;
|
|||
sortway = "asc",
|
||||
primarykey = "id",
|
||||
operates = {
|
||||
@OrganizationTableOperate(index = "0", text = "编辑"),
|
||||
@OrganizationTableOperate(index = "1", text = "删除")
|
||||
@OrganizationTableOperate(index = "0", labelId = 547132, text = "编辑"),
|
||||
@OrganizationTableOperate(index = "1", labelId = 547135, text = "删除")
|
||||
},
|
||||
tableType = WeaTableType.CHECKBOX
|
||||
)
|
||||
|
|
|
|||
|
|
@ -1,67 +0,0 @@
|
|||
package com.engine.organization.entity.hrmresource.vo;
|
||||
|
||||
import com.cloudstore.eccom.pc.table.WeaTableType;
|
||||
import com.engine.organization.annotation.OrganizationTable;
|
||||
import com.engine.organization.annotation.OrganizationTableColumn;
|
||||
import com.engine.organization.annotation.OrganizationTableOperate;
|
||||
import lombok.AllArgsConstructor;
|
||||
import lombok.Builder;
|
||||
import lombok.Data;
|
||||
import lombok.NoArgsConstructor;
|
||||
|
||||
import java.util.Date;
|
||||
|
||||
@Data
|
||||
@Builder
|
||||
@NoArgsConstructor
|
||||
@AllArgsConstructor
|
||||
@OrganizationTable(pageId = "8df45b09-0cda-4f57-a93a-ca9f96a4c111",
|
||||
fields = "t.id," +
|
||||
"t.name," +
|
||||
"t.basic_fields," +
|
||||
"t.personal_fields," +
|
||||
"t.work_fields," +
|
||||
"t.isused," +
|
||||
"t.creator," +
|
||||
"t.create_time," +
|
||||
"t.update_time",
|
||||
fromSql = "FROM jcl_org_custom_template t ",
|
||||
orderby = "id",
|
||||
sortway = "asc",
|
||||
primarykey = "id",
|
||||
operates = {
|
||||
@OrganizationTableOperate(index = "0", text = "编辑"),
|
||||
@OrganizationTableOperate(index = "1", text = "另存为"),
|
||||
@OrganizationTableOperate(index = "2", text = "删除")
|
||||
},
|
||||
tableType = WeaTableType.CHECKBOX
|
||||
)
|
||||
public class JclOrgCustomTemplateVO {
|
||||
|
||||
@OrganizationTableColumn(column = "id", display = false)
|
||||
private Integer id;
|
||||
|
||||
@OrganizationTableColumn(text = "模板名称", width = "30%", column = "name")
|
||||
private String name;
|
||||
|
||||
@OrganizationTableColumn(column = "basic_fields", display = false)
|
||||
private String basicFields;
|
||||
|
||||
@OrganizationTableColumn(column = "personal_fields", display = false)
|
||||
private String personalFields;
|
||||
|
||||
@OrganizationTableColumn(column = "work_fields", display = false)
|
||||
private String workFields;
|
||||
|
||||
@OrganizationTableColumn(column = "isused", display = false)
|
||||
private Integer isUsed;
|
||||
|
||||
@OrganizationTableColumn(column = "creator", display = false)
|
||||
private Integer creator;
|
||||
|
||||
@OrganizationTableColumn(text = "创建时间",column = "create_time", width = "30%")
|
||||
private Date createTime;
|
||||
|
||||
@OrganizationTableColumn(text = "更新时间",column = "update_time", display = false)
|
||||
private Date updateTime;
|
||||
}
|
||||
|
|
@ -32,8 +32,8 @@ import lombok.NoArgsConstructor;
|
|||
sortway = "asc",
|
||||
primarykey = "fid",
|
||||
operates = {
|
||||
@OrganizationTableOperate(index = "0", text = "编辑"),
|
||||
@OrganizationTableOperate(index = "1", text = "删除"),
|
||||
@OrganizationTableOperate(index = "0", labelId = 547132, text = "编辑"),
|
||||
@OrganizationTableOperate(index = "1", labelId = 547135, text = "删除"),
|
||||
@OrganizationTableOperate(index = "2", text = "恢复")
|
||||
},
|
||||
tableType = WeaTableType.CHECKBOX,
|
||||
|
|
@ -54,13 +54,13 @@ public class ResourceBasicInfoVO {
|
|||
/**
|
||||
* 编号
|
||||
*/
|
||||
@OrganizationTableColumn(text = "编号", width = "20%", column = "fno", orderkey = "fno")
|
||||
@OrganizationTableColumn(labelId = 547118, text = "编号", width = "20%", column = "fno", orderkey = "fno")
|
||||
private String fNo;
|
||||
|
||||
/**
|
||||
* 名称
|
||||
*/
|
||||
@OrganizationTableColumn(text = "名称", width = "20%", column = "fname")
|
||||
@OrganizationTableColumn(labelId = 547141, text = "名称", width = "20%", column = "fname")
|
||||
private String fName;
|
||||
|
||||
/**
|
||||
|
|
|
|||
|
|
@ -34,12 +34,12 @@ public class JobListDTO {
|
|||
/**
|
||||
* 名称
|
||||
*/
|
||||
@TableTitle(title = "名称", dataIndex = "jobTitleName", key = "jobTitleName", width = "150")
|
||||
@TableTitle(labelId = 547141, title = "名称", dataIndex = "jobTitleName", key = "jobTitleName", width = "150")
|
||||
private String jobTitleName;
|
||||
/**
|
||||
* 编号
|
||||
*/
|
||||
@TableTitle(title = "编号", dataIndex = "jobNo", key = "jobNo")
|
||||
@TableTitle(labelId = 547118, title = "编号", dataIndex = "jobNo", key = "jobNo")
|
||||
private String jobNo;
|
||||
/**
|
||||
* 所属分部
|
||||
|
|
|
|||
|
|
@ -28,8 +28,8 @@ import lombok.NoArgsConstructor;
|
|||
sortway = "asc",
|
||||
primarykey = "id",
|
||||
operates = {
|
||||
@OrganizationTableOperate(index = "0", text = "编辑"),
|
||||
@OrganizationTableOperate(index = "1", text = "删除")
|
||||
@OrganizationTableOperate(index = "0", labelId = 547132, text = "编辑"),
|
||||
@OrganizationTableOperate(index = "1", labelId = 547135, text = "删除")
|
||||
},
|
||||
tableType = WeaTableType.CHECKBOX
|
||||
)
|
||||
|
|
@ -38,7 +38,7 @@ public class JobBrowserVO {
|
|||
@OrganizationTableColumn(text = "标识", width = "25%", column = "id", display = false)
|
||||
private Long id;
|
||||
|
||||
@OrganizationTableColumn(text = "编号", width = "25%", column = "job_no")
|
||||
@OrganizationTableColumn(labelId = 547118, text = "编号", width = "25%", column = "job_no")
|
||||
private String jobNo;
|
||||
|
||||
@OrganizationTableColumn(text = "岗位名称", width = "25%", column = "name")
|
||||
|
|
|
|||
|
|
@ -26,7 +26,7 @@ public class SingleJobTreeVO {
|
|||
|
||||
private Long id;
|
||||
|
||||
@TableTitle(title = "编号", dataIndex = "jobNo", key = "jobNo")
|
||||
@TableTitle(labelId = 547118, title = "编号", dataIndex = "jobNo", key = "jobNo")
|
||||
private String jobNo;
|
||||
|
||||
@TableTitle(title = "岗位名称", dataIndex = "jobName", key = "jobName")
|
||||
|
|
|
|||
|
|
@ -43,7 +43,7 @@ public class CardAccessVO {
|
|||
@OrganizationTableColumn(text = "栏目", width = "15%", column = "type_name")
|
||||
private Integer typeName;
|
||||
|
||||
@OrganizationTableColumn(text = "是否启用", width = "15%", column = "status")
|
||||
@OrganizationTableColumn(labelId = 547130, text = "是否启用", width = "15%", column = "status")
|
||||
private Integer status;
|
||||
|
||||
@OrganizationTableColumn(text = "所有人可见", width = "15%", column = "all_people")
|
||||
|
|
|
|||
|
|
@ -33,8 +33,8 @@ import lombok.NoArgsConstructor;
|
|||
sortway = "asc",
|
||||
primarykey = "id",
|
||||
operates = {
|
||||
@OrganizationTableOperate(index = "0", text = "编辑"),
|
||||
@OrganizationTableOperate(index = "1", text = "删除")
|
||||
@OrganizationTableOperate(index = "0", labelId = 547132, text = "编辑"),
|
||||
@OrganizationTableOperate(index = "1", labelId = 547135, text = "删除")
|
||||
}, tableType = WeaTableType.CHECKBOX,
|
||||
operatePopedom = @OperatePopedom(transmethod = "com.engine.organization.util.ConfigTrans.formatSourceOperates", otherpara = "column:is_used"),
|
||||
checkboxPopedom = @CheckboxPopedom(showmethod = "com.engine.organization.util.ConfigTrans.getCheckBoxPopedom", popedompara = "column:is_used")
|
||||
|
|
@ -48,12 +48,12 @@ public class PostInfoTableVO {
|
|||
/**
|
||||
* 编号
|
||||
*/
|
||||
@OrganizationTableColumn(text = "编号", width = "20%", column = "post_info_no", orderkey = "post_info_no")
|
||||
@OrganizationTableColumn(labelId = 547118, text = "编号", width = "20%", column = "post_info_no", orderkey = "post_info_no")
|
||||
private String postInfoNo;
|
||||
/**
|
||||
* 名称
|
||||
*/
|
||||
@OrganizationTableColumn(text = "名称", width = "20%", column = "post_info_name")
|
||||
@OrganizationTableColumn(labelId = 547141, text = "名称", width = "20%", column = "post_info_name")
|
||||
private String postInfoName;
|
||||
/**
|
||||
* 权限
|
||||
|
|
@ -84,6 +84,6 @@ public class PostInfoTableVO {
|
|||
/**
|
||||
* 禁用标记
|
||||
*/
|
||||
@OrganizationTableColumn(text = "是否启用", width = "10%", column = "forbidden_tag")
|
||||
@OrganizationTableColumn(labelId = 547130, text = "是否启用", width = "10%", column = "forbidden_tag")
|
||||
private Integer forbiddenTag;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -31,8 +31,8 @@ import lombok.NoArgsConstructor;
|
|||
sortway = "asc",
|
||||
primarykey = "id",
|
||||
operates = {
|
||||
@OrganizationTableOperate(text = "编辑"),
|
||||
@OrganizationTableOperate(index = "1", text = "删除")
|
||||
@OrganizationTableOperate(index = "0", labelId = 547132, text = "编辑"),
|
||||
@OrganizationTableOperate(index = "1", labelId = 547135, text = "删除")
|
||||
},
|
||||
tableType = WeaTableType.CHECKBOX,
|
||||
operatePopedom = @OperatePopedom(transmethod = "com.engine.organization.util.ConfigTrans.formatSourceOperates", otherpara = "column:is_used"),
|
||||
|
|
@ -53,12 +53,12 @@ public class GradeTableVO {
|
|||
/**
|
||||
* 编号
|
||||
*/
|
||||
@OrganizationTableColumn(text = "编号", width = "20%", column = "grade_no", orderkey = "grade_no")
|
||||
@OrganizationTableColumn(labelId = 547118, text = "编号", width = "20%", column = "grade_no", orderkey = "grade_no")
|
||||
private String gradeNo;
|
||||
/**
|
||||
* 名称
|
||||
*/
|
||||
@OrganizationTableColumn(text = "名称", width = "20%", column = "grade_name")
|
||||
@OrganizationTableColumn(labelId = 547141, text = "名称", width = "20%", column = "grade_name")
|
||||
private String gradeName;
|
||||
|
||||
/**
|
||||
|
|
@ -68,22 +68,22 @@ public class GradeTableVO {
|
|||
/**
|
||||
* 等级方案
|
||||
*/
|
||||
@OrganizationTableColumn(text = "等级方案", width = "20%", column = "scheme_name")
|
||||
@OrganizationTableColumn( labelId = 547124, text = "等级方案", width = "20%", column = "scheme_name")
|
||||
private String schemeName;
|
||||
/**
|
||||
* 职等
|
||||
*/
|
||||
@OrganizationTableColumn(text = "职等", width = "20%", column = "level_id", transmethod = "com.engine.organization.transmethod.LevelTransMethod.getLevelId")
|
||||
@OrganizationTableColumn(labelId = 547139, text = "职等", width = "20%", column = "level_id", transmethod = "com.engine.organization.transmethod.LevelTransMethod.getLevelId")
|
||||
private String levelId;
|
||||
|
||||
/**
|
||||
* 描述说明
|
||||
*/
|
||||
@OrganizationTableColumn(text = "描述说明", width = "30%", column = "description")
|
||||
@OrganizationTableColumn(labelId = 547142, text = "描述说明", width = "30%", column = "description")
|
||||
private String description;
|
||||
/**
|
||||
* 禁用标记
|
||||
*/
|
||||
@OrganizationTableColumn(text = "是否启用", width = "10%", column = "forbidden_tag")
|
||||
@OrganizationTableColumn(labelId = 547130, text = "是否启用", width = "10%", column = "forbidden_tag")
|
||||
private int forbiddenTag;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -30,8 +30,8 @@ import lombok.NoArgsConstructor;
|
|||
sortway = "asc",
|
||||
primarykey = "id",
|
||||
operates = {
|
||||
@OrganizationTableOperate(text = "编辑"),
|
||||
@OrganizationTableOperate(index = "1", text = "删除")
|
||||
@OrganizationTableOperate(index = "0", labelId = 547132, text = "编辑"),
|
||||
@OrganizationTableOperate(index = "1", labelId = 547135, text = "删除")
|
||||
}, tableType = WeaTableType.CHECKBOX,
|
||||
operatePopedom = @OperatePopedom(transmethod = "com.engine.organization.util.ConfigTrans.formatSourceOperates", otherpara = "column:is_used"),
|
||||
checkboxPopedom = @CheckboxPopedom(showmethod = "com.engine.organization.util.ConfigTrans.getCheckBoxPopedom", popedompara = "column:is_used")
|
||||
|
|
@ -51,30 +51,30 @@ public class LevelTableVO {
|
|||
/**
|
||||
* 编号
|
||||
*/
|
||||
@OrganizationTableColumn(text = "编号", width = "20%", column = "level_no", orderkey = "level_no")
|
||||
@OrganizationTableColumn(labelId = 547118, text = "编号", width = "20%", column = "level_no", orderkey = "level_no")
|
||||
private String levelNo;
|
||||
/**
|
||||
* 名称
|
||||
*/
|
||||
@OrganizationTableColumn(text = "名称", width = "20%", column = "level_name")
|
||||
@OrganizationTableColumn(labelId = 547141, text = "名称", width = "20%", column = "level_name")
|
||||
private String levelName;
|
||||
|
||||
/**
|
||||
* 等级方案
|
||||
*/
|
||||
@OrganizationTableColumn(text = "等级方案", width = "20%", column = "scheme_name")
|
||||
@OrganizationTableColumn(text = "等级方案", labelId = 547124, width = "20%", column = "scheme_name")
|
||||
private String schemeName;
|
||||
|
||||
/**
|
||||
* 描述说明
|
||||
*/
|
||||
@OrganizationTableColumn(text = "描述说明", width = "30%", column = "description")
|
||||
@OrganizationTableColumn(labelId = 547142, text = "描述说明", width = "30%", column = "description")
|
||||
private String description;
|
||||
|
||||
|
||||
/**
|
||||
* 禁用标记
|
||||
*/
|
||||
@OrganizationTableColumn(text = "是否启用", width = "10%", column = "forbidden_tag")
|
||||
@OrganizationTableColumn(labelId = 547130, text = "是否启用", width = "10%", column = "forbidden_tag")
|
||||
private Integer forbiddenTag;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -34,8 +34,8 @@ import lombok.NoArgsConstructor;
|
|||
sortway = "asc",
|
||||
primarykey = "id",
|
||||
operates = {
|
||||
@OrganizationTableOperate(text = "编辑"),
|
||||
@OrganizationTableOperate(index = "1", text = "删除")
|
||||
@OrganizationTableOperate(index = "0", labelId = 547132, text = "编辑"),
|
||||
@OrganizationTableOperate(index = "1", labelId = 547135, text = "删除")
|
||||
},
|
||||
tableType = WeaTableType.CHECKBOX,
|
||||
operatePopedom = @OperatePopedom(transmethod = "com.engine.organization.util.ConfigTrans.formatSourceOperates", otherpara = "column:is_used"),
|
||||
|
|
@ -57,30 +57,30 @@ public class SequenceTableVO {
|
|||
/**
|
||||
* 编号
|
||||
*/
|
||||
@OrganizationTableColumn(text = "编号", width = "20%", column = "sequence_no", orderkey = "sequence_no")
|
||||
@OrganizationTableColumn(labelId = 547118, text = "编号", width = "20%", column = "sequence_no", orderkey = "sequence_no")
|
||||
private String sequenceNo;
|
||||
/**
|
||||
* 名称
|
||||
*/
|
||||
@OrganizationTableColumn(text = "名称", width = "20%", column = "sequence_name")
|
||||
@OrganizationTableColumn(labelId = 547141, text = "名称", width = "20%", column = "sequence_name")
|
||||
private String sequenceName;
|
||||
|
||||
|
||||
/**
|
||||
* 等级方案
|
||||
*/
|
||||
@OrganizationTableColumn(text = "等级方案", width = "20%", column = "scheme_name")
|
||||
@OrganizationTableColumn(text = "等级方案", labelId = 547124, width = "20%", column = "scheme_name")
|
||||
private String schemeName;
|
||||
|
||||
/**
|
||||
* 描述说明
|
||||
*/
|
||||
@OrganizationTableColumn(text = "描述说明", width = "30%", column = "description")
|
||||
@OrganizationTableColumn(labelId = 547142, text = "描述说明", width = "30%", column = "description")
|
||||
private String description;
|
||||
|
||||
/**
|
||||
* 禁用标记
|
||||
*/
|
||||
@OrganizationTableColumn(text = "是否启用", width = "10%", column = "forbidden_tag")
|
||||
@OrganizationTableColumn(labelId = 547130, text = "是否启用", width = "10%", column = "forbidden_tag")
|
||||
private Integer forbiddenTag;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -24,8 +24,8 @@ import lombok.NoArgsConstructor;
|
|||
sortway = "asc",
|
||||
primarykey = "id",
|
||||
operates = {
|
||||
@OrganizationTableOperate(text = "编辑"),
|
||||
@OrganizationTableOperate(index = "1", text = "删除")
|
||||
@OrganizationTableOperate(index = "0", labelId = 547132, text = "编辑"),
|
||||
@OrganizationTableOperate(index = "1", labelId = 547135, text = "删除")
|
||||
}, tableType = WeaTableType.CHECKBOX,
|
||||
operatePopedom = @OperatePopedom(transmethod = "com.engine.organization.util.ConfigTrans.formatStaffOperates", otherpara = "column:is_used"),
|
||||
checkboxPopedom = @CheckboxPopedom(showmethod = "com.engine.organization.util.ConfigTrans.getCheckBoxPopedom", popedompara = "column:is_used")
|
||||
|
|
@ -46,12 +46,12 @@ public class StaffPlanTableVO {
|
|||
/**
|
||||
* 编号
|
||||
*/
|
||||
@OrganizationTableColumn(text = "编号", width = "16%", column = "plan_no", orderkey = "plan_no")
|
||||
@OrganizationTableColumn(labelId = 547118, text = "编号", width = "16%", column = "plan_no", orderkey = "plan_no")
|
||||
private String planNo;
|
||||
/**
|
||||
* 名称
|
||||
*/
|
||||
@OrganizationTableColumn(text = "名称", width = "16%", column = "plan_name")
|
||||
@OrganizationTableColumn(labelId = 547141, text = "名称", width = "16%", column = "plan_name")
|
||||
private String planName;
|
||||
/**
|
||||
* w维度
|
||||
|
|
@ -76,7 +76,7 @@ public class StaffPlanTableVO {
|
|||
/**
|
||||
* 状态
|
||||
*/
|
||||
@OrganizationTableColumn(text = "是否启用", width = "16%", column = "forbidden_tag")
|
||||
@OrganizationTableColumn(labelId = 547130, text = "是否启用", width = "16%", column = "forbidden_tag")
|
||||
private Integer forbiddenTag;
|
||||
|
||||
}
|
||||
|
|
|
|||
|
|
@ -23,8 +23,8 @@ import lombok.NoArgsConstructor;
|
|||
orderby = "id desc",
|
||||
primarykey = "id",
|
||||
operates = {
|
||||
@OrganizationTableOperate(text = "编辑"),
|
||||
@OrganizationTableOperate(index = "1", text = "删除"),
|
||||
@OrganizationTableOperate(index = "0", labelId = 547132, text = "编辑"),
|
||||
@OrganizationTableOperate(index = "1", labelId = 547135, text = "删除"),
|
||||
@OrganizationTableOperate(index = "2", text = "变更")
|
||||
}, tableType = WeaTableType.CHECKBOX
|
||||
|
||||
|
|
|
|||
|
|
@ -19,6 +19,7 @@ import com.engine.organization.util.db.MapperProxyFactory;
|
|||
import org.apache.commons.collections.CollectionUtils;
|
||||
import org.apache.commons.lang3.StringUtils;
|
||||
import weaver.general.Util;
|
||||
import weaver.systeminfo.SystemEnv;
|
||||
|
||||
import java.util.*;
|
||||
import java.util.concurrent.atomic.AtomicInteger;
|
||||
|
|
@ -102,7 +103,7 @@ public class CardAccessServiceImpl extends Service implements CardAccessService
|
|||
public Map<String, Object> getCardButtonTable() {
|
||||
List<ExtendInfoPO> infoPOList = new ArrayList<>();
|
||||
infoPOList.add(ExtendInfoPO.builder().id(null).fieldName("name").fieldNameDesc("按钮名称").fieldType("varchar(50)").controlType(1).browserType("1").customValue("[\"input\",\"text\",\"50\"]").showOrder(1).isrequired(0).isSystemDefault(0).build());
|
||||
infoPOList.add(ExtendInfoPO.builder().id(null).fieldName("status").fieldNameDesc("启用").fieldType("char(1)").controlType(7).browserType("1").customValue("[\"check\"]").showOrder(2).isrequired(0).isSystemDefault(0).build());
|
||||
infoPOList.add(ExtendInfoPO.builder().id(null).fieldName("status").fieldNameDesc(SystemEnv.getHtmlLabelName(547186, user.getLanguage())).fieldType("char(1)").controlType(7).browserType("1").customValue("[\"check\"]").showOrder(2).isrequired(0).isSystemDefault(0).build());
|
||||
infoPOList.add(ExtendInfoPO.builder().id(null).fieldName("url").fieldNameDesc("跳转地址").fieldType("varchar(1000)").controlType(1).browserType("1").customValue("[\"input\",\"text\",\"1000\"]").showOrder(3).isrequired(0).isSystemDefault(0).build());
|
||||
infoPOList.add(ExtendInfoPO.builder().id(null).fieldName("roles").fieldNameDesc("角色").fieldType("text").controlType(3).browserType("65").customValue("[\"browser\",{\"valueSpan\":\"多角色\",\"replaceDatas\":[{\"itemorderid\":\"65\",\"name\":\"多角色\",\"id\":\"65\",\"parenttitle\":\"人员\",\"title\":\"人员-多角色\"}],\"value\":\"65\"}]").showOrder(4).isrequired(0).isSystemDefault(0).build());
|
||||
|
||||
|
|
|
|||
|
|
@ -178,9 +178,9 @@ public class CompServiceImpl extends Service implements CompService {
|
|||
List<SearchConditionGroup> addGroups = new ArrayList<>();
|
||||
List<SearchConditionItem> conditionItems = new ArrayList<>();
|
||||
// 编号
|
||||
SearchConditionItem subCompanyCodeItem = OrganizationFormItemUtil.inputItem(user, 2, 16, 2, 50, "编号", "subCompanyCode");
|
||||
SearchConditionItem subCompanyCodeItem = OrganizationFormItemUtil.inputItem(user, 2, 16, 2, 50, 547118, "subCompanyCode");
|
||||
// 名称
|
||||
SearchConditionItem subCompanyDescItem = OrganizationFormItemUtil.inputItem(user, 2, 16, 2, 50, "名称", "subCompanyDesc");
|
||||
SearchConditionItem subCompanyDescItem = OrganizationFormItemUtil.inputItem(user, 2, 16, 2, 50, 547141, "subCompanyDesc");
|
||||
// 简称
|
||||
SearchConditionItem subCompanyNameItem = OrganizationFormItemUtil.inputItem(user, 2, 16, 2, 50, "简称", "subCompanyName");
|
||||
// 上级公司
|
||||
|
|
|
|||
|
|
@ -231,9 +231,9 @@ public class DepartmentServiceImpl extends Service implements DepartmentService
|
|||
List<SearchConditionGroup> addGroups = new ArrayList<>();
|
||||
List<SearchConditionItem> conditionItems = new ArrayList<>();
|
||||
// 编号
|
||||
SearchConditionItem departmentCodeItem = OrganizationFormItemUtil.inputItem(user, 2, 16, 2, 50, "编号", "departmentCode");
|
||||
SearchConditionItem departmentCodeItem = OrganizationFormItemUtil.inputItem(user, 2, 16, 2, 50, 547118, "departmentCode");
|
||||
// 名称
|
||||
SearchConditionItem departmentNameItem = OrganizationFormItemUtil.inputItem(user, 2, 16, 2, 50, "名称", "departmentName");
|
||||
SearchConditionItem departmentNameItem = OrganizationFormItemUtil.inputItem(user, 2, 16, 2, 50, 547141, "departmentName");
|
||||
// 所属分部
|
||||
SearchConditionItem subCompanyId1Item = OrganizationFormItemUtil.browserItem(user, 2, 16, 2, false, "所属分部", "164", "subCompanyId1", "");
|
||||
// 上级部门
|
||||
|
|
|
|||
|
|
@ -75,7 +75,7 @@ public class GradeServiceImpl extends Service implements GradeService {
|
|||
@Override
|
||||
public int saveGrade(GradeSearchParam param) {
|
||||
HasRightUtil.hasRight(user, RIGHT_NAME, false);
|
||||
OrganizationAssert.isTrue(checkRepeatNo(param.getSchemeId(), param.getGradeNo(), null), "同一等级方案下编号不能重复");
|
||||
OrganizationAssert.isTrue(checkRepeatNo(param.getSchemeId(), param.getGradeNo(), null), SystemEnv.getHtmlLabelName(547177, user.getLanguage()));
|
||||
GradePO gradePO = GradeDTO.convertParamToPO(param, (long) user.getUID());
|
||||
return getGradeMapper().insertIgnoreNull(gradePO);
|
||||
}
|
||||
|
|
@ -84,7 +84,7 @@ public class GradeServiceImpl extends Service implements GradeService {
|
|||
public int updateGrade(GradeSearchParam param) {
|
||||
HasRightUtil.hasRight(user, RIGHT_NAME, false);
|
||||
GradePO gradePO = GradeDTO.convertParamToPO(param, (long) user.getUID());
|
||||
OrganizationAssert.isTrue(checkRepeatNo(gradePO.getSchemeId(), gradePO.getGradeNo(), gradePO.getId()), "同一等级方案下编号不能重复");
|
||||
OrganizationAssert.isTrue(checkRepeatNo(gradePO.getSchemeId(), gradePO.getGradeNo(), gradePO.getId()), SystemEnv.getHtmlLabelName(547177, user.getLanguage()));
|
||||
return getGradeMapper().updateGrade(gradePO);
|
||||
}
|
||||
|
||||
|
|
@ -98,7 +98,7 @@ public class GradeServiceImpl extends Service implements GradeService {
|
|||
@Override
|
||||
public int deleteByIds(Collection<Long> ids) {
|
||||
HasRightUtil.hasRight(user, RIGHT_NAME, false);
|
||||
OrganizationAssert.notEmpty(ids, "请选择要删除的数据");
|
||||
OrganizationAssert.notEmpty(ids, SystemEnv.getHtmlLabelName(547138,user.getLanguage()));
|
||||
return getGradeMapper().deleteByIds(ids);
|
||||
}
|
||||
|
||||
|
|
@ -108,8 +108,8 @@ public class GradeServiceImpl extends Service implements GradeService {
|
|||
Map<String, Object> apiDatas = new HashMap<>();
|
||||
List<SearchConditionGroup> addGroups = new ArrayList<>();
|
||||
List<SearchConditionItem> conditionItems = new ArrayList<>();
|
||||
SearchConditionItem browserItem = OrganizationFormItemUtil.browserItem(user, 2, 16, 2, false, "等级方案", "161", "schemeId", "schemeBrowser");
|
||||
SearchConditionItem gradeNameCondition = OrganizationFormItemUtil.inputItem(user, 2, 16, 2, 50, "名称", "gradeName");
|
||||
SearchConditionItem browserItem = OrganizationFormItemUtil.browserItem(user, 2, 16, 2, false, 547124, "161", "schemeId", "schemeBrowser");
|
||||
SearchConditionItem gradeNameCondition = OrganizationFormItemUtil.inputItem(user, 2, 16, 2, 50, 547141, "gradeName");
|
||||
conditionItems.add(browserItem);
|
||||
conditionItems.add(gradeNameCondition);
|
||||
addGroups.add(new SearchConditionGroup("高级搜索条件", true, conditionItems));
|
||||
|
|
@ -126,12 +126,12 @@ public class GradeServiceImpl extends Service implements GradeService {
|
|||
List<SearchConditionGroup> addGroups = new ArrayList<>();
|
||||
String id = Util.null2String(params.get("id"));
|
||||
String schemeId = Util.null2String(params.get("schemeId"));
|
||||
SearchConditionItem gradeNameCondition = OrganizationFormItemUtil.inputItem(user, 2, 17, 3, 50, "名称", "gradeName");
|
||||
SearchConditionItem gradeNameCondition = OrganizationFormItemUtil.inputItem(user, 2, 17, 3, 50, 547141, "gradeName");
|
||||
gradeNameCondition.setRules("required|string");
|
||||
SearchConditionItem gradeNoCondition = OrganizationFormItemUtil.inputItem(user, 2, 17, 3, 50, "编号", "gradeNo");
|
||||
SearchConditionItem gradeNoCondition = OrganizationFormItemUtil.inputItem(user, 2, 17, 3, 50, 547118, "gradeNo");
|
||||
gradeNoCondition.setRules("required|string");
|
||||
SearchConditionItem descriptionCondition = OrganizationFormItemUtil.textareaItem(user, 2, 17, true, 2, 200, "描述说明", "description");
|
||||
SearchConditionItem schemeBrowserItem = OrganizationFormItemUtil.browserItem(user, 2, 17, 3, false, "等级方案", "161", "schemeId", "schemeBrowser");
|
||||
SearchConditionItem descriptionCondition = OrganizationFormItemUtil.textareaItem(user, 2, 17, true, 2, 200, 547142, "description");
|
||||
SearchConditionItem schemeBrowserItem = OrganizationFormItemUtil.browserItem(user, 2, 17, 3, false, 547124, "161", "schemeId", "schemeBrowser");
|
||||
schemeBrowserItem.setRules("required|string");
|
||||
BrowserBean schemeBrowserBean = schemeBrowserItem.getBrowserConditionParam();
|
||||
if (StringUtils.isNotBlank(schemeId) && !"-1".equals(schemeId) && StringUtil.isEmpty(id)) {
|
||||
|
|
@ -140,7 +140,7 @@ public class GradeServiceImpl extends Service implements GradeService {
|
|||
schemeBrowserBean.setReplaceDatas(maps);
|
||||
schemeBrowserItem.setBrowserConditionParam(schemeBrowserBean);
|
||||
}
|
||||
SearchConditionItem levelBrowserItem = OrganizationFormItemUtil.browserItem(user, 2, 17, 3, false, "职等", "162", "levelId", "LevelBrowser");
|
||||
SearchConditionItem levelBrowserItem = OrganizationFormItemUtil.browserItem(user, 2, 17, 3, false, 547139, "162", "levelId", "LevelBrowser");
|
||||
levelBrowserItem.setRules("required|string");
|
||||
|
||||
// 编辑状态下赋值操作
|
||||
|
|
@ -206,9 +206,9 @@ public class GradeServiceImpl extends Service implements GradeService {
|
|||
public Map<String, Object> getTabInfo() {
|
||||
Map<String, Object> apiDatas = new HashMap<>();
|
||||
List<TopTab> topTabs = new ArrayList<>();
|
||||
topTabs.add(TopTab.builder().color("#000000").groupId("flowAll").showcount(true).title("全部").viewCondition("-1").build());
|
||||
topTabs.add(TopTab.builder().color("#ff3232").groupId("enable").showcount(true).title("启用").viewCondition("0").build());
|
||||
topTabs.add(TopTab.builder().color("#fea468").groupId("disable").showcount(true).title("禁用").viewCondition("1").build());
|
||||
topTabs.add(TopTab.builder().color("#000000").groupId("flowAll").showcount(true).title(SystemEnv.getHtmlLabelName(547191, user.getLanguage())).viewCondition("-1").build());
|
||||
topTabs.add(TopTab.builder().color("#ff3232").groupId("enable").showcount(true).title(SystemEnv.getHtmlLabelName(547186, user.getLanguage())).viewCondition("0").build());
|
||||
topTabs.add(TopTab.builder().color("#fea468").groupId("disable").showcount(true).title(SystemEnv.getHtmlLabelName(547192, user.getLanguage())).viewCondition("1").build());
|
||||
apiDatas.put("topTabs", topTabs);
|
||||
|
||||
HashMap<String, Integer> countMap = new HashMap<>();
|
||||
|
|
|
|||
|
|
@ -62,6 +62,7 @@ import weaver.general.StringUtil;
|
|||
import weaver.general.TimeUtil;
|
||||
import weaver.general.Util;
|
||||
import weaver.hrm.definedfield.HrmFieldManager;
|
||||
import weaver.systeminfo.SystemEnv;
|
||||
|
||||
import java.math.BigDecimal;
|
||||
import java.math.RoundingMode;
|
||||
|
|
@ -1314,7 +1315,7 @@ public class HrmResourceServiceImpl extends Service implements HrmResourceServic
|
|||
List<SearchConditionOption> options = searchConditionItem.getOptions();
|
||||
SearchConditionOption searchConditionOption = new SearchConditionOption();
|
||||
searchConditionOption.setKey("-1");
|
||||
searchConditionOption.setShowname("全部");
|
||||
searchConditionOption.setShowname(SystemEnv.getHtmlLabelName(547191,user.getLanguage()));
|
||||
options.add(0, searchConditionOption);
|
||||
options.forEach(item -> item.setSelected(false));
|
||||
}
|
||||
|
|
|
|||
|
|
@ -222,9 +222,9 @@ public class JobServiceImpl extends Service implements JobService {
|
|||
List<SearchConditionGroup> addGroups = new ArrayList<>();
|
||||
List<SearchConditionItem> conditionItems = new ArrayList<>();
|
||||
// 编号
|
||||
SearchConditionItem jobNoItem = OrganizationFormItemUtil.inputItem(user, 2, 16, 2, 50, "编号", "jobNo");
|
||||
SearchConditionItem jobNoItem = OrganizationFormItemUtil.inputItem(user, 2, 16, 2, 50, 547118, "jobNo");
|
||||
// 名称
|
||||
SearchConditionItem jobTitleNameItem = OrganizationFormItemUtil.inputItem(user, 2, 16, 2, 50, "名称", "jobTitleName");
|
||||
SearchConditionItem jobTitleNameItem = OrganizationFormItemUtil.inputItem(user, 2, 16, 2, 50, 547141, "jobTitleName");
|
||||
// 所属分部
|
||||
SearchConditionItem parentCompBrowserItem = OrganizationFormItemUtil.browserItem(user, 2, 16, 2, false, "所属分部", "164", "subcompanyid1", "");
|
||||
// 所属部门
|
||||
|
|
@ -499,7 +499,7 @@ public class JobServiceImpl extends Service implements JobService {
|
|||
@Override
|
||||
public int deleteByIds(Collection<Long> ids) {
|
||||
HasRightUtil.hasRight(user, RIGHT_NAME, false);
|
||||
OrganizationAssert.notEmpty(ids, "请选择要删除的数据");
|
||||
OrganizationAssert.notEmpty(ids, SystemEnv.getHtmlLabelName(547138,user.getLanguage()));
|
||||
List<JobPO> jobsByIds = getJobMapper().getJobsByIds(ids);
|
||||
for (JobPO jobsById : jobsByIds) {
|
||||
// 判断是否可以删除
|
||||
|
|
|
|||
|
|
@ -72,7 +72,7 @@ public class LevelServiceImpl extends Service implements LevelService {
|
|||
public int saveLevel(LevelSearchParam param) {
|
||||
HasRightUtil.hasRight(user, RIGHT_NAME, false);
|
||||
List<LevelPO> list = getLevelMapper().listByNo(Util.null2String(param.getLevelNo()));
|
||||
OrganizationAssert.isTrue(checkRepeatNo(param.getSchemeId(), param.getLevelNo(), null), "同一等级方案下编号不能重复");
|
||||
OrganizationAssert.isTrue(checkRepeatNo(param.getSchemeId(), param.getLevelNo(), null), SystemEnv.getHtmlLabelName(547177, user.getLanguage()));
|
||||
LevelPO levelPO = LevelDTO.convertParamToPO(param, (long) user.getUID());
|
||||
return getLevelMapper().insertIgnoreNull(levelPO);
|
||||
}
|
||||
|
|
@ -81,7 +81,7 @@ public class LevelServiceImpl extends Service implements LevelService {
|
|||
public int updateLevel(LevelSearchParam param) {
|
||||
HasRightUtil.hasRight(user, RIGHT_NAME, false);
|
||||
LevelPO levelPO = LevelDTO.convertParamToPO(param, (long) user.getUID());
|
||||
OrganizationAssert.isTrue(checkRepeatNo(levelPO.getSchemeId(), levelPO.getLevelNo(), levelPO.getId()), "同一等级方案下编号不能重复");
|
||||
OrganizationAssert.isTrue(checkRepeatNo(levelPO.getSchemeId(), levelPO.getLevelNo(), levelPO.getId()), SystemEnv.getHtmlLabelName(547177, user.getLanguage()));
|
||||
return getLevelMapper().updateLevel(levelPO);
|
||||
}
|
||||
|
||||
|
|
@ -95,7 +95,7 @@ public class LevelServiceImpl extends Service implements LevelService {
|
|||
@Override
|
||||
public int deleteByIds(Collection<Long> ids) {
|
||||
HasRightUtil.hasRight(user, RIGHT_NAME, false);
|
||||
OrganizationAssert.notEmpty(ids, "请选择要删除的数据");
|
||||
OrganizationAssert.notEmpty(ids, SystemEnv.getHtmlLabelName(547138,user.getLanguage()));
|
||||
return getLevelMapper().deleteByIds(ids);
|
||||
}
|
||||
|
||||
|
|
@ -105,8 +105,8 @@ public class LevelServiceImpl extends Service implements LevelService {
|
|||
Map<String, Object> apiDatas = new HashMap<>();
|
||||
List<SearchConditionGroup> addGroups = new ArrayList<>();
|
||||
List<SearchConditionItem> conditionItems = new ArrayList<>();
|
||||
SearchConditionItem browserItem = OrganizationFormItemUtil.browserItem(user, 2, 16, 2, false, "等级方案", "161", "schemeId", "schemeBrowser");
|
||||
SearchConditionItem levelNameCondition = OrganizationFormItemUtil.inputItem(user, 2, 16, 2, 50, "名称", "levelName");
|
||||
SearchConditionItem browserItem = OrganizationFormItemUtil.browserItem(user, 2, 16, 2, false, 547124, "161", "schemeId", "schemeBrowser");
|
||||
SearchConditionItem levelNameCondition = OrganizationFormItemUtil.inputItem(user, 2, 16, 2, 50, 547141, "levelName");
|
||||
conditionItems.add(browserItem);
|
||||
conditionItems.add(levelNameCondition);
|
||||
addGroups.add(new SearchConditionGroup("高级搜索条件", true, conditionItems));
|
||||
|
|
@ -123,12 +123,12 @@ public class LevelServiceImpl extends Service implements LevelService {
|
|||
List<SearchConditionGroup> addGroups = new ArrayList<>();
|
||||
String id = Util.null2String(params.get("id"));
|
||||
String schemeId = Util.null2String(params.get("schemeId"));
|
||||
SearchConditionItem levelNameCondition = OrganizationFormItemUtil.inputItem(user, 2, 17, 3, 50, "名称", "levelName");
|
||||
SearchConditionItem levelNameCondition = OrganizationFormItemUtil.inputItem(user, 2, 17, 3, 50, 547141, "levelName");
|
||||
levelNameCondition.setRules("required|string");
|
||||
SearchConditionItem levelNoCondition = OrganizationFormItemUtil.inputItem(user, 2, 17, 3, 50, "编号", "levelNo");
|
||||
SearchConditionItem levelNoCondition = OrganizationFormItemUtil.inputItem(user, 2, 17, 3, 50, 547118, "levelNo");
|
||||
levelNoCondition.setRules("required|string");
|
||||
SearchConditionItem descriptionCondition = OrganizationFormItemUtil.textareaItem(user, 2, 17, true, 2, 200, "描述说明", "description");
|
||||
SearchConditionItem browserItem = OrganizationFormItemUtil.browserItem(user, 2, 17, 3, false, "等级方案", "161", "schemeId", "schemeBrowser");
|
||||
SearchConditionItem descriptionCondition = OrganizationFormItemUtil.textareaItem(user, 2, 17, true, 2, 200, 547142, "description");
|
||||
SearchConditionItem browserItem = OrganizationFormItemUtil.browserItem(user, 2, 17, 3, false, 547124, "161", "schemeId", "schemeBrowser");
|
||||
BrowserBean browserBean = browserItem.getBrowserConditionParam();
|
||||
if (StringUtils.isNotBlank(schemeId) && !"-1".equals(schemeId) && StringUtil.isEmpty(id)) {
|
||||
browserItem.setValue(schemeId);
|
||||
|
|
@ -173,9 +173,9 @@ public class LevelServiceImpl extends Service implements LevelService {
|
|||
public Map<String, Object> getTabInfo() {
|
||||
Map<String, Object> apiDatas = new HashMap<>();
|
||||
List<TopTab> topTabs = new ArrayList<>();
|
||||
topTabs.add(TopTab.builder().color("#000000").groupId("flowAll").showcount(true).title("全部").viewCondition("-1").build());
|
||||
topTabs.add(TopTab.builder().color("#ff3232").groupId("enable").showcount(true).title("启用").viewCondition("0").build());
|
||||
topTabs.add(TopTab.builder().color("#fea468").groupId("disable").showcount(true).title("禁用").viewCondition("1").build());
|
||||
topTabs.add(TopTab.builder().color("#000000").groupId("flowAll").showcount(true).title(SystemEnv.getHtmlLabelName(547191, user.getLanguage())).viewCondition("-1").build());
|
||||
topTabs.add(TopTab.builder().color("#ff3232").groupId("enable").showcount(true).title(SystemEnv.getHtmlLabelName(547186, user.getLanguage())).viewCondition("0").build());
|
||||
topTabs.add(TopTab.builder().color("#fea468").groupId("disable").showcount(true).title(SystemEnv.getHtmlLabelName(547192, user.getLanguage())).viewCondition("1").build());
|
||||
apiDatas.put("topTabs", topTabs);
|
||||
|
||||
HashMap<String, Integer> countMap = new HashMap<>();
|
||||
|
|
@ -190,7 +190,7 @@ public class LevelServiceImpl extends Service implements LevelService {
|
|||
@Override
|
||||
public TreeData getTreeData() {
|
||||
ArrayList<TreeData> treeDataList = getLevelMapper().getTreeData();
|
||||
return TreeData.builder().children(treeDataList).title("职等").key("-1").build();
|
||||
return TreeData.builder().children(treeDataList).title(SystemEnv.getHtmlLabelName(547139, user.getLanguage())).key("-1").build();
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
|
|||
|
|
@ -136,7 +136,7 @@ public class PostInfoServiceImpl extends Service implements PostInfoService {
|
|||
@Override
|
||||
public int deleteByIds(Collection<Long> ids) {
|
||||
HasRightUtil.hasRight(user, RIGHT_NAME, false);
|
||||
OrganizationAssert.notEmpty(ids, "请选择要删除的数据");
|
||||
OrganizationAssert.notEmpty(ids, SystemEnv.getHtmlLabelName(547138,user.getLanguage()));
|
||||
return getPostInfoMapper().deleteByIds(ids);
|
||||
}
|
||||
|
||||
|
|
@ -147,7 +147,7 @@ public class PostInfoServiceImpl extends Service implements PostInfoService {
|
|||
List<SearchConditionGroup> addGroups = new ArrayList<>();
|
||||
List<SearchConditionItem> conditionItems = new ArrayList<>();
|
||||
SearchConditionItem browserItem = OrganizationFormItemUtil.browserItem(user, 2, 16, 2, false, "职务分类", "161", "postId", "postBrowser");
|
||||
SearchConditionItem nameCondition = OrganizationFormItemUtil.inputItem(user, 2, 16, 2, 50, "名称", "postInfoName");
|
||||
SearchConditionItem nameCondition = OrganizationFormItemUtil.inputItem(user, 2, 16, 2, 50, 547141, "postInfoName");
|
||||
conditionItems.add(browserItem);
|
||||
conditionItems.add(nameCondition);
|
||||
addGroups.add(new SearchConditionGroup("高级搜索条件", true, conditionItems));
|
||||
|
|
@ -163,10 +163,10 @@ public class PostInfoServiceImpl extends Service implements PostInfoService {
|
|||
List<SearchConditionItem> selectItems = new ArrayList<>();
|
||||
List<SearchConditionGroup> addGroups = new ArrayList<>();
|
||||
// 编号
|
||||
SearchConditionItem noItem = OrganizationFormItemUtil.inputItem(user, 2, 17, 3, 50, "编号", "postInfoNo");
|
||||
SearchConditionItem noItem = OrganizationFormItemUtil.inputItem(user, 2, 17, 3, 50, 547118, "postInfoNo");
|
||||
noItem.setRules("required|string");
|
||||
// 名称
|
||||
SearchConditionItem nameItem = OrganizationFormItemUtil.inputItem(user, 2, 17, 3, 50, "名称", "postInfoName");
|
||||
SearchConditionItem nameItem = OrganizationFormItemUtil.inputItem(user, 2, 17, 3, 50, 547141, "postInfoName");
|
||||
nameItem.setRules("required|string");
|
||||
// 权限
|
||||
SearchConditionItem authorityItem = OrganizationFormItemUtil.textareaItem(user, 2, 17, true, 2, 0, "权限", "postInfoAuthority");
|
||||
|
|
@ -178,7 +178,7 @@ public class PostInfoServiceImpl extends Service implements PostInfoService {
|
|||
SearchConditionItem postIdBrowser = OrganizationFormItemUtil.browserItem(user, 2, 17, 3, false, "职务分类", "161", "postId", "postBrowser");
|
||||
postIdBrowser.setRules("required|string");
|
||||
// 说明
|
||||
SearchConditionItem descriptionItem = OrganizationFormItemUtil.textareaItem(user, 2, 17, true, 2, 200, "描述说明", "description");
|
||||
SearchConditionItem descriptionItem = OrganizationFormItemUtil.textareaItem(user, 2, 17, true, 2, 200, 547142, "description");
|
||||
|
||||
// 编辑状态下赋值操作
|
||||
String id = Util.null2String(params.get("id"));
|
||||
|
|
|
|||
|
|
@ -49,7 +49,7 @@ public class PostServiceImpl extends Service implements PostService {
|
|||
@Override
|
||||
public int deleteByIds(Collection<Long> ids) {
|
||||
HasRightUtil.hasRight(user, RIGHT_NAME, false);
|
||||
OrganizationAssert.notEmpty(ids, "请选择要删除的数据");
|
||||
OrganizationAssert.notEmpty(ids, SystemEnv.getHtmlLabelName(547138,user.getLanguage()));
|
||||
return getPostMapper().deleteByIds(ids);
|
||||
}
|
||||
|
||||
|
|
@ -59,9 +59,9 @@ public class PostServiceImpl extends Service implements PostService {
|
|||
Map<String, Object> apiDatas = new HashMap<>();
|
||||
List<SearchConditionItem> selectItems = new ArrayList<>();
|
||||
List<SearchConditionGroup> addGroups = new ArrayList<>();
|
||||
SearchConditionItem postNameItem = OrganizationFormItemUtil.inputItem(user, 2, 17, 3, 50, "名称", "postName");
|
||||
SearchConditionItem postNameItem = OrganizationFormItemUtil.inputItem(user, 2, 17, 3, 50, 547141, "postName");
|
||||
postNameItem.setRules("required|string");
|
||||
SearchConditionItem descriptionItem = OrganizationFormItemUtil.textareaItem(user, 2, 17, true, 2, 200, "描述说明", "description");
|
||||
SearchConditionItem descriptionItem = OrganizationFormItemUtil.textareaItem(user, 2, 17, true, 2, 200, 547142, "description");
|
||||
|
||||
// 编辑状态下赋值操作
|
||||
String id = Util.null2String(params.get("id"));
|
||||
|
|
|
|||
|
|
@ -71,7 +71,7 @@ public class QuickSearchServiceImpl extends Service implements QuickSearchServic
|
|||
} else {
|
||||
// 字段本身值、判断有无下拉框选项
|
||||
List<ConditionOption> options = selectOptions.stream().map(item -> ConditionOption.builder().key(item.getKey()).showname(item.getShowname()).build()).collect(Collectors.toList());
|
||||
options.add(0,ConditionOption.builder().key("-1").showname("全部").build());
|
||||
options.add(0,ConditionOption.builder().key("-1").showname(SystemEnv.getHtmlLabelName(547191,user.getLanguage())).build());
|
||||
condition.setOptions(options);
|
||||
}
|
||||
rangeConditions.add(condition);
|
||||
|
|
@ -105,7 +105,7 @@ public class QuickSearchServiceImpl extends Service implements QuickSearchServic
|
|||
condition.setCom("未设置选项");
|
||||
} else {
|
||||
List<ConditionOption> collect = quickSearchDetailList.stream().map(item -> ConditionOption.builder().key(item.getId().toString()).showname(item.getCustomName()).build()).collect(Collectors.toList());
|
||||
collect.add(0,ConditionOption.builder().key("-1").showname("全部").build());
|
||||
collect.add(0,ConditionOption.builder().key("-1").showname(SystemEnv.getHtmlLabelName(547191,user.getLanguage())).build());
|
||||
condition.setOptions(collect);
|
||||
}
|
||||
rangeConditions.add(condition);
|
||||
|
|
|
|||
|
|
@ -96,9 +96,9 @@ public class ResourceBasicInfoServiceImpl extends Service implements ResourceBas
|
|||
resourceTypeItem.setBrowserConditionParam(browserBean);
|
||||
}
|
||||
|
||||
SearchConditionItem fNo = OrganizationFormItemUtil.inputItem(user, 2, 17, 3, 50, "编号", "fno");
|
||||
SearchConditionItem fNo = OrganizationFormItemUtil.inputItem(user, 2, 17, 3, 50, 547118, "fno");
|
||||
fNo.setRules("required|string");
|
||||
SearchConditionItem fName = OrganizationFormItemUtil.inputItem(user, 2, 17, 3, 50, "名称", "fname");
|
||||
SearchConditionItem fName = OrganizationFormItemUtil.inputItem(user, 2, 17, 3, 50, 547141, "fname");
|
||||
fName.setRules("required|string");
|
||||
SearchConditionItem fMemo = OrganizationFormItemUtil.textareaItem(user, 2, 17, true, 2, 60, "说明", "fmemo");
|
||||
|
||||
|
|
@ -126,7 +126,7 @@ public class ResourceBasicInfoServiceImpl extends Service implements ResourceBas
|
|||
|
||||
@Override
|
||||
public int deletByIds(Collection<Long> ids) {
|
||||
OrganizationAssert.notEmpty(ids, "请选择要删除的数据");
|
||||
OrganizationAssert.notEmpty(ids, SystemEnv.getHtmlLabelName(547138,user.getLanguage()));
|
||||
return getResourceBasicInfoMapper().deleteByIds(ids);
|
||||
}
|
||||
|
||||
|
|
@ -158,9 +158,9 @@ public class ResourceBasicInfoServiceImpl extends Service implements ResourceBas
|
|||
String id = Util.null2String(params.get("fid"));
|
||||
List<SearchConditionItem> selectItems = new ArrayList<>();
|
||||
List<SearchConditionGroup> addGroups = new ArrayList<>();
|
||||
SearchConditionItem fNo = OrganizationFormItemUtil.inputItem(user, 2, 17, 3, 50, "编号", "fno");
|
||||
SearchConditionItem fNo = OrganizationFormItemUtil.inputItem(user, 2, 17, 3, 50, 547118, "fno");
|
||||
fNo.setRules("required|string");
|
||||
SearchConditionItem fName = OrganizationFormItemUtil.inputItem(user, 2, 17, 3, 50, "名称", "fname");
|
||||
SearchConditionItem fName = OrganizationFormItemUtil.inputItem(user, 2, 17, 3, 50, 547141, "fname");
|
||||
fName.setRules("required|string");
|
||||
SearchConditionItem fMemo = OrganizationFormItemUtil.textareaItem(user, 2, 17, true, 2, 60, "说明", "fmemo");
|
||||
|
||||
|
|
@ -212,8 +212,8 @@ public class ResourceBasicInfoServiceImpl extends Service implements ResourceBas
|
|||
public List<SearchConditionGroup> getSearchCondition() {
|
||||
List<SearchConditionGroup> addGroups = new ArrayList<>();
|
||||
List<SearchConditionItem> conditionItems = new ArrayList<>();
|
||||
SearchConditionItem schemeNameCondition = OrganizationFormItemUtil.inputItem(user, 2, 16, 2, 50, "名称", "fname");
|
||||
SearchConditionItem schemeNoCondition = OrganizationFormItemUtil.inputItem(user, 2, 16, 2, 50, "编号", "fno");
|
||||
SearchConditionItem schemeNameCondition = OrganizationFormItemUtil.inputItem(user, 2, 16, 2, 50, 547141, "fname");
|
||||
SearchConditionItem schemeNoCondition = OrganizationFormItemUtil.inputItem(user, 2, 16, 2, 50, 547118, "fno");
|
||||
conditionItems.add(schemeNameCondition);
|
||||
conditionItems.add(schemeNoCondition);
|
||||
addGroups.add(new SearchConditionGroup("高级搜索条件", true, conditionItems));
|
||||
|
|
|
|||
|
|
@ -139,7 +139,7 @@ public class SequenceServiceImpl extends Service implements SequenceService {
|
|||
@Override
|
||||
public int deleteByIds(Collection<Long> ids) {
|
||||
HasRightUtil.hasRight(user, RIGHT_NAME, false);
|
||||
OrganizationAssert.notEmpty(ids, "请选择要删除的数据");
|
||||
OrganizationAssert.notEmpty(ids, SystemEnv.getHtmlLabelName(547138,user.getLanguage()));
|
||||
return getSequenceMapper().deleteByIds(ids);
|
||||
}
|
||||
|
||||
|
|
@ -149,8 +149,8 @@ public class SequenceServiceImpl extends Service implements SequenceService {
|
|||
Map<String, Object> apiDatas = new HashMap<>();
|
||||
List<SearchConditionGroup> addGroups = new ArrayList<>();
|
||||
List<SearchConditionItem> conditionItems = new ArrayList<>();
|
||||
SearchConditionItem browserItem = OrganizationFormItemUtil.browserItem(user, 2, 16, 2, false, "等级方案", "161", "schemeId", "schemeBrowser");
|
||||
SearchConditionItem sequenceNameCondition = OrganizationFormItemUtil.inputItem(user, 2, 16, 2, 50, "名称", "sequenceName");
|
||||
SearchConditionItem browserItem = OrganizationFormItemUtil.browserItem(user, 2, 16, 2, false, 547124, "161", "schemeId", "schemeBrowser");
|
||||
SearchConditionItem sequenceNameCondition = OrganizationFormItemUtil.inputItem(user, 2, 16, 2, 50, 547141, "sequenceName");
|
||||
conditionItems.add(browserItem);
|
||||
conditionItems.add(sequenceNameCondition);
|
||||
addGroups.add(new SearchConditionGroup("高级搜索条件", true, conditionItems));
|
||||
|
|
@ -165,12 +165,12 @@ public class SequenceServiceImpl extends Service implements SequenceService {
|
|||
Map<String, Object> apiDatas = new HashMap<>();
|
||||
List<SearchConditionItem> selectItems = new ArrayList<>();
|
||||
List<SearchConditionGroup> addGroups = new ArrayList<>();
|
||||
SearchConditionItem sequenceNameCondition = OrganizationFormItemUtil.inputItem(user, 2, 17, 3, 50, "名称", "sequenceName");
|
||||
SearchConditionItem sequenceNameCondition = OrganizationFormItemUtil.inputItem(user, 2, 17, 3, 50, 547141, "sequenceName");
|
||||
sequenceNameCondition.setRules("required|string");
|
||||
SearchConditionItem sequenceNoCondition = OrganizationFormItemUtil.inputItem(user, 2, 17, 3, 50, "编号", "sequenceNo");
|
||||
SearchConditionItem sequenceNoCondition = OrganizationFormItemUtil.inputItem(user, 2, 17, 3, 50, 547118, "sequenceNo");
|
||||
sequenceNoCondition.setRules("required|string");
|
||||
SearchConditionItem descriptionCondition = OrganizationFormItemUtil.textareaItem(user, 2, 17, true, 2, 200, "描述说明", "description");
|
||||
SearchConditionItem browserItem = OrganizationFormItemUtil.browserItem(user, 2, 17, 3, false, "等级方案", "161", "schemeId", "schemeBrowser");
|
||||
SearchConditionItem descriptionCondition = OrganizationFormItemUtil.textareaItem(user, 2, 17, true, 2, 200, 547142, "description");
|
||||
SearchConditionItem browserItem = OrganizationFormItemUtil.browserItem(user, 2, 17, 3, false, 547124, "161", "schemeId", "schemeBrowser");
|
||||
browserItem.setRules("required|string");
|
||||
|
||||
// 编辑状态下赋值操作
|
||||
|
|
@ -214,9 +214,9 @@ public class SequenceServiceImpl extends Service implements SequenceService {
|
|||
public Map<String, Object> getTabInfo() {
|
||||
Map<String, Object> apiDatas = new HashMap<>();
|
||||
List<TopTab> topTabs = new ArrayList<>();
|
||||
topTabs.add(TopTab.builder().color("#000000").groupId("flowAll").showcount(true).title("全部").viewCondition("-1").build());
|
||||
topTabs.add(TopTab.builder().color("#ff3232").groupId("enable").showcount(true).title("启用").viewCondition("0").build());
|
||||
topTabs.add(TopTab.builder().color("#fea468").groupId("disable").showcount(true).title("禁用").viewCondition("1").build());
|
||||
topTabs.add(TopTab.builder().color("#000000").groupId("flowAll").showcount(true).title(SystemEnv.getHtmlLabelName(547191,user.getLanguage())).viewCondition("-1").build());
|
||||
topTabs.add(TopTab.builder().color("#ff3232").groupId("enable").showcount(true).title(SystemEnv.getHtmlLabelName(547186,user.getLanguage())).viewCondition("0").build());
|
||||
topTabs.add(TopTab.builder().color("#fea468").groupId("disable").showcount(true).title(SystemEnv.getHtmlLabelName(547192, user.getLanguage())).viewCondition("1").build());
|
||||
apiDatas.put("topTabs", topTabs);
|
||||
|
||||
HashMap<String, Integer> countMap = new HashMap<>();
|
||||
|
|
|
|||
|
|
@ -115,7 +115,7 @@ public class StaffPlanServiceImpl extends Service implements StaffPlanService {
|
|||
@Override
|
||||
public int deleteByIds(Collection<Long> ids) {
|
||||
HasRightUtil.hasRight(user, RIGHT_NAME, false);
|
||||
OrganizationAssert.notEmpty(ids, "请选择要删除的数据");
|
||||
OrganizationAssert.notEmpty(ids, SystemEnv.getHtmlLabelName(547138,user.getLanguage()));
|
||||
return getStaffPlanMapper().deleteByIds(ids);
|
||||
}
|
||||
|
||||
|
|
@ -125,9 +125,9 @@ public class StaffPlanServiceImpl extends Service implements StaffPlanService {
|
|||
List<SearchConditionGroup> addGroups = new ArrayList<>();
|
||||
List<SearchConditionItem> conditionItems = new ArrayList<>();
|
||||
// 编号
|
||||
SearchConditionItem planNoItem = OrganizationFormItemUtil.inputItem(user, 2, 16, 2, 50, "编号", "planNo");
|
||||
SearchConditionItem planNoItem = OrganizationFormItemUtil.inputItem(user, 2, 16, 2, 50, 547118, "planNo");
|
||||
// 名称
|
||||
SearchConditionItem planNameItem = OrganizationFormItemUtil.inputItem(user, 2, 16, 2, 50, "名称", "planName");
|
||||
SearchConditionItem planNameItem = OrganizationFormItemUtil.inputItem(user, 2, 16, 2, 50, 547141, "planName");
|
||||
// 年度
|
||||
SearchConditionItem planYearItem = OrganizationFormItemUtil.datePickerItem(user, 2, 16, false, 2, "年度", "planYear");
|
||||
planYearItem.setFormat("YYYY");
|
||||
|
|
@ -141,8 +141,8 @@ public class StaffPlanServiceImpl extends Service implements StaffPlanService {
|
|||
SearchConditionItem descriptionItem = OrganizationFormItemUtil.inputItem(user, 2, 16, 2, 50, "说明", "description");
|
||||
// 状态
|
||||
List<SearchConditionOption> selectOptions = new ArrayList<>();
|
||||
SearchConditionOption enableOption = new SearchConditionOption("true", "启用");
|
||||
SearchConditionOption disableOption = new SearchConditionOption("false", "禁用");
|
||||
SearchConditionOption enableOption = new SearchConditionOption("true", SystemEnv.getHtmlLabelName(547186, user.getLanguage()));
|
||||
SearchConditionOption disableOption = new SearchConditionOption("false", SystemEnv.getHtmlLabelName(547192, user.getLanguage()));
|
||||
selectOptions.add(enableOption);
|
||||
selectOptions.add(disableOption);
|
||||
SearchConditionItem forbiddenTagItem = OrganizationFormItemUtil.selectItem(user, selectOptions, 2, 16, 6, false, "禁用标记", "forbiddenTag");
|
||||
|
|
@ -168,10 +168,10 @@ public class StaffPlanServiceImpl extends Service implements StaffPlanService {
|
|||
List<SearchConditionItem> selectItems = new ArrayList<>();
|
||||
List<SearchConditionGroup> addGroups = new ArrayList<>();
|
||||
// 编号
|
||||
SearchConditionItem planNoItem = OrganizationFormItemUtil.inputItem(user, 2, 16, 3, 50, "编号", "planNo");
|
||||
SearchConditionItem planNoItem = OrganizationFormItemUtil.inputItem(user, 2, 16, 3, 50, 547118, "planNo");
|
||||
planNoItem.setRules("required|string");
|
||||
// 名称
|
||||
SearchConditionItem planNameItem = OrganizationFormItemUtil.inputItem(user, 2, 16, 3, 50, "名称", "planName");
|
||||
SearchConditionItem planNameItem = OrganizationFormItemUtil.inputItem(user, 2, 16, 3, 50, 547141, "planName");
|
||||
planNameItem.setRules("required|string");
|
||||
// 年度
|
||||
SearchConditionItem planYearItem = OrganizationFormItemUtil.datePickerItem(user, 2, 16, false, 3, "年度", "planYear");
|
||||
|
|
|
|||
|
|
@ -188,7 +188,7 @@ public class StaffServiceImpl extends Service implements StaffService {
|
|||
@Override
|
||||
public int deleteByIds(Collection<Long> ids) {
|
||||
HasRightUtil.hasRight(user, RIGHT_NAME, false);
|
||||
OrganizationAssert.notEmpty(ids, "请选择要删除的数据");
|
||||
OrganizationAssert.notEmpty(ids, SystemEnv.getHtmlLabelName(547138,user.getLanguage()));
|
||||
List<StaffPO> staffsByIds = getStaffMapper().getStaffsByIds(ids);
|
||||
int deleteByIds = getStaffMapper().deleteByIds(ids);
|
||||
//for (StaffPO staffsById : staffsByIds) {
|
||||
|
|
@ -286,7 +286,7 @@ public class StaffServiceImpl extends Service implements StaffService {
|
|||
controlPolicyItem.setViewAttr(3);
|
||||
controlPolicyItem.setValue("1");
|
||||
controlPolicyItem.setRules("required|string");
|
||||
SearchConditionItem descriptionItem = OrganizationFormItemUtil.textareaItem(user, 2, 16, true, 2, 200, "描述说明", "description");
|
||||
SearchConditionItem descriptionItem = OrganizationFormItemUtil.textareaItem(user, 2, 16, true, 2, 200, 547142, "description");
|
||||
|
||||
StaffPlanPO staffPlanPO = new StaffPlanPO();
|
||||
// 编辑状态下赋值操作
|
||||
|
|
|
|||
|
|
@ -16,8 +16,10 @@ public class Column {
|
|||
boolean display;
|
||||
String width;
|
||||
boolean sorter;
|
||||
int labelId;
|
||||
|
||||
public Column(String title, String dataIndex, String key, String width) {
|
||||
public Column(int labelId, String title, String dataIndex, String key, String width) {
|
||||
this.labelId = labelId;
|
||||
this.title = title;
|
||||
this.dataIndex = dataIndex;
|
||||
this.key = key;
|
||||
|
|
|
|||
|
|
@ -56,7 +56,8 @@ public class PageInfo<T> extends com.github.pagehelper.PageInfo<T> {
|
|||
boolean display = annotation.display();
|
||||
String width = annotation.width();
|
||||
boolean sorter = annotation.sorter();
|
||||
Column column = Column.builder().sorter(sorter).width(width).title(title).dataIndex(dataIndex).key(key).display(display).build();
|
||||
int labelId = annotation.labelId();
|
||||
Column column = Column.builder().sorter(sorter).width(width).labelId(labelId).title(title).dataIndex(dataIndex).key(key).display(display).build();
|
||||
columns.add(column);
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -1,22 +1,24 @@
|
|||
package com.engine.organization.util.response;
|
||||
|
||||
public enum ResultCode implements IErrorCode {
|
||||
SUCCESS(200,"操作成功"),
|
||||
FAILED(500,"操作失败"),
|
||||
VALIDATE_FAILED(404,"参数检验失败"),
|
||||
UNAUTHORIZED(401,"暂未登陆或相关token已经过期"),
|
||||
FORBIDDEN(403,"没有相关权限"),
|
||||
public enum ResultCode implements IErrorCode {
|
||||
SUCCESS(200, "操作成功", 547157),
|
||||
FAILED(500, "操作失败", 547158),
|
||||
VALIDATE_FAILED(404, "参数检验失败", -1),
|
||||
UNAUTHORIZED(401, "暂未登陆或相关token已经过期", -1),
|
||||
FORBIDDEN(403, "没有相关权限", -1),
|
||||
|
||||
|
||||
BODY_NOT_MATCH(400,"请求的数据格式不符!"),
|
||||
INTERNAL_SERVER_ERROR(500, "服务器内部错误!"),
|
||||
SERVER_BUSY(503,"服务器正忙,请稍后再试!");
|
||||
BODY_NOT_MATCH(400, "请求的数据格式不符!", -1),
|
||||
INTERNAL_SERVER_ERROR(500, "服务器内部错误!", -1),
|
||||
SERVER_BUSY(503, "服务器正忙,请稍后再试!", -1);
|
||||
private long code;
|
||||
private String msg;
|
||||
private int labelId;
|
||||
|
||||
ResultCode(long code, String msg) {
|
||||
ResultCode(long code, String msg, int labelId) {
|
||||
this.code = code;
|
||||
this.msg = msg;
|
||||
this.labelId = labelId;
|
||||
}
|
||||
|
||||
@Override
|
||||
|
|
@ -28,11 +30,18 @@ public enum ResultCode implements IErrorCode {
|
|||
public String getMessage() {
|
||||
return msg;
|
||||
}
|
||||
|
||||
@Override
|
||||
public int getLabelId() {
|
||||
return labelId;
|
||||
}
|
||||
}
|
||||
|
||||
interface IErrorCode {
|
||||
long getCode();
|
||||
|
||||
String getMessage();
|
||||
|
||||
int getLabelId();
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -8,6 +8,8 @@ package com.engine.organization.util.response;
|
|||
**/
|
||||
|
||||
import weaver.general.BaseBean;
|
||||
import weaver.hrm.User;
|
||||
import weaver.systeminfo.SystemEnv;
|
||||
|
||||
import java.io.Serializable;
|
||||
|
||||
|
|
@ -111,11 +113,24 @@ public class ReturnResult<T> implements Serializable {
|
|||
* @param data
|
||||
* @return
|
||||
*/
|
||||
@Deprecated
|
||||
public static <T> ReturnResult<T> successed(T data) {
|
||||
|
||||
return new ReturnResult<>(ResultCode.SUCCESS.getCode(), ResultCode.SUCCESS.getMessage(), data);
|
||||
}
|
||||
|
||||
/**
|
||||
* 多语言响应
|
||||
*
|
||||
* @param user
|
||||
* @param data
|
||||
* @param <T>
|
||||
* @return
|
||||
*/
|
||||
public static <T> ReturnResult<T> successed(User user, T data) {
|
||||
return new ReturnResult<>(ResultCode.SUCCESS.getCode(), SystemEnv.getHtmlLabelName(ResultCode.SUCCESS.getLabelId(), user.getLanguage()), data);
|
||||
}
|
||||
|
||||
/**
|
||||
* 异常处理
|
||||
*
|
||||
|
|
|
|||
|
|
@ -47,7 +47,7 @@ public class SchemeController {
|
|||
try {
|
||||
User user = HrmUserVarify.getUser(request, response);
|
||||
Map<String, Object> map = ParamUtil.request2Map(request);
|
||||
return ReturnResult.successed(getSchemeWrapper(user).listPage(map));
|
||||
return ReturnResult.successed(user,getSchemeWrapper(user).listPage(map));
|
||||
} catch (Exception e) {
|
||||
return ReturnResult.exceptionHandle(e);
|
||||
}
|
||||
|
|
@ -66,7 +66,7 @@ public class SchemeController {
|
|||
public ReturnResult saveScheme(@Context HttpServletRequest request, @Context HttpServletResponse response, @RequestBody SchemeSearchParam param) {
|
||||
try {
|
||||
User user = HrmUserVarify.getUser(request, response);
|
||||
return ReturnResult.successed(getSchemeWrapper(user).save(param));
|
||||
return ReturnResult.successed(user,getSchemeWrapper(user).save(param));
|
||||
} catch (Exception e) {
|
||||
return ReturnResult.exceptionHandle(e);
|
||||
}
|
||||
|
|
@ -86,7 +86,7 @@ public class SchemeController {
|
|||
public ReturnResult updateScheme(@Context HttpServletRequest request, @Context HttpServletResponse response, @RequestBody SchemeSearchParam param) {
|
||||
try {
|
||||
User user = HrmUserVarify.getUser(request, response);
|
||||
return ReturnResult.successed(getSchemeWrapper(user).updateScheme(param));
|
||||
return ReturnResult.successed(user,getSchemeWrapper(user).updateScheme(param));
|
||||
} catch (Exception e) {
|
||||
return ReturnResult.exceptionHandle(e);
|
||||
}
|
||||
|
|
@ -107,7 +107,7 @@ public class SchemeController {
|
|||
public ReturnResult updateForbiddenTagById(@Context HttpServletRequest request, @Context HttpServletResponse response, @RequestBody SchemeSearchParam param) {
|
||||
try {
|
||||
User user = HrmUserVarify.getUser(request, response);
|
||||
return ReturnResult.successed(getSchemeWrapper(user).updateForbiddenTagById(param));
|
||||
return ReturnResult.successed(user,getSchemeWrapper(user).updateForbiddenTagById(param));
|
||||
} catch (Exception e) {
|
||||
return ReturnResult.exceptionHandle(e);
|
||||
}
|
||||
|
|
@ -128,7 +128,7 @@ public class SchemeController {
|
|||
public ReturnResult deleteByIds(@Context HttpServletRequest request, @Context HttpServletResponse response, @RequestBody DeleteParam param) {
|
||||
try {
|
||||
User user = HrmUserVarify.getUser(request, response);
|
||||
return ReturnResult.successed(getSchemeWrapper(user).deleteByIds(param.getIds()));
|
||||
return ReturnResult.successed(user,getSchemeWrapper(user).deleteByIds(param.getIds()));
|
||||
} catch (Exception e) {
|
||||
return ReturnResult.exceptionHandle(e);
|
||||
}
|
||||
|
|
@ -141,7 +141,7 @@ public class SchemeController {
|
|||
try {
|
||||
User user = HrmUserVarify.getUser(request, response);
|
||||
Map<String, Object> map = ParamUtil.request2Map(request);
|
||||
return ReturnResult.successed(getSchemeWrapper(user).getSearchCondition(map));
|
||||
return ReturnResult.successed(user,getSchemeWrapper(user).getSearchCondition(map));
|
||||
} catch (Exception e) {
|
||||
return ReturnResult.exceptionHandle(e);
|
||||
}
|
||||
|
|
@ -155,7 +155,7 @@ public class SchemeController {
|
|||
try {
|
||||
User user = HrmUserVarify.getUser(request, response);
|
||||
Map<String, Object> map = ParamUtil.request2Map(request);
|
||||
return ReturnResult.successed(getSchemeWrapper(user).getSchemeForm(map));
|
||||
return ReturnResult.successed(user,getSchemeWrapper(user).getSchemeForm(map));
|
||||
} catch (Exception e) {
|
||||
return ReturnResult.exceptionHandle(e);
|
||||
}
|
||||
|
|
@ -167,7 +167,7 @@ public class SchemeController {
|
|||
public ReturnResult getTableBtn(@Context HttpServletRequest request, @Context HttpServletResponse response) {
|
||||
try {
|
||||
User user = HrmUserVarify.getUser(request, response);
|
||||
return ReturnResult.successed(getSchemeWrapper(user).getTableBtn());
|
||||
return ReturnResult.successed(user,getSchemeWrapper(user).getTableBtn());
|
||||
} catch (Exception e) {
|
||||
return ReturnResult.exceptionHandle(e);
|
||||
}
|
||||
|
|
@ -179,7 +179,7 @@ public class SchemeController {
|
|||
public ReturnResult getTreeData(@Context HttpServletRequest request, @Context HttpServletResponse response) {
|
||||
try {
|
||||
User user = HrmUserVarify.getUser(request, response);
|
||||
return ReturnResult.successed(getSchemeWrapper(user).getTreeData());
|
||||
return ReturnResult.successed(user,getSchemeWrapper(user).getTreeData());
|
||||
} catch (Exception e) {
|
||||
return ReturnResult.exceptionHandle(e);
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in New Issue