Subversion Repositories SmartDukaan

Rev

Rev 25503 | Rev 26684 | Go to most recent revision | Details | Compare with Previous | Last modification | View Log | RSS feed

Rev Author Line No. Line
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;
21
	public Scheme getSchemeById(int schemeId) throws ProfitMandiBusinessException;
23019 ashik.ali 22
	public List<SchemeModel> getAllSchemeModels(LocalDateTime startDateTime, LocalDateTime endDateTime);
22653 ashik.ali 23
	public void activeSchemeById(int schemeId) throws ProfitMandiBusinessException;
25071 amit.gupta 24
	public void expireSchemeById(int schemeId, LocalDateTime expiryDate) throws ProfitMandiBusinessException;
23365 ashik.ali 25
	public void processSchemeIn(int purchaseId, int retailerId) throws ProfitMandiBusinessException;
26
	public void processSchemeOut(int fofoOrderId, int retailerId) throws ProfitMandiBusinessException;
23638 amit.gupta 27
//	public void rollbackSchemeForInventoryItemId(int inventoryItemId);
28
	public void rollbackSchemes(List<Integer> inventoryItemIds, int rollbackReference, String rollbackReason) throws Exception;
23781 ashik.ali 29
	public Map<String, Object> getSchemes(Set<Integer> roleIds, int offset, int limit) throws ProfitMandiBusinessException;
30
	public List<Scheme> getPaginatedSchemes(Set<Integer> roleIds, int offset, int limit) throws ProfitMandiBusinessException;
26332 amit.gupta 31
	void reverseSchemes(List<InventoryItem> inventoryItems, int reversalReference, String reversalReason) throws ProfitMandiBusinessException;
24264 amit.gupta 32
	void reverseSchemes(List<InventoryItem> inventoryItems, int reversalReference, String reversalReason,
33
			SchemeType schemeType) throws ProfitMandiBusinessException;
26332 amit.gupta 34
 
35
	public double getTotalMargin(int itemId, PartnerType partnerType, LocalDateTime localDateTime);
24563 amit.gupta 36
//	void updateSchmesForModel(int catalogId) throws ProfitMandiBusinessException;
22608 ashik.ali 37
}