11
jhzh
2024-08-01 4ebbadfe4c8c7aa6404dcd9b126cc8265bf03c0d
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
import store from "@/store";
export function _symbolName(str, type) {
  const data = store.state?.home?.coinList;
  let symbol = "";
  if (data) {
    // console.log(data, "====");
    let arr = data.filter((item) => item.symbol === str);
    if (arr[0] && arr[0]?.symbol === str) {
      let symbol1 = arr[0].symbolFullName;
      if (type) {
        symbol = symbol1;
      } else {
        symbol = symbol1.replace("/USDT", "");
      }
    }
  }
 
  return symbol;
}