提交 b27861ad 编写于 作者: ibizdev's avatar ibizdev

xignzi006 发布系统代码 [Spring Boot]

上级 7b3747cd
......@@ -234,14 +234,6 @@ public class Account_journal extends EntityMP implements Serializable {
@JSONField(name = "update_posted")
@JsonProperty("update_posted")
private Boolean updatePosted;
/**
* 授权差异的总金额
*/
@DEField(name = "amount_authorized_diff")
@TableField(value = "amount_authorized_diff")
@JSONField(name = "amount_authorized_diff")
@JsonProperty("amount_authorized_diff")
private Double amountAuthorizedDiff;
/**
* 看板仪表板图表
*/
......@@ -643,14 +635,6 @@ public class Account_journal extends EntityMP implements Serializable {
this.modify("update_posted",updatePosted);
}
/**
* 设置 [授权差异的总金额]
*/
public void setAmountAuthorizedDiff(Double amountAuthorizedDiff){
this.amountAuthorizedDiff = amountAuthorizedDiff ;
this.modify("amount_authorized_diff",amountAuthorizedDiff);
}
/**
* 设置 [类型]
*/
......
......@@ -479,10 +479,10 @@ public class Res_usersServiceImpl extends EBSServiceImpl<Res_usersMapper, Res_us
protected cn.ibizlab.businesscentral.core.odoo_hr.service.IHr_attendanceService hrAttendanceService;
@Autowired
@Lazy
protected cn.ibizlab.businesscentral.core.odoo_hr.service.IHr_contract_typeService hrContractTypeService;
protected cn.ibizlab.businesscentral.core.odoo_hr.service.IHr_contractService hrContractService;
@Autowired
@Lazy
protected cn.ibizlab.businesscentral.core.odoo_hr.service.IHr_contractService hrContractService;
protected cn.ibizlab.businesscentral.core.odoo_hr.service.IHr_contract_typeService hrContractTypeService;
@Autowired
@Lazy
protected cn.ibizlab.businesscentral.core.odoo_hr.service.IHr_departmentService hrDepartmentService;
......
......@@ -429,6 +429,29 @@ public class Hr_contract extends EntityMP implements Serializable {
@JSONField(name = "department_id")
@JsonProperty("department_id")
private Long departmentId;
/**
* 人力资源主管
*/
@DEField(name = "hr_responsible_id")
@TableField(value = "hr_responsible_id")
@JSONField(name = "hr_responsible_id")
@JsonProperty("hr_responsible_id")
private Long hrResponsibleId;
/**
* 人力资源主管
*/
@TableField(exist = false)
@JSONField(name = "hr_responsible_name")
@JsonProperty("hr_responsible_name")
private String hrResponsibleName;
/**
*
*/
@JsonIgnore
@JSONField(serialize = false)
@TableField(exist = false)
private cn.ibizlab.businesscentral.core.odoo_base.domain.Res_users odooHrResponsible;
/**
*
......@@ -638,6 +661,14 @@ public class Hr_contract extends EntityMP implements Serializable {
this.modify("department_id",departmentId);
}
/**
* 设置 [人力资源主管]
*/
public void setHrResponsibleId(Long hrResponsibleId){
this.hrResponsibleId = hrResponsibleId ;
this.modify("hr_responsible_id",hrResponsibleId);
}
@Override
public Serializable getDefaultKey(boolean gen) {
......
......@@ -195,6 +195,27 @@ public class Hr_contractSearchContext extends QueryWrapperContext<Hr_contract> {
this.getSearchCond().eq("department_id", n_department_id_eq);
}
}
private Long n_hr_responsible_id_eq;//[人力资源主管]
public void setN_hr_responsible_id_eq(Long n_hr_responsible_id_eq) {
this.n_hr_responsible_id_eq = n_hr_responsible_id_eq;
if(!ObjectUtils.isEmpty(this.n_hr_responsible_id_eq)){
this.getSearchCond().eq("hr_responsible_id", n_hr_responsible_id_eq);
}
}
private String n_hr_responsible_name_eq;//[人力资源主管]
public void setN_hr_responsible_name_eq(String n_hr_responsible_name_eq) {
this.n_hr_responsible_name_eq = n_hr_responsible_name_eq;
if(!ObjectUtils.isEmpty(this.n_hr_responsible_name_eq)){
this.getSearchCond().eq("hr_responsible_name", n_hr_responsible_name_eq);
}
}
private String n_hr_responsible_name_like;//[人力资源主管]
public void setN_hr_responsible_name_like(String n_hr_responsible_name_like) {
this.n_hr_responsible_name_like = n_hr_responsible_name_like;
if(!ObjectUtils.isEmpty(this.n_hr_responsible_name_like)){
this.getSearchCond().like("hr_responsible_name", n_hr_responsible_name_like);
}
}
/**
* 启用快速搜索
......
......@@ -62,6 +62,8 @@ public interface Hr_contractMapper extends BaseMapper<Hr_contract>{
@Delete("${sql}")
boolean deleteBySQL(@Param("sql") String sql, @Param("et")Map param);
List<Hr_contract> selectByHrResponsibleId(@Param("id") Serializable id) ;
List<Hr_contract> selectByDepartmentId(@Param("id") Serializable id) ;
List<Hr_contract> selectByEmployeeId(@Param("id") Serializable id) ;
......
......@@ -37,6 +37,8 @@ public interface IHr_contractService extends IService<Hr_contract>{
boolean save(Hr_contract et) ;
void saveBatch(List<Hr_contract> list) ;
Page<Hr_contract> searchDefault(Hr_contractSearchContext context) ;
List<Hr_contract> selectByHrResponsibleId(Long id);
void removeByHrResponsibleId(Long id);
List<Hr_contract> selectByDepartmentId(Long id);
void resetByDepartmentId(Long id);
void resetByDepartmentId(Collection<Long> ids);
......
......@@ -51,6 +51,9 @@ import org.springframework.util.StringUtils;
@Service("Hr_contractServiceImpl")
public class Hr_contractServiceImpl extends EBSServiceImpl<Hr_contractMapper, Hr_contract> implements IHr_contractService {
@Autowired
@Lazy
protected cn.ibizlab.businesscentral.core.odoo_base.service.IRes_usersService resUsersService;
@Autowired
@Lazy
protected cn.ibizlab.businesscentral.core.odoo_hr.service.IHr_departmentService hrDepartmentService;
......@@ -66,9 +69,6 @@ public class Hr_contractServiceImpl extends EBSServiceImpl<Hr_contractMapper, Hr
@Autowired
@Lazy
protected cn.ibizlab.businesscentral.core.odoo_base.service.IRes_companyService resCompanyService;
@Autowired
@Lazy
protected cn.ibizlab.businesscentral.core.odoo_base.service.IRes_usersService resUsersService;
protected int batchSize = 500;
......@@ -207,6 +207,15 @@ public class Hr_contractServiceImpl extends EBSServiceImpl<Hr_contractMapper, Hr
}
@Override
public List<Hr_contract> selectByHrResponsibleId(Long id) {
return baseMapper.selectByHrResponsibleId(id);
}
@Override
public void removeByHrResponsibleId(Long id) {
this.remove(new QueryWrapper<Hr_contract>().eq("hr_responsible_id",id));
}
@Override
public List<Hr_contract> selectByDepartmentId(Long id) {
return baseMapper.selectByDepartmentId(id);
......@@ -337,6 +346,16 @@ public class Hr_contractServiceImpl extends EBSServiceImpl<Hr_contractMapper, Hr
* @param et
*/
private void fillParentData(Hr_contract et){
//实体关系[DER1N_HR_CONTRACT_RES_USERS_HR_RESPONSIBLE_ID]
if(!ObjectUtils.isEmpty(et.getHrResponsibleId())){
cn.ibizlab.businesscentral.core.odoo_base.domain.Res_users odooHrResponsible=et.getOdooHrResponsible();
if(ObjectUtils.isEmpty(odooHrResponsible)){
cn.ibizlab.businesscentral.core.odoo_base.domain.Res_users majorEntity=resUsersService.get(et.getHrResponsibleId());
et.setOdooHrResponsible(majorEntity);
odooHrResponsible=majorEntity;
}
et.setHrResponsibleName(odooHrResponsible.getName());
}
//实体关系[DER1N_HR_CONTRACT__HR_DEPARTMENT__DEPARTMENT_ID]
if(!ObjectUtils.isEmpty(et.getDepartmentId())){
cn.ibizlab.businesscentral.core.odoo_hr.domain.Hr_department odooDepartment=et.getOdooDepartment();
......
......@@ -19061,19 +19061,6 @@
"major_field":0
},
{
"fieldname":"AMOUNT_AUTHORIZED_DIFF" ,
"codename":"Amount_authorized_diff",
"field_logic_name":"授权差异的总金额",
"entity_name":"Account_journal",
"field_type":"FLOAT",
"nullable":1,
"physical_field":1,
"data_type":"FLOAT",
"key_field":0,
"show_order":1000,
"major_field":0
},
{
"fieldname":"KANBAN_DASHBOARD_GRAPH" ,
"codename":"Kanban_dashboard_graph",
"field_logic_name":"看板仪表板图表",
......@@ -63116,11 +63103,52 @@
"key_field":0,
"show_order":1000,
"major_field":0
},
{
"fieldname":"HR_RESPONSIBLE_ID" ,
"codename":"Hr_responsible_id",
"field_logic_name":"人力资源主管",
"entity_name":"Hr_contract",
"ref_de":"RES_USERS",
"ref_field_name":"ID",
"relation_name":"DER1N_HR_CONTRACT_RES_USERS_HR_RESPONSIBLE_ID",
"relation_codename":"Odoo_hr_responsible",
"field_type":"PICKUP",
"nullable":1,
"physical_field":1,
"data_type":"BIGINT",
"key_field":0,
"show_order":1000,
"major_field":0
},
{
"fieldname":"HR_RESPONSIBLE_NAME" ,
"codename":"Hr_responsible_name",
"field_logic_name":"人力资源主管",
"entity_name":"Hr_contract",
"ref_de":"RES_USERS",
"ref_field_name":"NAME",
"relation_name":"DER1N_HR_CONTRACT_RES_USERS_HR_RESPONSIBLE_ID",
"relation_codename":"Odoo_hr_responsible",
"field_type":"PICKUPTEXT",
"nullable":1,
"physical_field":0,
"data_type":"VARCHAR",
"data_length":100,
"key_field":0,
"show_order":1000,
"major_field":0
}
],
"subEntitys":[
],
"parentEntitys":[
{"name":"DER1N_HR_CONTRACT_RES_USERS_HR_RESPONSIBLE_ID",
"relation_type":"DER1N",
"code_name":"Odoo_hr_responsible",
"entity_name":"HR_CONTRACT",
"ref_entity_name":"RES_USERS"
},
{"name":"DER1N_HR_CONTRACT__HR_DEPARTMENT__DEPARTMENT_ID",
"relation_type":"DER1N",
"code_name":"Odoo_department",
......@@ -158518,6 +158546,12 @@
"entity_name":"HR_ATTENDANCE",
"ref_entity_name":"RES_USERS"
},
{"name":"DER1N_HR_CONTRACT_RES_USERS_HR_RESPONSIBLE_ID",
"relation_type":"DER1N",
"code_name":"Odoo_hr_responsible",
"entity_name":"HR_CONTRACT",
"ref_entity_name":"RES_USERS"
},
{"name":"DER1N_HR_CONTRACT_TYPE__RES_USERS__CREATE_UID",
"relation_type":"DER1N",
"code_name":"Odoo_create",
......@@ -244,14 +244,6 @@ public class Account_journalDTO extends DTOBase implements Serializable {
@JsonProperty("update_posted")
private Boolean updatePosted;
/**
* 属性 [AMOUNT_AUTHORIZED_DIFF]
*
*/
@JSONField(name = "amount_authorized_diff")
@JsonProperty("amount_authorized_diff")
private Double amountAuthorizedDiff;
/**
* 属性 [KANBAN_DASHBOARD_GRAPH]
*
......@@ -617,14 +609,6 @@ public class Account_journalDTO extends DTOBase implements Serializable {
this.modify("update_posted",updatePosted);
}
/**
* 设置 [AMOUNT_AUTHORIZED_DIFF]
*/
public void setAmountAuthorizedDiff(Double amountAuthorizedDiff){
this.amountAuthorizedDiff = amountAuthorizedDiff ;
this.modify("amount_authorized_diff",amountAuthorizedDiff);
}
/**
* 设置 [TYPE]
*/
......
......@@ -487,6 +487,24 @@ public class Hr_contractDTO extends DTOBase implements Serializable {
@JsonSerialize(using = ToStringSerializer.class)
private Long departmentId;
/**
* 属性 [HR_RESPONSIBLE_ID]
*
*/
@JSONField(name = "hr_responsible_id")
@JsonProperty("hr_responsible_id")
@JsonSerialize(using = ToStringSerializer.class)
private Long hrResponsibleId;
/**
* 属性 [HR_RESPONSIBLE_NAME]
*
*/
@JSONField(name = "hr_responsible_name")
@JsonProperty("hr_responsible_name")
@Size(min = 0, max = 100, message = "内容长度必须小于等于[100]")
private String hrResponsibleName;
/**
* 设置 [DATE_END]
......@@ -608,6 +626,14 @@ public class Hr_contractDTO extends DTOBase implements Serializable {
this.modify("department_id",departmentId);
}
/**
* 设置 [HR_RESPONSIBLE_ID]
*/
public void setHrResponsibleId(Long hrResponsibleId){
this.hrResponsibleId = hrResponsibleId ;
this.modify("hr_responsible_id",hrResponsibleId);
}
}
......
......@@ -2,6 +2,7 @@ package cn.ibizlab.businesscentral.util.annotation;
import cn.ibizlab.businesscentral.util.enums.DEFieldDefaultValueType;
import cn.ibizlab.businesscentral.util.enums.DEPredefinedFieldType;
import cn.ibizlab.businesscentral.util.enums.DupCheck;
import java.lang.annotation.ElementType;
import java.lang.annotation.Retention;
import java.lang.annotation.RetentionPolicy;
......@@ -66,5 +67,14 @@ public @interface DEField
* @return
*/
String format() default "";
/**
* 重复性检查
* @return
*/
DupCheck dupCheck() default DupCheck.NONE;
/**
* 范围属性
*/
String dupCheckField() default "";
}
package cn.ibizlab.businesscentral.util.enums;
/**
* 属性重复值检查
*/
public enum DupCheck {
/**
* 不检查
*/
NONE,
/**
* 全部检查
*/
ALL,
/**
* 非空检查
*/
NOTNULL,
/**
* 指定范围检查
*/
RANGE,
}
Markdown 格式
0% or
您添加了 0 到此讨论。请谨慎行事。
先完成此消息的编辑!
想要评论请 注册