闫增涛
2024-06-07 82df6ffb8981d27c4d2fa8388595b52972aef0b1
题目请求取消token
2个文件已修改
9 ■■■■ 已修改文件
src/assets/js/middleGround/api/store.js 3 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/books/childHealth/view/content/index.vue 6 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/assets/js/middleGround/api/store.js
@@ -302,7 +302,8 @@
      })
    }
    let token = localStorage.getItem(tokenKey)
    let url = token ? '/store/api/ApiQueryProductByAppUser' : '/store/api/ApiQueryProduct'
    // let url = token ? '/store/api/ApiQueryProductByAppUser' : '/store/api/ApiQueryProduct'
    let url = '/store/api/ApiQueryProduct'
    return request({
      url: url,
      method: 'post',
src/books/childHealth/view/content/index.vue
@@ -619,31 +619,25 @@
            );
            const catalog = catalogDom.getAttribute("num");
            if (!this.questionDataMap[page]) {
              const token = localStorage.getItem(this.config.tokenKey)
              if (testData && testData[catalog]) {
                if (testData[catalog][page]) {
                  if (Array.isArray(testData[catalog][page])) {
                    if(token) {
                      this.questionDataMap[page] = await getQuestionList(
                        page,
                        testData[catalog][page],
                        this.config.activeBook
                      );
                    }
                  } else {
                    const obj = {};
                    for (let key in testData[catalog][page]) {
                      if(token) {
                          obj[key] = await getQuestionList(
                          [],
                          testData[catalog][page][key],
                          this.config.activeBook
                        );
                      }
                    }
                    this.questionDataMap[page] = obj;
                  }
                  console.log("题目", this.questionDataMap);
                }
              }
            }