editdoc.html.php 2.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657
  1. <?php
  2. /**
  3. * The editdoc view of assetlib module of ZenTaoPMS.
  4. *
  5. * @copyright Copyright 2009-2021 禅道软件(青岛)有限公司(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 Shujie Tian <tianshujie@easycorp.ltd>
  8. * @package assetlib
  9. * @version $Id: editdoc.html.php 975 2021-06-30 13:25:25Z jajacn@126.com $
  10. * @link https://www.zentao.net
  11. */
  12. ?>
  13. <?php include $app->getModuleRoot() . 'common/view/header.html.php';?>
  14. <?php if($doc->contentType == 'html' || $doc->contentType == 'doc') include $app->getModuleRoot() . 'common/view/kindeditor.html.php';?>
  15. <?php if($doc->contentType == 'markdown') include $app->getModuleRoot() . 'common/view/markdown.html.php';?>
  16. <div id='mainContent' class='main-content'>
  17. <div class='center-block'>
  18. <div class='main-header'>
  19. <h2>
  20. <span class='label label-id'><?php echo $doc->id;?></span>
  21. <?php $viewMethod = $objectType == 'practice' ? 'practiceView' : 'componentView';?>
  22. <?php echo html::a($this->createLink('assetlib', $viewMethod, "docID=$doc->id"), $doc->title, '', "title='$doc->title'");?>
  23. <small> <?php echo $lang->arrow . ' ' . $lang->doc->edit;?></small>
  24. </h2>
  25. </div>
  26. <form class='load-indicator main-form form-ajax' method='post' enctype='multipart/form-data' id='dataform'>
  27. <table class='table table-form'>
  28. <tr>
  29. <th><?php echo $lang->doc->title;?></th>
  30. <td colspan='2'><?php echo html::input('title', $doc->title, "class='form-control' required");?></td>
  31. </tr>
  32. <tr>
  33. <th><?php echo $lang->doc->keywords;?></th>
  34. <td colspan='2'><?php echo html::input('keywords', $doc->keywords, "class='form-control'");?></td>
  35. </tr>
  36. <tr id='contentBox'>
  37. <th><?php echo $lang->doc->content;?></th>
  38. <td colspan='2'><?php echo html::textarea('content', $doc->type == 'url' ? '' : htmlspecialchars($doc->content), "style='width:100%; height:200px'") . html::hidden('contentType', $doc->contentType);?></td>
  39. </tr>
  40. <tr id='fileBox'>
  41. <th><?php echo $lang->doc->files;?></th>
  42. <td colspan='2'><?php echo $this->fetch('file', 'buildoldform');?></td>
  43. </tr>
  44. <tr>
  45. <td colspan='3' class='text-center form-actions'>
  46. <?php
  47. echo html::hidden('editedDate', $doc->editedDate);
  48. echo html::submitButton();
  49. echo html::backButton();
  50. ?>
  51. </td>
  52. </tr>
  53. </table>
  54. </form>
  55. </div>
  56. </div>
  57. <?php include $app->getModuleRoot() . 'common/view/footer.html.php';?>