Compare commits
1 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
| fa96ab86b1 |
Generated
-31
@@ -2231,37 +2231,6 @@
|
|||||||
"integrity": "sha512-3YDiu347mtVtjpyV3u5kVqQLP242c06zwDOgpeRnybmXlYYsLbtTrUBUm8i8srONt+FWobl5aibnU1030PeeuA==",
|
"integrity": "sha512-3YDiu347mtVtjpyV3u5kVqQLP242c06zwDOgpeRnybmXlYYsLbtTrUBUm8i8srONt+FWobl5aibnU1030PeeuA==",
|
||||||
"dev": true
|
"dev": true
|
||||||
},
|
},
|
||||||
"axios": {
|
|
||||||
"version": "0.19.2",
|
|
||||||
"resolved": "https://registry.npmjs.org/axios/-/axios-0.19.2.tgz",
|
|
||||||
"integrity": "sha512-fjgm5MvRHLhx+osE2xoekY70AhARk3a6hkN+3Io1jc00jtquGvxYlKlsFUhmUET0V5te6CcZI7lcv2Ym61mjHA==",
|
|
||||||
"requires": {
|
|
||||||
"follow-redirects": "1.5.10"
|
|
||||||
},
|
|
||||||
"dependencies": {
|
|
||||||
"debug": {
|
|
||||||
"version": "3.1.0",
|
|
||||||
"resolved": "https://registry.npmjs.org/debug/-/debug-3.1.0.tgz",
|
|
||||||
"integrity": "sha512-OX8XqP7/1a9cqkxYw2yXss15f26NKWBpDXQd0/uK/KPqdQhxbPa994hnzjcE2VqQpDslf55723cKPUOGSmMY3g==",
|
|
||||||
"requires": {
|
|
||||||
"ms": "2.0.0"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"follow-redirects": {
|
|
||||||
"version": "1.5.10",
|
|
||||||
"resolved": "https://registry.npmjs.org/follow-redirects/-/follow-redirects-1.5.10.tgz",
|
|
||||||
"integrity": "sha512-0V5l4Cizzvqt5D44aTXbFZz+FtyXV1vrDN6qrelxtfYQKW0KO0W2T/hkE8xvGa/540LkZlkaUjO4ailYTFtHVQ==",
|
|
||||||
"requires": {
|
|
||||||
"debug": "=3.1.0"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"ms": {
|
|
||||||
"version": "2.0.0",
|
|
||||||
"resolved": "https://registry.npmjs.org/ms/-/ms-2.0.0.tgz",
|
|
||||||
"integrity": "sha1-VgiurfwAvmwpAd9fmGF4jeDVl8g="
|
|
||||||
}
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"babel-eslint": {
|
"babel-eslint": {
|
||||||
"version": "10.1.0",
|
"version": "10.1.0",
|
||||||
"resolved": "https://registry.npmjs.org/babel-eslint/-/babel-eslint-10.1.0.tgz",
|
"resolved": "https://registry.npmjs.org/babel-eslint/-/babel-eslint-10.1.0.tgz",
|
||||||
|
|||||||
@@ -8,7 +8,6 @@
|
|||||||
"lint": "vue-cli-service lint"
|
"lint": "vue-cli-service lint"
|
||||||
},
|
},
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"axios": "^0.19.2",
|
|
||||||
"bootstrap": "^4.5.2",
|
"bootstrap": "^4.5.2",
|
||||||
"core-js": "^3.6.5",
|
"core-js": "^3.6.5",
|
||||||
"jquery": "^3.5.1",
|
"jquery": "^3.5.1",
|
||||||
|
|||||||
Binary file not shown.
|
Before Width: | Height: | Size: 278 KiB |
Binary file not shown.
|
Before Width: | Height: | Size: 278 KiB |
+2
-2
@@ -4,8 +4,8 @@
|
|||||||
<meta charset="utf-8">
|
<meta charset="utf-8">
|
||||||
<meta http-equiv="X-UA-Compatible" content="IE=edge">
|
<meta http-equiv="X-UA-Compatible" content="IE=edge">
|
||||||
<meta name="viewport" content="width=device-width,initial-scale=1.0">
|
<meta name="viewport" content="width=device-width,initial-scale=1.0">
|
||||||
<link rel="shortcut icon" type="image/png" href="assets/icono.png">
|
<link rel="icon" href="<%= BASE_URL %>favicon.ico">
|
||||||
<title>Portal Editorial Acatlán</title>
|
<title><%= htmlWebpackPlugin.options.title %></title>
|
||||||
</head>
|
</head>
|
||||||
<body>
|
<body>
|
||||||
<noscript>
|
<noscript>
|
||||||
|
|||||||
+32
-29
@@ -7,13 +7,27 @@
|
|||||||
>
|
>
|
||||||
<div class="carousel-inner">
|
<div class="carousel-inner">
|
||||||
<div
|
<div
|
||||||
class="carousel-item"
|
class="carousel-item "
|
||||||
v-bind:key="libro.id"
|
v-bind:key="libro.id"
|
||||||
v-for="(libro, idx) in Libros"
|
v-for="(libro, idx) in Libros"
|
||||||
:class="{ active: idx == 0 }"
|
:class="{ active: idx == 0 }"
|
||||||
>
|
>
|
||||||
<img :src="libro.img" class="d-block w-100 img-fluid" alt="img" />
|
<img :src="libro.img" class="d-block w-100 img-fluid" alt="img" />
|
||||||
</div>
|
</div>
|
||||||
|
<!-- <div class="carousel-item">
|
||||||
|
<img
|
||||||
|
src="https://www.unam.mx/sites/default/files/images/carrusel/bannermxok.jpg"
|
||||||
|
class="d-block w-100 img-fluid"
|
||||||
|
alt="img"
|
||||||
|
/>
|
||||||
|
</div>
|
||||||
|
<div class="carousel-item">
|
||||||
|
<img
|
||||||
|
src="https://www.unam.mx/sites/default/files/images/carrusel/bannermxok.jpg"
|
||||||
|
class="d-block w-100 img-fluid"
|
||||||
|
alt="img"
|
||||||
|
/>
|
||||||
|
</div> -->
|
||||||
</div>
|
</div>
|
||||||
<a
|
<a
|
||||||
class="carousel-control-prev"
|
class="carousel-control-prev"
|
||||||
@@ -38,38 +52,27 @@
|
|||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script>
|
<script>
|
||||||
import axios from "axios";
|
|
||||||
import config from "../config/config.js";
|
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
Libros: []
|
Libros: [
|
||||||
|
{
|
||||||
|
id: 0,
|
||||||
|
img:
|
||||||
|
"https://www.unam.mx/sites/default/files/images/carrusel/bannermxok.jpg"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
id: 1,
|
||||||
|
img:
|
||||||
|
"https://www.unam.mx/sites/default/files/images/carrusel/bannermxok.jpg"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
id: 2,
|
||||||
|
img:
|
||||||
|
"https://www.unam.mx/sites/default/files/images/carrusel/bannermxok.jpg"
|
||||||
|
}
|
||||||
|
]
|
||||||
};
|
};
|
||||||
},
|
|
||||||
async created() {
|
|
||||||
try {
|
|
||||||
let nombres = await axios.get(`${config.api}/nombreCarrusel`);
|
|
||||||
nombres = nombres.data.data;
|
|
||||||
for (let i = 0; i < nombres.length; i++) {
|
|
||||||
console.log(` Este es el nombre ${nombres[i]}`);
|
|
||||||
let config = {
|
|
||||||
// example url
|
|
||||||
url: `http://localhost:3000/imagenCarrusel?nombre=${nombres[i]}`,
|
|
||||||
method: "GET",
|
|
||||||
responseType: "blob"
|
|
||||||
};
|
|
||||||
await axios(config).then(response => {
|
|
||||||
let reader = new FileReader();
|
|
||||||
reader.readAsDataURL(response.data);
|
|
||||||
reader.onload = () => {
|
|
||||||
this.Libros.push({ id: i, img: reader.result });
|
|
||||||
};
|
|
||||||
});
|
|
||||||
}
|
|
||||||
} catch (error) {
|
|
||||||
console.log(`Ocurrio un error msj: ${error}`);
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
</script>
|
</script>
|
||||||
|
|||||||
@@ -21,43 +21,96 @@
|
|||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script>
|
<script>
|
||||||
import axios from "axios";
|
|
||||||
import config from "../config/config.js";
|
|
||||||
export default {
|
export default {
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
Libros: []
|
Libros: [
|
||||||
|
{
|
||||||
|
id: 0,
|
||||||
|
title:
|
||||||
|
"Some quick example text to build on the card title and make up the bulk of the cards content.",
|
||||||
|
img:
|
||||||
|
"https://edit.org/img/blog/xwdn-editar-portadas-de-libros-gratis.jpg.pagespeed.ic.PmNhyGc59r.jpg"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
id: 1,
|
||||||
|
title:
|
||||||
|
"Some quick example text to build on the card title and make up the bulk of the cards content.",
|
||||||
|
img:
|
||||||
|
"https://edit.org/img/blog/xwdn-editar-portadas-de-libros-gratis.jpg.pagespeed.ic.PmNhyGc59r.jpg"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
id: 1,
|
||||||
|
title:
|
||||||
|
"Some quick example text to build on the card title and make up the bulk of the cards content.",
|
||||||
|
img:
|
||||||
|
"https://edit.org/img/blog/xwdn-editar-portadas-de-libros-gratis.jpg.pagespeed.ic.PmNhyGc59r.jpg"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
id: 1,
|
||||||
|
title:
|
||||||
|
"Some quick example text to build on the card title and make up the bulk of the cards content.",
|
||||||
|
img:
|
||||||
|
"https://edit.org/img/blog/xwdn-editar-portadas-de-libros-gratis.jpg.pagespeed.ic.PmNhyGc59r.jpg"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
id: 1,
|
||||||
|
title:
|
||||||
|
"Some quick example text to build on the card title and make up the bulk of the cards content.",
|
||||||
|
img:
|
||||||
|
"https://edit.org/img/blog/xwdn-editar-portadas-de-libros-gratis.jpg.pagespeed.ic.PmNhyGc59r.jpg"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
id: 0,
|
||||||
|
title:
|
||||||
|
"Some quick example text to build on the card title and make up the bulk of the cards content.",
|
||||||
|
img:
|
||||||
|
"https://edit.org/img/blog/xwdn-editar-portadas-de-libros-gratis.jpg.pagespeed.ic.PmNhyGc59r.jpg"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
id: 1,
|
||||||
|
title:
|
||||||
|
"Some quick example text to build on the card title and make up the bulk of the cards content.",
|
||||||
|
img:
|
||||||
|
"https://edit.org/img/blog/xwdn-editar-portadas-de-libros-gratis.jpg.pagespeed.ic.PmNhyGc59r.jpg"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
id: 1,
|
||||||
|
title:
|
||||||
|
"Some quick example text to build on the card title and make up the bulk of the cards content.",
|
||||||
|
img:
|
||||||
|
"https://edit.org/img/blog/xwdn-editar-portadas-de-libros-gratis.jpg.pagespeed.ic.PmNhyGc59r.jpg"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
id: 1,
|
||||||
|
title:
|
||||||
|
"Some quick example text to build on the card title and make up the bulk of the cards content.",
|
||||||
|
img:
|
||||||
|
"https://edit.org/img/blog/xwdn-editar-portadas-de-libros-gratis.jpg.pagespeed.ic.PmNhyGc59r.jpg"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
id: 1,
|
||||||
|
title:
|
||||||
|
"Some quick example text to build on the card title and make up the bulk of the cards content.",
|
||||||
|
img:
|
||||||
|
"https://edit.org/img/blog/xwdn-editar-portadas-de-libros-gratis.jpg.pagespeed.ic.PmNhyGc59r.jpg"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
id: 1,
|
||||||
|
title:
|
||||||
|
"Some quick example text to build on the card title and make up the bulk of the cards content.",
|
||||||
|
img:
|
||||||
|
"https://edit.org/img/blog/xwdn-editar-portadas-de-libros-gratis.jpg.pagespeed.ic.PmNhyGc59r.jpg"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
id: 1,
|
||||||
|
title:
|
||||||
|
"Some quick example text to build on the card title and make up the bulk of the cards content.",
|
||||||
|
img:
|
||||||
|
"https://edit.org/img/blog/xwdn-editar-portadas-de-libros-gratis.jpg.pagespeed.ic.PmNhyGc59r.jpg"
|
||||||
|
}
|
||||||
|
]
|
||||||
};
|
};
|
||||||
},
|
|
||||||
async created() {
|
|
||||||
try {
|
|
||||||
let novedades = await axios.get(`${config.api}/librosNovedades`);
|
|
||||||
novedades = novedades.data.data;
|
|
||||||
console.log(`${novedades}`);
|
|
||||||
for (let i = 0; i < novedades.length; i++) {
|
|
||||||
//alert(novedades[i].titulo);
|
|
||||||
//this.Libros[i].title = novedades[i].titulo;
|
|
||||||
let config = {
|
|
||||||
// example url
|
|
||||||
url: `http://localhost:3000/libroImagen?idLibro=${(i % 3) + 1}`,
|
|
||||||
method: "GET",
|
|
||||||
responseType: "blob"
|
|
||||||
};
|
|
||||||
await axios(config).then(response => {
|
|
||||||
let reader = new FileReader();
|
|
||||||
reader.readAsDataURL(response.data);
|
|
||||||
reader.onload = () => {
|
|
||||||
this.Libros.push({
|
|
||||||
id: i,
|
|
||||||
title: novedades[i].titulo,
|
|
||||||
img: reader.result
|
|
||||||
});
|
|
||||||
};
|
|
||||||
});
|
|
||||||
}
|
|
||||||
} catch (error) {
|
|
||||||
console.log(`Ocurrio un error ${error}`);
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
</script>
|
</script>
|
||||||
|
|||||||
@@ -2,7 +2,7 @@
|
|||||||
<div class="container">
|
<div class="container">
|
||||||
<div class="row ">
|
<div class="row ">
|
||||||
<div class="col-md-6 col-sm-12 py-5">
|
<div class="col-md-6 col-sm-12 py-5">
|
||||||
<img :src="src" alt="" class="libro" />
|
<img v-bind:src="rutaIm" class="libro" />
|
||||||
<button class="button pre">
|
<button class="button pre">
|
||||||
Previsualizar</button
|
Previsualizar</button
|
||||||
><br /><br />
|
><br /><br />
|
||||||
@@ -78,8 +78,6 @@
|
|||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script>
|
<script>
|
||||||
import axios from "axios";
|
|
||||||
import config from "../config/config.js";
|
|
||||||
import Title from "../components/titulo.vue";
|
import Title from "../components/titulo.vue";
|
||||||
export default {
|
export default {
|
||||||
components: {
|
components: {
|
||||||
@@ -88,105 +86,41 @@ export default {
|
|||||||
|
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
idLibro: "",
|
titulo: "Competitive programing",
|
||||||
titulo: "",
|
autor: "HALIM",
|
||||||
autor: "",
|
paginas: "300",
|
||||||
paginas: "",
|
isbn: "POSF-12-43",
|
||||||
isbn: "",
|
edicion: "Primera edicion",
|
||||||
edicion: "",
|
precio: "$3232.00",
|
||||||
precio: "",
|
rutaIm:
|
||||||
src: "",
|
"https://edit.org/img/blog/xwdn-editar-portadas-de-libros-gratis.jpg.pagespeed.ic.PmNhyGc59r.jpg",
|
||||||
version: "",
|
version: "Electronica",
|
||||||
desc: ``,
|
desc: `En relación al estudio del álgebra, las expresiones algebraicas son el conjunto de números, y por símbolos representados por letras que manifiestan un valor desconocido, siendo llamado como incógnita o variable.\n\nLos símbolos se encuentran relacionados a través de signos que indican las operaciones que se necesitan efectuar, bien sea multiplicación, suma, resta, entre otros, con el objetivo de conseguir el resultado de las variables. En este sentido, los términos se distinguen o separan por medio de signos, y en el caso de estar separadas por el signo de igualdad se llama ecuación.`,
|
||||||
boton2: "",
|
boton2: "Comprar",
|
||||||
categoria: "",
|
|
||||||
Libros: [
|
Libros: [
|
||||||
{
|
{
|
||||||
id: 0,
|
id: 0,
|
||||||
title: "",
|
title:
|
||||||
img: ""
|
"Some quick example text to build on the card title and make up the bulk of the cards content.",
|
||||||
|
img:
|
||||||
|
"https://edit.org/img/blog/xwdn-editar-portadas-de-libros-gratis.jpg.pagespeed.ic.PmNhyGc59r.jpg"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
id: 1,
|
id: 1,
|
||||||
title: "",
|
title:
|
||||||
img: ""
|
"Some quick example text to build on the card title and make up the bulk of the cards content.",
|
||||||
|
img:
|
||||||
|
"https://edit.org/img/blog/xwdn-editar-portadas-de-libros-gratis.jpg.pagespeed.ic.PmNhyGc59r.jpg"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
id: 1,
|
id: 1,
|
||||||
title: "",
|
title:
|
||||||
img: ""
|
"Some quick example text to build on the card title and make up the bulk of the cards content.",
|
||||||
|
img:
|
||||||
|
"https://edit.org/img/blog/xwdn-editar-portadas-de-libros-gratis.jpg.pagespeed.ic.PmNhyGc59r.jpg"
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
};
|
};
|
||||||
},
|
|
||||||
async created() {
|
|
||||||
try {
|
|
||||||
//this.idLibro = window.localStorage.getItem("idLibro");
|
|
||||||
this.idLibro = 1;
|
|
||||||
|
|
||||||
let detalle = await axios.get(
|
|
||||||
`${config.api}/libroDetalle?idLibro=${this.idLibro}`
|
|
||||||
);
|
|
||||||
|
|
||||||
detalle = await detalle.data.datos;
|
|
||||||
|
|
||||||
this.titulo = detalle.titulo;
|
|
||||||
this.autor = detalle.autor;
|
|
||||||
this.paginas = detalle.paginas;
|
|
||||||
this.isbn = detalle.isbn;
|
|
||||||
this.edicion = detalle.impresion;
|
|
||||||
this.precio = detalle.precio;
|
|
||||||
this.version = detalle.version;
|
|
||||||
this.desc = detalle.descripcion;
|
|
||||||
this.categoria = detalle.categoria;
|
|
||||||
if (detalle.precio !== "Gratis") this.boton2 = "Comprar";
|
|
||||||
else this.boton2 = "Descargar";
|
|
||||||
} catch (error) {
|
|
||||||
console.log(error);
|
|
||||||
}
|
|
||||||
|
|
||||||
try {
|
|
||||||
let config = {
|
|
||||||
// example url
|
|
||||||
url: `http://localhost:3000/libroImagen?idLibro=${this.idLibro}`,
|
|
||||||
method: "GET",
|
|
||||||
responseType: "blob"
|
|
||||||
};
|
|
||||||
await axios(config).then(response => {
|
|
||||||
let reader = new FileReader();
|
|
||||||
reader.readAsDataURL(response.data);
|
|
||||||
reader.onload = () => {
|
|
||||||
this.src = reader.result;
|
|
||||||
};
|
|
||||||
});
|
|
||||||
} catch (error) {
|
|
||||||
console.log(error);
|
|
||||||
}
|
|
||||||
try {
|
|
||||||
let similares = await axios.get(
|
|
||||||
`${config.api}/librosSimilares?categoria=${this.categoria}`
|
|
||||||
);
|
|
||||||
similares = similares.data.data;
|
|
||||||
console.log(`${similares}`);
|
|
||||||
for (let i = 0; i < similares.length; i++) {
|
|
||||||
this.Libros[i].title = similares[i].titulo;
|
|
||||||
let config = {
|
|
||||||
// example url
|
|
||||||
url: `http://localhost:3000/libroImagen?idLibro=${i + 2}`,
|
|
||||||
method: "GET",
|
|
||||||
responseType: "blob"
|
|
||||||
};
|
|
||||||
await axios(config).then(response => {
|
|
||||||
let reader = new FileReader();
|
|
||||||
reader.readAsDataURL(response.data);
|
|
||||||
reader.onload = () => {
|
|
||||||
this.Libros[i].img = reader.result;
|
|
||||||
};
|
|
||||||
});
|
|
||||||
}
|
|
||||||
} catch (error) {
|
|
||||||
console.log(`Ocurrio un error ${error}`);
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
</script>
|
</script>
|
||||||
|
|||||||
@@ -1,5 +0,0 @@
|
|||||||
const config = {
|
|
||||||
api: "http://localhost:3000"
|
|
||||||
//api: "https://venus.acatlan.unam.mx/indiana_hackaton"
|
|
||||||
};
|
|
||||||
module.exports = config;
|
|
||||||
+27
-21
@@ -81,34 +81,39 @@
|
|||||||
v-if="isExist"
|
v-if="isExist"
|
||||||
class="form-inline my-0 my-lg-0 buscador col-4 d-flex justify-content-end"
|
class="form-inline my-0 my-lg-0 buscador col-4 d-flex justify-content-end"
|
||||||
>
|
>
|
||||||
<div class="input-group input-group-sm mb-0">
|
<div class="input-group input-group-sm mb-0 ver">
|
||||||
<input
|
<input
|
||||||
type="text"
|
type="text"
|
||||||
class="form-control reIzq "
|
class="form-control reIzq "
|
||||||
placeholder="Buscar"
|
placeholder="Buscar"
|
||||||
|
v-model="search"
|
||||||
aria-label="Recipient's username"
|
aria-label="Recipient's username"
|
||||||
aria-describedby="basic-addon2"
|
aria-describedby="basic-addon2"
|
||||||
/>
|
/>
|
||||||
<div class="input-group-append reDer bg-white">
|
<div class="input-group-append reDer bg-white">
|
||||||
<button class="btn my-0" type="submit">
|
<router-link
|
||||||
<svg
|
:to="{ name: 'search', params: { searchProp: search } }"
|
||||||
width="1em"
|
>
|
||||||
height="1em"
|
<button class="btn my-0" type="submit">
|
||||||
viewBox="0 0 16 16"
|
<svg
|
||||||
class="bi bi-search blanco"
|
width="1em"
|
||||||
fill="currentColor"
|
height="1em"
|
||||||
xmlns="http://www.w3.org/2000/svg"
|
viewBox="0 0 16 16"
|
||||||
>
|
class="bi bi-search blanco"
|
||||||
<path
|
fill="currentColor"
|
||||||
fill-rule="evenodd"
|
xmlns="http://www.w3.org/2000/svg"
|
||||||
d="M10.442 10.442a1 1 0 0 1 1.415 0l3.85 3.85a1 1 0 0 1-1.414 1.415l-3.85-3.85a1 1 0 0 1 0-1.415z"
|
>
|
||||||
/>
|
<path
|
||||||
<path
|
fill-rule="evenodd"
|
||||||
fill-rule="evenodd"
|
d="M10.442 10.442a1 1 0 0 1 1.415 0l3.85 3.85a1 1 0 0 1-1.414 1.415l-3.85-3.85a1 1 0 0 1 0-1.415z"
|
||||||
d="M6.5 12a5.5 5.5 0 1 0 0-11 5.5 5.5 0 0 0 0 11zM13 6.5a6.5 6.5 0 1 1-13 0 6.5 6.5 0 0 1 13 0z"
|
/>
|
||||||
/>
|
<path
|
||||||
</svg>
|
fill-rule="evenodd"
|
||||||
</button>
|
d="M6.5 12a5.5 5.5 0 1 0 0-11 5.5 5.5 0 0 0 0 11zM13 6.5a6.5 6.5 0 1 1-13 0 6.5 6.5 0 0 1 13 0z"
|
||||||
|
/>
|
||||||
|
</svg>
|
||||||
|
</button>
|
||||||
|
</router-link>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</form>
|
</form>
|
||||||
@@ -121,7 +126,8 @@
|
|||||||
export default {
|
export default {
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
isExist: true
|
isExist: true,
|
||||||
|
search: ""
|
||||||
};
|
};
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
|
|||||||
+2
-2
@@ -2,12 +2,12 @@ import home from "./view/home.vue";
|
|||||||
import login from "./view/login.vue";
|
import login from "./view/login.vue";
|
||||||
import libroDescripcion from "./view/libroDescripcion.vue";
|
import libroDescripcion from "./view/libroDescripcion.vue";
|
||||||
import difusion from "./view/difusion.vue";
|
import difusion from "./view/difusion.vue";
|
||||||
import lineamientos from "./view/lineamiento.vue";
|
import search from "./view/search.vue";
|
||||||
|
|
||||||
export const routes = [
|
export const routes = [
|
||||||
{ path: "/", component: home, name: "form" },
|
{ path: "/", component: home, name: "form" },
|
||||||
{ path: "/login", component: login, name: "Login" },
|
{ path: "/login", component: login, name: "Login" },
|
||||||
{ path: "/desc", component: libroDescripcion, name: "LibroDesc" },
|
{ path: "/desc", component: libroDescripcion, name: "LibroDesc" },
|
||||||
{ path: "/difusion", component: difusion, name: "difusion" },
|
{ path: "/difusion", component: difusion, name: "difusion" },
|
||||||
{ path: "/lineamientos", component: lineamientos, name: "lineamientos" }
|
{ path: "/search", component: search, name: "search", props: true }
|
||||||
];
|
];
|
||||||
|
|||||||
@@ -11,7 +11,7 @@
|
|||||||
|
|
||||||
<script>
|
<script>
|
||||||
import Header from "./../components/header.vue";
|
import Header from "./../components/header.vue";
|
||||||
import Nav from "./../esteticas/nav.vue";
|
import Nav from "./../components/navPrincipal.vue";
|
||||||
import Descrip from "./../components/descripcion.vue";
|
import Descrip from "./../components/descripcion.vue";
|
||||||
import Footer from "./../components/footer.vue";
|
import Footer from "./../components/footer.vue";
|
||||||
|
|
||||||
|
|||||||
File diff suppressed because it is too large
Load Diff
@@ -0,0 +1,121 @@
|
|||||||
|
<template>
|
||||||
|
<div>
|
||||||
|
<Header></Header>
|
||||||
|
<Nav></Nav>
|
||||||
|
|
||||||
|
<!-- <div class="wrapper">
|
||||||
|
<div class="card" v-bind:key="post.id" v-for="post in filteredList">
|
||||||
|
<a v-bind:href="post.link" ta rget="_blank">
|
||||||
|
<img v-bind:src="post.img" width="45px" />
|
||||||
|
<small>posted by: {{ post.title }}</small>
|
||||||
|
{{ post.title }}
|
||||||
|
</a>
|
||||||
|
</div>
|
||||||
|
</div> -->
|
||||||
|
|
||||||
|
<div class="search-wrapper m-4">
|
||||||
|
<input type="text" v-model="searchProp" placeholder="buscar libro" />
|
||||||
|
</div>
|
||||||
|
<div v-if="searchProp">
|
||||||
|
<Title title="Resultados" />
|
||||||
|
|
||||||
|
<div class="divMaster row mb-5">
|
||||||
|
<div class="col-10 offset-1 d-flex flex-wrap justify-content-center">
|
||||||
|
<div
|
||||||
|
class="card m-3"
|
||||||
|
style="width: 12rem;"
|
||||||
|
v-bind:key="post.id"
|
||||||
|
v-for="post in ListaFiltrada"
|
||||||
|
>
|
||||||
|
<router-link :to="{ path: 'home' }" class="textt">
|
||||||
|
<img :src="post.img" class="card-img-top rounded" alt="libro" />
|
||||||
|
<div class="card-body cd textt">
|
||||||
|
<p class="card-text textt">
|
||||||
|
{{ post.title }}
|
||||||
|
</p>
|
||||||
|
</div>
|
||||||
|
</router-link>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div v-else>
|
||||||
|
<h1>Ingresa un Titulo en el buscador</h1>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<Footer></Footer>
|
||||||
|
</div>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<script>
|
||||||
|
import Header from "./../components/header.vue";
|
||||||
|
import Nav from "./../esteticas/nav.vue";
|
||||||
|
//import Nav from "./../components/navPrincipal.vue";
|
||||||
|
import Footer from "./../components/footer.vue";
|
||||||
|
import Title from "../components/titulo.vue";
|
||||||
|
|
||||||
|
export default {
|
||||||
|
props: ["searchProp"],
|
||||||
|
components: {
|
||||||
|
Header,
|
||||||
|
Nav,
|
||||||
|
Footer,
|
||||||
|
Title
|
||||||
|
},
|
||||||
|
data() {
|
||||||
|
return {
|
||||||
|
search: "",
|
||||||
|
postLista: [
|
||||||
|
{
|
||||||
|
id: 0,
|
||||||
|
title: "titu",
|
||||||
|
img:
|
||||||
|
"https://edit.org/img/blog/xwdn-editar-portadas-de-libros-gratis.jpg.pagespeed.ic.PmNhyGc59r.jpg"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
id: 0,
|
||||||
|
title: "papa",
|
||||||
|
img:
|
||||||
|
"https://edit.org/img/blog/xwdn-editar-portadas-de-libros-gratis.jpg.pagespeed.ic.PmNhyGc59r.jpg"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
id: 0,
|
||||||
|
title: "titu2",
|
||||||
|
img:
|
||||||
|
"https://edit.org/img/blog/xwdn-editar-portadas-de-libros-gratis.jpg.pagespeed.ic.PmNhyGc59r.jpg"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
id: 0,
|
||||||
|
title: "he",
|
||||||
|
img:
|
||||||
|
"https://edit.org/img/blog/xwdn-editar-portadas-de-libros-gratis.jpg.pagespeed.ic.PmNhyGc59r.jpg"
|
||||||
|
}
|
||||||
|
]
|
||||||
|
};
|
||||||
|
},
|
||||||
|
computed: {
|
||||||
|
ListaFiltrada() {
|
||||||
|
return this.postLista.filter(post => {
|
||||||
|
return post.title.toLowerCase().includes(this.searchProp.toLowerCase());
|
||||||
|
});
|
||||||
|
}
|
||||||
|
}
|
||||||
|
};
|
||||||
|
</script>
|
||||||
|
|
||||||
|
<style scoped>
|
||||||
|
.divMaster {
|
||||||
|
height: auto;
|
||||||
|
}
|
||||||
|
.card {
|
||||||
|
border: none !important;
|
||||||
|
border-bottom: 5px solid #1b3d70 !important;
|
||||||
|
}
|
||||||
|
a {
|
||||||
|
text-decoration: none !important;
|
||||||
|
color: black;
|
||||||
|
}
|
||||||
|
.ver {
|
||||||
|
display: none !important;
|
||||||
|
}
|
||||||
|
</style>
|
||||||
@@ -1,3 +0,0 @@
|
|||||||
module.exports = {
|
|
||||||
publicPath: "./"
|
|
||||||
};
|
|
||||||
Reference in New Issue
Block a user