Subversion Repositories SmartDukaan

Rev

Rev 37205 | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 37205 Rev 37210
Line 291... Line 291...
291
			LOGGER.info("Password override for partner retailerId={} storeCode={} by {}", retailerId, storeCode, setBy);
291
			LOGGER.info("Password override for partner retailerId={} storeCode={} by {}", retailerId, storeCode, setBy);
292
		} else {
292
		} else {
293
			if (identifier == null || identifier.trim().isEmpty()) {
293
			if (identifier == null || identifier.trim().isEmpty()) {
294
				throw new ProfitMandiBusinessException("Auth User", "identifier", "Please enter an email or mobile");
294
				throw new ProfitMandiBusinessException("Auth User", "identifier", "Please enter an email or mobile");
295
			}
295
			}
296
			authService.resetPassword(identifier.trim(), newPassword);
296
			AuthUser authUser = authService.resetAuthUserPassword(identifier.trim(), newPassword);
297
			AuthUser authUser = authRepository.selectByEmailOrMobile(identifier.trim());
-
 
298
			passwordOverrideRepository.upsert("AUTH_USER", authUser.getId(), 0, identifier.trim(),
297
			passwordOverrideRepository.upsert("AUTH_USER", authUser.getId(), 0, identifier.trim(),
299
					authUser.getPassword(), newPassword, setBy);
298
					authUser.getPassword(), newPassword, setBy);
300
			LOGGER.info("Password override for authUser={} by {}", identifier.trim(), setBy);
299
			LOGGER.info("Password override for authUser={} by {}", identifier.trim(), setBy);
301
		}
300
		}
302
	}
301
	}