edit.html 3.4 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788
  1. <!DOCTYPE html>
  2. <html lang="zh" xmlns:th="http://www.thymeleaf.org" >
  3. <head>
  4. <th:block th:include="include :: header('修改渠道信息')" />
  5. </head>
  6. <body class="white-bg">
  7. <div class="wrapper wrapper-content animated fadeInRight ibox-content">
  8. <form class="form-horizontal m" id="form-dict-edit" th:object="${homeChannel}">
  9. <input name="id" type="hidden" th:field="*{id}" />
  10. <div class="form-group" id="chargeErBanNo">
  11. <label class="col-sm-2 control-label">渠道:</label>
  12. <div class="col-sm-10">
  13. <input name="channel" id="channel" class="form-control" th:field="*{channel}" type="text" placeholder="请输入渠道"/>
  14. </div>
  15. </div>
  16. <div class="form-group">
  17. <label class="col-sm-2 control-label">渠道别名:</label>
  18. <div class="col-sm-10">
  19. <input id="channelName" name="channelName" th:field="*{channelName}" class="form-control" type="text" placeholder="请输入渠道别名" required/>
  20. </div>
  21. </div>
  22. <div class="form-group">
  23. <label class="col-sm-2 control-label">上级渠道:</label>
  24. <div class="col-sm-10">
  25. <select name="superiorChannel" id="superiorChannel" th:with="type=${homeChannelList}">
  26. <option value=''>全部</option>
  27. <option th:each="homeChannel : ${type}" th:text="${homeChannel.name}" th:value="${homeChannel.channel}" th:field="*{superiorChannel}"></option>
  28. </select>
  29. </div>
  30. </div>
  31. <div class="form-group" id="chargeBlockIp">
  32. <label class="col-sm-2 control-label">首页默认大小:</label>
  33. <div class="col-sm-10">
  34. <input id="homeDefault" name="homeDefault" class="form-control" type="text" th:field="*{homeDefault}" placeholder="请输入首页默认大小" required/>
  35. </div>
  36. </div>
  37. <div class="form-group">
  38. <label class="col-sm-2 control-label">新老用户:</label>
  39. <div class="col-sm-10">
  40. <select name="isNews" id="isNews" class="form-control m-b" th:with="type=${@dict.getType('is_news_type')}">
  41. <option th:each="dict : ${type}" th:text="${dict.dictLabel}" th:value="${dict.dictValue}" th:field="*{isNews}"></option>
  42. </select>
  43. </div>
  44. </div>
  45. <div class="form-group">
  46. <label class="col-sm-2 control-label">是否对外:</label>
  47. <div class="col-sm-10">
  48. <select name="type" id="type" class="form-control m-b" th:with="type=${@dict.getType('is_foreign_type')}">
  49. <option th:each="dict : ${type}" th:text="${dict.dictLabel}" th:value="${dict.dictValue}" th:field="*{type}"></option>
  50. </select>
  51. </div>
  52. </div>
  53. <div class="form-group">
  54. <label class="col-sm-2 control-label">组别:</label>
  55. <div class="col-sm-10">
  56. <select name="groupId" th:with="type=${homeChannelGroupList}">
  57. <option value="0">没有</option>
  58. <option th:each="homeChannelGroup : ${type}" th:text="${homeChannelGroup.groupName}" th:value="${homeChannelGroup.groupId}" th:field="*{groupId}"></option>
  59. </select>
  60. </div>
  61. </div>
  62. </form>
  63. </div>
  64. <th:block th:include="include :: footer" />
  65. <script type="text/javascript">
  66. var prefix = ctx + "marketing/channel";
  67. $("#form-dict-edit").validate({
  68. focusCleanup: true
  69. });
  70. function submitHandler() {
  71. if ($.validate.form()) {
  72. $.operate.save(prefix + "/edit", $('#form-dict-edit').serialize());
  73. }
  74. }
  75. </script>
  76. </body>
  77. </html>