PageSourceSearch

https://lalexpo.com/build/assets/AdminHomeSectionsComponent-Cy0MaaOo.js

js lalexpo.com collected 2026-09-24 23:33:43 UTC 18,499 bytes, 68 lines download raw bytes

1import { r as d, o as ie, Z as re, c as u, e as o, I as f, b as i, g as a, u as x, F, C as c, $ as ue, d as l, f as t, h as r, n as ce, W as de, i as pe, t as me, D as fe, U as L } from "./vendor-DwBTsVHv.js";
2import { _ as ve, U as p } from "./app-CVhtgxmC.js";
3import _e from "./CreateSectionHomeAdmin-EQ30G9sf.js";
4import ge from "./EditSectionHomeAdmin-B_ts3v08.js";
5const ye = { class: "ant-table-wrapper ant-table-striped mt-1" }, be = { class: "ant-spin-nested-loading" }, xe = { key: 0 }, he = { class: "ant-table ant-table-scroll-horizontal ant-table-small" }, ke = { class: "ant-table-container" }, we = { class: "ant-table-content", style: { overflow: "auto hidden" } }, ze = { style: { width: "1000px", "min-width": "100%", "table-layout": "auto" } }, Ce = { class: "ant-table-cell" }, Se = ["innerHTML"], Ee = ["innerHTML"], Oe = { class: "ant-table-cell" }, Ne = ["innerHTML"], He = ["innerHTML"], Te = { class: "ant-table-cell" }, Me = { class: "d-flex flex-column" }, Ae = { class: "d-flex align-items-center" }, De = { class: "text-capitalize" }, Le = { class: "d-flex flex-column" }, je = { class: "d-flex align-items-start justify-content-center flex-column" }, Ue = { key: 0 }, Ve = { key: 1 }, $e = { key: 2 }, Be = { key: 3 }, Fe = { key: 4 }, Pe = { key: 5 }, qe = { key: 6 }, Ie = { key: 7 }, Re = { class: "d-flex flex-column" }, Ge = { class: "d-flex justify-content-start" }, Qe = { key: 0, class: "text-primary-lalexpo" }, We = { key: 1, class: "text-primary-lalexpo" }, Ze = { class: "d-flex flex-column" }, Je = { class: "d-flex justify-content-start" }, Ke = { key: 0, class: "text-primary-lalexpo" }, Xe = { key: 1, class: "text-primary-lalexpo" }, Ye = { key: 2, class: "text-primary-lalexpo" }, et = { class: "ant-table-cell" }, tt = { class: "d-flex justify-content-center" }, st = { key: 0, class: "status-outline status-success-outline" }, at = { key: 1, class: "status-outline status-danger-outline" }, lt = { class: "ant-table-cell" }, nt = { class: "d-flex align-items-center justify-content-center" }, ot = { key: 1, class: "ant-table-placeholder" }, it = { key: 0, class: "d-flex justify-content-end mt-2" }, rt = { name: "AdminHomeSectionsComponent" }, ut = Object.assign(rt, { props: ["users"], setup(P) {
6  p.methods.$language();
7  const y = d({ search: null, search_by_status: null, current_page: null, page_size: null }), j = d(false), C = d(false), q = _.debounce(function(n) {
8    j.value = true, (y.value.search.length >= 3 || y.value.search.length === 0) && (z.value = 1, v());
9  }, 500), I = () => {
10    C.value = true, z.value = 1, v();
11  }, N = d(false), v = () => {
12    b.value = true, y.value.current_page = z.value, y.value.page_size = H.value, axios.post(route("admin.home.sections.get_sections_home"), y.value).then((n) => {
13      w.value = n.data.sections, N.value = n.data.slider_primary;
14      const e = { ...g.value };
15      e.total = n.data.total_registers, h.value = n.data.total_registers, g.value = e, b.value = false, C.value = false;
16    }).catch((n) => {
17      b.value = false, C.value = false, console.error(n);
18    });
19  };
20  ie(v);
21  const b = d(false), w = d([]), R = (n) => {
22    const e = { ...g.value };
23    e.current = g.current, g.value = e, z.value = n.current, H.value = n.pageSize, g.value.pageSize = H.value, v();
24  }, g = d({ pageSize: 20, showSizeChanger: true, pageSizeOptions: ["20", "30", "40", "50", "100"], showTotal: (n) => `Total: ${h.value}` }), z = d(1), H = d(20), h = d(0), S = d(false), G = (n) => {
25    n && v();
26  }, E = d(false), U = d({}), Q = (n) => {
27    U.value = n, E.value = true;
28  }, W = (n) => {
29    n && v();
30  }, m = d(false);
31  re(ue, { style: { fontSize: "18px" }, spin: true });
32  const Z = (n) => {
33    m.value = true, axios.post(route("admin.home.sections.update_status_section"), { id: n }).then((e) => {
34      e.data.success ? (p.methods.openNotification("success", "Success", "Secci\xF3n activada correctamente."), v(), m.value = false) : (p.methods.openNotification("error", "Error", "Ha ocurrido un error al procesar la solicitud. Por favor intente m\xE1s tarde."), m.value = false);
35    }).catch((e) => {
36      p.methods.openNotification("error", "Error", e), m.value = false, console.log(e);
37    });
38  }, J = (n) => {
39    m.value = true, axios.post(route("admin.home.sections.update_status_section"), { id: n }).then((e) => {
40      e.data.success ? (p.methods.openNotification("success", "Success", "Secci\xF3n desactivada correctamente."), v(), m.value = false) : (p.methods.openNotification("error", "Error", "Ha ocurrido un error al procesar la solicitud. Por favor intente m\xE1s tarde."), m.value = false);
41    }).catch((e) => {
42      p.methods.openNotification("error", "Error", e), m.value = false, console.log(e);
43    });
44  }, K = (n) => {
45    m.value = true, axios.post(route("admin.home.sections.delete_section_home"), { id: n }).then((e) => {
46      e.data.success ? (p.methods.openNotification("success", "Success", "Secci\xF3n eliminada correctamente."), v(), m.value = false) : (p.methods.openNotification("error", "Error", "Ha ocurrido un error al procesar la solicitud. Por favor intente m\xE1s tarde."), m.value = false);
47    }).catch((e) => {
48      p.methods.openNotification("error", "Error", e), m.value = false, console.log(e);
49    });
50  }, X = (n) => {
51    let e = null;
52    e = w.value.map((T) => T.id), Y(e);
53  }, Y = (n) => {
54    b.value = true, axios.post(route("admin.home.sections.update_order"), { new_order: n }).then((e) => {
55      e.data.success ? p.methods.openNotification("success", "Success", "Orden actualizado.") : p.methods.openNotification("error", "Error", "No se ha actualizado el orden. Por favor intente m\xE1s tarde."), b.value = false;
56    }).catch((e) => {
57      b.value = false, p.methods.openNotification("error", "Error", "Ha ocurrido un error al procesar la solicitud. Por favor intente m\xE1s tarde.");
58    });
59  };
60  return (n, e) => {
61    const T = c("a-badge"), V = c("a-divider"), $ = c("a-button"), M = c("a-select-option"), ee = c("a-select"), te = c("a-input-search"), k = c("a-col"), se = c("a-avatar"), B = c("a-row"), O = c("a-menu-item"), A = c("a-popconfirm"), ae = c("a-menu"), le = c("a-dropdown"), ne = c("a-pagination"), oe = c("a-card");
62    return l(), u(F, null, [o(oe, { bordered: false, style: { width: "100%" } }, { default: a(() => [o(V, { orientation: "left", class: "mt-0 mb-3" }, { default: a(() => [o(T, { class: "mr-icon badge-color-primary mr-4", overflowCount: 99999999, count: h.value }, { default: a(() => e[9] || (e[9] = [t("span", { class: "mr-1" }, "Home Principal: Secciones", -1)])), _: 1, __: [9] }, 8, ["count"]), o(V, { class: "mr-1", type: "vertical" }), o($, { type: "dashed", class: "mr-1", onClick: e[0] || (e[0] = (s) => S.value = true) }, { default: a(() => e[10] || (e[10] = [t("i", { class: "fad fa-object-group mr-icon" }, null, -1), r(" Nueva secci\xF3n ")])), _: 1, __: [10] })]), _: 1 }), o(B, null, { default: a(() => [o(k, { span: 24, class: "table-filters text-right" }, { default: a(() => [o(ee, { value: y.value.search_by_status, "onUpdate:value": e[1] || (e[1] = (s) => y.value.search_by_status = s), style: { "text-align": "center", width: "200px" }, placeholder: "--Seleccione un Estado--", size: "small", class: "mr-1", onChange: I, loading: C.value }, { default: a(() => [o(M, { value: null, "aria-selected": "true" }, { default: a(() => e[11] || (e[11] = [r("--Todos los estados--")])), _: 1, __: [11] }), o(M, { value: 1 }, { default: a(() => e[12] || (e[12] = [r("Activo")])), _: 1, __: [12] }), o(M, { value: 0 }, { default: a(() => e[13] || (e[13] = [r("Inactivo")])), _: 1, __: [13] })]), _: 1 }, 8, ["value", "loading"]), o(te, { value: y.value.search, "onUpdate:value": e[2] || (e[2] = (s) => y.value.search = s), placeholder: "Buscar", size: "small", style: { width: "300px" }, class: "text-left", loading: j.value, onChange: x(q) }, null, 8, ["value", "loading", "onChange"])]), _: 1 }), o(k, { span: 24 }, { default: a(() => [t("div", ye, [t("div", be, [b.value ? (l(), u("div", xe, e[14] || (e[14] = [t("div", { class: "ant-spin ant-spin-spinning" }, [t("span", { class: "ant-spin-dot ant-spin-dot-spin" }, [t("i", { class: "ant-spin-dot-item" }), t("i", { class: "ant-spin-dot-item" }), t("i", { class: "ant-spin-dot-item" }), t("i", { class: "ant-spin-dot-item" })])], -1)]))) : i("", true), t("div", { class: ce(b.value ? "ant-spin-container ant-spin-blur" : "ant-spin-container") }, [t("div", he, [t("div", ke, [t("div", we, [t("table", ze, [e[43] || (e[43] = t("colgroup", null, null, -1)), e[44] || (e[44] = t("thead", { class: "ant-table-thead" }, [t("tr", null, [t("th", { class: "ant-table-cell", style: { width: "35px" } }), t("th", { class: "ant-table-cell" }, "Nombre"), t("th", { class: "ant-table-cell" }, "Sub T\xEDtulo"), t("th", { class: "ant-table-cell" }, "Informaci\xF3n General"), t("th", { class: "ant-table-cell text-center", style: { width: "100px" } }, "Estado"), t("th", { class: "ant-table-cell text-center", style: { width: "100px" } }, "Acciones")])], -1)), o(x(de), { modelValue: w.value, "onUpdate:modelValue": e[4] || (e[4] = (s) => w.value = s), tag: "tbody", class: "ant-table-tbody", onChange: X }, { default: a(() => [h.value > 0 ? (l(true), u(F, { key: 0 }, pe(w.value, (s) => (l(), u("tr", { class: "ant-table-row ant-table-row-level-0", key: s.key }, [e[41] || (e[41] = t("td", { class: "ant-table-cell text-center" }, [t("span", { style: { cursor: "grab" } }, [t("svg", { viewBox: "64 64 896 896", focusable: "false", "data-icon": "holder", width: "1em", height: "1em", fill: "currentColor", "aria-hidden": "true" }, [t("path", { d: "M300 276.5a56 56 0 1056-97 56 56 0 00-56 97zm0 284a56 56 0 1056-97 56 56 0 00-56 97zM640 228a56 56 0 10112 0 56 56 0 00-112 0zm0 284a56 56 0 10112 0 56 56 0 00-112 0zM300 844.5a56 56 0 1056-97 56 56 0 00-56 97zM640 796a56 56 0 10112 0 56 56 0 00-112 0z" })])])], -1)), t("td", Ce, [e[15] || (e[15] = t("small", { class: "text-contrast" }, [r("Espa\xF1ol:"), t("br")], -1)), t("span", { class: "name-format-table", innerHTML: s.name_es }, null, 8, Se), e[16] || (e[16] = t("br", null, null, -1)), e[17] || (e[17] = t("small", { class: "text-contrast" }, [r("Ingl\xE9s:"), t("br")], -1)), t("span", { class: "name-format-table", innerHTML: s.name_en }, null, 8, Ee)]), t("td", Oe, [e[18] || (e[18] = t("small", { class: "text-contrast" }, [r("Espa\xF1ol:"), t("br")], -1)), t("span", { class: "name-format-table", innerHTML: s.name_es }, null, 8, Ne), e[19] || (e[19] = t("br", null, null, -1)), e[20] || (e[20] = t("small", { class: "text-contrast" }, [r("Ingl\xE9s:"), t("br")], -1)), t("span", { class: "name-format-table", innerHTML: s.name_en }, null, 8, He)]), t("td", Te, [o(B, { gutter: [10, 10] }, { default: a(() => [o(k, { xs: 24, sm: 24, md: 8, lg: 8, xl: 8 }, { default: a(() => [t("div", Me, [e[21] || (e[21] = t("small", { class: "d-inline-block text-contrast mb-small" }, "Creado por:", -1)), t("div", Ae, [o(se, { class: "m-0 mr-1", size: 25, src: n.$asset(s.avatar) }, null, 8, ["src"]), t("span", De, me(s.name + " " + s.last_name), 1)])])]), _: 2 }, 1024), s.type === 2 && s.brightness ? (l(), f(k, { key: 0, xs: 24, sm: 24, md: 8, lg: 8, xl: 8 }, { default: a(() => [t("div", Le, [e[30] || (e[30] = t("small", { class: "d-inline-block text-contrast mb-small" }, "Dise\xF1o: ", -1)), t("div", je, [s.brightness === "red.png" ? (l(), u("span", Ue, e[22] || (e[22] = [t("span", { class: "circle-color red" }, null, -1), r(" Rojo (Opci\xF3n One)")]))) : i("", true), s.brightness === "red2.png" ? (l(), u("span", Ve, e[23] || (e[23] = [t("span", { class: "circle-color red" }, null, -1), r(" Rojo (Opci\xF3n Two)")]))) : i("", true), s.brightness === "yellow.png" ? (l(), u("span", $e, e[24] || (e[24] = [t("span", { class: "circle-color yellow-1" }, null, -1), r(" Amarillo (Opci\xF3n One)")]))) : i("", true), s.brightness === "yellow2.png" ? (l(), u("span", Be, e[25] || (e[25] = [t("span", { class: "circle-color yellow-1" }, null, -1), r(" Amarillo (Opci\xF3n Two)")]))) : i("", true), s.brightness === "blue1.png" ? (l(), u("span", Fe, e[26] || (e[26] = [t("span", { class: "circle-color blue-1" }, null, -1), r(" Azul (Opci\xF3n One)")]))) : i("", true), s.brightness === "blue2.png" ? (l(), u("span", Pe, e[27] || (e[27] = [t("span", { class: "circle-color blue-2" }, null, -1), r(" Azul (Opci\xF3n Two)")]))) : i("", true), s.brightness === "white.png" ? (l(), u("span", qe, e[28] || (e[28] = [t("span", { class: "circle-color white" }, null, -1), r(" Blanco")]))) : i("", true), s.brightness === "bronze.png" ? (l(), u("span", Ie, e[29] || (e[29] = [t("span", { class: "circle-color bronze" }, null, -1), r(" Bronze")]))) : i("", true)])])]), _: 2 }, 1024)) : i("", true), s.grid ? (l(), f(k, { key: 1, xs: 24, sm: 24, md: 8, lg: 8, xl: 8 }, { default: a(() => [t("div", Re, [e[31] || (e[31] = t("small", { class: "d-inline-block text-contrast mb-small" }, "Grid: ", -1)), t("div", Ge, [s.grid === "default" ? (l(), u("span", Qe, "Default")) : i("", true), s.grid === "single" ? (l(), u("span", We, "Single")) : i("", true)])])]), _: 2 }, 1024)) : i("", true), s.type ? (l(), f(k, { key: 2, xs: 24, sm: 24, md: 8, lg: 8, xl: 8 }, { default: a(() => [t("div", Ze, [e[32] || (e[32] = t("small", { class: "d-inline-block text-contrast mb-small" }, "Tipo de secci\xF3n: ", -1)), t("div", Je, [s.type === 0 ? (l(), u("span", Ke, "Slider principal")) : i("", true), s.type === 1 ? (l(), u("span", Xe, "Slider")) : i("", true), s.type === 2 ? (l(), u("span", Ye, "Paquete sponsor")) : i("", true)])])]), _: 2 }, 1024)) : i("", true)]), _: 2 }, 1024)]), t("td", et, [t("div", tt, [s.status === 1 ? (l(), u("span", st, "Activo")) : i("", true), s.status === 0 ? (l(), u("span", at, "Inactivo")) : i("", true)])]), t("td", lt, [t("div", nt, [o(le, { trigger: ["click"] }, { overlay: a(() => [o(ae, null, { default: a(() => [(l(), f(O, { key: s.id, onClick: (D) => Q(s) }, { default: a(() => e[33] || (e[33] = [t("i", { class: "fad fa-edit mr-icon text-cyan" }, null, -1), t("span", null, "Editar", -1)])), _: 2, __: [33] }, 1032, ["onClick"])), s.status === 0 ? (l(), f(A, { key: 0, "ok-text": "Activar", "cancel-text": "Cancelar", onConfirm: (D) => Z(s.id), placement: "left" }, { icon: a(() => [o(x(L), { style: { color: "#d89614" } })]), title: a(() => e[34] || (e[34] = [t("p", null, [r("\xBFEst\xE1s seguro que deseas"), t("br"), r(" activar esta secci\xF3n?")], -1)])), default: a(() => [(l(), f(O, { key: s.id, onClick: e[3] || (e[3] = () => {
63    }) }, { default: a(() => e[35] || (e[35] = [t("i", { class: "fad fa-check-circle mr-icon text-green-light" }, null, -1), t("span", null, "Activar", -1)])), _: 2, __: [35] }, 1024))]), _: 2 }, 1032, ["onConfirm"])) : i("", true), s.status === 1 ? (l(), f(A, { key: 1, "ok-text": "Desactivar", "cancel-text": "Cancelar", onConfirm: (D) => J(s.id), placement: "left" }, { icon: a(() => [o(x(L), { style: { color: "#d89614" } })]), title: a(() => e[36] || (e[36] = [t("p", null, [r("\xBFEst\xE1s seguro que deseas"), t("br"), r(" desactivar esta secci\xF3n?")], -1)])), default: a(() => [(l(), f(O, { key: s.id }, { default: a(() => e[37] || (e[37] = [t("i", { class: "fad fa-ban mr-icon text-primary-lalexpo" }, null, -1), t("span", null, "Desactivar", -1)])), _: 2, __: [37] }, 1024))]), _: 2 }, 1032, ["onConfirm"])) : i("", true), o(A, { "ok-text": "Eliminar", "cancel-text": "Cancelar", onConfirm: (D) =>
63 K(s.id), placement: "left" }, { icon: a(() => [o(x(L), { style: { color: "#983539" } })]), title: a(() => e[38] || (e[38] = [t("p", null, [r("\xBFEst\xE1s seguro que deseas"), t("br"), r(" eliminar esta secci\xF3n?")], -1)])), default: a(() => [(l(), f(O, { key: s.id }, { default: a(() => e[39] || (e[39] = [t("i", { class: "fad fa-trash-alt mr-icon text-primary-lalexpo" }, null, -1), t("span", null, "Eliminar", -1)])), _: 2, __: [39] }, 1024))]), _: 2 }, 1032, ["onConfirm"])]), _: 2 }, 1024)]), default: a(() => [o($, null, { default: a(() => [e[40] || (e[40] = t("i", { class: "fad fa-cogs mr-icon" }, null, -1)), o(x(fe))]), _: 1, __: [40] })]), _: 2 }, 1024)])])]))), 128)) : (l(), u("tr", ot, e[42] || (e[42] = [t("td", { colspan: "8", class: "ant-table-cell" }, [t("div", { class: "ant-table-expanded-row-fixed", style: { width: "1556px", position: "sticky", left: "0", overflow: "hidden" } }, [t("div", { class: "ant-empty ant-empty-normal" }, [t("div", { class: "ant-empty-image" }, [t("svg", { class: "ant-empty-img-simple", width: "64", height: "41", viewBox: "0 0 64 41" }, [t("g", { transform: "translate(0 1)", fill: "none", "fill-rule": "evenodd" }, [t("ellipse", { class: "ant-empty-img-simple-ellipse", fill: "#F5F5F5", cx: "32", cy: "33", rx: "32", ry: "7" }), t("g", { class: "ant-empty-img-simple-g", "fill-rule": "nonzero", stroke: "#D9D9D9" }, [t("path", { d: "M55 12.76L44.854 1.258C44.367.474 43.656 0 42.907 0H21.093c-.749 0-1.46.474-1.947 1.257L9 12.761V22h46v-9.24z" }), t("path", { d: "M41.613 15.931c0-1.605.994-2.93 2.227-2.931H55v18.137C55 33.26 53.68 35 52.05 35h-40.1C10.32 35 9 33.259 9 31.137V13h11.16c1.233 0 2.227 1.323 2.227 2.928v.022c0 1.605 1.005 2.901 2.237 2.901h14.752c1.232 0 2.237-1.308 2.237-2.913v-.007z", fill: "#FAFAFA", class: "ant-empty-img-simple-path" })])])])]), t("p", { class: "ant-empty-description" }, "No Data")])])], -1)])))]), _: 1 }, 8, ["modelValue"])])])])])], 2)])]), h.value > 0 ? (l(), u("div", it, [o(ne, { size: "small", current: g.value.current_page, "onUpdate:current": e[5] || (e[5] = (s) => g.value.current_page = s), pageSize: g.value.pageSize, "onUpdate:pageSize": e[6] || (e[6] = (s) => g.value.pageSize = s), total: h.value, "show-total": (s) => `Total: ${h.value}`, pageSizeOptions: ["20", "40", "60", "80", "100"], onChange: R, "show-less-items": "", "show-size-changer": "" }, null, 8, ["current", "pageSize", "total", "show-total"])])) : i("", true)]), _: 1 })]), _: 1 })]), _: 1 }), S.value ? (l(), f(x(_e), { key: 0, "is-open": S.value, "onUpdate:isOpen": e[7] || (e[7] = (s) => S.value = s), onResponseCreateEmit: G, users: P.users, "exist-slider-primary": N.value }, null, 8, ["is-open", "users", "exist-slider-primary"])) : i("", true), E.value ? (l(), f(x(ge), { key: 1, "is-open-edit": E.value, "onUpdate:isOpenEdit": e[8] || (e[8] = (s) => E.value = s), onResponseEditEmit: W, "data-edit": U.value, "exist-slider-primary": N.value }, null, 8, ["is-open-edit", "data-edit", "exist-slider-primary"])) : i("", true)], 64);
64  };
65} }), ft = ve(ut, [["__scopeId", "data-v-5f84fec5"]]);
66export {
67  ft as default
68};

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.