litian
2024-07-05 2f9305515c7264637164c9e03c2840f4219ca1e3
packageBookService/pages/bookServices/examination/examination.js
@@ -820,7 +820,7 @@
      let query = {
        path: "*",
        queryType: "*",
        storeInfo: this.data.storeInfo,
        productId: this.data.bookId,
        cmsPath: pathitem.productLinkPath,
        itemFields: {
@@ -840,6 +840,9 @@
          size: 999,
        },
      };
      if (this.data.storeInfo) {
        query.storeInfo = this.data.storeInfo
      }
      await app.MG.store.getProductDetail(query).then((res) => {
        this.setData({
          total: res.datas.cmsDatas[0].datas.length,
@@ -1355,7 +1358,6 @@
    for (let qindex = 0; qindex < this.data.collectList.length; qindex++) {
      const qitem = this.data.collectList[qindex];
      let query = {
        storeInfo: this.data.storeInfo,
        path: "*",
        cmsPath: this.data.rootCmsItemId,
        cmsType: "*",
@@ -1374,6 +1376,9 @@
          Embedded_QuestionBank_Difficulty: [],
        },
      };
      if (this.data.storeInfo) {
        query.storeInfo = this.data.storeInfo
      }
      await app.MG.store.getProductDetail(query).then((res) => {
        let questionArr = [];
        res.datas.cmsDatas[0].datas.forEach((item, index) => {
@@ -1603,7 +1608,6 @@
    let multipleChoiceArr = []; // 多选
    let completionArr = []; // 填空
    let query = {
      storeInfo: this.data.storeInfo,
      path: "*",
      cmsPath: this.data.rootCmsItemId,
      cmsType: "*",
@@ -1622,6 +1626,9 @@
        Embedded_QuestionBank_Difficulty: [],
      },
    };
    if (this.data.storeInfo) {
      query.storeInfo = this.data.storeInfo
    }
    await app.MG.store.getProductDetail(query).then((res) => {
      let questionArr = [];
      res.datas.cmsDatas[0].datas.forEach((item, index) => {
@@ -1889,7 +1896,6 @@
        itemIds.push(item.id + "");
      });
      let query = {
        storeInfo: this.data.storeInfo,
        path: "*",
        cmsPath: this.data.rootCmsItemId,
        cmsType: "*",
@@ -1908,6 +1914,9 @@
          Embedded_QuestionBank_Difficulty: [],
        },
      };
      if (this.data.storeInfo) {
        query.storeInfo = this.data.storeInfo
      }
      await app.MG.store.getProductDetail(query).then((res) => {
        res.datas.cmsDatas[0].datas.forEach((item, index) => {
          // 循环questionList,给每题赋值分数