Subversion Repositories SmartDukaan

Rev

Rev 22288 | Rev 22353 | Go to most recent revision | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 22288 Rev 22321
Line 170... Line 170...
170
		return mopPriceMap;
170
		return mopPriceMap;
171
	}
171
	}
172
	
172
	
173
	//Currently it only handles fofos
173
	//Currently it only handles fofos
174
	public List<Integer> getTagsIdsByRetailerId(int retailerId) throws Throwable{
174
	public List<Integer> getTagsIdsByRetailerId(int retailerId) throws Throwable{
-
 
175
		//Currently as pincode tags are hardly any its safe to use any hardcoded pin future need to be implemented
-
 
176
		//We specifically need to find out the way to identify valid pin in such scenarios
175
		int addressId = retailerRegisteredAddressRepository.selectAddressIdByRetailerId(retailerId);
177
		/*int addressId = retailerRegisteredAddressRepository.selectAddressIdByRetailerId(retailerId);
176
		Address retailerAddress = addressRepository.selectById(addressId);
178
		Address retailerAddress = addressRepository.selectById(addressId);*/
177
		Set<Integer> pinCodeTagIds = tagService.getFofoTagIdsByPinCode(retailerAddress.getPinCode());
179
		Set<Integer> pinCodeTagIds = tagService.getFofoTagIdsByPinCode("110001");
178
		Set<Integer> pinNegativeTagIds = tagService.getPinCodeNegativeTagIds();
180
		Set<Integer> pinNegativeTagIds = tagService.getPinCodeNegativeTagIds();
179
		Set<Integer> pinCodeIntersection = new HashSet<>(CollectionUtils.intersection(pinCodeTagIds, pinNegativeTagIds));
181
		Set<Integer> pinCodeIntersection = new HashSet<>(CollectionUtils.intersection(pinCodeTagIds, pinNegativeTagIds));
180
		
182
		
181
		Set<Integer> validTagIds = new HashSet<>(CollectionUtils.subtract(pinNegativeTagIds, pinCodeIntersection));
183
		Set<Integer> validTagIds = new HashSet<>(CollectionUtils.subtract(pinNegativeTagIds, pinCodeIntersection));
182
		Set<Integer> pinPositiveTagIds = tagService.getPinCodePositiveTagIds();
184
		Set<Integer> pinPositiveTagIds = tagService.getPinCodePositiveTagIds();