booth_setting.html 2.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263
  1. {include file="public/header" /}
  2. <div class="page">
  3. <form id="add_form" method="post">
  4. <table class="ds-default-table">
  5. <tbody>
  6. <tr class="noborder">
  7. <td class="required w150"><label class="validation" for="promotion_booth_price">{$Think.lang.promotion_booth_price}{$Think.lang.ds_colon}</label></td>
  8. <td class="vatop rowform">
  9. <input type="text" id="promotion_booth_price" name="promotion_booth_price" value="{$setting.promotion_booth_price}" class="txt">
  10. </td>
  11. <td class="vatop tips">{$Think.lang.promotion_booth_price_tips}</td>
  12. </tr>
  13. <tr class="noborder">
  14. <td class="required"><label class="validation" for="promotion_booth_goods_sum">{$Think.lang.promotion_booth_goods_sum}{$Think.lang.ds_colon}</label></td>
  15. <td class="vatop rowform">
  16. <input type="text" id="promotion_booth_goods_sum" name="promotion_booth_goods_sum" value="{$setting.promotion_booth_goods_sum}" class="txt">
  17. </td>
  18. <td class="vatop tips">{$Think.lang.promotion_booth_goods_sum_tips}</td>
  19. </tr>
  20. </tbody>
  21. <tfoot>
  22. <tr class="tfoot">
  23. <td colspan="15"><input class="btn" type="submit" value="{$Think.lang.ds_submit}"/></td>
  24. </tr>
  25. </tfoot>
  26. </table>
  27. </form>
  28. </div>
  29. <script type="text/javascript">
  30. $(document).ready(function(){
  31. //页面输入内容验证
  32. $("#add_form").validate({
  33. errorPlacement: function(error, element){
  34. error.appendTo(element.parent().parent().find('td:last'));
  35. },
  36. rules : {
  37. promotion_booth_price: {
  38. required : true,
  39. digits : true
  40. },
  41. promotion_booth_goods_sum: {
  42. required : true,
  43. digits : true,
  44. min : 1
  45. }
  46. },
  47. messages : {
  48. promotion_booth_price: {
  49. required : '{$Think.lang.ds_required_error}',
  50. digits : '{$Think.lang.ds_digits_error}'
  51. },
  52. promotion_booth_goods_sum: {
  53. required : '{$Think.lang.ds_required_error}',
  54. digits : '{$Think.lang.ds_digits_error}',
  55. min : '{$Think.lang.ds_min_error}1'
  56. }
  57. }
  58. });
  59. });
  60. </script>