|
@@ -0,0 +1,548 @@
|
|
|
+package com.miaxis.test;
|
|
|
+
|
|
|
+import com.alibaba.fastjson.JSONArray;
|
|
|
+import com.alibaba.fastjson.JSONObject;
|
|
|
+import com.miaxis.ZzjsApplication;
|
|
|
+import com.miaxis.common.utils.StringUtils;
|
|
|
+import com.miaxis.feign.service.IKtService;
|
|
|
+import com.miaxis.question.domain.QuestionColumn;
|
|
|
+import com.miaxis.question.domain.QuestionFree;
|
|
|
+import com.miaxis.question.domain.QuestionInfoKtGet;
|
|
|
+import com.miaxis.question.domain.QuestionInfoKtNew;
|
|
|
+import com.miaxis.question.service.IQuestionColumnService;
|
|
|
+import com.miaxis.question.service.IQuestionFreeService;
|
|
|
+import com.miaxis.question.service.IQuestionInfoKtGetService;
|
|
|
+import com.miaxis.question.service.IQuestionInfoKtNewService;
|
|
|
+import org.junit.Test;
|
|
|
+import org.junit.runner.RunWith;
|
|
|
+import org.springframework.beans.factory.annotation.Autowired;
|
|
|
+import org.springframework.boot.test.context.SpringBootTest;
|
|
|
+import org.springframework.test.context.junit4.SpringRunner;
|
|
|
+
|
|
|
+import java.util.ArrayList;
|
|
|
+import java.util.LinkedHashMap;
|
|
|
+import java.util.List;
|
|
|
+import java.util.Map;
|
|
|
+
|
|
|
+@SpringBootTest(classes = ZzjsApplication.class)
|
|
|
+@RunWith(SpringRunner.class)
|
|
|
+public class KtTest3 {
|
|
|
+
|
|
|
+
|
|
|
+ @Autowired
|
|
|
+ private IKtService ktService;
|
|
|
+
|
|
|
+
|
|
|
+ @Autowired
|
|
|
+ private IQuestionColumnService questionColumnService;
|
|
|
+
|
|
|
+ @Autowired
|
|
|
+ private IQuestionInfoKtNewService questionInfoKtNewService;
|
|
|
+
|
|
|
+
|
|
|
+
|
|
|
+ /**
|
|
|
+ * 获取一点通题库
|
|
|
+ */
|
|
|
+ @Test
|
|
|
+ public void test() {
|
|
|
+ QuestionInfoKtNew questionInfoKtNew = new QuestionInfoKtNew();
|
|
|
+ questionInfoKtNew.setNumber(150511l);
|
|
|
+ int count = questionInfoKtNewService.selectQuestionInfoKtNewCount(questionInfoKtNew);
|
|
|
+ System.out.println(count);
|
|
|
+
|
|
|
+ }
|
|
|
+
|
|
|
+ @Test
|
|
|
+ public void getColumn() {
|
|
|
+
|
|
|
+ List<Map<String, String>> mapList = this.getMap();
|
|
|
+ for (Map<String, String> m : mapList) {
|
|
|
+
|
|
|
+ String time = String.valueOf(System.currentTimeMillis() / 1000);
|
|
|
+ System.out.println(m.get("model") + "," + m.get("subject"));
|
|
|
+ String result = ktService.getInfo(m.get("model"), m.get("subject"), time);
|
|
|
+ JSONObject json = JSONObject.parseObject(result);
|
|
|
+ JSONArray data = json.getJSONArray("data");
|
|
|
+ System.out.println(data);
|
|
|
+ for (int i = 0; i < data.size(); i++) {
|
|
|
+ JSONObject n1 = (JSONObject) data.get(i);
|
|
|
+ Integer countid = n1.getInteger("id");
|
|
|
+ String title = n1.getString("title");
|
|
|
+ String model = n1.getString("model");
|
|
|
+ String subject = n1.getString("subject");
|
|
|
+ Integer sort = n1.getInteger("sort");
|
|
|
+ System.out.println(countid + "," + title + "," + model + "," + subject);
|
|
|
+
|
|
|
+ QuestionColumn questionColumn = new QuestionColumn();
|
|
|
+ questionColumn.setColumnId(countid);
|
|
|
+ questionColumn.setModel(model);
|
|
|
+ questionColumn.setSort(sort);
|
|
|
+ questionColumn.setSubject(subject);
|
|
|
+ questionColumn.setTitle(title);
|
|
|
+
|
|
|
+ questionColumnService.save(questionColumn);
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+
|
|
|
+ @Test
|
|
|
+ public void getQuestion() {
|
|
|
+
|
|
|
+ List<Map<String, String>> mapList = this.getMap();
|
|
|
+ for (Map<String, String> m : mapList) {
|
|
|
+
|
|
|
+ String time = String.valueOf(System.currentTimeMillis() / 1000);
|
|
|
+ System.out.println(m.get("model") + "," + m.get("subject"));
|
|
|
+ String result = ktService.getInfo(m.get("model"), m.get("subject"), time);
|
|
|
+ JSONObject json = JSONObject.parseObject(result);
|
|
|
+ JSONArray data = json.getJSONArray("data");
|
|
|
+
|
|
|
+ for (int i = 0; i < data.size(); i++) {
|
|
|
+ JSONObject n1 = (JSONObject) data.get(i);
|
|
|
+ String countid = n1.getString("id");
|
|
|
+ String title = n1.getString("title");
|
|
|
+ //String model = n1.getString("model");
|
|
|
+ String model = m.get("model");
|
|
|
+ String subject = n1.getString("subject");
|
|
|
+ System.out.println(countid + "," + title + "," + model);
|
|
|
+ String result2 = ktService.getQuestion(model, countid, title, subject, time);
|
|
|
+ JSONObject json2 = JSONObject.parseObject(result2);
|
|
|
+ JSONArray data2 = json2.getJSONArray("data");
|
|
|
+ List<QuestionInfoKtNew> addList = new ArrayList<QuestionInfoKtNew>();
|
|
|
+ List<QuestionInfoKtNew> upList = new ArrayList<QuestionInfoKtNew>();
|
|
|
+
|
|
|
+ for (int j = 0; j < data2.size(); j++) {
|
|
|
+ JSONObject n2 = (JSONObject) data2.get(j);
|
|
|
+ String id2 = n2.getString("id"); //快通ID
|
|
|
+ String idYdt = n2.getString("idYdt"); //一点通ID
|
|
|
+ String number = n2.getString("number"); //一点通ID
|
|
|
+ String type = n2.getString("type"); // 1:判断题 2:选择题 3:多选题
|
|
|
+ String answer = n2.getString("answer"); //答案
|
|
|
+ String answerkeyword = n2.getString("answerkeyword");//答案关键词
|
|
|
+ String explainGif = n2.getString("explainGif"); //技巧讲解图片URL
|
|
|
+ String explainJq = n2.getString("explainJq"); //技巧讲解说明
|
|
|
+ String explainJs = n2.getString("explainJs"); //官方解释
|
|
|
+ String explainMp3 = n2.getString("explainMp3"); //技巧讲解语音URL
|
|
|
+ String image = n2.getString("image"); //题目图片URL
|
|
|
+ String imageYdt = n2.getString("imageYdt"); //题目图片URL2
|
|
|
+ String issue = n2.getString("issue"); //题目
|
|
|
+ String model2 = n2.getString("model"); //车型
|
|
|
+ String columnAll = n2.getString("columnAll"); //车型
|
|
|
+ String opts = n2.getString("opts"); //答案选项
|
|
|
+ String skillkeyword = n2.getString("skillkeyword"); //答题技巧关键词
|
|
|
+ String subject2 = n2.getString("subject"); // 科目与分类
|
|
|
+ String titlekeyword = n2.getString("titlekeyword"); // 题目关键词
|
|
|
+ String issuemp3 = n2.getString("issuemp3"); //读题语音URL
|
|
|
+ String answermp3 = n2.getString("answermp3"); //答案语音URL
|
|
|
+ String explainjsmp3 = n2.getString("explainjsmp3"); //读题+答案语音URL
|
|
|
+
|
|
|
+ //查询当前是否数据是否存在
|
|
|
+ QuestionInfoKtNew questionInfoKtNewQuery = new QuestionInfoKtNew();
|
|
|
+ questionInfoKtNewQuery.setId(Long.parseLong(id2));
|
|
|
+ int count = questionInfoKtNewService.selectQuestionInfoKtNewCount(questionInfoKtNewQuery);
|
|
|
+ if (count == 0) {
|
|
|
+ QuestionInfoKtNew questionInfoKtNew = new QuestionInfoKtNew();
|
|
|
+ questionInfoKtNew.setId(Long.parseLong(id2));
|
|
|
+ questionInfoKtNew.setIdYdt(idYdt == null ? null : Long.parseLong(idYdt));
|
|
|
+ questionInfoKtNew.setNumber(number == null ? null : Long.parseLong(number));
|
|
|
+ questionInfoKtNew.setQuestionType(type == null ? null : Long.parseLong(type));
|
|
|
+ questionInfoKtNew.setAnswer(answer);
|
|
|
+ questionInfoKtNew.setAnswerkeyword(answerkeyword);
|
|
|
+ questionInfoKtNew.setExplainGif(explainGif);
|
|
|
+ questionInfoKtNew.setExplainJq(explainJq);
|
|
|
+ questionInfoKtNew.setExplainJs(explainJs);
|
|
|
+ questionInfoKtNew.setExplainMp3(explainMp3);
|
|
|
+ questionInfoKtNew.setImage(image);
|
|
|
+ questionInfoKtNew.setImageYdt(imageYdt);
|
|
|
+ questionInfoKtNew.setIssue(issue);
|
|
|
+ questionInfoKtNew.setOpts(opts);
|
|
|
+ questionInfoKtNew.setSkillkeyword(skillkeyword);
|
|
|
+ questionInfoKtNew.setTitlekeyword(titlekeyword);
|
|
|
+ questionInfoKtNew.setIssuemp3(issuemp3);
|
|
|
+ questionInfoKtNew.setAnswermp3(answermp3);
|
|
|
+ questionInfoKtNew.setExplainjsmp3(explainjsmp3);
|
|
|
+
|
|
|
+ questionInfoKtNew.setModel(model2);
|
|
|
+ questionInfoKtNew.setSubject(subject2);
|
|
|
+ questionInfoKtNew.setColumnAll(columnAll);
|
|
|
+
|
|
|
+ addList.add(questionInfoKtNew);
|
|
|
+ // questionInfoGetService.save(questionInfoKt);
|
|
|
+ } else {
|
|
|
+ QuestionInfoKtNew questionInfoKtNew = new QuestionInfoKtNew();
|
|
|
+ questionInfoKtNew.setId(Long.parseLong(id2));
|
|
|
+ questionInfoKtNew.setIdYdt(idYdt == null ? null : Long.parseLong(idYdt));
|
|
|
+ questionInfoKtNew.setNumber(number == null ? null : Long.parseLong(number));
|
|
|
+ questionInfoKtNew.setQuestionType(type == null ? null : Long.parseLong(type));
|
|
|
+ questionInfoKtNew.setAnswer(answer);
|
|
|
+ questionInfoKtNew.setAnswerkeyword(answerkeyword);
|
|
|
+ questionInfoKtNew.setExplainGif(explainGif);
|
|
|
+ questionInfoKtNew.setExplainJq(explainJq);
|
|
|
+ questionInfoKtNew.setExplainJs(explainJs);
|
|
|
+ questionInfoKtNew.setExplainMp3(explainMp3);
|
|
|
+ questionInfoKtNew.setImage(image);
|
|
|
+ questionInfoKtNew.setImageYdt(imageYdt);
|
|
|
+ questionInfoKtNew.setIssue(issue);
|
|
|
+ questionInfoKtNew.setOpts(opts);
|
|
|
+ questionInfoKtNew.setSkillkeyword(skillkeyword);
|
|
|
+ questionInfoKtNew.setTitlekeyword(titlekeyword);
|
|
|
+ questionInfoKtNew.setIssuemp3(issuemp3);
|
|
|
+ questionInfoKtNew.setAnswermp3(answermp3);
|
|
|
+ questionInfoKtNew.setExplainjsmp3(explainjsmp3);
|
|
|
+
|
|
|
+ questionInfoKtNew.setModel(model2);
|
|
|
+ questionInfoKtNew.setSubject(subject2);
|
|
|
+ questionInfoKtNew.setColumnAll(columnAll);
|
|
|
+ upList.add(questionInfoKtNew);
|
|
|
+ }
|
|
|
+ }
|
|
|
+ questionInfoKtNewService.saveBatch(addList);
|
|
|
+ questionInfoKtNewService.updateBatchById(upList);
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ }
|
|
|
+
|
|
|
+
|
|
|
+ public List<Map<String, String>> getMap() {
|
|
|
+
|
|
|
+ //小车 科目一
|
|
|
+ Map<String, String> cart_k1 = new LinkedHashMap(); // k1:顺序练习
|
|
|
+ cart_k1.put("model", "cart");
|
|
|
+ cart_k1.put("subject", "k1");
|
|
|
+ Map<String, String> cart_k1_2 = new LinkedHashMap(); // k1_2:精选必考题
|
|
|
+ cart_k1_2.put("model", "cart");
|
|
|
+ cart_k1_2.put("subject", "k1_2");
|
|
|
+ Map<String, String> cart_k1_3 = new LinkedHashMap(); // k1_3:分类练习
|
|
|
+ cart_k1_3.put("model", "cart");
|
|
|
+ cart_k1_3.put("subject", "k1_3");
|
|
|
+ Map<String, String> cart_k1_4 = new LinkedHashMap(); // k1_4:地方题库
|
|
|
+ cart_k1_4.put("model", "cart");
|
|
|
+ cart_k1_4.put("subject", "k1_4");
|
|
|
+
|
|
|
+ //客车 科目一
|
|
|
+ Map<String, String> bus_k1 = new LinkedHashMap(); // k1:顺序练习
|
|
|
+ bus_k1.put("model", "bus");
|
|
|
+ bus_k1.put("subject", "k1");
|
|
|
+ Map<String, String> bus_k1_2 = new LinkedHashMap(); // k1_2:精选必考题
|
|
|
+ bus_k1_2.put("model", "bus");
|
|
|
+ bus_k1_2.put("subject", "k1_2");
|
|
|
+ Map<String, String> bus_k1_3 = new LinkedHashMap(); // k1_3:分类练习
|
|
|
+ bus_k1_3.put("model", "bus");
|
|
|
+ bus_k1_3.put("subject", "k1_3");
|
|
|
+ Map<String, String> bus_k1_4 = new LinkedHashMap(); // k1_4:地方题库
|
|
|
+ bus_k1_4.put("model", "bus");
|
|
|
+ bus_k1_4.put("subject", "k1_4");
|
|
|
+
|
|
|
+
|
|
|
+ //货车 科目一
|
|
|
+ Map<String, String> truck_k1 = new LinkedHashMap(); // k1:顺序练习
|
|
|
+ truck_k1.put("model", "truck");
|
|
|
+ truck_k1.put("subject", "k1");
|
|
|
+ Map<String, String> truck_k1_2 = new LinkedHashMap(); // k1_2:精选必考题
|
|
|
+ truck_k1_2.put("model", "truck");
|
|
|
+ truck_k1_2.put("subject", "k1_2");
|
|
|
+ Map<String, String> truck_k1_3 = new LinkedHashMap(); // k1_3:分类练习
|
|
|
+ truck_k1_3.put("model", "truck");
|
|
|
+ truck_k1_3.put("subject", "k1_3");
|
|
|
+ Map<String, String> truck_k1_4 = new LinkedHashMap(); // k1_4:地方题库
|
|
|
+ truck_k1_4.put("model", "truck");
|
|
|
+ truck_k1_4.put("subject", "k1_4");
|
|
|
+
|
|
|
+ //摩托车 科目一
|
|
|
+ Map<String, String> mtc_k1 = new LinkedHashMap(); // k1:顺序练习
|
|
|
+ mtc_k1.put("model", "mtc");
|
|
|
+ mtc_k1.put("subject", "k1");
|
|
|
+ Map<String, String> mtc_k1_2 = new LinkedHashMap(); // k1_2:精选必考题
|
|
|
+ mtc_k1_2.put("model", "mtc");
|
|
|
+ mtc_k1_2.put("subject", "k1_2");
|
|
|
+ Map<String, String> mtc_k1_3 = new LinkedHashMap(); // k1_3:分类练习
|
|
|
+ mtc_k1_3.put("model", "mtc");
|
|
|
+ mtc_k1_3.put("subject", "k1_3");
|
|
|
+ Map<String, String> mtc_k1_4 = new LinkedHashMap(); // k1_4:地方题库
|
|
|
+ mtc_k1_4.put("model", "mtc");
|
|
|
+ mtc_k1_4.put("subject", "k1_4");
|
|
|
+
|
|
|
+
|
|
|
+ //小车 科目四
|
|
|
+ Map<String, String> cart_k4 = new LinkedHashMap(); // k4:顺序练习
|
|
|
+ cart_k4.put("model", "cart");
|
|
|
+ cart_k4.put("subject", "k4");
|
|
|
+ Map<String, String> cart_k4_2 = new LinkedHashMap(); // k4_2:精选必考题
|
|
|
+ cart_k4_2.put("model", "cart");
|
|
|
+ cart_k4_2.put("subject", "k4_2");
|
|
|
+ Map<String, String> cart_k4_3 = new LinkedHashMap(); // k4_3:分类练习
|
|
|
+ cart_k4_3.put("model", "cart");
|
|
|
+ cart_k4_3.put("subject", "k4_3");
|
|
|
+ Map<String, String> cart_k4_4 = new LinkedHashMap(); // k4_4:地方题库
|
|
|
+ cart_k4_4.put("model", "cart");
|
|
|
+ cart_k4_4.put("subject", "k4_4");
|
|
|
+
|
|
|
+ //客车 科目四
|
|
|
+ Map<String, String> bus_k4 = new LinkedHashMap(); // k4:顺序练习
|
|
|
+ bus_k4.put("model", "bus");
|
|
|
+ bus_k4.put("subject", "k4");
|
|
|
+ Map<String, String> bus_k4_2 = new LinkedHashMap(); // k4_2:精选必考题
|
|
|
+ bus_k4_2.put("model", "bus");
|
|
|
+ bus_k4_2.put("subject", "k4_2");
|
|
|
+ Map<String, String> bus_k4_3 = new LinkedHashMap(); // k4_3:分类练习
|
|
|
+ bus_k4_3.put("model", "bus");
|
|
|
+ bus_k4_3.put("subject", "k4_3");
|
|
|
+ Map<String, String> bus_k4_4 = new LinkedHashMap(); // k4_4:地方题库
|
|
|
+ bus_k4_4.put("model", "bus");
|
|
|
+ bus_k4_4.put("subject", "k4_4");
|
|
|
+
|
|
|
+
|
|
|
+ //货车 科目四
|
|
|
+ Map<String, String> truck_k4 = new LinkedHashMap(); // k4:顺序练习
|
|
|
+ truck_k4.put("model", "truck");
|
|
|
+ truck_k4.put("subject", "k4");
|
|
|
+ Map<String, String> truck_k4_2 = new LinkedHashMap(); // k4_2:精选必考题
|
|
|
+ truck_k4_2.put("model", "truck");
|
|
|
+ truck_k4_2.put("subject", "k4_2");
|
|
|
+ Map<String, String> truck_k4_3 = new LinkedHashMap(); // k4_3:分类练习
|
|
|
+ truck_k4_3.put("model", "truck");
|
|
|
+ truck_k4_3.put("subject", "k4_3");
|
|
|
+ Map<String, String> truck_k4_4 = new LinkedHashMap(); // k4_4:地方题库
|
|
|
+ truck_k4_4.put("model", "truck");
|
|
|
+ truck_k4_4.put("subject", "k4_4");
|
|
|
+
|
|
|
+ //摩托车 科目四
|
|
|
+ Map<String, String> mtc_k4 = new LinkedHashMap(); // k4:顺序练习
|
|
|
+ mtc_k4.put("model", "mtc");
|
|
|
+ mtc_k4.put("subject", "k4");
|
|
|
+ Map<String, String> mtc_k4_2 = new LinkedHashMap(); // k4_2:精选必考题
|
|
|
+ mtc_k4_2.put("model", "mtc");
|
|
|
+ mtc_k4_2.put("subject", "k4_2");
|
|
|
+ Map<String, String> mtc_k4_3 = new LinkedHashMap(); // k4_3:分类练习
|
|
|
+ mtc_k4_3.put("model", "mtc");
|
|
|
+ mtc_k4_3.put("subject", "k4_3");
|
|
|
+ Map<String, String> mtc_k4_4 = new LinkedHashMap(); // k4_4:地方题库
|
|
|
+ mtc_k4_4.put("model", "mtc");
|
|
|
+ mtc_k4_4.put("subject", "k4_4");
|
|
|
+
|
|
|
+
|
|
|
+ List<Map<String, String>> mapList = new ArrayList<Map<String, String>>();
|
|
|
+ //小车 科目一
|
|
|
+ mapList.add(cart_k1);
|
|
|
+ mapList.add(cart_k1_2);
|
|
|
+ mapList.add(cart_k1_3);
|
|
|
+ mapList.add(cart_k1_4);
|
|
|
+ //客车 科目一
|
|
|
+ mapList.add(bus_k1);
|
|
|
+ mapList.add(bus_k1_2);
|
|
|
+ mapList.add(bus_k1_3);
|
|
|
+ mapList.add(bus_k1_4);
|
|
|
+ //货车 科目一
|
|
|
+ mapList.add(truck_k1);
|
|
|
+ mapList.add(truck_k1_2);
|
|
|
+ mapList.add(truck_k1_3);
|
|
|
+ mapList.add(truck_k1_4);
|
|
|
+ //摩托车 科目一
|
|
|
+ mapList.add(mtc_k1);
|
|
|
+ mapList.add(mtc_k1_2);
|
|
|
+ mapList.add(mtc_k1_3);
|
|
|
+ mapList.add(mtc_k1_4);
|
|
|
+
|
|
|
+ //小车 科目四
|
|
|
+ mapList.add(cart_k4);
|
|
|
+ mapList.add(cart_k4_2);
|
|
|
+ mapList.add(cart_k4_3);
|
|
|
+ mapList.add(cart_k4_4);
|
|
|
+ //客车 科目四
|
|
|
+ mapList.add(bus_k4);
|
|
|
+ mapList.add(bus_k4_2);
|
|
|
+ mapList.add(bus_k4_3);
|
|
|
+ mapList.add(bus_k4_4);
|
|
|
+ //货车 科目四
|
|
|
+ mapList.add(truck_k4);
|
|
|
+ mapList.add(truck_k4_2);
|
|
|
+ mapList.add(truck_k4_3);
|
|
|
+ mapList.add(truck_k4_4);
|
|
|
+ //摩托车 科目四
|
|
|
+ mapList.add(mtc_k4);
|
|
|
+ mapList.add(mtc_k4_2);
|
|
|
+ mapList.add(mtc_k4_3);
|
|
|
+ mapList.add(mtc_k4_4);
|
|
|
+
|
|
|
+ return mapList;
|
|
|
+ }
|
|
|
+
|
|
|
+ public List<Map<String, String>> get1Map() {
|
|
|
+
|
|
|
+ //小车 科目一
|
|
|
+ Map<String, String> cart_k1 = new LinkedHashMap(); // k1:顺序练习
|
|
|
+ cart_k1.put("model", "cart");
|
|
|
+ cart_k1.put("subject", "k1");
|
|
|
+ Map<String, String> cart_k1_2 = new LinkedHashMap(); // k1_2:精选必考题
|
|
|
+ cart_k1_2.put("model", "cart");
|
|
|
+ cart_k1_2.put("subject", "k1_2");
|
|
|
+ Map<String, String> cart_k1_3 = new LinkedHashMap(); // k1_3:分类练习
|
|
|
+ cart_k1_3.put("model", "cart");
|
|
|
+ cart_k1_3.put("subject", "k1_3");
|
|
|
+ Map<String, String> cart_k1_4 = new LinkedHashMap(); // k1_4:地方题库
|
|
|
+ cart_k1_4.put("model", "cart");
|
|
|
+ cart_k1_4.put("subject", "k1_4");
|
|
|
+
|
|
|
+ //客车 科目一
|
|
|
+ Map<String, String> bus_k1 = new LinkedHashMap(); // k1:顺序练习
|
|
|
+ bus_k1.put("model", "bus");
|
|
|
+ bus_k1.put("subject", "k1");
|
|
|
+ Map<String, String> bus_k1_2 = new LinkedHashMap(); // k1_2:精选必考题
|
|
|
+ bus_k1_2.put("model", "bus");
|
|
|
+ bus_k1_2.put("subject", "k1_2");
|
|
|
+ Map<String, String> bus_k1_3 = new LinkedHashMap(); // k1_3:分类练习
|
|
|
+ bus_k1_3.put("model", "bus");
|
|
|
+ bus_k1_3.put("subject", "k1_3");
|
|
|
+ Map<String, String> bus_k1_4 = new LinkedHashMap(); // k1_4:地方题库
|
|
|
+ bus_k1_4.put("model", "bus");
|
|
|
+ bus_k1_4.put("subject", "k1_4");
|
|
|
+
|
|
|
+
|
|
|
+ //货车 科目一
|
|
|
+ Map<String, String> truck_k1 = new LinkedHashMap(); // k1:顺序练习
|
|
|
+ truck_k1.put("model", "truck");
|
|
|
+ truck_k1.put("subject", "k1");
|
|
|
+ Map<String, String> truck_k1_2 = new LinkedHashMap(); // k1_2:精选必考题
|
|
|
+ truck_k1_2.put("model", "truck");
|
|
|
+ truck_k1_2.put("subject", "k1_2");
|
|
|
+ Map<String, String> truck_k1_3 = new LinkedHashMap(); // k1_3:分类练习
|
|
|
+ truck_k1_3.put("model", "truck");
|
|
|
+ truck_k1_3.put("subject", "k1_3");
|
|
|
+ Map<String, String> truck_k1_4 = new LinkedHashMap(); // k1_4:地方题库
|
|
|
+ truck_k1_4.put("model", "truck");
|
|
|
+ truck_k1_4.put("subject", "k1_4");
|
|
|
+
|
|
|
+ //摩托车 科目一
|
|
|
+ Map<String, String> mtc_k1 = new LinkedHashMap(); // k1:顺序练习
|
|
|
+ mtc_k1.put("model", "mtc");
|
|
|
+ mtc_k1.put("subject", "k1");
|
|
|
+ Map<String, String> mtc_k1_2 = new LinkedHashMap(); // k1_2:精选必考题
|
|
|
+ mtc_k1_2.put("model", "mtc");
|
|
|
+ mtc_k1_2.put("subject", "k1_2");
|
|
|
+ Map<String, String> mtc_k1_3 = new LinkedHashMap(); // k1_3:分类练习
|
|
|
+ mtc_k1_3.put("model", "mtc");
|
|
|
+ mtc_k1_3.put("subject", "k1_3");
|
|
|
+ Map<String, String> mtc_k1_4 = new LinkedHashMap(); // k1_4:地方题库
|
|
|
+ mtc_k1_4.put("model", "mtc");
|
|
|
+ mtc_k1_4.put("subject", "k1_4");
|
|
|
+
|
|
|
+
|
|
|
+ List<Map<String, String>> mapList = new ArrayList<Map<String, String>>();
|
|
|
+ //小车 科目一
|
|
|
+ mapList.add(cart_k1);
|
|
|
+ mapList.add(cart_k1_2);
|
|
|
+ mapList.add(cart_k1_3);
|
|
|
+ mapList.add(cart_k1_4);
|
|
|
+ //客车 科目一
|
|
|
+ mapList.add(bus_k1);
|
|
|
+ mapList.add(bus_k1_2);
|
|
|
+ mapList.add(bus_k1_3);
|
|
|
+ mapList.add(bus_k1_4);
|
|
|
+ //货车 科目一
|
|
|
+ mapList.add(truck_k1);
|
|
|
+ mapList.add(truck_k1_2);
|
|
|
+ mapList.add(truck_k1_3);
|
|
|
+ mapList.add(truck_k1_4);
|
|
|
+ //摩托车 科目一
|
|
|
+ mapList.add(mtc_k1);
|
|
|
+ mapList.add(mtc_k1_2);
|
|
|
+ mapList.add(mtc_k1_3);
|
|
|
+ mapList.add(mtc_k1_4);
|
|
|
+
|
|
|
+ return mapList;
|
|
|
+ }
|
|
|
+
|
|
|
+
|
|
|
+ public List<Map<String, String>> get4Map() {
|
|
|
+
|
|
|
+ //小车 科目四
|
|
|
+ Map<String, String> cart_k4 = new LinkedHashMap(); // k4:顺序练习
|
|
|
+ cart_k4.put("model", "cart");
|
|
|
+ cart_k4.put("subject", "k4");
|
|
|
+ Map<String, String> cart_k4_2 = new LinkedHashMap(); // k4_2:精选必考题
|
|
|
+ cart_k4_2.put("model", "cart");
|
|
|
+ cart_k4_2.put("subject", "k4_2");
|
|
|
+ Map<String, String> cart_k4_3 = new LinkedHashMap(); // k4_3:分类练习
|
|
|
+ cart_k4_3.put("model", "cart");
|
|
|
+ cart_k4_3.put("subject", "k4_3");
|
|
|
+ Map<String, String> cart_k4_4 = new LinkedHashMap(); // k4_4:地方题库
|
|
|
+ cart_k4_4.put("model", "cart");
|
|
|
+ cart_k4_4.put("subject", "k4_4");
|
|
|
+
|
|
|
+ //客车 科目四
|
|
|
+ Map<String, String> bus_k4 = new LinkedHashMap(); // k4:顺序练习
|
|
|
+ bus_k4.put("model", "bus");
|
|
|
+ bus_k4.put("subject", "k4");
|
|
|
+ Map<String, String> bus_k4_2 = new LinkedHashMap(); // k4_2:精选必考题
|
|
|
+ bus_k4_2.put("model", "bus");
|
|
|
+ bus_k4_2.put("subject", "k4_2");
|
|
|
+ Map<String, String> bus_k4_3 = new LinkedHashMap(); // k4_3:分类练习
|
|
|
+ bus_k4_3.put("model", "bus");
|
|
|
+ bus_k4_3.put("subject", "k4_3");
|
|
|
+ Map<String, String> bus_k4_4 = new LinkedHashMap(); // k4_4:地方题库
|
|
|
+ bus_k4_4.put("model", "bus");
|
|
|
+ bus_k4_4.put("subject", "k4_4");
|
|
|
+
|
|
|
+
|
|
|
+ //货车 科目四
|
|
|
+ Map<String, String> truck_k4 = new LinkedHashMap(); // k4:顺序练习
|
|
|
+ truck_k4.put("model", "truck");
|
|
|
+ truck_k4.put("subject", "k4");
|
|
|
+ Map<String, String> truck_k4_2 = new LinkedHashMap(); // k4_2:精选必考题
|
|
|
+ truck_k4_2.put("model", "truck");
|
|
|
+ truck_k4_2.put("subject", "k4_2");
|
|
|
+ Map<String, String> truck_k4_3 = new LinkedHashMap(); // k4_3:分类练习
|
|
|
+ truck_k4_3.put("model", "truck");
|
|
|
+ truck_k4_3.put("subject", "k4_3");
|
|
|
+ Map<String, String> truck_k4_4 = new LinkedHashMap(); // k4_4:地方题库
|
|
|
+ truck_k4_4.put("model", "truck");
|
|
|
+ truck_k4_4.put("subject", "k4_4");
|
|
|
+
|
|
|
+ //摩托车 科目四
|
|
|
+ Map<String, String> mtc_k4 = new LinkedHashMap(); // k4:顺序练习
|
|
|
+ mtc_k4.put("model", "mtc");
|
|
|
+ mtc_k4.put("subject", "k4");
|
|
|
+ Map<String, String> mtc_k4_2 = new LinkedHashMap(); // k4_2:精选必考题
|
|
|
+ mtc_k4_2.put("model", "mtc");
|
|
|
+ mtc_k4_2.put("subject", "k4_2");
|
|
|
+ Map<String, String> mtc_k4_3 = new LinkedHashMap(); // k4_3:分类练习
|
|
|
+ mtc_k4_3.put("model", "mtc");
|
|
|
+ mtc_k4_3.put("subject", "k4_3");
|
|
|
+ Map<String, String> mtc_k4_4 = new LinkedHashMap(); // k4_4:地方题库
|
|
|
+ mtc_k4_4.put("model", "mtc");
|
|
|
+ mtc_k4_4.put("subject", "k4_4");
|
|
|
+
|
|
|
+
|
|
|
+ List<Map<String, String>> mapList = new ArrayList<Map<String, String>>();
|
|
|
+ //小车 科目四
|
|
|
+ mapList.add(cart_k4);
|
|
|
+ mapList.add(cart_k4_2);
|
|
|
+ mapList.add(cart_k4_3);
|
|
|
+ mapList.add(cart_k4_4);
|
|
|
+ //客车 科目四
|
|
|
+ mapList.add(bus_k4);
|
|
|
+ mapList.add(bus_k4_2);
|
|
|
+ mapList.add(bus_k4_3);
|
|
|
+ mapList.add(bus_k4_4);
|
|
|
+ //货车 科目四
|
|
|
+ mapList.add(truck_k4);
|
|
|
+ mapList.add(truck_k4_2);
|
|
|
+ mapList.add(truck_k4_3);
|
|
|
+ mapList.add(truck_k4_4);
|
|
|
+ //摩托车 科目四
|
|
|
+ mapList.add(mtc_k4);
|
|
|
+ mapList.add(mtc_k4_2);
|
|
|
+ mapList.add(mtc_k4_3);
|
|
|
+ mapList.add(mtc_k4_4);
|
|
|
+
|
|
|
+ return mapList;
|
|
|
+ }
|
|
|
+
|
|
|
+
|
|
|
+}
|
|
|
+
|
|
|
+
|
|
|
+
|