edit.htm 2.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566
  1. <link rel="stylesheet" href="/admin/assets/css/bootstrap.min.css" />
  2. <link rel="stylesheet" href="/admin/assets/css/font-awesome.min.css" />
  3. <link rel="stylesheet" href="/admin/assets/css/ace.min.css" />
  4. <link rel="stylesheet" href="/admin/assets/css/ace-rtl.min.css" />
  5. <link rel="stylesheet" href="/admin/assets/css/ace-skins.min.css" />
  6. <script src="/admin/script/jquery.min.js"></script>
  7. <script src="/admin/script/jquery.form.js"></script>
  8. <div class="page-content" style="height:450px;overflow:scroll;">
  9. <div class="page-header">
  10. <h1>
  11. ##if(type.type==1){
  12. 编辑模板用途
  13. ##}else if(type.type==2){
  14. 编辑模板行业
  15. ##}else if(type.type==3){
  16. 编辑模板节日
  17. ##}else{
  18. 编辑模板风格
  19. ##}
  20. </h1>
  21. </div>
  22. <div class="row">
  23. <div class="col-xs-12">
  24. <form class="form-horizontal" action="/admin/diyType/update" method="post" id="submit_form">
  25. <div class="form-group">
  26. <label class="col-sm-3 control-label"><span style="color: #f00">*</span>名称</label>
  27. <div class="col-sm-9">
  28. <input type="text" name="title" class="col-xs-10 col-sm-5" style="border: 1px solid #ccc" value="${type.title!}" />
  29. </div>
  30. </div>
  31. <div class="space-4"></div>
  32. <div class="form-group">
  33. <label class="col-sm-2 control-label"><span style="color: #f00">*</span>顺序</label>
  34. <div class="col-sm-10">
  35. <input type="text" name="idx" class="col-xs-10 col-sm-5" style="border: 1px solid #ccc" value="${type.idx!}" />
  36. </div>
  37. </div>
  38. <input type="hidden" value="${type.id!}" name="id" />
  39. </form>
  40. </div>
  41. </div>
  42. </div>
  43. <div style="width:100%;text-align: center;">
  44. <button type="button" class="btn btn-info" onclick="return submitForm()" style="padding:0px 5px;margin-top:5px;">
  45. <i class="icon-ok bigger-110"></i>确定
  46. </button>
  47. &nbsp;&nbsp;
  48. <button type="reset" class="btn" onclick="parent.hideAlert()" style="padding:0px 5px;margin-top:5px;">
  49. <i class="icon-undo bigger-110"></i>取消
  50. </button>
  51. </div>
  52. <script>
  53. function submitForm(){
  54. $('#submit_form').ajaxSubmit({
  55. success: function(data){
  56. alert(data.msg);
  57. if(data.success){
  58. parent.location.reload();
  59. }
  60. }
  61. });
  62. }
  63. </script>