change some bug
This commit is contained in:
@@ -6,7 +6,7 @@
|
||||
</div>
|
||||
<div v-if="!isBoursecuProject()" class="flex mt-2 justify-center text-tertiary w-full z-20">
|
||||
{{ metalAssetLabel }}:
|
||||
<div class="text-l mr-2 font-bold">{{ (userStore?.userInfo?.wallet?.count_gold ?? 0).toFixed(3) }} گرم</div>
|
||||
<div class="text-l mr-2 font-bold">{{ (userStore?.userInfo?.wallet?.count_gold ?? 0).toFixed(3) }} {{ weightUnit }}</div>
|
||||
<BasicIcon @click="$emit('openGoldModal')" icon="vuesax-linear:info-circle" size="18" color="tertiary" />
|
||||
</div>
|
||||
<div class="flex mt-2 justify-center text-tertiary w-full z-20">
|
||||
@@ -23,10 +23,11 @@ import { useUserStore } from '@/store/userStore'
|
||||
import BasicIcon from '@/components/BasicPacks/BasicIcon.vue'
|
||||
import {usePriceWithoutType} from "../../../../utils/usePrice";
|
||||
import { isBoursecuProject } from '@/utils/config'
|
||||
import { getMetalAssetLabel } from '@/utils/productDealMethod'
|
||||
import { getMetalAssetLabel, getWeightUnit } from '@/utils/productDealMethod'
|
||||
|
||||
const userStore = useUserStore()
|
||||
const metalAssetLabel = computed(() => getMetalAssetLabel())
|
||||
const weightUnit = computed(() => getWeightUnit())
|
||||
|
||||
defineEmits<{
|
||||
openGoldModal: []
|
||||
|
||||
@@ -7,11 +7,11 @@
|
||||
<div class="mt-5">
|
||||
<BasicInfoItem
|
||||
class="flex justify-between"
|
||||
title="مجموعه کل دارایی طلایی"
|
||||
:title="`مجموعه کل دارایی ${settingsStore.metalTypeLabel}`"
|
||||
is-line
|
||||
:info="`در این قسمت مجموع کل وزن طلای آبشده (${(walletInfo?.gold ?? 0)?.toFixed(3)}) + ارزش دارایی ها (${(walletInfo?.treasure_sum ?? 0)?.toFixed(3)} ) را مشاهده میفرمایید.`"
|
||||
infoHead="مجموع کل دارایی طلایی"
|
||||
:value="parseFloat((walletInfo?.gold_sum ?? 0).toFixed(2)) + ' گرم'"
|
||||
:info="`در این قسمت مجموع کل وزن ${settingsStore.metalTypeLabel} آبشده (${(walletInfo?.gold ?? 0)?.toFixed(3)}) + ارزش دارایی ها (${(walletInfo?.treasure_sum ?? 0)?.toFixed(3)} ) را مشاهده میفرمایید.`"
|
||||
:infoHead="`مجموع کل دارایی ${settingsStore.metalTypeLabel}`"
|
||||
:value="parseFloat((walletInfo?.gold_sum ?? 0).toFixed(2)) + ' ' + weightUnit"
|
||||
/>
|
||||
<a-divider class="!my-1" />
|
||||
<BasicInfoItem
|
||||
@@ -23,9 +23,9 @@
|
||||
<a-divider class="!my-1" />
|
||||
<BasicInfoItem
|
||||
class="flex justify-between"
|
||||
title="دارایی کیف پول طلایی"
|
||||
:title="`دارایی کیف پول ${settingsStore.metalTypeLabel}`"
|
||||
is-line
|
||||
:value="(walletInfo?.count_gold_wallet ?? 0) + ' گرم'"
|
||||
:value="(walletInfo?.count_gold_wallet ?? 0) + ' ' + weightUnit"
|
||||
/>
|
||||
<a-divider v-if="nameProject === 'goldsun'" class="!my-1" />
|
||||
<BasicInfoItem
|
||||
@@ -62,6 +62,8 @@ import { computed } from 'vue'
|
||||
import BasicActionSheet from '@/components/BasicPacks/BasicActionSheet.vue'
|
||||
import BasicInfoItem from '@/components/BasicPacks/BasicInfoItem.vue'
|
||||
import { useConfigStore } from '@/store/configStore'
|
||||
import { useSettingsStore } from '@/store/settingsStore'
|
||||
import { getWeightUnit } from '@/utils/productDealMethod'
|
||||
import {usePrice} from "@/utils/usePrice";
|
||||
|
||||
const props = defineProps<{
|
||||
@@ -76,6 +78,8 @@ const emit = defineEmits<{
|
||||
|
||||
const config = useConfigStore()
|
||||
const nameProject = config.config.name
|
||||
const settingsStore = useSettingsStore()
|
||||
const weightUnit = computed(() => getWeightUnit())
|
||||
|
||||
const visible = computed({
|
||||
get: () => props.show,
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
<template>
|
||||
<div class="w-full relative mt-2 border-gray-200 border-1 rounded-lg py-3 flex flex-col justify-center home_appear_fade_in">
|
||||
<div class="text-gray-600 text-[12px] ml-2 w-full text-center">قیمت خرید از {{ config.config.name_fa }}</div>
|
||||
<div class="w-full items-center flex justify-center">
|
||||
<div class="text-gray-600 text-[12px] ml-2">قیمت خرید از {{ config.config.name_fa }}</div>
|
||||
<div v-if="price" class="flex gap-1 text-xs items-center">
|
||||
<div
|
||||
v-if="percentPriceChanged() !== 0"
|
||||
|
||||
@@ -33,6 +33,6 @@ const props = defineProps<{
|
||||
price: any
|
||||
}>()
|
||||
|
||||
const highPrice = computed(() => getTradeBuyPrice(props.price))
|
||||
const lowPrice = computed(() => getTradeSellPrice(props.price))
|
||||
const highPrice = computed(() => props.price?.up?.buy ?? getTradeBuyPrice(props.price))
|
||||
const lowPrice = computed(() => props.price?.up?.sell ?? getTradeSellPrice(props.price))
|
||||
</script>
|
||||
Reference in New Issue
Block a user