add.html 2.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748
  1. <form id="add-form" class="form-horizontal form-ajax" role="form" data-toggle="validator" method="POST" action="">
  2. <div class="form-group">
  3. <label for="module" class="control-label col-xs-12 col-sm-2">{:__('Resource title')}:</label>
  4. <div class="col-xs-12 col-sm-8">
  5. <input type="text" class="form-control" id="title" name="row[title]" value="" data-rule="required" />
  6. </div>
  7. </div>
  8. <div class="form-group">
  9. <label for="remark" class="control-label col-xs-12 col-sm-2">{:__('Memo')}:</label>
  10. <div class="col-xs-12 col-sm-8">
  11. <textarea class="form-control" id="remark" name="row[remark]"></textarea>
  12. </div>
  13. </div>
  14. <div class="form-group">
  15. <label for="content" class="control-label col-xs-12 col-sm-2">{:__('Type')}:</label>
  16. <div class="col-xs-12 col-sm-8">
  17. <input type="radio" name="row[type]" value="text" id="type-text" checked />
  18. <label for="type-text">{:__('Text')}</label>
  19. <input type="radio" name="row[type]" value="app" id="type-app" />
  20. <label for="type-app">{:__('App')}</label>
  21. </div>
  22. </div>
  23. <div id="expand">
  24. </div>
  25. <div class="form-group">
  26. <label for="status" class="control-label col-xs-12 col-sm-2">{:__('Status')}:</label>
  27. <div class="col-xs-12 col-sm-8">
  28. {:build_radios('row[status]', ['normal'=>__('Normal'), 'hidden'=>__('Hidden')])}
  29. </div>
  30. </div>
  31. <div class="form-group {:input('get.callback')?'':'hidden layer-footer'}">
  32. <div class="col-xs-2"></div>
  33. <div class="col-xs-12 col-sm-8">
  34. <button type="submit" class="btn btn-success btn-embossed disabled">{:__('OK')}</button>
  35. <button type="reset" class="btn btn-default btn-embossed">{:__('Reset')}</button>
  36. </div>
  37. </div>
  38. <select name="applist" disabled="true" class="hidden">
  39. {foreach $applist as $k => $v}
  40. <option value="{$k}">{$v.name}</option>
  41. {/foreach}
  42. </select>
  43. </form>
  44. <script>
  45. var apps = {:json_encode($applist)};
  46. var datas = {};
  47. </script>