change models
This commit is contained in:
parent
d5c33d899f
commit
05555425ce
7 changed files with 39 additions and 5 deletions
|
@ -6,6 +6,7 @@ export interface DamageReportViewModel {
|
|||
status: string;
|
||||
done: boolean;
|
||||
description: string;
|
||||
providedImage: string;
|
||||
affectedEquipmentId: string;
|
||||
affectedEquipment: EquipmentViewModel;
|
||||
}
|
||||
|
|
|
@ -1,4 +1,5 @@
|
|||
import type { EquipmentTypeViewModel } from "../equipmentType/equipmentType.models";
|
||||
import type { InspectionViewMoel } from "../inspectionPlan/inspectionPlan.models";
|
||||
|
||||
export interface EquipmentViewModel {
|
||||
id: string;
|
||||
|
@ -7,6 +8,7 @@ export interface EquipmentViewModel {
|
|||
location: string;
|
||||
equipmentTypeId: string;
|
||||
equipmentType: EquipmentTypeViewModel;
|
||||
inspections: Array<InspectionViewMoel>;
|
||||
}
|
||||
|
||||
export interface CreateEquipmentViewModel {
|
||||
|
|
|
@ -1,8 +1,10 @@
|
|||
import type { InspectionPlanViewModel } from "../inspectionPlan/inspectionPlan.models";
|
||||
|
||||
export interface EquipmentTypeViewModel {
|
||||
id: string;
|
||||
type: string;
|
||||
description: string;
|
||||
// attached inspection plans
|
||||
inspectionPlans: Array<InspectionPlanViewModel>;
|
||||
}
|
||||
|
||||
export interface CreateEquipmentTypeViewModel {
|
||||
|
|
|
@ -1,3 +1,4 @@
|
|||
import type InspectionPlan from "../../../../views/admin/unit/inspectionPlan/InspectionPlan.vue";
|
||||
import type { EquipmentTypeViewModel } from "../equipmentType/equipmentType.models";
|
||||
|
||||
export interface InspectionPlanViewModel {
|
||||
|
@ -31,3 +32,19 @@ export interface InspectionPointViewModel {
|
|||
description: string;
|
||||
type: "iO-niO" | "text" | "number";
|
||||
}
|
||||
|
||||
export interface InspectionViewMoel {
|
||||
id: string;
|
||||
inspectionPlanId: string;
|
||||
date: Date;
|
||||
status: "open" | "finished";
|
||||
results: Array<InspectionPointResultViewMoel>;
|
||||
}
|
||||
|
||||
export interface InspectionPointResultViewMoel {
|
||||
id: string;
|
||||
inspectionId: string;
|
||||
inspectionPlanId: string;
|
||||
inspectionPointId: string;
|
||||
value: string;
|
||||
}
|
||||
|
|
|
@ -1,7 +1,10 @@
|
|||
import type { InspectionPlanViewModel } from "../inspectionPlan/inspectionPlan.models";
|
||||
|
||||
export interface VehicleTypeViewModel {
|
||||
id: string;
|
||||
type: string;
|
||||
description: string;
|
||||
inspectionPlans: Array<InspectionPlanViewModel>;
|
||||
}
|
||||
|
||||
export interface CreateVehicleTypeViewModel {
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
<MainTemplate>
|
||||
<template #topBar>
|
||||
<div class="flex flex-row items-center justify-between pt-5 pb-3 px-7">
|
||||
<h1 class="font-bold text-xl h-8">Ausrüstung erfassen</h1>
|
||||
<h1 class="font-bold text-xl h-8">Prüfplan erstellen</h1>
|
||||
</div>
|
||||
</template>
|
||||
<template #diffMain>
|
||||
|
|
|
@ -10,9 +10,18 @@
|
|||
<input type="text" id="interval" :value="activeInspectionPlanObj.inspectionInterval" reaonly />
|
||||
</div>
|
||||
</div>
|
||||
<div v-if="activeInspectionPlanObj?.inspectionPoints">
|
||||
<div v-for="point in activeInspectionPlanObj?.inspectionPoints">
|
||||
{{ point }}
|
||||
<div v-if="activeInspectionPlanObj?.inspectionPoints" class="flex flex-col gap-2">
|
||||
<div
|
||||
v-for="point in activeInspectionPlanObj?.inspectionPoints"
|
||||
class="flex flex-col h-fit w-full border border-primary rounded-md"
|
||||
>
|
||||
<div class="bg-primary p-2 text-white flex flex-row justify-between items-center">
|
||||
<p>{{ point.title }}</p>
|
||||
</div>
|
||||
<div class="p-2">
|
||||
<p>Eingabetyp: {{ point.type }}</p>
|
||||
<p>Beschreibung: {{ point.description }}</p>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue