edit.html 7.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121
  1. <form id="edit-form" class="form-horizontal" role="form" data-toggle="validator" method="POST" action="">
  2. <div class="form-group">
  3. <label class="control-label col-xs-12 col-sm-2">{:__('Is_home')}:</label>
  4. <div class="col-xs-12 col-sm-8">
  5. <select id="c-is_home" data-rule="required" class="form-control selectpicker" name="row[is_home]">
  6. {foreach name="isHomeList" item="vo"}
  7. <option value="{$key}" {in name="key" value="$row.is_home"}selected{/in}>{$vo}</option>
  8. {/foreach}
  9. </select>
  10. </div>
  11. </div>
  12. <div class="form-group">
  13. <label class="control-label col-xs-12 col-sm-2">{:__('Name')}:</label>
  14. <div class="col-xs-12 col-sm-8">
  15. <input id="c-name" data-rule="required" class="form-control" name="row[name]" type="text" value="{$row.name|htmlentities}">
  16. </div>
  17. </div>
  18. <div class="form-group">
  19. <label class="control-label col-xs-12 col-sm-2">{:__('Image')}:</label>
  20. <div class="col-xs-12 col-sm-8">
  21. <div class="input-group">
  22. <input id="c-image" data-rule="required" class="form-control" size="50" name="row[image]" type="text" value="{$row.image|htmlentities}">
  23. <div class="input-group-addon no-border no-padding">
  24. <span><button type="button" id="faupload-image" class="btn btn-danger faupload" data-input-id="c-image" data-mimetype="image/gif,image/jpeg,image/png,image/jpg,image/bmp,image/webp" data-multiple="false" data-preview-id="p-image"><i class="fa fa-upload"></i> {:__('Upload')}</button></span>
  25. <span><button type="button" id="fachoose-image" class="btn btn-primary fachoose" data-input-id="c-image" data-mimetype="image/*" data-multiple="false"><i class="fa fa-list"></i> {:__('Choose')}</button></span>
  26. </div>
  27. <span class="msg-box n-right" for="c-image"></span>
  28. </div>
  29. <ul class="row list-inline faupload-preview" id="p-image"></ul>
  30. </div>
  31. </div>
  32. <div class="form-group">
  33. <label class="control-label col-xs-12 col-sm-2">{:__('Images')}:</label>
  34. <div class="col-xs-12 col-sm-8">
  35. <div class="input-group">
  36. <input id="c-images" data-rule="required" class="form-control" size="50" name="row[images]" type="textarea" value="{$row.images|htmlentities}">
  37. <div class="input-group-addon no-border no-padding">
  38. <span><button type="button" id="faupload-images" class="btn btn-danger faupload" data-input-id="c-images" data-mimetype="image/gif,image/jpeg,image/png,image/jpg,image/bmp,image/webp" data-multiple="true" data-preview-id="p-images"><i class="fa fa-upload"></i> {:__('Upload')}</button></span>
  39. <span><button type="button" id="fachoose-images" class="btn btn-primary fachoose" data-input-id="c-images" data-mimetype="image/*" data-multiple="true"><i class="fa fa-list"></i> {:__('Choose')}</button></span>
  40. </div>
  41. <span class="msg-box n-right" for="c-images"></span>
  42. </div>
  43. <ul class="row list-inline faupload-preview" id="p-images"></ul>
  44. </div>
  45. </div>
  46. <div class="form-group">
  47. <label class="control-label col-xs-12 col-sm-2">{:__('Price')}:</label>
  48. <div class="col-xs-12 col-sm-8">
  49. <input id="c-price" data-rule="required" class="form-control" step="0.01" name="row[price]" type="number" value="{$row.price|htmlentities}">
  50. </div>
  51. </div>
  52. <div class="form-group">
  53. <label class="control-label col-xs-12 col-sm-2">{:__('Original_price')}:</label>
  54. <div class="col-xs-12 col-sm-8">
  55. <input id="c-original_price" data-rule="required" class="form-control" step="0.01" name="row[original_price]" type="number" value="{$row.original_price|htmlentities}">
  56. </div>
  57. </div>
  58. <div class="form-group">
  59. <label class="control-label col-xs-12 col-sm-2">{:__('Tags')}:</label>
  60. <div class="col-xs-12 col-sm-8">
  61. <input id="c-tags" data-rule="required" class="form-control" data-role="tagsinput" name="row[tags]" type="text" value="{$row.tags|htmlentities}">
  62. </div>
  63. </div>
  64. <div class="form-group">
  65. <label class="control-label col-xs-12 col-sm-2">{:__('Address')}:</label>
  66. <div class="col-xs-12 col-sm-8">
  67. <input id="c-address" data-rule="required" class="form-control" name="row[address]" type="text" value="{$row.address|htmlentities}">
  68. </div>
  69. </div>
  70. <div class="form-group">
  71. <label class="control-label col-xs-12 col-sm-2">{:__('Lat')}:</label>
  72. <div class="col-xs-12 col-sm-8">
  73. <input id="c-lat" data-rule="required" class="form-control" step="0.000001" name="row[lat]" type="number" value="{$row.lat|htmlentities}">
  74. </div>
  75. </div>
  76. <div class="form-group">
  77. <label class="control-label col-xs-12 col-sm-2">{:__('Lng')}:</label>
  78. <div class="col-xs-12 col-sm-8">
  79. <input id="c-lng" data-rule="required" class="form-control" step="0.000001" name="row[lng]" type="number" value="{$row.lng|htmlentities}">
  80. </div>
  81. </div>
  82. <div class="form-group">
  83. <label class="control-label col-xs-12 col-sm-2">{:__('Weigh')}:</label>
  84. <div class="col-xs-12 col-sm-8">
  85. <input id="c-weigh" data-rule="required" class="form-control" name="row[weigh]" type="number" value="{$row.weigh|htmlentities}">
  86. </div>
  87. </div>
  88. <div class="form-group">
  89. <label class="control-label col-xs-12 col-sm-2">{:__('Status')}:</label>
  90. <div class="col-xs-12 col-sm-8">
  91. <div class="radio">
  92. {foreach name="statusList" item="vo"}
  93. <label for="row[status]-{$key}"><input id="row[status]-{$key}" name="row[status]" type="radio" value="{$key}" {in name="key" value="$row.status"}checked{/in} /> {$vo}</label>
  94. {/foreach}
  95. </div>
  96. </div>
  97. </div>
  98. <div class="form-group">
  99. <label class="control-label col-xs-12 col-sm-2">{:__('Create_time')}:</label>
  100. <div class="col-xs-12 col-sm-8">
  101. <input id="c-create_time" data-rule="required" class="form-control datetimepicker" data-date-format="YYYY-MM-DD HH:mm:ss" data-use-current="true" name="row[create_time]" type="text" value="{:$row.create_time?datetime($row.create_time):''}">
  102. </div>
  103. </div>
  104. <div class="form-group">
  105. <label class="control-label col-xs-12 col-sm-2">{:__('Update_time')}:</label>
  106. <div class="col-xs-12 col-sm-8">
  107. <input id="c-update_time" data-rule="required" class="form-control datetimepicker" data-date-format="YYYY-MM-DD HH:mm:ss" data-use-current="true" name="row[update_time]" type="text" value="{:$row.update_time?datetime($row.update_time):''}">
  108. </div>
  109. </div>
  110. <div class="form-group layer-footer">
  111. <label class="control-label col-xs-12 col-sm-2"></label>
  112. <div class="col-xs-12 col-sm-8">
  113. <button type="submit" class="btn btn-primary btn-embossed disabled">{:__('OK')}</button>
  114. </div>
  115. </div>
  116. </form>