Skip to content

Added Employee detail component, Request component integration with employee and request services, styling, and refactoring #13

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 13 commits into from
Oct 8, 2018

Conversation

iammangod96
Copy link
Contributor

No description provided.

Copy link
Owner

@SKrudra SKrudra left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please incorporate comments.

public void updateRequestStatus(@PathVariable Long empId, RequestStatus requestStatus){
requestService.setRequestStatus(requestStatus, empId);
//2. Update Request Status PUT/request/{reqId}
// @RequestMapping(value="/api/request", method=RequestMethod.PUT)
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Removed commented out code unless you need it.

requestService.addRequest(newRequest);
@RequestMapping(value="/api/request", method=RequestMethod.POST)
public ResponseEntity createRequest(@RequestBody Request newRequest){
System.out.println(newRequest);
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Don't comment any system logs. Use logger if you want to add logs to the app. [log4j]

emp = employeeService.getEmployee(newRequest.getEmployee().getId());
Request req =newRequest;
req.setEmployee(emp);
this.requestService.addRequest(req);
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Do you really need to use "this" keyword?

request.requestDescription = requestDescription;
request.requestStatus='OPEN';
request.comment="NA";
console.log(request);
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Don't commit any console logs.

@iammangod96
Copy link
Contributor Author

Required changes done.

@SKrudra SKrudra merged commit d06e1e1 into SKrudra:master Oct 8, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants