| Line 1... |
Line 1... |
| 1 |
package com.spice.profitmandi.web.controller;
|
1 |
package com.spice.profitmandi.web.controller;
|
| 2 |
|
2 |
|
| - |
|
3 |
import com.spice.profitmandi.common.exception.ProfitMandiBusinessException;
|
| - |
|
4 |
import com.spice.profitmandi.common.model.ProfitMandiConstants;
|
| - |
|
5 |
import com.spice.profitmandi.dao.entity.auth.AuthUser;
|
| 3 |
import java.util.List;
|
6 |
import com.spice.profitmandi.dao.hrms.*;
|
| 4 |
|
- |
|
| - |
|
7 |
import com.spice.profitmandi.dao.repository.auth.AuthRepository;
|
| 5 |
import javax.servlet.http.HttpServletRequest;
|
8 |
import com.spice.profitmandi.dao.repository.hrms.*;
|
| 6 |
|
- |
|
| - |
|
9 |
import com.spice.profitmandi.web.model.LoginDetails;
|
| - |
|
10 |
import com.spice.profitmandi.web.util.CookiesProcessor;
|
| - |
|
11 |
import com.spice.profitmandi.web.util.MVCResponseSender;
|
| 7 |
import org.apache.logging.log4j.LogManager;
|
12 |
import org.apache.logging.log4j.LogManager;
|
| 8 |
import org.apache.logging.log4j.Logger;
|
13 |
import org.apache.logging.log4j.Logger;
|
| 9 |
import org.springframework.beans.factory.annotation.Autowired;
|
14 |
import org.springframework.beans.factory.annotation.Autowired;
|
| 10 |
import org.springframework.stereotype.Controller;
|
15 |
import org.springframework.stereotype.Controller;
|
| 11 |
import org.springframework.transaction.annotation.Transactional;
|
16 |
import org.springframework.transaction.annotation.Transactional;
|
| Line 13... |
Line 18... |
| 13 |
import org.springframework.web.bind.annotation.RequestBody;
|
18 |
import org.springframework.web.bind.annotation.RequestBody;
|
| 14 |
import org.springframework.web.bind.annotation.RequestMapping;
|
19 |
import org.springframework.web.bind.annotation.RequestMapping;
|
| 15 |
import org.springframework.web.bind.annotation.RequestMethod;
|
20 |
import org.springframework.web.bind.annotation.RequestMethod;
|
| 16 |
import org.springframework.web.bind.annotation.RequestParam;
|
21 |
import org.springframework.web.bind.annotation.RequestParam;
|
| 17 |
|
22 |
|
| 18 |
import com.spice.profitmandi.common.exception.ProfitMandiBusinessException;
|
- |
|
| 19 |
import com.spice.profitmandi.common.model.ProfitMandiConstants;
|
- |
|
| 20 |
import com.spice.profitmandi.dao.entity.auth.AuthUser;
|
23 |
import javax.servlet.http.HttpServletRequest;
|
| 21 |
import com.spice.profitmandi.dao.hrms.*;
|
24 |
import java.util.List;
|
| 22 |
import com.spice.profitmandi.dao.repository.auth.AuthRepository;
|
- |
|
| 23 |
import com.spice.profitmandi.dao.repository.hrms.AddressDetailsFormRepository;
|
- |
|
| 24 |
import com.spice.profitmandi.dao.repository.hrms.ContactDetailFormRepository;
|
- |
|
| 25 |
import com.spice.profitmandi.dao.repository.hrms.DocumentsDetailsFormRepository;
|
- |
|
| 26 |
import com.spice.profitmandi.dao.repository.hrms.InsuranceDetailFormRepository;
|
- |
|
| 27 |
import com.spice.profitmandi.dao.repository.hrms.StatutoryDocsAndDateRepository;
|
- |
|
| 28 |
import com.spice.profitmandi.dao.repository.hrms.WorkExperienceFormRepository;
|
- |
|
| 29 |
import com.spice.profitmandi.dao.repository.hrms.PersonalDetailsformRepository;
|
- |
|
| 30 |
import com.spice.profitmandi.dao.repository.hrms.FamilyMemberDetailsFormRepository;
|
- |
|
| 31 |
import com.spice.profitmandi.dao.repository.hrms.EmployFormRepository;
|
- |
|
| 32 |
import com.spice.profitmandi.dao.repository.hrms.BankDetailsFormRepository;
|
- |
|
| 33 |
import com.spice.profitmandi.dao.repository.hrms.BasicDetailsRepository;
|
- |
|
| 34 |
import com.spice.profitmandi.dao.repository.hrms.CompensationDetailsFormRepository;
|
- |
|
| 35 |
import com.spice.profitmandi.dao.repository.hrms.FamilyMemberDetailsFormRepository;
|
- |
|
| 36 |
import com.spice.profitmandi.web.model.LoginDetails;
|
- |
|
| 37 |
import com.spice.profitmandi.web.util.CookiesProcessor;
|
- |
|
| 38 |
import com.spice.profitmandi.web.util.MVCResponseSender;
|
- |
|
| 39 |
|
25 |
|
| 40 |
@Controller
|
26 |
@Controller
|
| 41 |
@Transactional(rollbackFor = Throwable.class)
|
27 |
@Transactional(rollbackFor = Throwable.class)
|
| 42 |
public class HrmsController {
|
28 |
public class HrmsController {
|
| 43 |
|
29 |
|
| Line 211... |
Line 197... |
| 211 |
compensationDetailsForm.setVariableCostAnnual(createEmployeeDetailFormHRMS.getVariableCostAnnual());
|
197 |
compensationDetailsForm.setVariableCostAnnual(createEmployeeDetailFormHRMS.getVariableCostAnnual());
|
| 212 |
compensationDetailsForm.setVctcMonthly(createEmployeeDetailFormHRMS.getVctcMonthly());
|
198 |
compensationDetailsForm.setVctcMonthly(createEmployeeDetailFormHRMS.getVctcMonthly());
|
| 213 |
compensationDetailsForm.setCarLease(createEmployeeDetailFormHRMS.getCarLease());
|
199 |
compensationDetailsForm.setCarLease(createEmployeeDetailFormHRMS.getCarLease());
|
| 214 |
compensationDetailsFormRepository.persist(compensationDetailsForm);
|
200 |
compensationDetailsFormRepository.persist(compensationDetailsForm);
|
| 215 |
|
201 |
|
| 216 |
model.addAttribute("response", mvcResponseSender.createResponseString(true));
|
202 |
model.addAttribute("response1", mvcResponseSender.createResponseString(true));
|
| 217 |
} else {
|
203 |
} else {
|
| 218 |
throw new ProfitMandiBusinessException(ProfitMandiConstants.ID, createEmployeeDetailFormHRMS.getAuthId(),
|
204 |
throw new ProfitMandiBusinessException(ProfitMandiConstants.ID, createEmployeeDetailFormHRMS.getAuthId(),
|
| 219 |
"Auth User not Exist");
|
205 |
"Auth User not Exist");
|
| 220 |
}
|
206 |
}
|
| 221 |
|
207 |
|