listItem.json 5.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135
  1. [
  2. {
  3. "title" : MWF.xApplication.Attendance.LP.name,
  4. "headStyles" : "normalThNode",
  5. "contentStyles" : "normalTdNode",
  6. "item" : "function( d ){ return (d.empName || '').split('@')[0] }",
  7. "name" : "empName",
  8. "width" : "6%"
  9. },
  10. {
  11. "title" : MWF.xApplication.Attendance.LP.date,
  12. "headStyles" : "normalThNode",
  13. "contentStyles" : "normalTdNode",
  14. "defaultSort" : "desc",
  15. "item" : "recordDateString",
  16. "name" : "recordDateString",
  17. "width" : "6%"
  18. },
  19. {
  20. "title" : MWF.xApplication.Attendance.LP.description,
  21. "headStyles" : "normalThNode",
  22. "contentStyles" : "normalTdNode",
  23. "item" : "function( data ){ if(data.isHoliday){ return MWF.xApplication.Attendance.LP.holiday1 }else if(data.isWeekend){return MWF.xApplication.Attendance.LP.weekend }else if(data.isWorkday){return MWF.xApplication.Attendance.LP.workDaysoff }else{return MWF.xApplication.Attendance.LP.workDay } }",
  24. "name" : "description",
  25. "width" : "6%"
  26. },
  27. {
  28. "title" : MWF.xApplication.Attendance.LP.onDutyTime,
  29. "headStyles" : "normalThNode",
  30. "contentStyles" : "normalTdNode",
  31. "item" : "onDutyTime",
  32. "name" : "onDutyTime",
  33. "width" : "6%"
  34. },
  35. {
  36. "title" : MWF.xApplication.Attendance.LP.middayRestStartTime,
  37. "headStyles" : "normalThNode",
  38. "contentStyles" : "normalTdNode",
  39. "item" : "morningOffDutyTime",
  40. "name" : "morningOffDutyTime",
  41. "width" : "6%"
  42. },
  43. {
  44. "title" : MWF.xApplication.Attendance.LP.middayRestEndTime,
  45. "headStyles" : "normalThNode",
  46. "contentStyles" : "normalTdNode",
  47. "item" : "afternoonOnDutyTime",
  48. "name" : "afternoonOnDutyTime",
  49. "width" : "9%"
  50. },
  51. {
  52. "title" : MWF.xApplication.Attendance.LP.offDutyTime,
  53. "headStyles" : "normalThNode",
  54. "contentStyles" : "normalTdNode",
  55. "item" : "offDutyTime",
  56. "name" : "offDutyTime",
  57. "width" : "6%"
  58. },
  59. {
  60. "title": MWF.xApplication.Attendance.LP.attendanceStatus,
  61. "headStyles": "normalThNode",
  62. "contentStyles": "normalTdNode",
  63. "item": "function( d ){ var status=''; if(d.isGetSelfHolidays){ if(d.leaveType && d.leaveType!=''){status =d.leaveType }else{status = MWF.xApplication.Attendance.LP.levelAsked } }else if(d.isLate){ status = MWF.xApplication.Attendance.LP.late }else if(d.isLeaveEarlier){ status = MWF.xApplication.Attendance.LP.leaveEarly }else if(d.isAbsent){ status = MWF.xApplication.Attendance.LP.noSign }else if(d.isAbnormalDuty){ status = MWF.xApplication.Attendance.LP.abNormalDuty }else if(d.isLackOfTime){ status = MWF.xApplication.Attendance.LP.lackOfTime }else{ status = MWF.xApplication.Attendance.LP.normal }; return status; }",
  64. "name" : "status",
  65. "width" : "6%"
  66. } ,
  67. {
  68. "title": MWF.xApplication.Attendance.LP.isCheckInOutOfRange,
  69. "headStyles": "normalThNode",
  70. "contentStyles": "normalTdNode",
  71. "item": "function( d ){ if(d.isExternal){ return MWF.xApplication.Attendance.LP.yes }else{ return MWF.xApplication.Attendance.LP.no }}",
  72. "name" : "isOutRange",
  73. "width" : "7%"
  74. },
  75. {
  76. "title" : MWF.xApplication.Attendance.LP.recordAddress,
  77. "headStyles" : "normalThNode",
  78. "contentStyles" : "normalTdNode",
  79. "item" : "function( data ){ if(data.workAddress && data.workAddress!=\"\"){ return data.workAddress }else{return data.recordAddress }}",
  80. "name" : "address",
  81. "width" : "6%"
  82. },
  83. {
  84. "title" : MWF.xApplication.Attendance.LP.optMachineType,
  85. "headStyles" : "normalThNode",
  86. "contentStyles" : "normalTdNode",
  87. "item" : "optMachineType",
  88. "name" : "optMachineType",
  89. "width" : "6%"
  90. },
  91. {
  92. "title": MWF.xApplication.Attendance.LP.appealStatus,
  93. "headStyles": "normalThNode",
  94. "contentStyles": "normalTdNode",
  95. "item": "function( d ){ if(d.appealStatus==1){ return MWF.xApplication.Attendance.LP.appealStatusSelectText[0] }else if(d.appealStatus==-1){ return MWF.xApplication.Attendance.LP.appealStatusSelectText[1] }else if(d.appealStatus==9){ return MWF.xApplication.Attendance.LP.appealStatusSelectText[2] }else{ return '' } }",
  96. "name" : "appealStatus",
  97. "width" : "6%"
  98. },
  99. {
  100. "title": MWF.xApplication.Attendance.LP.appealAuditor,
  101. "headStyles": "normalThNode",
  102. "contentStyles": "normalTdNode",
  103. "item": "function( d ){ return d.appealProcessor ? d.appealProcessor.split('@')[0] : '' }",
  104. "name" : "appealAuditor",
  105. "width" : "6%"
  106. },
  107. {
  108. "title" :MWF.xApplication.Attendance.LP.appeal,
  109. "headStyles" : "normalThNode",
  110. "contentStyles" : "normalTdNode",
  111. "item" : "actions",
  112. "name" : "actions",
  113. "width" : "9%",
  114. "sub" : [{
  115. "title" : MWF.xApplication.Attendance.LP.createAppeal,
  116. "action" : "appeal",
  117. "fonticon": "o2icon-icon_tishi",
  118. // "icon": "appeal.png",
  119. "condition" : "function( d ){ if(!d.APPEALABLE)return false; if( d.appealStatus || d.isGetSelfHolidays ){ return false }else if( d.isAbsent || d.isLate || d.isLeaveEarlier || d.isAbnormalDuty || d.isLackOfTime ){ return true }else{ return false } }",
  120. "styles" : "documentActionNode",
  121. "overStyles" : "documentActionNode_over",
  122. "downStyles" : "documentActionNode_down"
  123. },{
  124. "title" : MWF.xApplication.Attendance.LP.viewAppealDetail,
  125. "action" : "seeAppeal",
  126. "fonticon": "o2icon-icon_shitu",
  127. // "icon": "open.png",
  128. "condition" : "function( d ){ if( d.appealStatus ){ return true }else{ return false } }",
  129. "styles" : "documentActionNode",
  130. "overStyles" : "documentActionNode_over",
  131. "downStyles" : "documentActionNode_down"
  132. }]
  133. }
  134. ]