add.html 3.6 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374
  1. <include file="public@header"/>
  2. </head>
  3. <body>
  4. <div class="wrap js-check-wrap">
  5. <ul class="nav nav-tabs">
  6. <li><a href="{:url('SlideItem/index',['slide_id'=>$slide_id])}">幻灯片页面列表</a></li>
  7. <li class="active"><a href="{:url('SlideItem/add',['slide_id'=>$slide_id])}">添加幻灯片页面</a></li>
  8. </ul>
  9. <form action="{:url('SlideItem/addPost')}" method="post" class="form-horizontal js-ajax-form margin-top-20">
  10. <div class="row">
  11. <div class="col-md-9">
  12. <table class="table table-bordered">
  13. <tr>
  14. <th>标题<span class="form-required">*</span></th>
  15. <td>
  16. <input class="form-control" type="text" style="width:400px;" name="post[title]" id="title"
  17. required value="" placeholder="请输入标题"/>
  18. </td>
  19. </tr>
  20. <tr>
  21. <th>链接</th>
  22. <td>
  23. <input class="form-control" type="text" name="post[url]" id="keywords" value=""
  24. style="width: 400px" placeholder="请输入链接">
  25. </td>
  26. </tr>
  27. <tr>
  28. <th>描述</th>
  29. <td><input class="form-control" type="text" name="post[description]" id="source" value=""
  30. style="width: 400px" placeholder="请输入描述"></td>
  31. </tr>
  32. <tr>
  33. <th>幻灯片内容</th>
  34. <td>
  35. <textarea class="form-control" name="post[content]" id="description"
  36. style="width: 47%; height: 100px;" placeholder="请填写幻灯片内容"></textarea>
  37. </td>
  38. </tr>
  39. </table>
  40. </div>
  41. <div class="col-md-3">
  42. <table class="table table-bordered">
  43. <tr>
  44. <th><b>缩略图</b></th>
  45. </tr>
  46. <tr>
  47. <td>
  48. <div style="text-align: center;">
  49. <input type="hidden" name="post[image]" id="thumb" value="">
  50. <a href="javascript:uploadOneImage('图片上传','#thumb');">
  51. <img src="__TMPL__/public/assets/images/default-thumbnail.png" id="thumb-preview"
  52. width="135" style="cursor: hand"/>
  53. </a>
  54. <input type="button" class="btn btn-sm"
  55. onclick="$('#thumb-preview').attr('src','__TMPL__/public/assets/images/default-thumbnail.png');$('#thumb').val('');return false;"
  56. value="取消图片">
  57. </div>
  58. </td>
  59. </tr>
  60. </table>
  61. </div>
  62. </div>
  63. <div class="form-group">
  64. <div class="col-sm-offset-2 col-sm-10">
  65. <input type="hidden" name="post[slide_id]" value="{$slide_id}">
  66. <button type="submit" class="btn btn-primary js-ajax-submit">{:lang('ADD')}</button>
  67. <a class="btn btn-default" href="{:url('SlideItem/index',['slide_id'=>$slide_id])}">{:lang('BACK')}</a>
  68. </div>
  69. </div>
  70. </form>
  71. </div>
  72. <script type="text/javascript" src="__STATIC__/js/admin.js"></script>
  73. </body>
  74. </html>