Commit 41f4927d by liuyang

2024-03-29 设计图管理添加部门管理

parent 0150172e
...@@ -39,6 +39,7 @@ public class HPDS002 extends DaoEPBase { ...@@ -39,6 +39,7 @@ public class HPDS002 extends DaoEPBase {
public static final String FIELD_REAL_PATH = "realPath"; /* 物理路径*/ public static final String FIELD_REAL_PATH = "realPath"; /* 物理路径*/
public static final String FIELD_BIZ_TYPE = "bizType"; /* 业务类型*/ public static final String FIELD_BIZ_TYPE = "bizType"; /* 业务类型*/
public static final String FIELD_MAT_ID = "matId"; /* 业务类型*/ public static final String FIELD_MAT_ID = "matId"; /* 业务类型*/
public static final String FIELD_DEP_CODE = "depCode"; /* 部门编码 预留*/
public static final String COL_COMPANY_CODE = "COMPANY_CODE"; /* 企业编码*/ public static final String COL_COMPANY_CODE = "COMPANY_CODE"; /* 企业编码*/
public static final String COL_DOC_ID = "DOC_ID"; /* 文件标识*/ public static final String COL_DOC_ID = "DOC_ID"; /* 文件标识*/
...@@ -57,6 +58,7 @@ public class HPDS002 extends DaoEPBase { ...@@ -57,6 +58,7 @@ public class HPDS002 extends DaoEPBase {
public static final String COL_REAL_PATH = "REAL_PATH"; /* 物理路径*/ public static final String COL_REAL_PATH = "REAL_PATH"; /* 物理路径*/
public static final String COL_BIZ_TYPE = "BIZ_TYPE"; /* 业务类型*/ public static final String COL_BIZ_TYPE = "BIZ_TYPE"; /* 业务类型*/
public static final String COL_MAT_ID = "MAT_ID"; /* 业务类型*/ public static final String COL_MAT_ID = "MAT_ID"; /* 业务类型*/
public static final String COL_DEP_CODE = "DEP_CODE"; /* 部门编码 预留*/
public static final String QUERY = "HPDS002.query"; public static final String QUERY = "HPDS002.query";
public static final String COUNT = "HPDS002.count"; public static final String COUNT = "HPDS002.count";
...@@ -82,6 +84,7 @@ public class HPDS002 extends DaoEPBase { ...@@ -82,6 +84,7 @@ public class HPDS002 extends DaoEPBase {
private String realPath = " "; /* 物理路径*/ private String realPath = " "; /* 物理路径*/
private String bizType = " "; /* 业务类型*/ private String bizType = " "; /* 业务类型*/
private String matId = " "; /* 业务类型*/ private String matId = " "; /* 业务类型*/
private String depCode = " "; /* 部门编码 预留*/
/** /**
* initialize the metadata. * initialize the metadata.
...@@ -162,6 +165,9 @@ public class HPDS002 extends DaoEPBase { ...@@ -162,6 +165,9 @@ public class HPDS002 extends DaoEPBase {
eiColumn.setDescName("物料ID"); eiColumn.setDescName("物料ID");
eiMetadata.addMeta(eiColumn); eiMetadata.addMeta(eiColumn);
eiColumn = new EiColumn(FIELD_DEP_CODE);
eiColumn.setDescName("部门编码 预留");
eiMetadata.addMeta(eiColumn);
} }
...@@ -439,6 +445,14 @@ public class HPDS002 extends DaoEPBase { ...@@ -439,6 +445,14 @@ public class HPDS002 extends DaoEPBase {
this.matId = matId; this.matId = matId;
} }
public String getDepCode() {
return depCode;
}
public void setDepCode(String depCode) {
this.depCode = depCode;
}
/** /**
* get the value from Map. * get the value from Map.
* *
...@@ -464,6 +478,7 @@ public class HPDS002 extends DaoEPBase { ...@@ -464,6 +478,7 @@ public class HPDS002 extends DaoEPBase {
setRealPath(StringUtils.defaultIfEmpty(StringUtils.toString(map.get(FIELD_REAL_PATH)), realPath)); setRealPath(StringUtils.defaultIfEmpty(StringUtils.toString(map.get(FIELD_REAL_PATH)), realPath));
setBizType(StringUtils.defaultIfEmpty(StringUtils.toString(map.get(FIELD_BIZ_TYPE)), bizType)); setBizType(StringUtils.defaultIfEmpty(StringUtils.toString(map.get(FIELD_BIZ_TYPE)), bizType));
setMatId(StringUtils.defaultIfEmpty(StringUtils.toString(map.get(FIELD_MAT_ID)), matId)); setMatId(StringUtils.defaultIfEmpty(StringUtils.toString(map.get(FIELD_MAT_ID)), matId));
setDepCode(StringUtils.defaultIfEmpty(StringUtils.toString(map.get(FIELD_DEP_CODE)),depCode));
} }
/** /**
...@@ -490,7 +505,7 @@ public class HPDS002 extends DaoEPBase { ...@@ -490,7 +505,7 @@ public class HPDS002 extends DaoEPBase {
map.put(FIELD_REAL_PATH, StringUtils.toString(realPath, eiMetadata.getMeta(FIELD_REAL_PATH))); map.put(FIELD_REAL_PATH, StringUtils.toString(realPath, eiMetadata.getMeta(FIELD_REAL_PATH)));
map.put(FIELD_BIZ_TYPE, StringUtils.toString(bizType, eiMetadata.getMeta(FIELD_BIZ_TYPE))); map.put(FIELD_BIZ_TYPE, StringUtils.toString(bizType, eiMetadata.getMeta(FIELD_BIZ_TYPE)));
map.put(FIELD_MAT_ID, StringUtils.toString(matId, eiMetadata.getMeta(FIELD_MAT_ID))); map.put(FIELD_MAT_ID, StringUtils.toString(matId, eiMetadata.getMeta(FIELD_MAT_ID)));
map.put(FIELD_DEP_CODE,StringUtils.toString(depCode, eiMetadata.getMeta(FIELD_DEP_CODE)));
return map; return map;
} }
} }
...@@ -113,6 +113,7 @@ ...@@ -113,6 +113,7 @@
BIZ_TYPE as "bizType", BIZ_TYPE as "bizType",
MAT_ID as "matId" MAT_ID as "matId"
FROM ${hpjxSchema}.TEUDM_TEMP WHERE 1=1 FROM ${hpjxSchema}.TEUDM_TEMP WHERE 1=1
<include refid="authCondition"/>
<include refid="condition" /> <include refid="condition" />
<dynamic prepend="ORDER BY"> <dynamic prepend="ORDER BY">
<isNotEmpty property="orderBy"> <isNotEmpty property="orderBy">
...@@ -128,6 +129,7 @@ ...@@ -128,6 +129,7 @@
<select id="count" resultClass="int"> <select id="count" resultClass="int">
SELECT COUNT(*) FROM ${hpjxSchema}.TEUDM_TEMP WHERE 1=1 SELECT COUNT(*) FROM ${hpjxSchema}.TEUDM_TEMP WHERE 1=1
<include refid="authCondition"/>
<include refid="condition" /> <include refid="condition" />
</select> </select>
...@@ -197,15 +199,17 @@ ...@@ -197,15 +199,17 @@
ARCHIVE_FLAG, <!-- 同步标记 --> ARCHIVE_FLAG, <!-- 同步标记 -->
REAL_PATH, <!-- 物理路径 --> REAL_PATH, <!-- 物理路径 -->
BIZ_TYPE, BIZ_TYPE,
MAT_ID MAT_ID,
DEP_CODE
) )
VALUES (#companyCode#, #docId#, #dirId#, #docName#, #chgName#, #docSize#, #docTag#, #createdBy#, #createdName#, VALUES (#companyCode#, #docId#, #dirId#, #docName#, #chgName#, #docSize#, #docTag#, #createdBy#, #createdName#,
#createdTime#, #updatedBy#, #updatedName#, #updatedTime#, #archiveFlag#, #realPath#, #bizType#, #matId#) #createdTime#, #updatedBy#, #updatedName#, #updatedTime#, #archiveFlag#, #realPath#, #bizType#, #matId#, #depCode#)
</insert> </insert>
<delete id="delete"> <delete id="delete">
DELETE FROM ${hpjxSchema}.TEUDM_TEMP WHERE DELETE FROM ${hpjxSchema}.TEUDM_TEMP WHERE
COMPANY_CODE = #companyCode# COMPANY_CODE = #companyCode#
<include refid="authCondition"/>
<isNotEmpty prepend=" AND " property="docId"> <isNotEmpty prepend=" AND " property="docId">
DOC_ID = #docId# DOC_ID = #docId#
</isNotEmpty> </isNotEmpty>
...@@ -235,12 +239,14 @@ ...@@ -235,12 +239,14 @@
UPDATED_NAME = #updatedName#, <!-- 记录修改名称 --> UPDATED_NAME = #updatedName#, <!-- 记录修改名称 -->
UPDATED_TIME = #updatedTime#, <!-- 记录修改时间 --> UPDATED_TIME = #updatedTime#, <!-- 记录修改时间 -->
ARCHIVE_FLAG = #archiveFlag#, <!-- 同步标记 --> ARCHIVE_FLAG = #archiveFlag#, <!-- 同步标记 -->
REAL_PATH = #realPath# <!-- 物理路径 --> REAL_PATH = #realPath#, <!-- 物理路径 -->
BIZ_TYPE = #bizType# BIZ_TYPE = #bizType#,
MAT_ID = #matId# MAT_ID = #matId#,
DEP_CODE = #depCode#
WHERE WHERE
COMPANY_CODE = #companyCode# AND COMPANY_CODE = #companyCode# AND
DOC_ID = #docId# DOC_ID = #docId#
<include refid="condition" />
<isNotEmpty prepend=" AND " property="bizType"> <isNotEmpty prepend=" AND " property="bizType">
BIZ_TYPE = #bizType# BIZ_TYPE = #bizType#
</isNotEmpty> </isNotEmpty>
......
...@@ -43,6 +43,7 @@ public class HPXS002 extends DaoEPBase { ...@@ -43,6 +43,7 @@ public class HPXS002 extends DaoEPBase {
public static final String FIELD_PROJ_NAME = "projName"; /* 项目名称*/ public static final String FIELD_PROJ_NAME = "projName"; /* 项目名称*/
public static final String FIELD_PRDT_TYPE = "prdtType"; /* 产品类型*/ public static final String FIELD_PRDT_TYPE = "prdtType"; /* 产品类型*/
public static final String FIELD_PRDT_NAME = "prdtName"; /* 产品名称*/ public static final String FIELD_PRDT_NAME = "prdtName"; /* 产品名称*/
public static final String FIELD_DEP_CODE = "depCode"; /* 部门编码 预留*/
public static final String COL_COMPANY_CODE = "COMPANY_CODE"; /* 企业编码*/ public static final String COL_COMPANY_CODE = "COMPANY_CODE"; /* 企业编码*/
public static final String COL_DOC_ID = "DOC_ID"; /* 文件标识*/ public static final String COL_DOC_ID = "DOC_ID"; /* 文件标识*/
...@@ -61,6 +62,7 @@ public class HPXS002 extends DaoEPBase { ...@@ -61,6 +62,7 @@ public class HPXS002 extends DaoEPBase {
public static final String COL_REAL_PATH = "REAL_PATH"; /* 物理路径*/ public static final String COL_REAL_PATH = "REAL_PATH"; /* 物理路径*/
public static final String COL_BIZ_TYPE = "BIZ_TYPE"; /* 业务类型*/ public static final String COL_BIZ_TYPE = "BIZ_TYPE"; /* 业务类型*/
public static final String COL_MAT_ID = "MAT_ID"; /* 业务类型*/ public static final String COL_MAT_ID = "MAT_ID"; /* 业务类型*/
public static final String COL_DEP_CODE = "DEP_CODE"; /* 部门编码 预留*/
public static final String QUERY = "HPXS002.query"; public static final String QUERY = "HPXS002.query";
public static final String COUNT = "HPXS002.count"; public static final String COUNT = "HPXS002.count";
...@@ -89,6 +91,7 @@ public class HPXS002 extends DaoEPBase { ...@@ -89,6 +91,7 @@ public class HPXS002 extends DaoEPBase {
private String projName = " "; /* 项目名称*/ private String projName = " "; /* 项目名称*/
private Integer prdtType; /* 产品类型*/ private Integer prdtType; /* 产品类型*/
private String prdtName = " "; /* 产品名称*/ private String prdtName = " "; /* 产品名称*/
private String depCode = " "; /* 部门编码 预留*/
/** /**
* initialize the metadata. * initialize the metadata.
...@@ -181,6 +184,10 @@ public class HPXS002 extends DaoEPBase { ...@@ -181,6 +184,10 @@ public class HPXS002 extends DaoEPBase {
eiColumn.setDescName("产品名称"); eiColumn.setDescName("产品名称");
eiMetadata.addMeta(eiColumn); eiMetadata.addMeta(eiColumn);
eiColumn = new EiColumn(FIELD_DEP_CODE);
eiColumn.setDescName("部门编码 预留");
eiMetadata.addMeta(eiColumn);
} }
/** /**
...@@ -481,6 +488,14 @@ public class HPXS002 extends DaoEPBase { ...@@ -481,6 +488,14 @@ public class HPXS002 extends DaoEPBase {
this.prdtName = prdtName; this.prdtName = prdtName;
} }
public String getDepCode() {
return depCode;
}
public void setDepCode(String depCode) {
this.depCode = depCode;
}
/** /**
* get the value from Map. * get the value from Map.
* *
...@@ -509,6 +524,7 @@ public class HPXS002 extends DaoEPBase { ...@@ -509,6 +524,7 @@ public class HPXS002 extends DaoEPBase {
setProjName(StringUtils.defaultIfEmpty(StringUtils.toString(map.get(FIELD_PROJ_NAME)), projName)); setProjName(StringUtils.defaultIfEmpty(StringUtils.toString(map.get(FIELD_PROJ_NAME)), projName));
setPrdtType(NumberUtils.toInteger(StringUtils.toString(map.get(FIELD_PRDT_TYPE)), prdtType)); setPrdtType(NumberUtils.toInteger(StringUtils.toString(map.get(FIELD_PRDT_TYPE)), prdtType));
setPrdtName(StringUtils.defaultIfEmpty(StringUtils.toString(map.get(FIELD_PRDT_NAME)), prdtName)); setPrdtName(StringUtils.defaultIfEmpty(StringUtils.toString(map.get(FIELD_PRDT_NAME)), prdtName));
setDepCode(StringUtils.defaultIfEmpty(StringUtils.toString(map.get(FIELD_DEP_CODE)),depCode));
} }
/** /**
...@@ -538,6 +554,7 @@ public class HPXS002 extends DaoEPBase { ...@@ -538,6 +554,7 @@ public class HPXS002 extends DaoEPBase {
map.put(FIELD_PROJ_NAME, StringUtils.toString(projName, eiMetadata.getMeta(FIELD_PROJ_NAME))); map.put(FIELD_PROJ_NAME, StringUtils.toString(projName, eiMetadata.getMeta(FIELD_PROJ_NAME)));
map.put(FIELD_PRDT_TYPE, StringUtils.toString(prdtType, eiMetadata.getMeta(FIELD_PRDT_TYPE))); map.put(FIELD_PRDT_TYPE, StringUtils.toString(prdtType, eiMetadata.getMeta(FIELD_PRDT_TYPE)));
map.put(FIELD_PRDT_NAME, StringUtils.toString(prdtName, eiMetadata.getMeta(FIELD_PRDT_NAME))); map.put(FIELD_PRDT_NAME, StringUtils.toString(prdtName, eiMetadata.getMeta(FIELD_PRDT_NAME)));
map.put(FIELD_DEP_CODE,StringUtils.toString(depCode, eiMetadata.getMeta(FIELD_DEP_CODE)));
return map; return map;
} }
} }
...@@ -77,6 +77,21 @@ ...@@ -77,6 +77,21 @@
<isNotEmpty prepend=" AND " property="matId"> <isNotEmpty prepend=" AND " property="matId">
MAT_ID = #matId# MAT_ID = #matId#
</isNotEmpty> </isNotEmpty>
<isNotEmpty prepend=" AND " property="depCode">
DEP_CODE = #depCode#
</isNotEmpty>
</sql>
<sql id="authCondition">
<isNotEmpty prepend=" AND " property="companyCode">
COMPANY_CODE=#companyCode#
</isNotEmpty>
<isNotEmpty prepend=" AND " property="depCode">
DEP_CODE= #depCode#
</isNotEmpty>
<isNotEmpty prepend=" AND " property="depCodes">
DEP_CODE IN <iterate close=")" open="(" conjunction="," property="depCodes">#depcodes[]#</iterate>
</isNotEmpty>
</sql> </sql>
<select id="query" parameterClass="java.util.HashMap" <select id="query" parameterClass="java.util.HashMap"
...@@ -97,7 +112,8 @@ ...@@ -97,7 +112,8 @@
A.CREATED_TIME as "createdTime", <!-- 记录创建时间 --> A.CREATED_TIME as "createdTime", <!-- 记录创建时间 -->
A.REAL_PATH as "realPath", <!-- 物理路径 --> A.REAL_PATH as "realPath", <!-- 物理路径 -->
A.BIZ_TYPE as "bizType", A.BIZ_TYPE as "bizType",
A.MAT_ID as "matId" A.MAT_ID as "matId",
A.DEP_CODE as "depCode"
FROM ${hpjxSchema}.TEUDM_TEMP AS A FROM ${hpjxSchema}.TEUDM_TEMP AS A
INNER JOIN ${hpjxSchema}.T_HPSC002 AS B ON A.MAT_ID = B.ID AND A.COMPANY_CODE = B.COMPANY_CODE INNER JOIN ${hpjxSchema}.T_HPSC002 AS B ON A.MAT_ID = B.ID AND A.COMPANY_CODE = B.COMPANY_CODE
WHERE 1=1 WHERE 1=1
...@@ -122,6 +138,12 @@ ...@@ -122,6 +138,12 @@
<isNotEmpty prepend=" AND " property="createdDateTo"> <isNotEmpty prepend=" AND " property="createdDateTo">
A.CREATED_TIME &lt;= #createdDateTo# A.CREATED_TIME &lt;= #createdDateTo#
</isNotEmpty> </isNotEmpty>
<isNotEmpty prepend=" AND " property="depCode">
A.DEP_CODE= #depCode#
</isNotEmpty>
<isNotEmpty prepend=" AND " property="depCodes">
A.DEP CODE IN <iterate close=")" open="(" conjunction="," property="depCodes">#depcodes[]#</iterate>
</isNotEmpty>
<dynamic prepend="ORDER BY"> <dynamic prepend="ORDER BY">
<isNotEmpty property="orderBy"> <isNotEmpty property="orderBy">
$orderBy$ $orderBy$
...@@ -157,6 +179,12 @@ ...@@ -157,6 +179,12 @@
<isNotEmpty prepend=" AND " property="createdDateTo"> <isNotEmpty prepend=" AND " property="createdDateTo">
A.CREATED_TIME &lt;= #createdDateTo# A.CREATED_TIME &lt;= #createdDateTo#
</isNotEmpty> </isNotEmpty>
<isNotEmpty prepend=" AND " property="depCode">
A.DEP_CODE= #depCode#
</isNotEmpty>
<isNotEmpty prepend=" AND " property="depCodes">
A.DEP_CODE IN <iterate close=")" open="(" conjunction="," property="depCodes">#depcodes[]#</iterate>
</isNotEmpty>
</select> </select>
<!-- <!--
...@@ -225,15 +253,17 @@ ...@@ -225,15 +253,17 @@
ARCHIVE_FLAG, <!-- 同步标记 --> ARCHIVE_FLAG, <!-- 同步标记 -->
REAL_PATH, <!-- 物理路径 --> REAL_PATH, <!-- 物理路径 -->
BIZ_TYPE, BIZ_TYPE,
MAT_ID MAT_ID,
DEP_CODE
) )
VALUES (#companyCode#, #docId#, #dirId#, #docName#, #chgName#, #docSize#, #docTag#, #createdBy#, #createdName#, VALUES (#companyCode#, #docId#, #dirId#, #docName#, #chgName#, #docSize#, #docTag#, #createdBy#, #createdName#,
#createdTime#, #updatedBy#, #updatedName#, #updatedTime#, #archiveFlag#, #realPath#, #bizType#, #matId#) #createdTime#, #updatedBy#, #updatedName#, #updatedTime#, #archiveFlag#, #realPath#, #bizType#, #matId#, #depCode#)
</insert> </insert>
<delete id="delete"> <delete id="delete">
DELETE FROM ${hpjxSchema}.TEUDM_TEMP WHERE DELETE FROM ${hpjxSchema}.TEUDM_TEMP WHERE
COMPANY_CODE = #companyCode# COMPANY_CODE = #companyCode#
<include refid="condition" />
<isNotEmpty prepend=" AND " property="docId"> <isNotEmpty prepend=" AND " property="docId">
DOC_ID = #docId# DOC_ID = #docId#
</isNotEmpty> </isNotEmpty>
...@@ -263,12 +293,14 @@ ...@@ -263,12 +293,14 @@
UPDATED_NAME = #updatedName#, <!-- 记录修改名称 --> UPDATED_NAME = #updatedName#, <!-- 记录修改名称 -->
UPDATED_TIME = #updatedTime#, <!-- 记录修改时间 --> UPDATED_TIME = #updatedTime#, <!-- 记录修改时间 -->
ARCHIVE_FLAG = #archiveFlag#, <!-- 同步标记 --> ARCHIVE_FLAG = #archiveFlag#, <!-- 同步标记 -->
REAL_PATH = #realPath# <!-- 物理路径 --> REAL_PATH = #realPath#, <!-- 物理路径 -->
BIZ_TYPE = #bizType# BIZ_TYPE = #bizType#,
MAT_ID = #matId# MAT_ID = #matId#,
DEP_CODE = #depCode#
WHERE WHERE
COMPANY_CODE = #companyCode# AND COMPANY_CODE = #companyCode# AND
DOC_ID = #docId# DOC_ID = #docId#
<include refid="condition" />
<isNotEmpty prepend=" AND " property="bizType"> <isNotEmpty prepend=" AND " property="bizType">
BIZ_TYPE = #bizType# BIZ_TYPE = #bizType#
</isNotEmpty> </isNotEmpty>
......
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