Преглед изворни кода

测试

Signed-off-by: EDZ <1>
EDZ пре 3 година
родитељ
комит
d3879c8018

+ 7 - 0
src/main/java/net/chenlin/dp/modules/sys/dao/TestU8Mapper.java

@@ -15,6 +15,13 @@ public interface TestU8Mapper extends BaseMapper<QuartzJobLogEntity> {
 
 	int testAll();
 
+	/**
+	 * 调用存储过程 获取下一个编码
+	 * @param StuNo
+	 * @return
+	 */
+	int callGetMaxCode(String StuNo);
+
 	/**
 	 * crm调用存储过程 同步存货档案
 	 * @param upTime

+ 8 - 0
src/main/java/net/chenlin/dp/modules/sys/mapper/testU8.xml

@@ -10,6 +10,14 @@
 			AA_Bank
 	</select>
 
+	<select id="callGetMaxCode" parameterType="map" statementType="CALLABLE" resultType="int">
+		{
+			call getMaxCode(
+				#{StuNo, mode=IN, jdbcType=VARCHAR}
+			)
+		}
+	</select>
+
 	<select id="callProductIn" parameterType="map" statementType="CALLABLE">
 		{
 			call product_In(

+ 11 - 0
src/main/java/net/chenlin/dp/modules/sys/service/impl/testU8ServiceImpl.java

@@ -22,6 +22,17 @@ public class testU8ServiceImpl implements testU8Service {
 		return testU8Mapper.testAll();
 	}
 
+	/**
+	 * 调用存储过程 获取下一个编码
+	 * @param upTime
+	 * @return
+	 */
+	@Override
+	public int callGetMaxCode(String upTime) {
+		DynamicDataSource.setDataSource("slave-data-source");
+		return testU8Mapper.callGetMaxCode(upTime);
+	}
+
 	/**
 	 * crm调用存储过程 同步存货档案
 	 * @param upTime

+ 7 - 0
src/main/java/net/chenlin/dp/modules/sys/service/testU8Service.java

@@ -9,6 +9,13 @@ import net.chenlin.dp.common.support.orm.db.DynamicDataSource;
 public interface testU8Service {
 	int testAll();
 
+	/**
+	 * 调用存储过程 获取下一个编码
+	 * @param StuNo
+	 * @return
+	 */
+	public int callGetMaxCode(String StuNo);
+
 	/**
 	 * crm调用存储过程 同步存货档案
 	 * @param upTime