category.js 17 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159
  1. function createTableCategory(tx) {
  2. console.log("add category data");
  3. tx.executeSql('DROP TABLE IF EXISTS category', []);
  4. //科目,课、章、节,status1为正常,0为锁定,process为进度,deleted为会否删除,local_version为本地版本号,remote_version为服务器端版本号
  5. tx.executeSql('create table if not exists category(id INTEGER,code text,name text,status INTEGER,progress float,deleted INTEGER,local_version INTEGER,remote_version INTEGER,have_data INTEGGER)', []);
  6. try {
  7. // 未联网的情况下也是可以看到分类的。so,这个需要insert好多的基础数据
  8. tx.executeSql('INSERT INTO category values(?,?,?,?,?,?,?,?,?)', [0, '0', '托普统考英语', 1, null, null, 1, 1, 2]);
  9. tx.executeSql('INSERT INTO category values(?,?,?,?,?,?,?,?,?)', [1, '0001', '交际英语', 1, 0, 1, 1, 1, 1]);
  10. tx.executeSql('INSERT INTO category values(?,?,?,?,?,?,?,?,?)', [2, '00010001', 'A级基础', 1, 0, 1, 1, 1, 1]);
  11. tx.executeSql('INSERT INTO category values(?,?,?,?,?,?,?,?,?)', [3, '000100010001', '第1节', 1, 0, 1, 1, 1, 1]);
  12. tx.executeSql('INSERT INTO category values(?,?,?,?,?,?,?,?,?)', [4, '000100010002', '第2节', 1, 0, 1, 1, 1, 1]);
  13. tx.executeSql('INSERT INTO category values(?,?,?,?,?,?,?,?,?)', [5, '000100010003', '第3节', 1, 0, 1, 1, 1, 1]);
  14. tx.executeSql('INSERT INTO category values(?,?,?,?,?,?,?,?,?)', [6, '000100010004', '第4节', 1, 0, 1, 1, 1, 1]);
  15. tx.executeSql('INSERT INTO category values(?,?,?,?,?,?,?,?,?)', [7, '000100010005', '第5节', 1, 0, 1, 1, 1, 1]);
  16. tx.executeSql('INSERT INTO category values(?,?,?,?,?,?,?,?,?)', [8, '00010002', 'B级强化', 1, 0, 1, 1, 1, 1]);
  17. tx.executeSql('INSERT INTO category values(?,?,?,?,?,?,?,?,?)', [9, '000100020001', '第1节', 1, 0, 1, 1, 1, 1]);
  18. tx.executeSql('INSERT INTO category values(?,?,?,?,?,?,?,?,?)', [10, '000100020002', '第2节', 1, 0, 1, 1, 1, 1]);
  19. tx.executeSql('INSERT INTO category values(?,?,?,?,?,?,?,?,?)', [11, '000100020003', '第3节', 1, 0, 1, 1, 1, 1]);
  20. tx.executeSql('INSERT INTO category values(?,?,?,?,?,?,?,?,?)', [12, '000100020004', '第4节', 1, 0, 1, 1, 1, 1]);
  21. tx.executeSql('INSERT INTO category values(?,?,?,?,?,?,?,?,?)', [13, '000100020005', '第5节', 1, 0, 1, 1, 1, 1]);
  22. tx.executeSql('INSERT INTO category values(?,?,?,?,?,?,?,?,?)', [14, '00010003', 'C级进阶 ', 1, 0, 1, 1, 1, 1]);
  23. tx.executeSql('INSERT INTO category values(?,?,?,?,?,?,?,?,?)', [15, '000100030001', '第1节', 1, 0, 1, 1, 1, 1]);
  24. tx.executeSql('INSERT INTO category values(?,?,?,?,?,?,?,?,?)', [16, '000100030002', '第2节', 1, 0, 1, 1, 1, 1]);
  25. tx.executeSql('INSERT INTO category values(?,?,?,?,?,?,?,?,?)', [17, '000100030003', '第3节', 1, 0, 1, 1, 1, 1]);
  26. tx.executeSql('INSERT INTO category values(?,?,?,?,?,?,?,?,?)', [18, '000100030004', '第4节', 1, 0, 1, 1, 1, 1]);
  27. tx.executeSql('INSERT INTO category values(?,?,?,?,?,?,?,?,?)', [19, '000100030005', '第5节', 1, 0, 1, 1, 1, 1]);
  28. tx.executeSql('INSERT INTO category values(?,?,?,?,?,?,?,?,?)', [20, '0002', '阅读理解', 1, 0, 1, 1, 1, 1]);
  29. tx.executeSql('INSERT INTO category values(?,?,?,?,?,?,?,?,?)', [21, '00020001', '判断对错', 1, 0, 1, 1, 1, 1]);
  30. tx.executeSql('INSERT INTO category values(?,?,?,?,?,?,?,?,?)', [22, '000200010001', '第1节', 1, 0, 1, 1, 1, 1]);
  31. tx.executeSql('INSERT INTO category values(?,?,?,?,?,?,?,?,?)', [23, '000200010002', '第2节', 1, 0, 1, 1, 1, 1]);
  32. tx.executeSql('INSERT INTO category values(?,?,?,?,?,?,?,?,?)', [24, '000200010003', '第3节', 1, 0, 1, 1, 1, 1]);
  33. tx.executeSql('INSERT INTO category values(?,?,?,?,?,?,?,?,?)', [25, '000200010004', '第4节', 1, 0, 1, 1, 1, 1]);
  34. tx.executeSql('INSERT INTO category values(?,?,?,?,?,?,?,?,?)', [26, '000200010005', '第5节', 1, 0, 1, 1, 1, 1]);
  35. tx.executeSql('INSERT INTO category values(?,?,?,?,?,?,?,?,?)', [27, '000200010006', '第6节', 1, 0, 1, 1, 1, 1]);
  36. tx.executeSql('INSERT INTO category values(?,?,?,?,?,?,?,?,?)', [28, '000200010007', '第7节', 1, 0, 1, 1, 1, 1]);
  37. tx.executeSql('INSERT INTO category values(?,?,?,?,?,?,?,?,?)', [29, '000200010008', '第8节', 1, 0, 1, 1, 1, 1]);
  38. tx.executeSql('INSERT INTO category values(?,?,?,?,?,?,?,?,?)', [30, '000200010009', '第9节', 1, 0, 1, 1, 1, 1]);
  39. tx.executeSql('INSERT INTO category values(?,?,?,?,?,?,?,?,?)', [31, '000200010010', '第10节', 1, 0, 1, 1, 1, 1]);
  40. tx.executeSql('INSERT INTO category values(?,?,?,?,?,?,?,?,?)', [32, '000200010011', '第11节', 1, 0, 1, 1, 1, 1]);
  41. tx.executeSql('INSERT INTO category values(?,?,?,?,?,?,?,?,?)', [33, '000200010012', '第12节', 1, 0, 1, 1, 1, 1]);
  42. tx.executeSql('INSERT INTO category values(?,?,?,?,?,?,?,?,?)', [34, '000200010013', '第13节', 1, 0, 1, 1, 1, 1]);
  43. tx.executeSql('INSERT INTO category values(?,?,?,?,?,?,?,?,?)', [35, '000200010014', '第14节', 1, 0, 1, 1, 1, 1]);
  44. tx.executeSql('INSERT INTO category values(?,?,?,?,?,?,?,?,?)', [36, '000200010015', '第15节', 1, 0, 1, 1, 1, 1]);
  45. tx.executeSql('INSERT INTO category values(?,?,?,?,?,?,?,?,?)', [37, '000200010016', '第16节', 1, 0, 1, 1, 1, 1]);
  46. tx.executeSql('INSERT INTO category values(?,?,?,?,?,?,?,?,?)', [38, '000200010017', '第17节', 1, 0, 1, 1, 1, 1]);
  47. tx.executeSql('INSERT INTO category values(?,?,?,?,?,?,?,?,?)', [39, '000200010018', '第18节', 1, 0, 1, 1, 1, 1]);
  48. tx.executeSql('INSERT INTO category values(?,?,?,?,?,?,?,?,?)', [40, '000200010018', '第19节', 1, 0, 1, 1, 1, 1]);
  49. tx.executeSql('INSERT INTO category values(?,?,?,?,?,?,?,?,?)', [41, '00020002', '阅读选择', 1, 0, 1, 1, 1, 1]);
  50. tx.executeSql('INSERT INTO category values(?,?,?,?,?,?,?,?,?)', [42, '000200020001', '第1节', 1, 0, 1, 1, 1, 1]);
  51. tx.executeSql('INSERT INTO category values(?,?,?,?,?,?,?,?,?)', [43, '000200020002', '第2节', 1, 0, 1, 1, 1, 1]);
  52. tx.executeSql('INSERT INTO category values(?,?,?,?,?,?,?,?,?)', [44, '000200020003', '第3节', 1, 0, 1, 1, 1, 1]);
  53. tx.executeSql('INSERT INTO category values(?,?,?,?,?,?,?,?,?)', [45, '000200020004', '第4节', 1, 0, 1, 1, 1, 1]);
  54. tx.executeSql('INSERT INTO category values(?,?,?,?,?,?,?,?,?)', [46, '000200020005', '第5节', 1, 0, 1, 1, 1, 1]);
  55. tx.executeSql('INSERT INTO category values(?,?,?,?,?,?,?,?,?)', [47, '000200020006', '第6节', 1, 0, 1, 1, 1, 1]);
  56. tx.executeSql('INSERT INTO category values(?,?,?,?,?,?,?,?,?)', [48, '000200020007', '第7节', 1, 0, 1, 1, 1, 1]);
  57. tx.executeSql('INSERT INTO category values(?,?,?,?,?,?,?,?,?)', [49, '000200020008', '第8节', 1, 0, 1, 1, 1, 1]);
  58. tx.executeSql('INSERT INTO category values(?,?,?,?,?,?,?,?,?)', [50, '000200020009', '第9节', 1, 0, 1, 1, 1, 1]);
  59. tx.executeSql('INSERT INTO category values(?,?,?,?,?,?,?,?,?)', [51, '000200020010', '第10节', 1, 0, 1, 1, 1, 1]);
  60. tx.executeSql('INSERT INTO category values(?,?,?,?,?,?,?,?,?)', [52, '000200020011', '第11节', 1, 0, 1, 1, 1, 1]);
  61. tx.executeSql('INSERT INTO category values(?,?,?,?,?,?,?,?,?)', [53, '000200020012', '第12节', 1, 0, 1, 1, 1, 1]);
  62. tx.executeSql('INSERT INTO category values(?,?,?,?,?,?,?,?,?)', [54, '000200020013', '第13节', 1, 0, 1, 1, 1, 1]);
  63. tx.executeSql('INSERT INTO category values(?,?,?,?,?,?,?,?,?)', [55, '000200020014', '第14节', 1, 0, 1, 1, 1, 1]);
  64. tx.executeSql('INSERT INTO category values(?,?,?,?,?,?,?,?,?)', [56, '000200020015', '第15节', 1, 0, 1, 1, 1, 1]);
  65. tx.executeSql('INSERT INTO category values(?,?,?,?,?,?,?,?,?)', [57, '000200020016', '第16节', 1, 0, 1, 1, 1, 1]);
  66. tx.executeSql('INSERT INTO category values(?,?,?,?,?,?,?,?,?)', [58, '000200020017', '第17节', 1, 0, 1, 1, 1, 1]);
  67. tx.executeSql('INSERT INTO category values(?,?,?,?,?,?,?,?,?)', [59, '000200020018', '第18节', 1, 0, 1, 1, 1, 1]);
  68. tx.executeSql('INSERT INTO category values(?,?,?,?,?,?,?,?,?)', [60, '000200020019', '第19节', 1, 0, 1, 1, 1, 1]);
  69. tx.executeSql('INSERT INTO category values(?,?,?,?,?,?,?,?,?)', [61, '000200020020', '第20节', 1, 0, 1, 1, 1, 1]);
  70. tx.executeSql('INSERT INTO category values(?,?,?,?,?,?,?,?,?)', [62, '000200020021', '第21节', 1, 0, 1, 1, 1, 1]);
  71. tx.executeSql('INSERT INTO category values(?,?,?,?,?,?,?,?,?)', [63, '0003', '词汇与结构', 1, 0, 1, 1, 1, 1]);
  72. tx.executeSql('INSERT INTO category values(?,?,?,?,?,?,?,?,?)', [64, '00030001', '基础部分', 1, 0, 1, 1, 1, 1]);
  73. tx.executeSql('INSERT INTO category values(?,?,?,?,?,?,?,?,?)', [65, '000300010001', '第1节', 1, 0, 1, 1, 1, 1]);
  74. tx.executeSql('INSERT INTO category values(?,?,?,?,?,?,?,?,?)', [66, '000300010002', '第2节', 1, 0, 1, 1, 1, 1]);
  75. tx.executeSql('INSERT INTO category values(?,?,?,?,?,?,?,?,?)', [67, '000300010003', '第3节', 1, 0, 1, 1, 1, 1]);
  76. tx.executeSql('INSERT INTO category values(?,?,?,?,?,?,?,?,?)', [68, '000300010004', '第4节', 1, 0, 1, 1, 1, 1]);
  77. tx.executeSql('INSERT INTO category values(?,?,?,?,?,?,?,?,?)', [69, '000300010005', '第5节', 1, 0, 1, 1, 1, 1]);
  78. tx.executeSql('INSERT INTO category values(?,?,?,?,?,?,?,?,?)', [70, '00030002', '重点部分', 1, 0, 1, 1, 1, 1]);
  79. tx.executeSql('INSERT INTO category values(?,?,?,?,?,?,?,?,?)', [71, '000300020001', '第1节', 1, 0, 1, 1, 1, 1]);
  80. tx.executeSql('INSERT INTO category values(?,?,?,?,?,?,?,?,?)', [72, '000300020002', '第2节', 1, 0, 1, 1, 1, 1]);
  81. tx.executeSql('INSERT INTO category values(?,?,?,?,?,?,?,?,?)', [73, '000300020003', '第3节', 1, 0, 1, 1, 1, 1]);
  82. tx.executeSql('INSERT INTO category values(?,?,?,?,?,?,?,?,?)', [74, '000300020004', '第4节', 1, 0, 1, 1, 1, 1]);
  83. tx.executeSql('INSERT INTO category values(?,?,?,?,?,?,?,?,?)', [75, '000300020005', '第5节', 1, 0, 1, 1, 1, 1]);
  84. tx.executeSql('INSERT INTO category values(?,?,?,?,?,?,?,?,?)', [77, '0004', '完形填空', 1, 0, 1, 1, 1, 1]);
  85. tx.executeSql('INSERT INTO category values(?,?,?,?,?,?,?,?,?)', [78, '00040001', '基础', 1, 0, 1, 1, 1, 1]);
  86. tx.executeSql('INSERT INTO category values(?,?,?,?,?,?,?,?,?)', [79, '000400010001', '第1节', 1, 0, 1, 1, 1, 1]);
  87. tx.executeSql('INSERT INTO category values(?,?,?,?,?,?,?,?,?)', [80, '000400010002', '第2节', 1, 0, 1, 1, 1, 1]);
  88. tx.executeSql('INSERT INTO category values(?,?,?,?,?,?,?,?,?)', [81, '000400010003', '第3节', 1, 0, 1, 1, 1, 1]);
  89. tx.executeSql('INSERT INTO category values(?,?,?,?,?,?,?,?,?)', [82, '000400010004', '第4节', 1, 0, 1, 1, 1, 1]);
  90. tx.executeSql('INSERT INTO category values(?,?,?,?,?,?,?,?,?)', [83, '000400010005', '第5节', 1, 0, 1, 1, 1, 1]);
  91. tx.executeSql('INSERT INTO category values(?,?,?,?,?,?,?,?,?)', [84, '000400010006', '第6节', 1, 0, 1, 1, 1, 1]);
  92. tx.executeSql('INSERT INTO category values(?,?,?,?,?,?,?,?,?)', [85, '000400010007', '第7节', 1, 0, 1, 1, 1, 1]);
  93. tx.executeSql('INSERT INTO category values(?,?,?,?,?,?,?,?,?)', [86, '000400010008', '第8节', 1, 0, 1, 1, 1, 1]);
  94. tx.executeSql('INSERT INTO category values(?,?,?,?,?,?,?,?,?)', [87, '000400010009', '第9节', 1, 0, 1, 1, 1, 1]);
  95. tx.executeSql('INSERT INTO category values(?,?,?,?,?,?,?,?,?)', [88, '000400010010', '第10节', 1, 0, 1, 1, 1, 1]);
  96. tx.executeSql('INSERT INTO category values(?,?,?,?,?,?,?,?,?)', [89, '000400010011', '第11节', 1, 0, 1, 1, 1, 1]);
  97. tx.executeSql('INSERT INTO category values(?,?,?,?,?,?,?,?,?)', [90, '000400010012', '第12节', 1, 0, 1, 1, 1, 1]);
  98. tx.executeSql('INSERT INTO category values(?,?,?,?,?,?,?,?,?)', [91, '000400010013', '第13节', 1, 0, 1, 1, 1, 1]);
  99. tx.executeSql('INSERT INTO category values(?,?,?,?,?,?,?,?,?)', [92, '000400010014', '第14节', 1, 0, 1, 1, 1, 1]);
  100. tx.executeSql('INSERT INTO category values(?,?,?,?,?,?,?,?,?)', [93, '000400010015', '第15节', 1, 0, 1, 1, 1, 1]);
  101. tx.executeSql('INSERT INTO category values(?,?,?,?,?,?,?,?,?)', [94, '000400010016', '第16节', 1, 0, 1, 1, 1, 1]);
  102. tx.executeSql('INSERT INTO category values(?,?,?,?,?,?,?,?,?)', [95, '000400010017', '第17节', 1, 0, 1, 1, 1, 1]);
  103. tx.executeSql('INSERT INTO category values(?,?,?,?,?,?,?,?,?)', [96, '000400010018', '第18节', 1, 0, 1, 1, 1, 1]);
  104. tx.executeSql('INSERT INTO category values(?,?,?,?,?,?,?,?,?)', [97, '000400010019', '第19节', 1, 0, 1, 1, 1, 1]);
  105. tx.executeSql('INSERT INTO category values(?,?,?,?,?,?,?,?,?)', [98, '000400010020', '第20节', 1, 0, 1, 1, 1, 1]);
  106. tx.executeSql('INSERT INTO category values(?,?,?,?,?,?,?,?,?)', [99, '00040002', '强化', 1, 0, 1, 1, 1, 1]);
  107. tx.executeSql('INSERT INTO category values(?,?,?,?,?,?,?,?,?)', [100, '000400020001', '第1节', 1, 0, 1, 1, 1, 1]);
  108. tx.executeSql('INSERT INTO category values(?,?,?,?,?,?,?,?,?)', [101, '000400020002', '第2节', 1, 0, 1, 1, 1, 1]);
  109. tx.executeSql('INSERT INTO category values(?,?,?,?,?,?,?,?,?)', [102, '000400020003', '第3节', 1, 0, 1, 1, 1, 1]);
  110. tx.executeSql('INSERT INTO category values(?,?,?,?,?,?,?,?,?)', [103, '000400020004', '第4节', 1, 0, 1, 1, 1, 1]);
  111. tx.executeSql('INSERT INTO category values(?,?,?,?,?,?,?,?,?)', [104, '000400020005', '第5节', 1, 0, 1, 1, 1, 1]);
  112. tx.executeSql('INSERT INTO category values(?,?,?,?,?,?,?,?,?)', [105, '000400020006', '第6节', 1, 0, 1, 1, 1, 1]);
  113. tx.executeSql('INSERT INTO category values(?,?,?,?,?,?,?,?,?)', [106, '000400020007', '第7节', 1, 0, 1, 1, 1, 1]);
  114. tx.executeSql('INSERT INTO category values(?,?,?,?,?,?,?,?,?)', [107, '000400020008', '第8节', 1, 0, 1, 1, 1, 1]);
  115. tx.executeSql('INSERT INTO category values(?,?,?,?,?,?,?,?,?)', [108, '000400020009', '第9节', 1, 0, 1, 1, 1, 1]);
  116. tx.executeSql('INSERT INTO category values(?,?,?,?,?,?,?,?,?)', [109, '000400020010', '第10节', 1, 0, 1, 1, 1, 1]);
  117. tx.executeSql('INSERT INTO category values(?,?,?,?,?,?,?,?,?)', [110, '000400020011', '第11节', 1, 0, 1, 1, 1, 1]);
  118. tx.executeSql('INSERT INTO category values(?,?,?,?,?,?,?,?,?)', [111, '000400020012', '第12节', 1, 0, 1, 1, 1, 1]);
  119. tx.executeSql('INSERT INTO category values(?,?,?,?,?,?,?,?,?)', [112, '000400020013', '第13节', 1, 0, 1, 1, 1, 1]);
  120. tx.executeSql('INSERT INTO category values(?,?,?,?,?,?,?,?,?)', [113, '000400020014', '第14节', 1, 0, 1, 1, 1, 1]);
  121. tx.executeSql('INSERT INTO category values(?,?,?,?,?,?,?,?,?)', [114, '000400020015', '第15节', 1, 0, 1, 1, 1, 1]);
  122. tx.executeSql('INSERT INTO category values(?,?,?,?,?,?,?,?,?)', [116, '0005', '英译汉复习资料', 1, 0, 1, 1, 1, 1]);
  123. tx.executeSql('INSERT INTO category values(?,?,?,?,?,?,?,?,?)', [117, '00050001', '重点复习部分', 1, 0, 1, 1, 1, 1]);
  124. tx.executeSql('INSERT INTO category values(?,?,?,?,?,?,?,?,?)', [118, '000500010001', '第1节', 1, 0, 1, 1, 1, 1]);
  125. tx.executeSql('INSERT INTO category values(?,?,?,?,?,?,?,?,?)', [119, '000500010002', '第2节', 1, 0, 1, 1, 1, 1]);
  126. tx.executeSql('INSERT INTO category values(?,?,?,?,?,?,?,?,?)', [120, '000500010003', '第3节', 1, 0, 1, 1, 1, 1]);
  127. tx.executeSql('INSERT INTO category values(?,?,?,?,?,?,?,?,?)', [121, '000500010004', '第4节', 1, 0, 1, 1, 1, 1]);
  128. tx.executeSql('INSERT INTO category values(?,?,?,?,?,?,?,?,?)', [122, '000500010005', '第5节', 1, 0, 1, 1, 1, 1]);
  129. tx.executeSql('INSERT INTO category values(?,?,?,?,?,?,?,?,?)', [123, '00050002', '尽量掌握部分', 1, 0, 1, 1, 1, 1]);
  130. tx.executeSql('INSERT INTO category values(?,?,?,?,?,?,?,?,?)', [124, '000500020001', '第1节', 1, 0, 1, 1, 1, 1]);
  131. tx.executeSql('INSERT INTO category values(?,?,?,?,?,?,?,?,?)', [125, '000500020002', '第2节', 1, 0, 1, 1, 1, 1]);
  132. tx.executeSql('INSERT INTO category values(?,?,?,?,?,?,?,?,?)', [126, '000500020003', '第3节', 1, 0, 1, 1, 1, 1]);
  133. tx.executeSql('INSERT INTO category values(?,?,?,?,?,?,?,?,?)', [127, '000500020004', '第4节', 1, 0, 1, 1, 1, 1]);
  134. tx.executeSql('INSERT INTO category values(?,?,?,?,?,?,?,?,?)', [128, '000500020005', '第5节', 1, 0, 1, 1, 1, 1]);
  135. tx.executeSql('INSERT INTO category values(?,?,?,?,?,?,?,?,?)', [129, '0006', '作文复习资料', 1, 0, 1, 1, 1, 1]);
  136. tx.executeSql('INSERT INTO category values(?,?,?,?,?,?,?,?,?)', [130, '00060001', '基础背诵资料', 1, 0, 1, 1, 1, 1]);
  137. tx.executeSql('INSERT INTO category values(?,?,?,?,?,?,?,?,?)', [131, '000600010001', '第1类:我的某某人', 1, 0, 1, 1, 1, 1]);
  138. tx.executeSql('INSERT INTO category values(?,?,?,?,?,?,?,?,?)', [132, '000600010002', '第2类:计划类', 1, 0, 1, 1, 1, 1]);
  139. tx.executeSql('INSERT INTO category values(?,?,?,?,?,?,?,?,?)', [133, '000600010003', '第3类:英语学习类', 1, 0, 1, 1, 1, 1]);
  140. tx.executeSql('INSERT INTO category values(?,?,?,?,?,?,?,?,?)', [134, '000600010004', '第4类:优点和缺点', 1, 0, 1, 1, 1, 1]);
  141. tx.executeSql('INSERT INTO category values(?,?,?,?,?,?,?,?,?)', [135, '000600010005', '第5类:运动类', 1, 0, 1, 1, 1, 1]);
  142. tx.executeSql('INSERT INTO category values(?,?,?,?,?,?,?,?,?)', [136, '000600010006', '第6类:远程教育学习类', 1, 0, 1, 1, 1, 1]);
  143. tx.executeSql('INSERT INTO category values(?,?,?,?,?,?,?,?,?)', [137, '000600010007', '第7类:书信类', 1, 0, 1, 1, 1, 1]);
  144. tx.executeSql('INSERT INTO category values(?,?,?,?,?,?,?,?,?)', [138, '000600010008', '第8类:最喜爱的某某', 1, 0, 1, 1, 1, 1]);
  145. tx.executeSql('INSERT INTO category values(?,?,?,?,?,?,?,?,?)', [139, '000600010009', '第9类:见解看法类', 1, 0, 1, 1, 1, 1]);
  146. tx.executeSql('INSERT INTO category values(?,?,?,?,?,?,?,?,?)', [140, '000600010010', '第10类:议论文', 1, 0, 1, 1, 1, 1]);
  147. tx.executeSql('INSERT INTO category values(?,?,?,?,?,?,?,?,?)', [141, '000600010011', '第11类:感谢信', 1, 0, 1, 1, 1, 1]);
  148. tx.executeSql('INSERT INTO category values(?,?,?,?,?,?,?,?,?)', [142, '00060002', '万能套用模板', 1, 0, 1, 1, 1, 1]);
  149. tx.executeSql('INSERT INTO category values(?,?,?,?,?,?,?,?,?)', [143, '000600020001', '适用所有作文类型', 1, 0, 1, 1, 1, 1]);
  150. } catch (e) {
  151. console.log('error---------------------');
  152. console.log(e);
  153. }
  154. tx.executeSql('select * from category', [], function(tx, rs) {
  155. console.log('category:' + rs.rows.length)
  156. }, onError);
  157. }