Предварительный макет

This commit is contained in:
iriska-gri committed 2024-04-16 17:00:17 +03:00
1 parent 95e6dfcba6
commit d069bac838
2 files changed
+172 -92

No files matched your search

@@ -1,59 +1,97 @@
<template> <template>
<div>
<v-row no-gutters class="gap h-100 flex-column"> <v-row no-gutters class="gap h-100 flex-column">
<v-col lg="3" class="flex-column w100">
<v-col lg=3 class="flex-column w100"> <structure-inspection-row :sText="'Руковдство'">
<v-row no-gutters class="h-100"> <template v-slot:cardboss>
<v-col class="bg-red flex-grow-0">Руководство</v-col> <v-col lg="3" v-for="x in structures" :key="x">
<v-col class="flex-column"> <v-card class="flex-column d-flex mr-1">
<v-row no-gutters class="h-100"> <v-card-text class="pa-0">
<v-col class="bg-green flex-column"> <v-row no-gutters>
<v-col lg="4" class="pa-1 w100">
<v-img
class="h-100"
:src="checkremote(`${spravURL}${x.login}.jpg`)"
cover
/>
</v-col>
<v-col class="text-center align-self-center text-h6">
{{ x.fio }}
</v-col>
</v-row>
</v-card-text>
</v-card>
</v-col>
</template>
</structure-inspection-row>
</v-col>
<v-col>
<structure-inspection-row :sText="'Структурные подразделения'">
<template v-slot:cardboss>
<v-col
class="flex-column"
v-for="bosses in structures"
:key="bosses"
>
<div v-for="x in bosses.deps" :key="x">
<!-- <v-col class="text-wrap text-center">
{{x.name}}
</v-col> -->
<v-card class="flex-column d-flex mb-1 mr-1">
<v-card-text class="pa-1 pt-3 px-3 flex-column">
<v-col lg="12" class=" minh pa-0">
<v-row no-gutters>
<v-col
class="text-wrap text-center text-body-2 font-weight-medium text-uppercase"
>
{{ x.name }}
</v-col> </v-col>
<v-col class="bg-yellow">2</v-col> <v-col class="flex-grow-0">
</v-row> <v-tooltip location="top">
</v-col> <template v-slot:activator="{ props }">
</v-row> <span v-bind="props">
<!-- <v-row> <v-icon
size="large"
<v-col class="bg-green flex-grow-0">2</v-col> color="green"
<v-col class="bg-yellow">2</v-col> icon="mdi-arrow-top-right"
</v-row> --> />
<!-- <v-row no-gutters class="gap"> </span>
</template>
<v-col class="flex-grow-0 bg-red"> <v-row>
<v-col> Перейти на страницу отдела </v-col>
s </v-row>
</v-tooltip>
</v-col>
<v-col v-for="structure in structures" :key="structure" class="flex-column bg-green">
<v-card class="h-100 flex-column d-flex">
{{structure.fio}}
</v-card>
</v-col>
</v-row> -->
</v-col>
<v-col class="bg-green flex-column">
<v-row no-gutters class="h-100">
<v-col class="w-0 flex-grow-0 text-no-wrap justify-center d-flex flex-column">
<div class="bg-red verticaltext text-h5">Структурные подразделения</div>
</v-col>
<v-col class="flex-column">
<v-row no-gutters class="h-100">
<v-col class="bg-green flex-column">
</v-col> </v-col>
<v-col class="bg-yellow">2</v-col> </v-row>
</v-row> </v-col>
</v-col>
</v-row>
</v-col>
<!-- <my-helper :pretext="structures" /> --> <v-row no-gutters>
<!-- <v-col lg="3" v-for="structure in structures" :key="structure"> <v-col lg="4" class="pa-1 w100">
<v-img
class="h-100"
:src="
checkremote(`${spravURL}${x.chief_deps.login}.jpg`)
"
cover
/>
</v-col>
<v-col class="text-center align-self-center text-h6 px-3">
<!-- <v-card-subtitle>
{{x.name}}
<my-helper :pretext="x" />
</v-card-subtitle> -->
{{ x.chief_deps.fio }}
</v-col>
</v-row>
</v-card-text>
</v-card>
</div>
</v-col>
</template>
</structure-inspection-row>
</v-col>
<!-- <v-col lg="3" v-for="structure in structures" :key="structure">
<v-card class="ma-2"> <v-card class="ma-2">
<v-card-item class="bg-teal-lighten-5 text-teal-darken-4 text-h6"> <v-card-item class="bg-teal-lighten-5 text-teal-darken-4 text-h6">
@@ -82,64 +120,58 @@ s
</v-col> --> </v-col> -->
</v-row> </v-row>
</div>
</template> </template>
<script> <script>
import { ref } from 'vue' import { ref } from "vue";
import { spravURL } from '@/utils/axios-api' import { spravURL } from "@/utils/axios-api";
import { checkremote } from '@/utils/universal_functions' import { checkremote } from "@/utils/universal_functions";
import { axiosApiInstance } from '@/utils/axios-api' import { axiosApiInstance } from "@/utils/axios-api";
import StructureInspectionRow from "./StructureInspectionRow.vue";
export default { export default {
setup() { components: { StructureInspectionRow },
const structures = ref([]) setup() {
const structures = ref([]);
const getStructure = () => { const getStructure = () => {
axiosApiInstance.get('api/about_inspection/getstructure/').then(res => { axiosApiInstance.get("api/about_inspection/getstructure/").then((res) => {
structures.value = res.data structures.value = res.data;
console.log(structures.value[0].deps) console.log(structures.value, "-----------");
}) });
};
} getStructure();
return {
getStructure() structures,
return { checkremote,
structures, spravURL,
checkremote, };
spravURL },
} };
}
}
</script> </script>
<style> <style>
.deps-title { .deps-title {
height: 90px; height: 90px;
} }
.rotate-text { .rotate-text {
transform: rotate(-90deg); transform: rotate(-90deg);
} }
.page_block { .page_block {
margin:0px; margin: 0px;
padding:10px; padding: 10px;
} }
#header {
position: relative; /* .container {
} text-align: center;
.verticaltext { background: #fdd835;
transform: rotate(-90deg); } */
transform-origin: right, top;
-ms-transform: rotate(-90deg); .minh {
-ms-transform-origin:right, top; min-height: 43px;
-webkit-transform: rotate(-90deg);
-webkit-transform-origin:right, top;
position: absolute;
color: #ed217c;
right: 0%;
} }
</style> </style>
@@ -0,0 +1,48 @@
<template>
<v-row no-gutters class="h-100">
<v-col class="align-self-center flex-grow-0">
<span class="vertext text-button my-1 pb-13">{{ sText }}</span>
</v-col>
<v-col class="w100">
<v-row no-gutters class="text-center text-button py-2" v-if="sText=='Руковдство'">
<v-col lg="3">Начальник инспекции</v-col>
<v-col>Заместители начальника инспекции</v-col>
</v-row>
<v-row no-gutters class="text-center text-button py-2" v-else>
<v-col> Координируемые структурные подразделения</v-col>
</v-row>
<v-row no-gutters class="h-100">
<slot name="cardboss"></slot>
</v-row>
</v-col>
</v-row>
</template>
<script>
import { spravURL } from "@/utils/axios-api";
import { checkremote } from "@/utils/universal_functions";
export default {
props: {
sText: {
type: String,
default: "",
},
},
setup() {
return {
checkremote,
spravURL,
};
},
};
</script>
<style>
.vertext {
writing-mode: vertical-rl;
transform: rotate(180deg);
}
</style>