From 2ccf8903f84ff67e88d7b8503e62179dcd9e56b9 Mon Sep 17 00:00:00 2001
From: iriska-gri <79623434+iriska-gri@users.noreply.github.com>
Date: Thu, 14 Dec 2023 16:58:34 +0300
Subject: [PATCH] =?UTF-8?q?=D0=9E=D1=82=D0=BA=D1=80=D1=8B=D1=82=D0=B8?=
=?UTF-8?q?=D0=B5=20=D0=B1=D0=BE=D0=BB=D1=8C=D1=88=D0=BE=D0=B9=20=D0=BA?=
=?UTF-8?q?=D0=B0=D1=80=D1=82=D0=B8=D0=BD=D0=BA=D0=B8?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
src/front/src/components/news-full.vue | 81 ++++++++++++++++----------
1 file changed, 51 insertions(+), 30 deletions(-)
diff --git a/src/front/src/components/news-full.vue b/src/front/src/components/news-full.vue
index 1ae7a6ff0..5265fe238 100644
--- a/src/front/src/components/news-full.vue
+++ b/src/front/src/components/news-full.vue
@@ -60,12 +60,16 @@
+
+
@@ -397,6 +401,42 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
@@ -425,6 +465,7 @@ export default {
const route = useRoute()
const newsFull=ref([])
const gallery = ref(false)
+
const burl = baseURL.slice(0,-1)
const loadNews = () => {
@@ -494,6 +535,7 @@ export default {
// ------------------------------ Галерея
const galleryimges=ref([])
const dialogfoto = ref(false)
+ const dialogfotoOne = ref(false)
const indximg = ref('')
const openImg = (idimg) => {
@@ -501,6 +543,13 @@ export default {
indximg.value = newsFull.value.gallery.findIndex(e=>e.id == idimg)
}
+ const openOneImg = (idimg) => {
+ dialogfotoOne.value = true
+ galleryimges.value = idimg
+ console.log(idimg);
+
+ }
+
watch(()=>indximg ,(newValue,oldValue)=>{
if(newValue){
galleryimges.value = newsFull.value.gallery[newValue.value]
@@ -535,36 +584,7 @@ export default {
}
- const downloadimg = (idimg) => {
- console.log(burl+idimg)
- const link = document.createElement('a');
-
- // link.href = burl+idimg
- // link.setAttribute('download', 'file.jpg'); //or any other extension
- // document.body.appendChild(link);
- // link.click();
- // let link = document.createElement("a")
-
- // link.href = burl+idimg
- // link.setAttribute("download", "image.jpeg");
- // document.body.appendChild(link);
- // link.download ='img.jpeg'
- // link.download('img.jpeg')
- // console.log(burl+idimg,'22222222222222222');
- // link.remove()
-
- }
-
-
- // const excelOp = (ex) => {
- // axiosApiInstance.get(`api/general_vacation/dailyroundup/?excel=${ex}`).then(result => {
- // let link = document.createElement("a")
- // link.href = baseURL+result.data.path
- // link.click()
- // link.remove()
- // })
- // }
return {
route,
newsFull,
@@ -588,7 +608,8 @@ export default {
galleryimges,
indximg,
toggleIncrementLike,
- downloadimg
+ openOneImg,
+ dialogfotoOne
}
}