| Line 2... |
Line 2... |
| 2 |
|
2 |
|
| 3 |
import com.spice.profitmandi.common.exception.ProfitMandiBusinessException;
|
3 |
import com.spice.profitmandi.common.exception.ProfitMandiBusinessException;
|
| 4 |
import com.spice.profitmandi.common.model.SamsungUpgradeOfferModel;
|
4 |
import com.spice.profitmandi.common.model.SamsungUpgradeOfferModel;
|
| 5 |
import com.spice.profitmandi.common.model.CreateOrderRequest;
|
5 |
import com.spice.profitmandi.common.model.CreateOrderRequest;
|
| 6 |
import com.spice.profitmandi.common.model.InsuranceModel;
|
6 |
import com.spice.profitmandi.common.model.InsuranceModel;
|
| - |
|
7 |
import com.spice.profitmandi.common.util.StringUtils;
|
| 7 |
import com.spice.profitmandi.dao.cart.CartService;
|
8 |
import com.spice.profitmandi.dao.cart.CartService;
|
| 8 |
import com.spice.profitmandi.dao.entity.user.Address;
|
9 |
import com.spice.profitmandi.dao.entity.user.Address;
|
| 9 |
import com.spice.profitmandi.dao.model.UserCart;
|
10 |
import com.spice.profitmandi.dao.model.UserCart;
|
| 10 |
import com.spice.profitmandi.dao.repository.dtr.UserAccountRepository;
|
11 |
import com.spice.profitmandi.dao.repository.dtr.UserAccountRepository;
|
| 11 |
import com.spice.profitmandi.dao.repository.user.AddressRepository;
|
12 |
import com.spice.profitmandi.dao.repository.user.AddressRepository;
|
| Line 285... |
Line 286... |
| 285 |
@GetMapping("/insurance/checkplans")
|
286 |
@GetMapping("/insurance/checkplans")
|
| 286 |
public ResponseEntity<ApiResponse<?>> getInsurancePrices(HttpServletRequest request,
|
287 |
public ResponseEntity<ApiResponse<?>> getInsurancePrices(HttpServletRequest request,
|
| 287 |
@RequestParam float price,
|
288 |
@RequestParam float price,
|
| 288 |
@RequestParam int itemId,
|
289 |
@RequestParam int itemId,
|
| 289 |
@RequestParam String createdDate) throws Throwable {
|
290 |
@RequestParam String createdDate) throws Throwable {
|
| - |
|
291 |
createdDate = String.valueOf(StringUtils.toDateTime(createdDate));
|
| 290 |
return wrapResponse(orderController.getInsurancePrices(request, price, itemId, createdDate));
|
292 |
return wrapResponse(orderController.getInsurancePrices(request, price, itemId, createdDate));
|
| 291 |
}
|
293 |
}
|
| 292 |
|
294 |
|
| 293 |
@PostMapping("/create-insurance")
|
295 |
@PostMapping("/create-insurance")
|
| 294 |
public ResponseEntity<ApiResponse<?>> createInsurance(HttpServletRequest request,
|
296 |
public ResponseEntity<ApiResponse<?>> createInsurance(HttpServletRequest request,
|