member_mallconsult_add.html 4.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123
  1. {extend name="default/base/base_member" /}
  2. {block name="member_main"}
  3. <div class="dsm-flow-layout">
  4. <div id="dsmInformFlow" class="dsm-flow-container">
  5. <div class="title">
  6. <h3>{$Think.lang.consulting_platform_customer_service}</h3>
  7. </div>
  8. <div class="dsm-flow-step">
  9. <dl class="step-first current">
  10. <dt>{$Think.lang.filling_consulting_content}</dt>
  11. <dd class="bg"></dd>
  12. </dl>
  13. <dl class="">
  14. <dt>{$Think.lang.platform_customer_service_reply}</dt>
  15. <dd class="bg"> </dd>
  16. </dl>
  17. <dl class="">
  18. <dt>{$Think.lang.consultation_completed}</dt>
  19. <dd class="bg"> </dd>
  20. </dl>
  21. </div>
  22. <div class="dsm-default-form">
  23. <form id="mallconsult_form" method="post" action="{:url('Membermallconsult/save_mallconsult')}">
  24. <dl>
  25. <dt>{$Think.lang.type_consultation}{$Think.lang.ds_colon}</dt>
  26. <dd>
  27. <div><select name="type_id" id="type_id">
  28. <option value="0">{$Think.lang.ds_please_choose}</option>
  29. {notempty name="type_list"}
  30. {foreach name="type_list" item="val"}
  31. <option value="{$val.mallconsulttype_id}">{$val.mallconsulttype_name}</option>
  32. {/foreach}
  33. {/notempty}
  34. </select>
  35. <span class="error"></span></div>
  36. <div>
  37. <div></div>
  38. {notempty name="type_list"}
  39. {foreach name="type_list" item="val"}
  40. <div style="display:none;">{:htmlspecialchars_decode($val.mallconsulttype_introduce)}</div>
  41. {/foreach}
  42. {/notempty}
  43. </div>
  44. </dd>
  45. </dl>
  46. <dl>
  47. <dt>{$Think.lang.content_consultation}{$Think.lang.ds_colon}</dt>
  48. <dd>
  49. <textarea id="consult_content" name="consult_content" class="textarea w400" ></textarea>
  50. <br>
  51. <span class="error"></span>
  52. </dd>
  53. </dl>
  54. <div class="bottom">
  55. <input type="submit" class="submit" value="{$Think.lang.confirm_submission}" />
  56. <a href="javascript:history.go(-1);" class="dsm-btn ml10">{$Think.lang.cancel_and_return}</a>
  57. </div>
  58. </form>
  59. </div>
  60. </div>
  61. <div class="dsm-flow-item">
  62. <div class="title">{$Think.lang.warm_tips}</div>
  63. <div class="content">
  64. <div class="alert">
  65. <ul>
  66. <li> {$Think.lang.goods_advice1}</li>
  67. <li> {$Think.lang.goods_advice2}</li>
  68. <li> {$Think.lang.goods_advice3}</li>
  69. </ul>
  70. </div>
  71. </div>
  72. </div>
  73. </div>
  74. <script>
  75. $(function () {
  76. $('#type_id').change(function () {
  77. $_index = $(this).children('option:selected').index();
  78. $_introduce = $(this).parent().next();
  79. $_introduce.children().hide();
  80. $_introduce.children(':eq(' + $_index + ')').show();
  81. });
  82. $('#mallconsult_form').validate({
  83. errorPlacement: function (error, element) {
  84. error.appendTo(element.nextAll('span.error'));
  85. },
  86. submitHandler: function (form) {
  87. ds_ajaxpost('mallconsult_form');
  88. },
  89. rules: {
  90. type_id: {
  91. required: true,
  92. min: 1
  93. },
  94. consult_content: {
  95. required: true
  96. }
  97. },
  98. messages: {
  99. type_id: {
  100. required: '<i class="iconfont">&#xe64c;</i>{$Think.lang.please_select_type_consultation}',
  101. min: '<i class="iconfont">&#xe64c;</i>{$Think.lang.please_select_type_consultation}'
  102. },
  103. consult_content: {
  104. required: '<i class="iconfont">&#xe64c;</i>{$Think.lang.please_fill_information}'
  105. }
  106. }
  107. });
  108. });
  109. </script>
  110. {/block}