DESKTOP-CVS3R96\我恁爹
2022-11-10 8085cefd6a3437a8bb9e7b39628d444fc4203223
src/page/kline/index.vue
@@ -25,32 +25,17 @@
                <div class="right">
                  <span v-if="$store.state.userInfo.userAmt==undefined">¥0.00</span>
                  <span
                    v-if="$store.state.userInfo&&tabsItemIndex == 1"
                    v-if="$store.state.userInfo&&kLineDetails.if_zhishu!='0'"
                    style="white-space: nowarp;"
                  >
                    {{ '¥' + $store.state.userInfo.userIndexAmt
                    }}
                  </span>
                  <span
                    v-if="$store.state.userInfo.userAmt!=undefined&&tabsItemIndex == 0"
                    v-if="$store.state.userInfo.userAmt!=undefined&&kLineDetails.if_zhishu=='0'"
                    style="white-space: nowarp;"
                  >
                    {{ '¥ ' + $store.state.userInfo.userAmt
                    }}
                  </span>
                  <span
                    v-if="$store.state.userInfo.userAmt!=undefined&&tabsItemIndex == 2"
                    style="white-space: nowarp;"
                  >
                    {{ '¥ ' + $store.state.userInfo.userAmt
                    }}
                  </span>
                  <span
                    v-if="$store.state.userInfo&&tabsItemIndex == 3"
                    style="white-space: nowarp;"
                  >
                    {{
                    '¥' + $store.state.userInfo.userFuturesAmt
                    }}
                  </span>
                </div>
@@ -252,7 +237,7 @@
            <span>{{ '卖出' }}</span>
          </div>
          <div class="bottom_buy">
            <span>{{ '145.533' }}</span>
            <span>{{ singDetails.nowPrice }}</span>
          </div>
        </div>
        <div class="sell_btn" @click="goBuy()">
@@ -260,7 +245,7 @@
            <span>{{ '买入' }}</span>
          </div>
          <div class="bottom_sell">
            <span>{{ '145.533' }}</span>
            <span>{{ singDetails.nowPrice }}</span>
          </div>
        </div>
      </div>
@@ -283,6 +268,7 @@
      jianjie: "",
      optionBtn:false,
      isOptionOpt:false,
      dialogFlag:false,
    };
  },
  components: {
@@ -294,6 +280,7 @@
    this.getOpation();
    // this.$Lazyload();
    this.getSingDetails();
    this.getUserInfo();
  },
  methods: {
    async option() {
@@ -321,6 +308,18 @@
          this.optionBtn = false;
        }
      }
    },
    async getUserInfo() {
      // 获取用户信息
      //   let showcookie = this.getCookie('USER_TOKEN');
      let data = await api.getUserInfo();
      if (data.status === 0) {
        // this.getProductSetting()
        this.$store.state.userInfo = data.data;
      } else {
        Toast(data.msg);
      }
      this.$store.state.user = this.user;
    },
    async getOpation () {
        let opts = {
@@ -365,7 +364,15 @@
    },
    goBuy() {
      this.$router.push({
        path: "/TradingBuy"
        path: "/TradingBuy",
        query: {
          t:1,
          code:this.kLineDetails.code,
          m:this.singDetails.nowPrice,
          type:this.kLineDetails.if_zhishu,
          name:this.kLineDetails.name,
        }
      });
    }
  }
@@ -393,6 +400,7 @@
  height: 1.2rem;
  display: flex;
  justify-content: flex-end;
  align-items: center;
}
.detail_title {
  width: 100%;