view.html 2.9 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758
  1. {extend name="../../base/view/common/base" /}
  2. {block name="style"}
  3. <link rel="stylesheet" href="{__GOUGU__}/third_party/prism/prism.css"/>
  4. <style>
  5. .text-detial-ops{line-height: 30px; color:#999; font-size: 12px; padding: 12px 0;}
  6. .text-detial-ops span{margin-right: 20px;}
  7. .text-detial-ops a{margin-right:10px;}
  8. .text-detial-content{padding: 8px 0; color:#333; word-break: break-all; border-top:1px solid #e8e8e8;font-size: 16px!important; line-height: 1.72!important;}
  9. .text-detial-content p{padding: 8px 0;}
  10. .text-detial-content img{max-width:98%!important; margin:0 auto; display:block; border: 1px solid #e6e6e6; -webkit-box-shadow: 0 2px 6px rgba(26,26,26,.08); box-shadow: 0 2px 6px rgba(26,26,26,.08); border-radius: 4px;}
  11. .text-detial-content h1,.text-detial-content h2,.text-detial-content h3,.text-detial-content h4,.text-detial-content h5{margin-top:10px;}
  12. .text-detial-content a{color:#186AF2; font-style:italic;}
  13. .text-detial-content a:hover{text-decoration:underline;}
  14. .text-detial-content p code,.blog-detial-content pre{margin:0 3px;font-size: 14px; font-family: SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace; background: #f6f6f6; padding: 10px; border-radius: 2px;}
  15. .text-detial-content p code{border: 1px solid #eee;padding: 2px 4px;}
  16. .text-detial-content table {border-collapse: collapse; border-spacing: 0; display: block; width: 100%; overflow: auto; word-break: normal;word-break: keep-all; margin-top: 0;margin-bottom: 16px;}
  17. .text-detial-content table tr {background-color: #fff;border-top: 1px solid #ccc;}
  18. .text-detial-content table tr:nth-child(2n) {background-color: #f8f8f8;}
  19. .text-detial-content table td, .blog-detial-content table th { padding: 6px 12px;border: 1px solid #ddd; font-size:14px; }
  20. .text-detial-content table th {font-weight: 800;}
  21. .text-detial-content li {list-style: initial;margin-left: 20px;}
  22. :not(pre)>code[class*=language-], pre[class*=language-]{background:#fff!important;border:1px solid #e8e8e8!important; border-radius:3px;}
  23. .upload-file{padding:12px; background-color:#fff; border:1px solid #eee; margin-bottom:12px;}
  24. .upload-file h3{margin-bottom:12px;}
  25. </style>
  26. {/block}
  27. <!-- 主体 -->
  28. {block name="body"}
  29. <form class="layui-form p-4">
  30. <h1>{$detail.title}</h1>
  31. <div class="text-detial-ops">
  32. <span>{$detail.admin_name}发表于:{$detail.create_time}</span><span>关联项目:{$detail.project_name}</span>
  33. </div>
  34. <div class="text-detial-content">
  35. {$detail.content|raw}
  36. </div>
  37. {notempty name="$detail.file_ids"}
  38. <div class="upload-file layui-row">
  39. <h3>相关附件</h3>
  40. {volist name="$detail.file_array" id="vo"}
  41. <div class="layui-col-md4" id="uploadFile{$vo.id}">{:file_card($vo,'view')}</div>
  42. {/volist}
  43. </div>
  44. {/notempty}
  45. </div>
  46. {/block}
  47. <!-- 脚本 -->
  48. {block name="script"}
  49. <script src="{__GOUGU__}/third_party/prism/prism.js"></script>
  50. <script>
  51. const moduleInit = ['tool'];
  52. function gouguInit() {
  53. var form = layui.form,tool=layui.tool;
  54. }
  55. </script>
  56. {/block}
  57. <!-- /脚本 -->