Advertisement
Guest User

Untitled

a guest
Oct 15th, 2019
108
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 3.73 KB | None | 0 0
  1. For emsd_report,
  2. there are two reports done:
  3. 1.user performance daily report
  4. 2.calllog report
  5. The source can be found in
  6. emsd_report\servlet_report_emsd_crm\src\servlet
  7.  
  8. ---------------------------------------------------------------------------------------------------------------------
  9. 1.user performance daily report
  10. The entry point of the report is generateReport method in DailyReportWorkbook class,
  11. which is defined in
  12. emsd_report\servlet_report_emsd_crm\src\servlet\DailyReportWorkbook.java
  13.  
  14. it then call the Report.getInstance method,
  15. defined in
  16. emsd_report\servlet_report_emsd_crm\src\servlet\report\userperformancemonthly\bean\Report.java
  17.  
  18. Inside the Report class,
  19. the agent id and name will be retrieved from db table `hanphone_crm_csc`.`user` first.
  20.  
  21. Afterward, the agent id list is used as key to search the `hanphone_crm_csc`.`presence_log` to retrieve all the records within the date range corresponding to the agents.
  22. The Report.getInstance method will call different method defined in the Report class to calculate different field related to status in the excel for each agent and each day on the data retrieved from db table `presence_log`.
  23.  
  24. The Report.getInstance method also call method in
  25. emsd_report\servlet_report_emsd_crm\src\servlet\report\userperformancemonthly\bean\CallDBconnecter.java
  26. for getting data about calls, doing calculation related to call count and call duration.
  27.  
  28. Finally, the Report.getInstance method will save all the calculated result to bean AgentDaily and AgentSummary
  29. At the end, the generateAgentRows method in DailyReportWorkbook class will retrieve the fields from bean AgentDaily and AgentSummary for showing them in an excel.
  30. ---------------------------------------------------------------------------------------------------------------------
  31.  
  32. 2.calllog report
  33. The entry point of the report is generateReport method in CallLogReportWorkbook class,
  34. which is defined in
  35. emsd_report\servlet_report_emsd_crm\src\servlet\CallLogReportWorkbook.java
  36.  
  37. it then call the Report constructor in
  38. emsd_report\servlet_report_emsd_crm\src\servlet\report\calllog\Report.java
  39.  
  40. The Report class is used for storing all the excel calllog rows.
  41.  
  42. Each calllog fields are calculated by using the data retrieved from db tables `oscc_dababase`.`callrecord`, `oscc_dababase`.`agentrecord` and `oscc_dababase`.`users`.
  43.  
  44. There is only one loop to retrieve data from db tables and do the calculation for each call.
  45.  
  46. The initiated calllog rows in the Report is eventually read by generateCallLogRows method in the CallLogReportWorkbook class to assign to the corresponding excel cells.
  47. =====================================================================================================================
  48. For the web portal,
  49. two items, 'User Performance Daily Report' and 'CallLog Report', are created under the 'Reports' tab of the top navigation bar.
  50. Here, we need to create two rows inside the db table `hanphone_crm_csc`.`menu`.
  51. We first find that the id of the Reports is 34 in this case.
  52. To add more items under the 'Reports', we just need to create the item with the parent field to be 34, that is ths id of the 'Reports
  53. id label parent sequence controller action
  54. 155 User Performance Daily Report 34 10 report userPerformanceDailyReport
  55.  
  56. 156 CallLog Report 34 11 report callLogReport
  57. the sequence number is the position under the tab. So 'CallLog Report' will appear under 'User Performance Daily Report' on web portal.
  58. the controller and action field store the name of the controller and action in this yii webapp for handling the page.
  59.  
  60. The main page of the web portal is generated by
  61. protected\views\layouts\main.php,
  62. which call the MenuUtil class to read menu table.
  63.  
  64. The final thing is to set the access right for these pages under the System tab to display the pages.
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement