| 22608 |
ashik.ali |
1 |
package com.spice.profitmandi.service.scheme;
|
|
|
2 |
|
| 23019 |
ashik.ali |
3 |
import java.time.LocalDateTime;
|
|
|
4 |
import java.util.List;
|
| 23752 |
govind |
5 |
import java.util.Map;
|
| 23781 |
ashik.ali |
6 |
import java.util.Set;
|
| 23019 |
ashik.ali |
7 |
|
| 22608 |
ashik.ali |
8 |
import org.springframework.stereotype.Service;
|
|
|
9 |
|
| 22653 |
ashik.ali |
10 |
import com.spice.profitmandi.common.exception.ProfitMandiBusinessException;
|
| 23019 |
ashik.ali |
11 |
import com.spice.profitmandi.common.model.SchemeModel;
|
| 22653 |
ashik.ali |
12 |
import com.spice.profitmandi.dao.entity.catalog.Scheme;
|
| 23968 |
amit.gupta |
13 |
import com.spice.profitmandi.dao.entity.fofo.InventoryItem;
|
| 26332 |
amit.gupta |
14 |
import com.spice.profitmandi.dao.entity.fofo.PartnerType;
|
| 24264 |
amit.gupta |
15 |
import com.spice.profitmandi.dao.enumuration.catalog.SchemeType;
|
| 25503 |
amit.gupta |
16 |
import com.spice.profitmandi.dao.model.CreateSchemeRequest;
|
| 22653 |
ashik.ali |
17 |
|
| 22608 |
ashik.ali |
18 |
@Service
|
|
|
19 |
public interface SchemeService {
|
| 22859 |
ashik.ali |
20 |
public void saveScheme(int creatorId, CreateSchemeRequest createSchemeRequest) throws ProfitMandiBusinessException;
|
| 26802 |
tejbeer |
21 |
|
| 22859 |
ashik.ali |
22 |
public Scheme getSchemeById(int schemeId) throws ProfitMandiBusinessException;
|
| 26802 |
tejbeer |
23 |
|
| 23019 |
ashik.ali |
24 |
public List<SchemeModel> getAllSchemeModels(LocalDateTime startDateTime, LocalDateTime endDateTime);
|
| 26802 |
tejbeer |
25 |
|
| 22653 |
ashik.ali |
26 |
public void activeSchemeById(int schemeId) throws ProfitMandiBusinessException;
|
| 26802 |
tejbeer |
27 |
|
| 25071 |
amit.gupta |
28 |
public void expireSchemeById(int schemeId, LocalDateTime expiryDate) throws ProfitMandiBusinessException;
|
| 26802 |
tejbeer |
29 |
|
| 23365 |
ashik.ali |
30 |
public void processSchemeIn(int purchaseId, int retailerId) throws ProfitMandiBusinessException;
|
| 26802 |
tejbeer |
31 |
|
| 23365 |
ashik.ali |
32 |
public void processSchemeOut(int fofoOrderId, int retailerId) throws ProfitMandiBusinessException;
|
| 26802 |
tejbeer |
33 |
|
|
|
34 |
// public void rollbackSchemeForInventoryItemId(int inventoryItemId);
|
|
|
35 |
public void rollbackSchemes(List<Integer> inventoryItemIds, int rollbackReference, String rollbackReason)
|
|
|
36 |
throws Exception;
|
|
|
37 |
|
|
|
38 |
public Map<String, Object> getSchemes(Set<Integer> roleIds, int offset, int limit)
|
|
|
39 |
throws ProfitMandiBusinessException;
|
|
|
40 |
|
|
|
41 |
public List<Scheme> getPaginatedSchemes(Set<Integer> roleIds, int offset, int limit)
|
|
|
42 |
throws ProfitMandiBusinessException;
|
|
|
43 |
|
|
|
44 |
void reverseSchemes(List<InventoryItem> inventoryItems, int reversalReference, String reversalReason)
|
|
|
45 |
throws ProfitMandiBusinessException;
|
|
|
46 |
|
| 24264 |
amit.gupta |
47 |
void reverseSchemes(List<InventoryItem> inventoryItems, int reversalReference, String reversalReason,
|
|
|
48 |
SchemeType schemeType) throws ProfitMandiBusinessException;
|
| 26802 |
tejbeer |
49 |
|
| 26332 |
amit.gupta |
50 |
public double getTotalMargin(int itemId, PartnerType partnerType, LocalDateTime localDateTime);
|
| 26802 |
tejbeer |
51 |
|
| 26684 |
amit.gupta |
52 |
Map<Integer, Float> getItemSchemeCashBack();
|
| 26802 |
tejbeer |
53 |
|
|
|
54 |
public List<Scheme> selectSchemeByPartnerType(PartnerType partnerType, int itemId, boolean isAdmin, int offset,
|
|
|
55 |
int limit);
|
|
|
56 |
|
|
|
57 |
// void updateSchmesForModel(int catalogId) throws ProfitMandiBusinessException;
|
|
|
58 |
|
|
|
59 |
public long selectSchemeCount(PartnerType partnerType, int itemId, boolean isAdmin);
|
| 22608 |
ashik.ali |
60 |
}
|