2
PC-20250623MANY\Administrator
2025-08-26 abb6c7bb45448fd8b3ca0e64900b9c4751e1d139
2
6 files modified
62 ■■■■ changed files
src/axios/api.js 4 ●●●● patch | view | raw | blame | history
src/locales/cht.json 3 ●●●● patch | view | raw | blame | history
src/locales/en.json 3 ●●●● patch | view | raw | blame | history
src/locales/zh.json 3 ●●●● patch | view | raw | blame | history
src/page/user/account.vue 47 ●●●● patch | view | raw | blame | history
src/page/user/myOrder.vue 2 ●●● patch | view | raw | blame | history
src/axios/api.js
@@ -671,3 +671,7 @@
export function getIndexData() {
  return post(`/api/stock/getIndexData.do`);
}
// 账户每周盈利获取
export function getWeeklyProfit() {
  return post(`/user/getWeeklyProfit.do`);
}
src/locales/cht.json
@@ -708,5 +708,6 @@
  "充值提示": "尊敬的會員您好,充值請聯繫客服",
  "市值": "市值",
  "持股": "持股",
  "可卖": "可賣"
  "可卖": "可賣",
  "每週盈利": "每週盈利"
}
src/locales/en.json
@@ -708,5 +708,6 @@
  "充值提示": "Dear member, please contact customer service for recharging",
  "市值": "Market capitalization",
  "持股": "Shareholding",
  "可卖": "For sale"
  "可卖": "For sale",
  "每週盈利": "Weekly profit"
}
src/locales/zh.json
@@ -708,5 +708,6 @@
  "充值提示": "尊敬的会员您好,充值请联系客服",
  "市值": "市值",
  "持股": "持股",
  "可卖": "可卖"
  "可卖": "可卖",
  "每週盈利": "每周盈利"
}
src/page/user/account.vue
@@ -28,7 +28,31 @@
          </div>
        </div>
      </div>
      <div class="all-assets flex-center">
      <div class="normal flex-between">
        <div>
          <div class="text-xs">{{ $t("每週盈利") }}</div>
          <div class="price" style="font-size: .6rem;">
            {{ moneyData.symbol }} {{ weeklyProfit }}
          </div>
        </div>
      </div>
      <div class="normal flex-between">
        <div>
          <div class="text-xs">{{ $t("hj48") }}</div>
          <div class="price" style="font-size: .3rem;">
            {{ moneyData.symbol }} {{ moneyData.availableBalance }}
          </div>
        </div>
      </div>
      <div class="normal flex-between">
        <div>
          <div class="text-xs">{{ $t("账户盈亏") }}</div>
          <div class="price" style="font-size: .3rem;">
            {{ moneyData.symbol }} {{ moneyData.cumulativeProfitAndLoss }}
          </div>
        </div>
      </div>
      <!-- <div class="all-assets flex-center">
        <div class="assets-item flex-center">
          <div class="all-size">{{ $t("hj48") }}</div>
          <div class="big-size">{{ moneyData.availableBalance }}</div>
@@ -37,11 +61,7 @@
          <div class="all-size">{{ $t("账户盈亏") }}</div>
          <div class="big-size">{{ moneyData.cumulativeProfitAndLoss }}</div>
        </div>
        <!-- <div class="assets-item flex-center">
          <div class="all-size">{{ $t("今日盈亏") }}</div>
          <div class="big-size">0.00</div>
        </div> -->
      </div>
      </div> -->
    </div>
    <div class="tui-spendMoney flex-between-start">
@@ -60,7 +80,7 @@
      </div>
    </div>
    <my-order :Operation="true"></my-order>
    <!-- <my-order :Operation="true"></my-order> -->
  </div>
</template>
@@ -80,6 +100,7 @@
      userInfo: {}, // 用户信息
      moneyData: {}, // 账户金额
      positionData: {}, // 账户持仓数据
      weeklyProfit: 0, // 每周盈利数据
      tabs: [
        {
          name: this.$t("hj177"),
@@ -112,6 +133,13 @@
        this.moneyData = data.data[0];
      }
    },
    // 获取账户每周盈利
    async getWeeklyProfit() {
      let data = await api.getWeeklyProfit();
      if (data.status === 0) {
        this.weeklyProfit = data.data;
      }
    },
    // 获取账户持仓数据
    async getMyPositionProfitAndLose() {
      let data = await api.getMyPositionProfitAndLose();
@@ -139,11 +167,12 @@
    // 充值提示
    czts() {
      Toast(this.$t("充值提示"));
    },
    }
  },
  created() {
    this.getUserInfo();
    this.getMoney();
    this.getWeeklyProfit();
    // this.getMyPositionProfitAndLose();
  }
};
@@ -207,7 +236,7 @@
      position: relative;
      .price {
        font-size: 0.825rem;
        line-height: 0.825rem;
        // line-height: 0.825rem;
        font-weight: 500;
        padding-top: 0.3rem;
        color: #fff;
src/page/user/myOrder.vue
@@ -401,7 +401,7 @@
      }
    },
    open(i, index) {
      if (!this.Operation) return;
      // if (!this.Operation) return;
      this.actObj = i;
      this.actIndex = index;
    },