1
0

rock_infor_tiku.php 2.8 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111
  1. <?php if(!defined('HOST'))die('not access');?>
  2. <script >
  3. $(document).ready(function(){
  4. var modenum='knowtiku';
  5. var a = $('#view_{rand}').bootstable({
  6. tablename:modenum,celleditor:true,autoLoad:false,modenum:modenum,fanye:true,params:{atype:'guan'},
  7. columns:[{
  8. text:'题名',dataIndex:'title',editor:false,align:'left'
  9. },{
  10. text:'分类',dataIndex:'typename'
  11. },{
  12. text:'类型',dataIndex:'type'
  13. },{
  14. text:'A',dataIndex:'ana'
  15. },{
  16. text:'B',dataIndex:'anb'
  17. },{
  18. text:'C',dataIndex:'anc'
  19. },{
  20. text:'D',dataIndex:'and'
  21. },{
  22. text:'E',dataIndex:'ane'
  23. },{
  24. text:'答案',dataIndex:'answer',editor:true
  25. },{
  26. text:'排序',dataIndex:'sort',sortable:true,editor:true
  27. },{
  28. text:'状态',dataIndex:'status',type:'checkbox',editor:true,sortable:true
  29. },{
  30. text:'',dataIndex:'caozuo'
  31. }],
  32. itemdblclick:function(d){
  33. openxiangs(d.title,modenum, d.id);
  34. }
  35. });
  36. var c = {
  37. del:function(){
  38. a.del();
  39. },
  40. daochu:function(){
  41. a.exceldown();
  42. },
  43. adds:function(){
  44. openinput('知识题库',modenum);
  45. },
  46. search:function(){
  47. var s=get('key_{rand}').value;
  48. a.setparams({key:s},true);
  49. },
  50. daoru:function(){
  51. managelistknowtiku = a;
  52. addtabs({num:'daoruknowtiku',url:'flow,input,daoru,modenum=knowtiku',icons:'plus',name:'导入题库'});
  53. },
  54. mobj:a,
  55. title:'题库分类',
  56. stable:'knowtiku',
  57. optionview:'optionview_{rand}',
  58. optionnum:'knowtikutype',
  59. rand:'{rand}'
  60. };
  61. var c = new optionclass(c);
  62. js.initbtn(c);
  63. });
  64. </script>
  65. <table width="100%">
  66. <tr valign="top">
  67. <td>
  68. <div style="border:1px #cccccc solid;width:220px">
  69. <div id="optionview_{rand}" style="height:400px;overflow:auto;"></div>
  70. </div>
  71. </td>
  72. <td width="10" nowrap><div style="width:10px">&nbsp;</div></td>
  73. <td width="95%">
  74. <div>
  75. <table width="100%"><tr>
  76. <td align="left" nowrap>
  77. <button class="btn btn-primary" click="adds" type="button"><i class="icon-plus"></i> 新增</button>&nbsp;
  78. <button class="btn btn-default" click="allshow" type="button">所有题库</button>&nbsp;
  79. </td>
  80. <td style="padding-left:10px">
  81. <input class="form-control" style="width:200px" id="key_{rand}" placeholder="题名/分类">
  82. </td>
  83. <td style="padding-left:10px">
  84. <button class="btn btn-default" click="search" type="button">搜索</button>
  85. </td>
  86. <td width="90%">
  87. &nbsp;&nbsp;<span id="megss{rand}"></span>
  88. </td>
  89. <td align="right" nowrap>
  90. <button class="btn btn-default" click="daoru" type="button">导入题库</button>&nbsp;
  91. <button class="btn btn-default" click="daochu" type="button">导出</button>
  92. </td>
  93. </tr></table>
  94. </div>
  95. <div class="blank10"></div>
  96. <div id="view_{rand}"></div>
  97. </td>
  98. </tr>
  99. </table>
粤ICP备19079148号