chb 7 years ago
parent
commit
305de99587

+ 4 - 1
ccb_fund_trusteeship/src/main/java/com/fuzamei/dao/CapitalTransferDao.java

@@ -8,6 +8,7 @@ import org.springframework.stereotype.Repository;
 
 import com.fuzamei.entity.CapitalTransfer;
 import com.fuzamei.entity.CapitalTransferCheck;
+import com.fuzamei.entity.User;
 import com.fuzamei.mapperInterface.CapitalTransferMapper;
 
 @Repository
@@ -28,5 +29,7 @@ public class CapitalTransferDao {
 	public  List<CapitalTransferCheck> selectCapitalTransferRecord(Map<String, Object> map){//资金划转 里审核记录   查看详情
 		return capitalTransferMapper.selectCapitalTransferRecord(map);
 	}
-
+	/*public List<User> selectByPersonName(Map<String, Object> map) {//临时测试的
+		return capitalTransferMapper.selectByPersonName(map);
+	}*/
 }

+ 35 - 1
ccb_fund_trusteeship/src/main/java/com/fuzamei/mapper/AccountOpenMapper.xml

@@ -185,7 +185,41 @@
 		               #{upload_person_id},
 		               #{create_time} )
 	</insert>
-	
+<!-- *******************下面暂时没用上************************************************* -->
+<!-- <select id="">
+	select 
+			customer_id,
+			customer_name,
+			bank_account,
+			f.attachment_name as basic_data_id,
+			f1.attachment_name as letter_of_commitment_id,
+			f2.attachment_name as application_id,
+			update_time,s.status_name 
+		from  
+			      account_opening_record a
+		LEFT JOIN  attachment f
+		
+			on a.basic_data_id=f.attachment_id 
+	  	LEFT JOIN	attachment f1
+	  	on	a.letter_of_commitment_id = f1.attachment_id 
+	  	LEFT JOIN attachment f2
+	  	on	a.application_id= f2.attachment_id 
+	  	LEFT JOIN status s
+	  	on a.status_id = s.status_id
+	 <where>
+		    <if test="customer_name!='' and customer_name!=null ">
+			  customer_name=#{customer_name}
+			</if>
+			<if test="bank_account!='' and bank_account!=null">
+			  and bank_account=#{bank_account}
+			</if>
+		   	<if test="startTime!='' and endTime != ''">
+			  and a.update_time  between #{startTime} and #{endTime}
+			</if>
+	 </where>
+	   order by update_time desc
+	   limit #{startPage},#{rowNum}
+</select>	 -->
 	
 	
 	

+ 30 - 8
ccb_fund_trusteeship/src/main/java/com/fuzamei/mapper/CapitalTransferMapper.xml

@@ -60,10 +60,23 @@
             sj.basis_of_payment=f.attachment_id
        and    
            y.user_id=sj.custodian 
+        <if test="fund_id!='' and fund_id!=null">
         and 
           fund_id=#{fund_id}
+        </if>
        </where>
   </select>
+  <!--**********************************  -->
+ <!--  详情 单独查看  资金划转 的管理人 -->
+ <!--  <select id="selectByPersonName" parameterType="java.util.Map" resultType="com.fuzamei.entity.User">
+  		select person_name  from  t_user  
+  		<where>
+  		<if test="user_id!='' and user_id!=null">
+  	          user_id=#{user_id}
+  	          </if>
+  		</where>
+  		
+  </select> -->
   
 <!--*************************************  -->
     <!--查看  查询划转资金审核记录表  框框 --> 
@@ -88,10 +101,16 @@
                status s
           on   sj.check_result =s.status_id ) sj
          left  join status s  on  s.status_id=sj.relation
+        <where>
+           <if test="fund_id!='' and fund_id!=null">
+      
+          fund_id=#{fund_id}
+           </if>
+       </where>
         
 	</select>
 	
-	<!-- 将划转资金上传     附件信息插入附件表中   可以公用此方法-->
+	<!-- 将划转资金   上传     附件信息插入附件表中   可以公用此方法-->
 	<insert id="insertAttachmentInfo">
 		insert into 
 			attachment(attachment_id,
@@ -124,21 +143,24 @@
 	</insert>
     <!--**************************************  -->
     <!--将审核意见插入到划转资金审核表里  -->
-    <insert id="">
+    <insert id="insertCheckTransfer">
 	    insert into capital_transfer_check( fund_id,
 			          check_department,
 						   check_person,
 						   check_opinion,
 						   check_time,
 						   check_result,relation) 		
-		values(1013,'省分行部门','老张','可以批了','20180101','通过','10');
-						  
-    
-    
+				values( #{fund_id},
+				       #{check_department},
+				       #{check_person},
+				       #{check_opinion},
+				       #{check_time},
+				       #{check_result},
+				       #{relation})
     </insert>
     
-    
-    
+   <!-- 资金划转*************///////////////////////////////////////////////////////// --> 
+
     
     
     

+ 2 - 1
ccb_fund_trusteeship/src/main/java/com/fuzamei/mapperInterface/CapitalTransferMapper.java

@@ -5,6 +5,7 @@ import java.util.Map;
 
 import com.fuzamei.entity.CapitalTransfer;
 import com.fuzamei.entity.CapitalTransferCheck;
+import com.fuzamei.entity.User;
 
 public interface CapitalTransferMapper {
 
@@ -12,7 +13,7 @@ public interface CapitalTransferMapper {
     public int  selectCapitalTransferPage();//查询资金划转表     总页数
 	public  List<CapitalTransfer> selectChaKanZiJinHuaZhuan(Map<String, Object> map);//资金划转    查看详情
 	public  List<CapitalTransferCheck> selectCapitalTransferRecord(Map<String, Object> map);//资金划转 里审核记录   查看详情
-	
+	//public  List<User> selectByPersonName(Map<String, Object> map);//临时测试用的
    
 	
 	

+ 3 - 3
ccb_fund_trusteeship/src/main/java/com/fuzamei/service/AccountOpenService.java

@@ -237,7 +237,7 @@ public class AccountOpenService {
 		  accountOpenDao.insertAccountUploadFileFuJianBiao(mapToDao);//将数据添加到附件表数据库里
 			
 		  Map<String, Object> mapToOperation = new LinkedHashMap<String,Object>();
-			mapToOperation.put("operatorTypeId", 1001);						//写死
+			mapToOperation.put("operatorTypeId", 1001);						//写死目前
 			mapToOperation.put("operatorAccount", 500000266);				//操作账号先定死
 			mapToOperation.put("operatorRole", "经办支行5");						//创建这个操作的角色  目前是写死
 			mapToOperation.put("operatorPerson", "张三3");						//操作人先写死
@@ -421,10 +421,10 @@ public class AccountOpenService {
 		     
 		//还要将账户开立添加上传的这个操作信息插入到操作记录表中
 		Map<String, Object> mapToOperationHistory = new LinkedHashMap<String,Object>();
-			mapToOperationHistory.put("operatorTypeId", 1001);						//刚刚创立业务申报,操作类型为业务申报
+			mapToOperationHistory.put("operatorTypeId", 1001);						//
 			mapToOperationHistory.put("operatorAccount", 500000255);				//操作账号先定死
 			mapToOperationHistory.put("operatorRole", "经办支行");						//创建这个操作的角色只能是经办支行
-			mapToOperationHistory.put("operatorPerson", "张");						//操作人先写死
+			mapToOperationHistory.put("operatorPerson", "张");						//操作人先写死
 			mapToOperationHistory.put("operatorTime", mapToDao.get("update_time")); //操作时间为当前操作时间
 			mapToOperationHistory.put("hash", "11a2s3d4f5g");	                    //写的时死值
 			accountOpenDao.insertOperationHistory(mapToOperationHistory);           //将账户开立添加上传的操作记录信息插入到操作记录表中     

+ 15 - 3
ccb_fund_trusteeship/src/main/java/com/fuzamei/service/CapitalTransferService.java

@@ -4,12 +4,15 @@ import java.util.LinkedHashMap;
 import java.util.List;
 import java.util.Map;
 
+import org.apache.poi.util.StringUtil;
 import org.springframework.beans.factory.annotation.Autowired;
 import org.springframework.stereotype.Service;
+import org.springframework.util.StringUtils;
 
 import com.fuzamei.dao.CapitalTransferDao;
 import com.fuzamei.entity.CapitalTransfer;
 import com.fuzamei.entity.CapitalTransferCheck;
+import com.fuzamei.entity.User;
 import com.fuzamei.utils.PageDTO;
 
 @Service
@@ -29,7 +32,9 @@ public class CapitalTransferService {
 		String status_name="";//状态名称
 		long startTime = 0; // 开始时间默认0
 		long endTime = Long.MAX_VALUE; // 结束时间默认Long最大值
-
+		
+		StringUtils.isEmpty(map);
+		
 		if (!"".equals(map.get("page")) && map.get("page") != null) { // 等于空就直接取第一页
 			try {
 				page = Integer.parseInt((String) map.get("page"));
@@ -73,6 +78,7 @@ public class CapitalTransferService {
 			mapToDao.put("startTime", startTime);
 			mapToDao.put("endTime", Long.MAX_VALUE);
 		}
+		
 		mapToDao.put("rowNum", ROW_NUM); // 默认每页显示数据是10条,可根据需求修改分页数量
 		int  countPage=capitalTransferDao.selectCapitalTransferPage();//资金划转表  总得信息数量页数
 		List<CapitalTransfer> CapitalTransferList=capitalTransferDao.selectCapitalTransferTable(mapToDao);
@@ -84,19 +90,25 @@ public class CapitalTransferService {
 	//资金划转   点击查看 详情
 	public Map<String, Object>  selectChaKanZiJinHuaZhuan(Map<String, Object> map){
 		int fund_id=0;
+		//int user_id=0;
 		if (!"".equals(map.get("fund_id")) && map.get("fund_id") != null) { 
 			fund_id =  Integer.parseInt((String)map.get("fund_id"));
 		}
+		/*if (!"".equals(map.get("user_id")) && map.get("user_id") != null) { 
+			user_id =  Integer.parseInt((String)map.get("user_id"));
+		}*/
 		
 		
 		 Map<String, Object> mapToDao = new LinkedHashMap<String, Object>();
 		  mapToDao.put("fund_id", fund_id);//附件名称    暂时没写
-		  
+		  //mapToDao.put("user_id", user_id);
 		  List<CapitalTransfer> list=capitalTransferDao.selectChaKanZiJinHuaZhuan(mapToDao);
 		  List<CapitalTransferCheck> lis= capitalTransferDao.selectCapitalTransferRecord(mapToDao);
+		  //List<User> user=capitalTransferDao.selectByPersonName(mapToDao);
 		  Map<String, Object> map1=new LinkedHashMap<String, Object>();
-		  map1.put("CapitalTransfer", list);
+		  map1.put("CapitalTransfer", list);//管理人取不到值  稍做修改 persont_name
 		  map1.put("CapitalTransferCheck", lis);
+		 // map1.put("user", user); 
 		return map1;
 	}
 	

+ 2 - 2
ccb_fund_trusteeship/src/main/java/com/fuzamei/web/CapitalTransferAction.java

@@ -4,7 +4,7 @@ import java.util.LinkedHashMap;
 import java.util.List;
 import java.util.Map;
 
-import org.junit.runners.Parameterized.Parameters;
+
 import org.springframework.beans.factory.annotation.Autowired;
 import org.springframework.stereotype.Controller;
 import org.springframework.web.bind.annotation.RequestBody;
@@ -42,7 +42,7 @@ public class CapitalTransferAction {
 		return mapResult;
 	}
 	
-	/**{
+	/**{ 
 	    "fund_id":"1005"   postman 传个id
        }
 	 * 资金划转查看详情