截流自动化的商城平台
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

setting.html 3.7KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889
  1. {layout name="layout1" /}
  2. <style>
  3. .layui-form-label {
  4. width: 120px;
  5. }
  6. .layui-input-block {
  7. margin-left: 150px;
  8. }
  9. </style>
  10. <div class="wrapper">
  11. <div class="layui-card">
  12. <div class="layui-card-body">
  13. <!--操作提示-->
  14. <div class="layui-collapse like-layui-collapse" lay-accordion="" style="border:1px dashed #c4c4c4">
  15. <div class="layui-colla-item">
  16. <h2 class="layui-colla-title like-layui-colla-title" style="background-color: #fff">操作提示</h2>
  17. <div class="layui-colla-content layui-show">
  18. <p>*设置是否启用种草功能,以及文章和评论相关审核设置,默认都开启审核</p>
  19. </div>
  20. </div>
  21. </div>
  22. <!--表单区域-->
  23. <div class="layui-form" style="margin-top: 15px;">
  24. <div class="layui-field-box">
  25. <div class="layui-form-item">
  26. <lable class="layui-form-label">种草功能:</lable>
  27. <div class="layui-input-block" style="width:300px;">
  28. <input type="radio" name="status" value="1" title="开启" {if $config.status == 1} checked {/if}>
  29. <input type="radio" name="status" value="0" title="关闭" {if !$config.status} checked {/if}>
  30. </div>
  31. </div>
  32. <div class="layui-form-item">
  33. <lable class="layui-form-label">文章审核:</lable>
  34. <div class="layui-input-block" style="width:300px;">
  35. <input type="radio" name="audit_article" value="1" title="开启" {if $config.audit_article == 1} checked {/if}>
  36. <input type="radio" name="audit_article" value="0" title="关闭" {if !$config.audit_article} checked {/if}>
  37. </div>
  38. </div>
  39. <div class="layui-form-item">
  40. <lable class="layui-form-label">评论审核:</lable>
  41. <div class="layui-input-block" style="width:300px;">
  42. <input type="radio" name="audit_comment" value="1" title="开启" {if $config.audit_comment == 1} checked {/if}>
  43. <input type="radio" name="audit_comment" value="0" title="关闭" {if !$config.audit_comment} checked {/if}>
  44. </div>
  45. </div>
  46. </div>
  47. <div class="layui-form-item">
  48. <lable class="layui-form-label"></lable>
  49. <div class="layui-input-block">
  50. <button class="layui-btn layui-btn-normal" lay-submit lay-filter="set">确定</button>
  51. </div>
  52. </div>
  53. </div>
  54. </div>
  55. </div>
  56. </div>
  57. <script>
  58. layui.config({
  59. version:"{$front_version}",
  60. base: '/static/lib/'
  61. }).use(['form','element'], function(){
  62. var $ = layui.$,
  63. form = layui.form,
  64. element = layui.element;
  65. form.on('submit(set)', function(data) {
  66. like.ajax({
  67. url:'{:url("community.CommunitySetting/setting")}',
  68. data: data.field,
  69. type:"post",
  70. success:function(res)
  71. {
  72. if(res.code == 1)
  73. {
  74. layui.layer.msg(res.msg, {
  75. offset: '15px'
  76. , icon: 1
  77. , time: 1000
  78. });
  79. }
  80. }
  81. });
  82. });
  83. });
  84. </script>