ff-admin/src/router/unit/inspectionPlan.ts

21 lines
631 B
TypeScript
Raw Normal View History

2025-04-11 14:14:11 +02:00
import { useInspectionPlanStore } from "@/stores/admin/unit/inspectionPlan/inspectionPlan";
export async function setInspectionPlanId(to: any, from: any, next: any) {
const InspectionPlanStore = useInspectionPlanStore();
InspectionPlanStore.activeInspectionPlan = to.params?.inspectionPlanId ?? null;
//useXYStore().$reset();
next();
}
export async function resetInspectionPlanStores(to: any, from: any, next: any) {
const InspectionPlanStore = useInspectionPlanStore();
InspectionPlanStore.activeInspectionPlan = null;
InspectionPlanStore.activeInspectionPlanObj = null;
//useXYStore().$reset();
next();
}