wwf
2 天以前 791a96ae03cf92478244127b294c1fe520d31e89
优化
11个文件已修改
54 ■■■■ 已修改文件
entry/src/main/ets/pages/account/AccountPage.ets 4 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
entry/src/main/ets/pages/account/CourseCollection.ets 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
entry/src/main/ets/pages/account/UserInfoPage.ets 6 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
entry/src/main/ets/pages/home/ActiveDetail.ets 4 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
entry/src/main/ets/pages/home/BannerDetail.ets 4 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
entry/src/main/ets/pages/home/ClassificationDetail.ets 4 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
entry/src/main/ets/pages/home/Home.ets 12 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
entry/src/main/ets/pages/login/LoginPage.ets 4 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
entry/src/main/ets/pages/login/SignInPage.ets 4 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
entry/src/main/ets/pages/search/SearchPage.ets 7 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
entry/src/main/ets/utils/config.ets 3 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
entry/src/main/ets/pages/account/AccountPage.ets
@@ -3,7 +3,7 @@
import { http } from "@kit.NetworkKit";
import { HttpResponseResult } from "../../data/HttpResponse";
import { common } from "@kit.AbilityKit";
import { ROMAIN } from "../../utils/config";
import { DOMAIN } from "../../utils/config";
export class UserInfo {
  nickName: string = ''
@@ -117,7 +117,7 @@
  getUserInfo() {
    let httpRequest = http.createHttp();
    httpRequest.request(
      `${ROMAIN}/quiz-community/public/v1.0/users/userinfo`,
      `${DOMAIN}/quiz-community/public/v1.0/users/userinfo`,
      {
        method: http.RequestMethod.GET,
        header: { 'Content-Type': 'application/json', 'x-jwt-token': `Bearer ${AppStorage.get('x-jwt-token')}` },
entry/src/main/ets/pages/account/CourseCollection.ets
@@ -109,7 +109,7 @@
              .border({ width: 1, style: BorderStyle.Solid, color: '#f2f2f2' })
              .borderRadius(10)
            }
          }, (index: number) => index.toString())
          })
        }
        .listDirection(Axis.Vertical) // 排列方向
        .scrollBar(BarState.Off)
entry/src/main/ets/pages/account/UserInfoPage.ets
@@ -1,7 +1,7 @@
import { promptAction, router } from "@kit.ArkUI"
import { http } from "@kit.NetworkKit"
import { HttpResponseResult } from "../../data/HttpResponse"
import { ROMAIN } from "../../utils/config"
import { DOMAIN } from "../../utils/config"
import { UserInfo } from "./AccountPage"
@Entry
@@ -30,7 +30,7 @@
  getUserInfo() {
    let httpRequest = http.createHttp();
    httpRequest.request(
      `${ROMAIN}/quiz-community/public/v1.0/users/userinfo`,
      `${DOMAIN}/quiz-community/public/v1.0/users/userinfo`,
      {
        method: http.RequestMethod.GET,
        header: { 'Content-Type': 'application/json', 'x-jwt-token': `Bearer ${AppStorage.get('x-jwt-token')}` },
@@ -62,7 +62,7 @@
      introduce: this.userInfo.introduce
    }
    httpRequest.request(
      `${ROMAIN}/quiz-community/public/v1.0/users/userinfo`,
      `${DOMAIN}/quiz-community/public/v1.0/users/userinfo`,
      {
        method: http.RequestMethod.PUT,
        header: { 'Content-Type': 'application/json' },
entry/src/main/ets/pages/home/ActiveDetail.ets
@@ -2,7 +2,7 @@
import { http } from "@kit.NetworkKit"
import { LvMarkdownIn } from "@luvi/lv-markdown-in"
import { HttpResponseResult } from "../../data/HttpResponse"
import { ROMAIN } from "../../utils/config"
import { DOMAIN } from "../../utils/config"
class Activity {
  id: string = ''
@@ -41,7 +41,7 @@
  getDetail() {
    let httpRequest = http.createHttp();
    httpRequest.request(
      `${ROMAIN}/quiz-community/public/v1.0/home/hotTraining/details?hotTrainingId=${this.hotTrainingId}`,
      `${DOMAIN}/quiz-community/public/v1.0/home/hotTraining/details?hotTrainingId=${this.hotTrainingId}`,
      {
        method: http.RequestMethod.GET,
        header: { 'Content-Type': 'application/json', 'x-jwt-token': `Bearer ${AppStorage.get('x-jwt-token')}` },
entry/src/main/ets/pages/home/BannerDetail.ets
@@ -2,7 +2,7 @@
import { http } from "@kit.NetworkKit";
import { HttpResponseResult } from "../../data/HttpResponse";
import { LvMarkdownIn } from "@luvi/lv-markdown-in"
import { ROMAIN } from "../../utils/config";
import { DOMAIN } from "../../utils/config";
class BannerInfo {
  pic: string = ''
@@ -33,7 +33,7 @@
  getDetail() {
    let httpRequest = http.createHttp();
    httpRequest.request(
      `${ROMAIN}/quiz-community/public/v1.0/home/slideshows/details?bannerId=${this.bannerId}`,
      `${DOMAIN}/quiz-community/public/v1.0/home/slideshows/details?bannerId=${this.bannerId}`,
      {
        method: http.RequestMethod.GET,
        header: { 'Content-Type': 'application/json', 'x-jwt-token': `Bearer ${AppStorage.get('x-jwt-token')}` },
entry/src/main/ets/pages/home/ClassificationDetail.ets
@@ -2,7 +2,7 @@
import { http } from "@kit.NetworkKit"
import { LvMarkdownIn } from "@luvi/lv-markdown-in"
import { HttpResponseResult } from "../../data/HttpResponse"
import { ROMAIN } from "../../utils/config"
import { DOMAIN } from "../../utils/config"
@Entry
@Component
@@ -21,7 +21,7 @@
  getDetail() {
    let httpRequest = http.createHttp();
    httpRequest.request(
      `${ROMAIN}/quiz-community/public/v1.0/home/module/details?moduleName=${this.moduleName}`,
      `${DOMAIN}/quiz-community/public/v1.0/home/module/details?moduleName=${this.moduleName}`,
      {
        method: http.RequestMethod.GET,
        header: { 'Content-Type': 'application/json', 'x-jwt-token': `Bearer ${AppStorage.get('x-jwt-token')}` },
entry/src/main/ets/pages/home/Home.ets
@@ -2,7 +2,7 @@
import http from '@ohos.net.http';
import { HttpResponseResult } from "../../data/HttpResponse";
import { JSON } from "@kit.ArkTS";
import { ROMAIN } from "../../utils/config";
import { DOMAIN } from "../../utils/config";
class TabBarBase {
  title: string = ''
@@ -144,7 +144,7 @@
  getBannerList() {
    let httpRequest = http.createHttp();
    httpRequest.request(
      `${ROMAIN}/quiz-community/public/v1.0/home/slideshows`,
      `${DOMAIN}/quiz-community/public/v1.0/home/slideshows`,
      {
        method: http.RequestMethod.GET,
        header: { 'Content-Type': 'application/json', 'x-jwt-token': `Bearer ${AppStorage.get('x-jwt-token')}` },
@@ -167,7 +167,7 @@
  getActivityList() {
    let httpRequest = http.createHttp();
    httpRequest.request(
      `${ROMAIN}/quiz-community/public/v1.0/home/hotTraining`,
      `${DOMAIN}/quiz-community/public/v1.0/home/hotTraining`,
      {
        method: http.RequestMethod.GET,
        header: { 'Content-Type': 'application/json', 'x-jwt-token': `Bearer ${AppStorage.get('x-jwt-token')}` },
@@ -190,7 +190,7 @@
  getCourseList() {
    let httpRequest = http.createHttp();
    httpRequest.request(
      `${ROMAIN}/quiz-community/public/v1.0/home/courses`,
      `${DOMAIN}/quiz-community/public/v1.0/home/courses`,
      {
        method: http.RequestMethod.GET,
        header: { 'Content-Type': 'application/json', 'x-jwt-token': `Bearer ${AppStorage.get('x-jwt-token')}` },
@@ -344,7 +344,7 @@
                        })
                      })
                    }
                  }, (index: number) => index.toString())
                  })
                }
                .listDirection(Axis.Vertical) // 排列方向
                .scrollBar(BarState.Off)
@@ -437,7 +437,7 @@
                      .border({ width: 1, style: BorderStyle.Solid, color: '#f2f2f2' })
                      .borderRadius(10)
                    }
                  }, (index: number) => index.toString())
                  })
                }
                .listDirection(Axis.Vertical) // 排列方向
                .scrollBar(BarState.Off)
entry/src/main/ets/pages/login/LoginPage.ets
@@ -4,7 +4,7 @@
import http from '@ohos.net.http';
import { HttpResponseResult } from '../../data/HttpResponse';
import { JSON } from '@kit.ArkTS';
import { ROMAIN } from '../../utils/config';
import { DOMAIN } from '../../utils/config';
/**
 * @Description : 登录页
@@ -68,7 +68,7 @@
    }
    httpRequest.request(
      `${ROMAIN}/quiz-community/public/v1.0/users/login`,
      `${DOMAIN}/quiz-community/public/v1.0/users/login`,
      {
        method: http.RequestMethod.PUT,
        header: { 'Content-Type': 'application/json' },
entry/src/main/ets/pages/login/SignInPage.ets
@@ -3,7 +3,7 @@
import { HttpResponseResult } from '../../data/HttpResponse';
import { ComponentContent } from '@kit.ArkUI';
import { PromptActionClass } from '../../utils/PromptActionClass';
import { ROMAIN } from '../../utils/config';
import { DOMAIN } from '../../utils/config';
class DialogParams {
  text: string = "";
@@ -91,7 +91,7 @@
    }
    httpRequest.request(
      `${ROMAIN}/quiz-community/public/v1.0/users/register`,
      `${DOMAIN}/quiz-community/public/v1.0/users/register`,
      {
        method: http.RequestMethod.POST,
        header: { 'Content-Type': 'application/json' },
entry/src/main/ets/pages/search/SearchPage.ets
@@ -2,7 +2,7 @@
import { http } from "@kit.NetworkKit"
import { LvMarkdownIn } from "@luvi/lv-markdown-in"
import { HttpResponseResult } from "../../data/HttpResponse"
import { ROMAIN } from "../../utils/config"
import { DOMAIN } from "../../utils/config"
class JobItem {
  ability: string = ''
@@ -29,7 +29,7 @@
  getJobList() {
    let httpRequest = http.createHttp();
    httpRequest.request(
      `${ROMAIN}/quiz-community/public/v1.0/home/seek/job`,
      `${DOMAIN}/quiz-community/public/v1.0/home/seek/job`,
      {
        method: http.RequestMethod.GET,
        header: { 'Content-Type': 'application/json', 'x-jwt-token': `Bearer ${AppStorage.get('x-jwt-token')}` },
@@ -56,6 +56,7 @@
        return ele.companyName.includes(this.searchKeyword) || ele.jobName.includes(this.searchKeyword)
      })
      this.jobList = list
      console.log(JSON.stringify(list))
    } else {
      this.jobList = this.origJobList
    }
@@ -188,7 +189,7 @@
            .border({ width: 1, style: BorderStyle.Solid, color: this.expandIndex == index ? '#1756f4' : '#f2f2f2' })
            .borderRadius(10)
          }
        }, (index: number) => index.toString())
        })
      }
      .listDirection(Axis.Vertical) // 排列方向
      .scrollBar(BarState.Off)
entry/src/main/ets/utils/config.ets
@@ -1 +1,2 @@
export const ROMAIN = 'http://192.168.20.70:8080'
// export const DOMAIN = 'http://192.168.20.70:8080'
export const DOMAIN = 'http://124.70.31.13:7776'