lxf
2025-07-15 691b86ca853959f5beb3db9b25d0a4a9929dd40f
src/components/Transform/list-quotation/index.vue
@@ -24,7 +24,9 @@
            <div class="block">{{ $t(topTitle) }}</div>
            <van-icon name="play" style="align-content:center;transform: rotate(90deg);"/>
          </div>
          <div class="px-16 py-20 bg-black text-white flex flex-col absolute min-w-140 box-border top-25 rounded-11 leading-28" style="z-index:999;margin-top: 0.8rem;" v-show="isTopShow">
          <div
            class="px-16 py-20 bg-black text-white flex flex-col absolute min-w-140 box-border top-25 rounded-11 leading-28"
            style="z-index:999;margin-top: 0.8rem;" v-show="isTopShow">
            <div @click="changeType('货币兑换', 2)">{{ $t('货币兑换') }}</div>
         <div @click="changeType('外汇交易', 1)">{{ $t('外汇交易') }}</div>
            <!-- <div>期貨</div>
@@ -35,7 +37,7 @@
      <transition-group :name="type" tag="div">
        <div v-if="active == 0" :key="active">
        <div>
          <van-cell v-for="item in listData" :key="item.id" style="background-color: #f0f0f0;margin-bottom: 10px;">
            <ul class="flex justify-between w-full items-center" @click="onItemClick(item)">
              <li class="flex items-center left">
@@ -66,44 +68,6 @@
                  {{ (item.change_ratio === 0 ? 0 : item.change_ratio) }}%</p>
                <p class="w-153 font-31 h-71 bg-red text-white border-0 text-center btn" v-else>
                  {{ (item.change_ratio === 0 ? 0 : item.change_ratio) }}%</p>
              </li>
            </ul>
          </van-cell>
        </div>
        <div v-else :key="active">
          <van-cell v-for="item in showList" :key="item.id">
            <ul class="flex justify-between w-full items-center" @click="onItemClick(item)">
              <li class="flex items-center left">
                <img :src="`${HOST_URL}/symbol/${item.symbol_data}.png`" alt="logo"
                  class="w-72 h-72 mr-16" />
                <p class="flex flex-col">
                  <span class="flex items-end font-32 flex items-center">
                    <span class="textColor font-600 font-30">{{ item.symbol_data && item.symbol_data.toUpperCase() || '--'
                    }}</span>
                    <!-- <span class="font-24 text-grey" style="position: relative; top: 1px">
                      {{ item.name && item.name.replace(item.symbol.toUpperCase(), '') || '--' }}</span> -->
                    <!-- <span class="font-24 text-grey" style="position: relative; top: 1px">
                      /USDT
                    </span> -->
                  </span>
                  <span class="font-24 text-grey text-left">{{ $t('成交量') + ' ' + (item.amount * 1).toFixed(2) }}</span>
                </p>
              </li>
              <li class="flex flex-col items-end mid">
                <p class="textColor font-32 font-600">{{ item.close }}</p>
                <!-- <p class="font-24 text-grey">{{ currency.currency_symbol }} {{ item.close && item.symbol_data.toUpperCase() == 'SHIB' ? (item.close * currency.rate).toFixed(8) : (item.close *
                    currency.rate).toFixed(2) || '--' }}</p> -->
              </li>
              <li class="right flex items-center justify-end text-right">
                <div v-if="active == 3" class="textColor w-182 font-700 font-24">
                  {{ (item.volume * 1).toFixed(2) }}
                </div>
                <template v-else>
                  <p class="w-153 font-31 h-71 bg-green text-white border-0 text-center btn" v-if="item.change_ratio_str > 0 || item.change_ratio > 0">
                    +{{ item.change_ratio_str }}%</p>
                  <p class="w-153 font-31 h-71 bg-red text-white border-0 text-center btn" v-else>
                    {{ (item.change_ratio_str === 0 ? 0 : '--') }}%</p>
                </template>
              </li>
            </ul>
          </van-cell>
@@ -328,6 +292,7 @@
  padding: 24px !important;
  border-radius: 1rem;
}
.list-quatation{
  margin: 0 20px;
}