|
|
@@ -280,7 +280,7 @@
|
|
|
<q-separator />
|
|
|
<div class="row items-center q-px-sm q-py-sm">
|
|
|
<span class="col text-body2 row items-center q-gutter-x-xs">
|
|
|
- {{ unit.fantasy_name }}
|
|
|
+ {{ formatUnitName(unit) }}
|
|
|
<q-icon
|
|
|
v-if="lockedUnitIds.has(unit.id)"
|
|
|
name="mdi-lock"
|
|
|
@@ -471,6 +471,7 @@ import { getUnitsForSelect } from "src/api/unit";
|
|
|
import { getPackage, createPackage, updatePackage } from "src/api/package";
|
|
|
import { getProductsForSelect } from "src/api/product";
|
|
|
import { getGroupsForSelect } from "src/api/group";
|
|
|
+import { formatUnitName } from "src/helpers/utils";
|
|
|
|
|
|
defineEmits([...useDialogPluginComponent.emits]);
|
|
|
|
|
|
@@ -625,7 +626,9 @@ watch(
|
|
|
const filteredUnits = computed(() => {
|
|
|
const q = unitSearch.value.toLowerCase();
|
|
|
if (!q) return units.value;
|
|
|
- return units.value.filter((u) => u.fantasy_name.toLowerCase().includes(q));
|
|
|
+ return units.value.filter((unit) =>
|
|
|
+ formatUnitName(unit).toLowerCase().includes(q),
|
|
|
+ );
|
|
|
});
|
|
|
|
|
|
const setAllVisible = (visible) => {
|
|
|
@@ -696,6 +699,7 @@ onMounted(async () => {
|
|
|
units.value = allUnits.map((u) => ({
|
|
|
id: u.id,
|
|
|
fantasy_name: u.fantasy_name,
|
|
|
+ social_reason: u.social_reason,
|
|
|
visible: groupLockedIds.has(u.id) ? true : (visibilityMap[u.id] ?? true),
|
|
|
}));
|
|
|
|