| 33873 |
ranu |
1 |
package com.spice.profitmandi.dao.cart;
|
|
|
2 |
|
|
|
3 |
import com.spice.profitmandi.common.exception.ProfitMandiBusinessException;
|
| 34384 |
ranu |
4 |
import com.spice.profitmandi.dao.model.PoAndGrnPendingPartnerStockModel;
|
|
|
5 |
import com.spice.profitmandi.dao.model.SoldAllCatalogitemQtyByPartnerModel;
|
|
|
6 |
import com.spice.profitmandi.dao.model.SoldFocusedItemPartnerWiseModel;
|
| 33873 |
ranu |
7 |
import org.springframework.stereotype.Service;
|
|
|
8 |
|
|
|
9 |
import java.time.LocalDateTime;
|
|
|
10 |
import java.util.List;
|
| 34449 |
ranu |
11 |
import java.util.Map;
|
| 33873 |
ranu |
12 |
import java.util.Set;
|
|
|
13 |
|
|
|
14 |
@Service
|
|
|
15 |
public interface SmartCartService{
|
|
|
16 |
|
|
|
17 |
List<SoldFocusedItemPartnerWiseModel> getAllSoldFocusModelByPartner(int fofoId, LocalDateTime orderDate);
|
|
|
18 |
|
|
|
19 |
List<PoAndGrnPendingPartnerStockModel> getAllGrnPendingAndPoPartnerStock(int fofoId);
|
|
|
20 |
|
|
|
21 |
Set<Integer> getAllItemIdsForSmartCartOfPartner(int fofoId) throws ProfitMandiBusinessException;
|
|
|
22 |
|
|
|
23 |
void addOpeningStock(int itemId, int fofoId, int quantity) throws ProfitMandiBusinessException;
|
|
|
24 |
|
|
|
25 |
void minusOpeningStock(int itemId, int fofoId, int quantity) throws ProfitMandiBusinessException;
|
|
|
26 |
|
| 35493 |
amit |
27 |
/**
|
|
|
28 |
* Batch update opening stock for multiple items - reduces N+1 queries to 2 queries
|
|
|
29 |
* @param itemIdQuantityMap map of itemId to quantity to subtract
|
|
|
30 |
* @param fofoId partner ID
|
|
|
31 |
*/
|
|
|
32 |
void minusOpeningStockBatch(Map<Integer, Integer> itemIdQuantityMap, int fofoId) throws ProfitMandiBusinessException;
|
|
|
33 |
|
| 33873 |
ranu |
34 |
public List<SoldAllCatalogitemQtyByPartnerModel> getAllSoldCatalogItemByPartner(int fofoId, LocalDateTime startOfday, LocalDateTime endOfDay);
|
|
|
35 |
|
|
|
36 |
|
| 34449 |
ranu |
37 |
public Map<Integer, Map<Integer, Integer>> activatedButNotBilledCatalogQtyMap() throws ProfitMandiBusinessException;
|
| 33873 |
ranu |
38 |
}
|