diff --git a/src/components/ui/VnStockValueDisplay.vue b/src/components/ui/VnStockValueDisplay.vue index 8bdb921a0..d8f43323b 100644 --- a/src/components/ui/VnStockValueDisplay.vue +++ b/src/components/ui/VnStockValueDisplay.vue @@ -33,7 +33,7 @@ const formattedValue = computed(() => props.value); color: $negative; } .neutral { - color: orange; + color: $primary; } .value-icon { margin-right: 4px; diff --git a/src/pages/Item/components/ItemProposal.vue b/src/pages/Item/components/ItemProposal.vue index 9bcdf3bdf..2a3f5d424 100644 --- a/src/pages/Item/components/ItemProposal.vue +++ b/src/pages/Item/components/ItemProposal.vue @@ -28,7 +28,6 @@ const $props = defineProps({ }, }); const proposalSelected = ref([]); -const quantity = ref(-1); const sale = computed(() => $props.sales[0]); const saleFk = computed(() => sale.value.saleFk); const filter = computed(() => ({ @@ -146,15 +145,11 @@ const columns = computed(() => [ }, ]); -const extractNumericValue = (percentageString) => { - const match = percentageString.match(/(\d+(\.\d+)?)/); - return match ? parseFloat(match[0]) : null; -}; -const compatibilityItem = (value) => `${100 * (value / MATCH_VALUES.length)}%`; +const compatibilityItem = (value) => 100 * (value / MATCH_VALUES.length); const gradientStyle = (value) => { let color = 'white'; - const perc = extractNumericValue(compatibilityItem(value)); + const perc = parseFloat(compatibilityItem(value)); switch (true) { case perc >= 0 && perc < 33: color = 'orange'; @@ -241,13 +236,13 @@ const isSelectionAvailable = (itemProposal) => {
- {{ compatibilityItem(statusConditionalValue(row)) }} + {{ compatibilityItem(statusConditionalValue(row)) }}%
@@ -281,8 +276,6 @@ const isSelectionAvailable = (itemProposal) => {