|  | @ -399,13 +399,29 @@ public class CourseService {
 | 
	
		
			
				|  |  |                     }
 | 
	
		
			
				|  |  |                 });
 | 
	
		
			
				|  |  |             }
 | 
	
		
			
				|  |  |             List aList = new ArrayList();
 | 
	
		
			
				|  |  |             List<Map<String , Object>> aList = new ArrayList();
 | 
	
		
			
				|  |  |             if (list.size() > 0){
 | 
	
		
			
				|  |  |                 for (int i =0;i<list.size();i++){
 | 
	
		
			
				|  |  |                     String sql1 = "SELECT * FROM base_course WHERE del = 1 AND org_code = '"+list.get(i).get("code")+"'" ;
 | 
	
		
			
				|  |  |                     List<Map<String , Object >> amapList = jdbcTemplate.queryForList(sql1);
 | 
	
		
			
				|  |  |                     if (amapList.size() > 0){
 | 
	
		
			
				|  |  |                         aList.add(amapList.get(0));
 | 
	
		
			
				|  |  |                         for (int j = 0;j<amapList.size();j++){
 | 
	
		
			
				|  |  |                             JSONObject o = new JSONObject();
 | 
	
		
			
				|  |  |                             o.put("id",amapList.get(j).get("id"));
 | 
	
		
			
				|  |  |                             o.put("name",amapList.get(j).get("name"));
 | 
	
		
			
				|  |  |                             o.put("orgCode",amapList.get(j).get("org_code"));
 | 
	
		
			
				|  |  |                             o.put("orgName",amapList.get(j).get("org_name"));
 | 
	
		
			
				|  |  |                             o.put("doctor",amapList.get(j).get("doctor"));
 | 
	
		
			
				|  |  |                             o.put("doctorName",amapList.get(j).get("doctor_name"));
 | 
	
		
			
				|  |  |                             o.put("liveTime",amapList.get(j).get("live_time"));
 | 
	
		
			
				|  |  |                             o.put("liveStatus",amapList.get(j).get("live_status"));
 | 
	
		
			
				|  |  |                             o.put("liveDuration",amapList.get(j).get("live_duration"));
 | 
	
		
			
				|  |  |                             o.put("courseCover",amapList.get(j).get("course_cover"));
 | 
	
		
			
				|  |  |                             o.put("status",amapList.get(j).get("status"));
 | 
	
		
			
				|  |  |                             o.put("fee",amapList.get(j).get("fee"));
 | 
	
		
			
				|  |  |                             o.put("introduction",amapList.get(j).get("introduction"));
 | 
	
		
			
				|  |  |                             aList.add(o);
 | 
	
		
			
				|  |  |                         }
 | 
	
		
			
				|  |  |                     }
 | 
	
		
			
				|  |  |                 }
 | 
	
		
			
				|  |  |                 if (aList.size() > 0 ){
 | 
	
	
		
			
				|  | @ -473,10 +489,11 @@ public class CourseService {
 | 
	
		
			
				|  |  |         List<Map<String , Object>> currentPageList = new ArrayList<>();
 | 
	
		
			
				|  |  |         if (positionList.size() > 0){
 | 
	
		
			
				|  |  |             for (int i=0;i<positionList.size();i++){
 | 
	
		
			
				|  |  |                 String sql1 = "SELECT id,`name`,longitude,latitude ,funDistance("+positionList.get(i).get("latitude")+","+positionList.get(i).get("longitude")+","+lat2+","+lon2+") funDistance FROM base.base_org where id = '"+positionList.get(i).get("id")+"'";
 | 
	
		
			
				|  |  |                 String sql1 = "SELECT id,code,`name`,longitude,latitude ,funDistance("+positionList.get(i).get("latitude")+","+positionList.get(i).get("longitude")+","+lat2+","+lon2+") funDistance FROM base.base_org where id = '"+positionList.get(i).get("id")+"'";
 | 
	
		
			
				|  |  |                 List<Map<String , Object>> mapList = jdbcTemplate.queryForList(sql1);
 | 
	
		
			
				|  |  |                 JSONObject obj = new JSONObject();
 | 
	
		
			
				|  |  |                 obj.put("id",mapList.get(0).get("id"));
 | 
	
		
			
				|  |  |                 obj.put("code",mapList.get(0).get("code"));
 | 
	
		
			
				|  |  |                 obj.put("name",mapList.get(0).get("name"));
 | 
	
		
			
				|  |  |                 obj.put("longitude",mapList.get(0).get("longitude"));
 | 
	
		
			
				|  |  |                 obj.put("latitude",mapList.get(0).get("latitude"));
 | 
	
	
		
			
				|  | @ -490,13 +507,22 @@ public class CourseService {
 | 
	
		
			
				|  |  |                     }
 | 
	
		
			
				|  |  |                 });
 | 
	
		
			
				|  |  |             }
 | 
	
		
			
				|  |  |             List aList = new ArrayList();
 | 
	
		
			
				|  |  |             List<Map<String , Object >> aList = new ArrayList<>();
 | 
	
		
			
				|  |  |             if (list.size() > 0){
 | 
	
		
			
				|  |  |                 for (int i =0;i<list.size();i++){
 | 
	
		
			
				|  |  |                     String sql1 = "SELECT id,`name`,job_title_code,job_title_name,visit_hospital,visit_hospital_name FROM base_doctor WHERE doctor_level = 3 AND enabled = 1 AND locked = 0 AND del = 1 and  visit_hospital = '"+list.get(i).get("id")+"'" ;
 | 
	
		
			
				|  |  |                     String sql1 = "SELECT id,`name`,job_title_code,job_title_name,visit_hospital,visit_hospital_name FROM base_doctor WHERE doctor_level = 3 AND enabled = 1 AND locked = 0 AND del = 1 and  visit_hospital = '"+list.get(i).get("code")+"'" ;
 | 
	
		
			
				|  |  |                     List<Map<String , Object >> amapList = jdbcTemplate.queryForList(sql1);
 | 
	
		
			
				|  |  |                     if (amapList.size() > 0){
 | 
	
		
			
				|  |  |                         aList.add(amapList.get(0));
 | 
	
		
			
				|  |  |                         for (int j=0;j<amapList.size();j++){
 | 
	
		
			
				|  |  |                             JSONObject o = new JSONObject();
 | 
	
		
			
				|  |  |                             o.put("id",amapList.get(j).get("id"));
 | 
	
		
			
				|  |  |                             o.put("name",amapList.get(j).get("name"));
 | 
	
		
			
				|  |  |                             o.put("jobTitleCode",amapList.get(j).get("jobTitleCode"));
 | 
	
		
			
				|  |  |                             o.put("jobtitlename",amapList.get(j).get("jobtitlename"));
 | 
	
		
			
				|  |  |                             o.put("visithospital",amapList.get(j).get("visithospital"));
 | 
	
		
			
				|  |  |                             o.put("visitHospitalName",amapList.get(j).get("visitHospitalName"));
 | 
	
		
			
				|  |  |                             aList.add(o);
 | 
	
		
			
				|  |  |                         }
 | 
	
		
			
				|  |  |                     }
 | 
	
		
			
				|  |  |                 }
 | 
	
		
			
				|  |  |             object.put("object",aList);
 | 
	
	
		
			
				|  | @ -648,7 +674,7 @@ public class CourseService {
 | 
	
		
			
				|  |  |             sql = "SELECT id,org_code orgCode,org_name orgName,order_no orderNo,pay_type payType,create_time createTime,status FROM base_recruit_students_record WHERE patient = '"+orderId+"'";
 | 
	
		
			
				|  |  |             mapList = jdbcTemplate.queryForList(sql);
 | 
	
		
			
				|  |  |         }
 | 
	
		
			
				|  |  |         if (mapList.size() > 0 && mapList.get(0).get("status").equals(6)){
 | 
	
		
			
				|  |  |         if (mapList.size() > 0 && mapList.get(0).get("orderStatus").equals(6)){
 | 
	
		
			
				|  |  |             String sql1 = "select status,create_time createTime,refund_price refundPrice,refund_desc refundDesc,enclosure from base_patient_order_refund where order_id = '"+mapList.get(0).get("id")+"' " ;
 | 
	
		
			
				|  |  |             List<Map<String , Object>> mapList1 = jdbcTemplate.queryForList(sql1);
 | 
	
		
			
				|  |  |             mapList.get(0).put("refundStatus",mapList1.get(0).get("status"));       //退款状态
 |