Search in sources :

Example 1 with AuditLogScreenDto

use of org.mifos.dto.screen.AuditLogScreenDto in project head by mifos.

the class LoanProductChangeLogController method showAllAuditLogsForSavingsProducts.

@ModelAttribute("auditLog")
@RequestMapping(method = RequestMethod.GET)
public AuditLogScreenDto showAllAuditLogsForSavingsProducts(@RequestParam(value = "productId", required = true) Integer productId) {
    LoanProductRequest productDetails = adminServiceFacade.retrieveLoanProductDetails(productId);
    List<AuditLogDto> auditLogRecords = adminServiceFacade.retrieveLoanProductAuditLogs(productId);
    return new AuditLogScreenDto(productDetails.getProductDetails().getId(), productDetails.getProductDetails().getName(), productDetails.getProductDetails().getCreatedDateFormatted(), auditLogRecords);
}
Also used : AuditLogScreenDto(org.mifos.dto.screen.AuditLogScreenDto) AuditLogDto(org.mifos.dto.domain.AuditLogDto) LoanProductRequest(org.mifos.dto.domain.LoanProductRequest) ModelAttribute(org.springframework.web.bind.annotation.ModelAttribute) RequestMapping(org.springframework.web.bind.annotation.RequestMapping)

Example 2 with AuditLogScreenDto

use of org.mifos.dto.screen.AuditLogScreenDto in project head by mifos.

the class SavingsProductChangeLogController method showAllAuditLogsForSavingsProducts.

@ModelAttribute("auditLog")
@RequestMapping(method = RequestMethod.GET)
public AuditLogScreenDto showAllAuditLogsForSavingsProducts(@RequestParam(value = "productId", required = true) Integer productId) {
    SavingsProductDto productDetails = adminServiceFacade.retrieveSavingsProductDetails(productId);
    List<AuditLogDto> auditLogRecords = adminServiceFacade.retrieveSavingsProductAuditLogs(productId);
    return new AuditLogScreenDto(productDetails.getProductDetails().getId(), productDetails.getProductDetails().getName(), productDetails.getProductDetails().getCreatedDateFormatted(), auditLogRecords);
}
Also used : SavingsProductDto(org.mifos.dto.domain.SavingsProductDto) AuditLogScreenDto(org.mifos.dto.screen.AuditLogScreenDto) AuditLogDto(org.mifos.dto.domain.AuditLogDto) ModelAttribute(org.springframework.web.bind.annotation.ModelAttribute) RequestMapping(org.springframework.web.bind.annotation.RequestMapping)

Aggregations

AuditLogDto (org.mifos.dto.domain.AuditLogDto)2 AuditLogScreenDto (org.mifos.dto.screen.AuditLogScreenDto)2 ModelAttribute (org.springframework.web.bind.annotation.ModelAttribute)2 RequestMapping (org.springframework.web.bind.annotation.RequestMapping)2 LoanProductRequest (org.mifos.dto.domain.LoanProductRequest)1 SavingsProductDto (org.mifos.dto.domain.SavingsProductDto)1