edit.html 5.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117
  1. {include file="public/header" /}
  2. <div class="page">
  3. <form method="post" id='form1'>
  4. <table class="ds-default-table">
  5. <tbody>
  6. <tr class="noborder">
  7. <td class="required w120">{$Think.lang.refund_order_refund}</td>
  8. <td>{:ds_price_format($refund['refund_amount'])}</td>
  9. </tr>
  10. <tr class="noborder">
  11. <td class="required w120">{$Think.lang.ds_goods_name}</td>
  12. <td>{$refund.goods_name}</td>
  13. <td class="vatop tips"></td>
  14. </tr>
  15. <tr class="noborder">
  16. <td class="required w120">{$Think.lang.refund_buyer_message}</td>
  17. <td>{$refund.reason_info}</td>
  18. <td class="vatop tips"></td>
  19. </tr>
  20. <tr class="noborder">
  21. <td class="required w120">{$Think.lang.refund_buyer_message}</td>
  22. <td class="vatop rowform">{$refund.buyer_message}</td>
  23. <td class="vatop tips"></td>
  24. </tr>
  25. <tr class="noborder">
  26. <td class="required w120">{$Think.lang.refund_image_upload}</td>
  27. <td class="vatop rowform">
  28. {notempty name="pic_list"}
  29. {foreach name="pic_list" item="val" key="key" }
  30. {notempty name="val"}
  31. <a href="{:ds_get_pic(ATTACH_PATH.'/refund',$val)}" data-lightbox="lightbox-image">
  32. <img width="64" height="64" class="show_image" src="{:ds_get_pic(ATTACH_PATH.'/refund',$val)}">
  33. </a>
  34. {/notempty}
  35. {/foreach}
  36. {/notempty}
  37. </td>
  38. <td class="vatop tips"></td>
  39. </tr>
  40. <tr class="noborder">
  41. <td class="required w120">{$Think.lang.refund_seller_message}</td>
  42. <td class="vatop rowform">{$refund.seller_message}</td>
  43. <td class="vatop tips"></td>
  44. </tr>
  45. <tr class="noborder">
  46. <td class="required"><label class="validation">{$Think.lang.refund_state}{$Think.lang.ds_colon}</label>
  47. </td>
  48. <td class="vatop rowform onoff">
  49. <label for="state1" class="cb-enable" title="{$Think.lang.ds_yes}"><span>{$Think.lang.ds_yes}</span></label>
  50. <label for="state0" class="cb-disable" title="{$Think.lang.ds_no}"><span>{$Think.lang.ds_no}</span></label>
  51. <input id="state1" name="refund_state" value="3" type="radio">
  52. <input id="state0" name="refund_state" value="4" type="radio">
  53. </td>
  54. <td class="vatop tips"></td>
  55. </tr>
  56. <tr class="noborder" dstype="state1" style="display: none">
  57. <td class="required w120">{$Think.lang.trade_no}</td>
  58. <td class="vatop rowform"><input type="text" class="txt2" name="trade_no" id="trade_no" value="{$trade_no}"></td>
  59. <td class="vatop tips">{$Think.lang.trade_no_tip}</td>
  60. </tr>
  61. <tr class="noborder">
  62. <td class="required w120">{$Think.lang.refund_message}</td>
  63. <td class="vatop rowform"><textarea id="admin_message" name="admin_message" class="tarea"></textarea></td>
  64. <td class="vatop tips"></td>
  65. </tr>
  66. </tbody>
  67. <tfoot>
  68. <tr class="tfoot">
  69. <td></td>
  70. <td colspan="15">{:token_field()}<input class="btn" onclick="submitForm()" type='button' value="{$Think.lang.ds_submit}" /></td>
  71. </tr>
  72. </tfoot>
  73. </table>
  74. </form>
  75. </div>
  76. <link rel="stylesheet" href="{$Think.PLUGINS_SITE_ROOT}/js/jquery.lightbox/css/lightbox.min.css">
  77. <script src="{$Think.PLUGINS_SITE_ROOT}/js/jquery.lightbox/js/lightbox.min.js"></script>
  78. <script type="text/javascript">
  79. var can_submit=true
  80. function submitForm(){
  81. if(!can_submit){
  82. return
  83. }
  84. can_submit=false
  85. $('#form1').submit()
  86. }
  87. $(function() {
  88. $('input[name="refund_state"]').change(function(){
  89. if($(this).val()==3){
  90. $('*[dstype="state1"]').show()
  91. }else{
  92. $('*[dstype="state1"]').hide()
  93. }
  94. })
  95. $('#post_form').validate({
  96. errorPlacement: function(error, element) {
  97. error.appendTo(element.parent().parent().prev().find('td:first'));
  98. },
  99. rules: {
  100. admin_message: {
  101. required: true
  102. }
  103. },
  104. messages: {
  105. admin_message: {
  106. required : '{$Think.lang.refund_message_null}'
  107. }
  108. }
  109. });
  110. });
  111. </script>