m.view.html.php 3.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293
  1. <?php
  2. /**
  3. * The view mobile view file of effort module of ZenTaoPMS.
  4. *
  5. * @copyright Copyright 2009-2015 禅道软件(青岛)有限公司(ZenTao Software (Qingdao) Co., Ltd. www.cnezsoft.com)
  6. * @license ZPL(http://zpl.pub/page/zplv12.html) or AGPL(https://www.gnu.org/licenses/agpl-3.0.en.html)
  7. * @author Yidong Wang <yidong@cnezsoft.com>
  8. * @package effort
  9. * @version $Id$
  10. * @link http://www.zentao.net
  11. */
  12. if($this->session->effortList)
  13. {
  14. $browseLink = $this->session->effortList;
  15. }
  16. elseif($effort->account == $app->user->account)
  17. {
  18. $browseLink = $this->createLink('my', 'effort');
  19. }
  20. else
  21. {
  22. $browseLink = $this->createLink('user', 'effort', "userID=$user->id");
  23. }
  24. $bodyClass = 'with-nav-bottom';
  25. include "../../common/view/m.header.html.php";
  26. ?>
  27. <div id='page' class='list-with-actions'>
  28. <div class='heading'>
  29. <div class='title'><?php echo $lang->effort->view;?></div>
  30. <nav class='nav'>
  31. <a href='javascript:history.go(-1);' class='btn primary'><?php echo $lang->goback;?></a>
  32. </nav>
  33. </div>
  34. <div class='section no-margin'>
  35. <div class='box'>
  36. <table class='table bordered table-detail'>
  37. <tr>
  38. <th class='w-80px'><?php echo $lang->effort->account;?></th>
  39. <td><?php echo zget($users, $effort->account);?></td>
  40. </tr>
  41. <tr>
  42. <th><?php echo $lang->effort->date;?></th>
  43. <td><?php echo date(DT_DATE1, strtotime($effort->date));?></td>
  44. </tr>
  45. <tr>
  46. <th><?php echo $lang->effort->consumed;?></th>
  47. <td>
  48. <?php
  49. if(isset($effort->consumed)) echo $effort->consumed . ' ' . $lang->effort->hour;
  50. ?>
  51. </td>
  52. </tr>
  53. <?php if($effort->objectType == 'task'):?>
  54. <tr>
  55. <th><?php echo $lang->effort->left;?></th>
  56. <td>
  57. <?php
  58. if(isset($effort->consumed)) echo $effort->left . ' ' . $lang->effort->hour;
  59. ?>
  60. </td>
  61. </tr>
  62. <?php endif;?>
  63. <tr <?php if($work) echo "data-url='" . $this->createLink($effort->objectType, 'view', "objectID={$effort->objectID}") . "'"?>>
  64. <th><?php echo $lang->effort->objectType;?></th>
  65. <td>
  66. <?php
  67. echo $lang->effort->objectTypeList[$effort->objectType];
  68. if($work) echo ' #' . $effort->objectID . ' ' .$work[$effort->objectID];
  69. ?>
  70. </td>
  71. </tr>
  72. <tr>
  73. <th><?php echo $lang->effort->work;?></th>
  74. <td><?php echo $effort->work;?></td>
  75. </tr>
  76. </table>
  77. </div>
  78. <?php include '../../common/view/m.action.html.php';?>
  79. </div>
  80. <nav class='nav nav-auto affix dock-bottom footer-actions'>
  81. <?php
  82. if($effort->account == $app->user->account)
  83. {
  84. common::printIcon('effort', 'edit', "effortID=$effort->id", $effort, 'button','', '', '', false, "data-display='modal' data-placement='bottom'", $lang->edit);
  85. if(common::hasPriv('effort', 'delete')) echo html::a($this->createLink('effort', 'delete', "effortID=$effort->id"), $lang->delete, 'hiddenwin');
  86. }
  87. ?>
  88. </nav>
  89. </div>
  90. <?php include "../../common/view/m.footer.html.php"; ?>