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

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

No files matched your search

@@ -1,58 +1,96 @@
<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>
<v-col class="bg-yellow">2</v-col> <v-col class="text-center align-self-center text-h6">
</v-row> {{ x.fio }}
</v-col> </v-col>
</v-row> </v-row>
<!-- <v-row> </v-card-text>
<v-col class="bg-green flex-grow-0">2</v-col>
<v-col class="bg-yellow">2</v-col>
</v-row> -->
<!-- <v-row no-gutters class="gap">
<v-col class="flex-grow-0 bg-red">
s
</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-card>
</v-col> </v-col>
</template>
</v-row> --> </structure-inspection-row>
</v-col> </v-col>
<v-col class="bg-green flex-column"> <v-col>
<v-row no-gutters class="h-100"> <structure-inspection-row :sText="'Структурные подразделения'">
<v-col class="w-0 flex-grow-0 text-no-wrap justify-center d-flex flex-column"> <template v-slot:cardboss>
<div class="bg-red verticaltext text-h5">Структурные подразделения</div> <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="flex-column"> <v-col class="flex-grow-0">
<v-row no-gutters class="h-100"> <v-tooltip location="top">
<v-col class="bg-green flex-column"> <template v-slot:activator="{ props }">
<span v-bind="props">
</v-col> <v-icon
<v-col class="bg-yellow">2</v-col> size="large"
color="green"
icon="mdi-arrow-top-right"
/>
</span>
</template>
<v-row>
<v-col> Перейти на страницу отдела </v-col>
</v-row> </v-row>
</v-tooltip>
</v-col> </v-col>
</v-row> </v-row>
</v-col> </v-col>
<!-- <my-helper :pretext="structures" /> --> <v-row no-gutters>
<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-col lg="3" v-for="structure in structures" :key="structure">
<v-card class="ma-2"> <v-card class="ma-2">
@@ -82,37 +120,36 @@ 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 {
components: { StructureInspectionRow },
setup() { setup() {
const structures = ref([]) 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();
getStructure()
return { return {
structures, structures,
checkremote, checkremote,
spravURL spravURL,
} };
} },
};
}
</script> </script>
<style> <style>
@@ -125,21 +162,16 @@ export default {
} }
.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>