yuhaitao14 7 years ago
parent
commit
56d85d11bd

+ 12 - 2
shop/src/main/java/com/zskk/shop/controller/api/ApiController.java

@@ -22,8 +22,18 @@ public class ApiController {
 	private BuyOrderService buyOrderService;
 	private BuyOrderService buyOrderService;
 	
 	
 	@RequestMapping("/refund")
 	@RequestMapping("/refund")
-	public ControllerResult refund(@RequestParam("String") String key){
-		buyOrderService.refund(Long.parseLong(key));
+	public ControllerResult refund(@RequestParam("extend") String extend){
+		buyOrderService.refund(Long.parseLong(extend));
 		return new ControllerResult(Boolean.TRUE);
 		return new ControllerResult(Boolean.TRUE);
 	}
 	}
+	
+	@RequestMapping("/orders")
+	public ControllerResult orders(@RequestParam("stime") String stime, @RequestParam("etime") String time){
+		return null;
+	}
+	
+	@RequestMapping("refundOrders")
+	public ControllerResult refundOrders(@RequestParam("stime") String stime, @RequestParam("etime") String time){
+		return null;
+	}
 }
 }

+ 6 - 1
shop/src/main/java/com/zskk/shop/service/FamilyPeopleService.java

@@ -17,6 +17,7 @@ import org.springframework.beans.factory.annotation.Autowired;
 import org.springframework.stereotype.Service;
 import org.springframework.stereotype.Service;
 import org.springframework.transaction.annotation.Transactional;
 import org.springframework.transaction.annotation.Transactional;
 
 
+import com.alibaba.fastjson.JSON;
 import com.zskk.shop.controller.bean.FamilyPeopleBean;
 import com.zskk.shop.controller.bean.FamilyPeopleBean;
 import com.zskk.shop.controller.bean.UserBean;
 import com.zskk.shop.controller.bean.UserBean;
 import com.zskk.shop.dao.FamilyPeopleMapper;
 import com.zskk.shop.dao.FamilyPeopleMapper;
@@ -162,9 +163,13 @@ public class FamilyPeopleService {
 		if (count != 1){
 		if (count != 1){
 			throw new ZSKKException(ErrorConstant.SERVER_ERROR);
 			throw new ZSKKException(ErrorConstant.SERVER_ERROR);
 		}
 		}
+		
+		Map<String, String> extendMap = new HashMap<>();
+		extendMap.put("extend", extend);
+		extendMap.put("aid", appointment.getId().toString());
 
 
 		//向体检系统 发起体检请求
 		//向体检系统 发起体检请求
-		String tjaid = tjCenterService.appointment(people, order, goodService.queryOneGoodBase(item.getGid()), atime, extend);
+		String tjaid = tjCenterService.appointment(people, order, goodService.queryOneGoodBase(item.getGid()), atime, JSON.toJSONString(extendMap));
 		appointment.setTjaid(tjaid);
 		appointment.setTjaid(tjaid);
 		familyPeopleMapper.updateAppointment(appointment);
 		familyPeopleMapper.updateAppointment(appointment);
 	}
 	}

+ 1 - 0
shop/src/main/java/com/zskk/shop/service/TJCenterService.java

@@ -92,6 +92,7 @@ public class TJCenterService {
 		data.put("package_name", good.getPackageName());
 		data.put("package_name", good.getPackageName());
 		data.put("maketime", atime);
 		data.put("maketime", atime);
 		data.put("phone", people.getPhone());
 		data.put("phone", people.getPhone());
+		data.put("extend", extend);
 		data.put("callback_url", myhost + "tj/callback");
 		data.put("callback_url", myhost + "tj/callback");
 		
 		
 		String url = tjcenter + "public/api.php/shop/addSubscribe";
 		String url = tjcenter + "public/api.php/shop/addSubscribe";