人人商城

recharge.html 5.7KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130
  1. <form action="" method="post" class="form-horizontal form-validate" enctype="multipart/form-data">
  2. <input type="hidden" name="c" value="site" />
  3. <input type="hidden" name="a" value="entry" />
  4. <input type="hidden" name="m" value="ewei_shopv2" />
  5. <input type="hidden" name="do" value="web" />
  6. <input type="hidden" name="r" value="finance.recharge" />
  7. <input type='hidden' name='type' value="{$type}" />
  8. <input type='hidden' name='id' value="{$id}" />
  9. <div class="modal-dialog">
  10. <div class="modal-content">
  11. <div class="modal-header">
  12. <button data-dismiss="modal" class="close" type="button">×</button>
  13. <h4 class="modal-title">会员充值</h4>
  14. </div>
  15. <div class="modal-body">
  16. <div class="form-group">
  17. <label class="col-sm-2 control-label">粉丝</label>
  18. <div class="col-sm-9 col-xs-12">
  19. <div class="form-control-static">
  20. <img src='{$profile['avatar']}' style='width:20px;height:20px;padding:1px;border:1px solid #ccc' />
  21. {$profile['nickname']}
  22. </div>
  23. </div>
  24. </div>
  25. <div class="form-group">
  26. <label class="col-sm-2 control-label">会员信息</label>
  27. <div class="col-sm-9 col-xs-12">
  28. <div class="form-control-static">ID: {$profile['id']} / 姓名: {$profile['realname']} / 手机号: {$profile['mobile']}</div>
  29. </div>
  30. </div>
  31. <div class="tabs-container">
  32. <div class="tabs">
  33. <ul class="nav nav-tabs">
  34. {ifp 'finance.recharge.credit1'}
  35. <li {if $type=='credit1'}class="active"{/if}><a data-toggle="tab" href="#tab-1" data-rechargetype="credit1" aria-expanded="true"> 充值积分</a></li>
  36. {/if}
  37. {ifp 'finance.recharge.credit2'}
  38. <li {if $type=='credit2'}class="active"{/if}><a data-toggle="tab" href="#tab-2" data-rechargetype="credit2" aria-expanded="false"> 充值余额</a></li>
  39. {/if}
  40. </ul>
  41. <div class="tab-content ">
  42. <div id="tab-1" class="tab-pane {if $type=='credit1'}active{/if}">
  43. <div class="form-group"></div>
  44. <div class="form-group">
  45. <label class="col-sm-2 control-label">当前积分</label>
  46. <div class="col-sm-9 col-xs-12">
  47. <div class="form-control-static">{$profile['credit1']}</div>
  48. </div>
  49. </div>
  50. </div>
  51. <div id="tab-2" class="tab-pane {if $type=='credit2'}active{/if}">
  52. <div class="form-group"></div>
  53. <div class="form-group">
  54. <label class="col-sm-2 control-label">当前余额</label>
  55. <div class="col-sm-9 col-xs-12">
  56. <div class="form-control-static">{$profile['credit2']}</div>
  57. </div>
  58. </div>
  59. </div>
  60. </div>
  61. </div>
  62. </div>
  63. <div class="form-group">
  64. <label class="col-sm-2 control-label">变化</label>
  65. <div class="col-sm-9 col-xs-12">
  66. <label class='radio-inline'>
  67. <input type='radio' name='changetype' value='0' checked /> 增加
  68. </label>
  69. <label class='radio-inline'>
  70. <input type='radio' name='changetype' value='1' /> 减少
  71. </label>
  72. <label class='radio-inline'>
  73. <input type='radio' name='changetype' value='2' /> 最终<span class='name'>{if $type=='credit1'}积分{else}余额{/if}</span>
  74. </label>
  75. </div>
  76. </div>
  77. <div class="form-group">
  78. <label class="col-sm-2 control-label mustl">充值数目</label>
  79. <div class="col-sm-9 col-xs-12">
  80. <input type="text" name="num" class="form-control" value="" data-rule-number='true' data-rule-required='true' data-rule-min='0.01' />
  81. </div>
  82. </div>
  83. <div class="form-group">
  84. <label class="col-sm-2 control-label">备注</label>
  85. <div class="col-sm-9 col-xs-12">
  86. <textarea name="remark" class="form-control richtext" cols="70"></textarea>
  87. </div>
  88. </div>
  89. </div> <div class="modal-footer">
  90. <button class="btn btn-primary" type="submit">确认充值</button>
  91. <button data-dismiss="modal" class="btn btn-default" type="button">取消</button>
  92. </div>
  93. </div>
  94. </div>
  95. </form>
  96. <script language='javascript'>
  97. $(function(){
  98. $('[data-toggle="tab"]').click(function(){
  99. var type =$(this).data('rechargetype');
  100. if(type=='credit1') {
  101. $('.name').html('积分');
  102. }else{
  103. $('.name').html('余额');
  104. }
  105. $(':hidden[name=type]').val( type) ;
  106. });
  107. })
  108. </script>