Advertisement
Guest User

Untitled

a guest
Mar 31st, 2019
312
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. (function(t) {
  2.     function e(e) {
  3.         for (var r, n, o = e[0], c = e[1], l = e[2], d = 0, p = []; d < o.length; d++)
  4.             n = o[d],
  5.             a[n] && p.push(a[n][0]),
  6.             a[n] = 0;
  7.         for (r in c)
  8.             Object.prototype.hasOwnProperty.call(c, r) && (t[r] = c[r]);
  9.         u && u(e);
  10.         while (p.length)
  11.             p.shift()();
  12.         return i.push.apply(i, l || []),
  13.         s()
  14.     }
  15.     function s() {
  16.         for (var t, e = 0; e < i.length; e++) {
  17.             for (var s = i[e], r = !0, o = 1; o < s.length; o++) {
  18.                 var c = s[o];
  19.                 0 !== a[c] && (r = !1)
  20.             }
  21.             r && (i.splice(e--, 1),
  22.             t = n(n.s = s[0]))
  23.         }
  24.         return t
  25.     }
  26.     var r = {}
  27.       , a = {
  28.         app: 0
  29.     }
  30.       , i = [];
  31.     function n(e) {
  32.         if (r[e])
  33.             return r[e].exports;
  34.         var s = r[e] = {
  35.             i: e,
  36.             l: !1,
  37.             exports: {}
  38.         };
  39.         return t[e].call(s.exports, s, s.exports, n),
  40.         s.l = !0,
  41.         s.exports
  42.     }
  43.     n.m = t,
  44.     n.c = r,
  45.     n.d = function(t, e, s) {
  46.         n.o(t, e) || Object.defineProperty(t, e, {
  47.             enumerable: !0,
  48.             get: s
  49.         })
  50.     }
  51.     ,
  52.     n.r = function(t) {
  53.         "undefined" !== typeof Symbol && Symbol.toStringTag && Object.defineProperty(t, Symbol.toStringTag, {
  54.             value: "Module"
  55.         }),
  56.         Object.defineProperty(t, "__esModule", {
  57.             value: !0
  58.         })
  59.     }
  60.     ,
  61.     n.t = function(t, e) {
  62.         if (1 & e && (t = n(t)),
  63.         8 & e)
  64.             return t;
  65.         if (4 & e && "object" === typeof t && t && t.__esModule)
  66.             return t;
  67.         var s = Object.create(null);
  68.         if (n.r(s),
  69.         Object.defineProperty(s, "default", {
  70.             enumerable: !0,
  71.             value: t
  72.         }),
  73.         2 & e && "string" != typeof t)
  74.             for (var r in t)
  75.                 n.d(s, r, function(e) {
  76.                     return t[e]
  77.                 }
  78.                 .bind(null, r));
  79.         return s
  80.     }
  81.     ,
  82.     n.n = function(t) {
  83.         var e = t && t.__esModule ? function() {
  84.             return t["default"]
  85.         }
  86.         : function() {
  87.             return t
  88.         }
  89.         ;
  90.         return n.d(e, "a", e),
  91.         e
  92.     }
  93.     ,
  94.     n.o = function(t, e) {
  95.         return Object.prototype.hasOwnProperty.call(t, e)
  96.     }
  97.     ,
  98.     n.p = "";
  99.     var o = window["webpackJsonp"] = window["webpackJsonp"] || []
  100.       , c = o.push.bind(o);
  101.     o.push = e,
  102.     o = o.slice();
  103.     for (var l = 0; l < o.length; l++)
  104.         e(o[l]);
  105.     var u = c;
  106.     i.push([0, "chunk-vendors"]),
  107.     s()
  108. }
  109. )({
  110.     0: function(t, e, s) {
  111.         t.exports = s("56d7")
  112.     },
  113.     "009b": function(t, e, s) {},
  114.     "03fa": function(t, e, s) {
  115.         "use strict";
  116.         var r = s("7ccc")
  117.           , a = s.n(r);
  118.         a.a
  119.     },
  120.     "07a3": function(t, e, s) {},
  121.     "0f42": function(t, e, s) {
  122.         "use strict";
  123.         var r = s("26d2")
  124.           , a = s.n(r);
  125.         a.a
  126.     },
  127.     "10fe": function(t, e, s) {
  128.         "use strict";
  129.         var r = s("5a61")
  130.           , a = s.n(r);
  131.         a.a
  132.     },
  133.     "1b77": function(t, e, s) {},
  134.     "1dd1": function(t, e, s) {},
  135.     "26d2": function(t, e, s) {},
  136.     "2e1c": function(t, e, s) {
  137.         "use strict";
  138.         var r = s("41ee")
  139.           , a = s.n(r);
  140.         a.a
  141.     },
  142.     "41a3": function(t, e, s) {
  143.         "use strict";
  144.         var r = s("7852")
  145.           , a = s.n(r);
  146.         a.a
  147.     },
  148.     "41ee": function(t, e, s) {},
  149.     "42f0": function(t, e, s) {},
  150.     "56d7": function(t, e, s) {
  151.         "use strict";
  152.         s.r(e);
  153.         s("cadf"),
  154.         s("551c"),
  155.         s("f751"),
  156.         s("097d");
  157.         var r = s("2b0e")
  158.           , a = function() {
  159.             var t = this
  160.               , e = t.$createElement
  161.               , s = t._self._c || e;
  162.             return s("div", {
  163.                 staticClass: "app"
  164.             }, [s("Navbar"), s("router-view"), t._m(0)], 1)
  165.         }
  166.           , i = [function() {
  167.             var t = this
  168.               , e = t.$createElement
  169.               , s = t._self._c || e;
  170.             return s("footer", {
  171.                 staticClass: "footer"
  172.             }, [s("div", {
  173.                 staticClass: "content has-text-centered"
  174.             }, [s("p", [s("strong", [t._v("Praca ZSE")])]), s("p", [t._v("Wszelkie prawa zastrzeżone.")])])])
  175.         }
  176.         ]
  177.           , n = function() {
  178.             var t = this
  179.               , e = t.$createElement
  180.               , r = t._self._c || e;
  181.             return r("nav", {
  182.                 staticClass: "navbar",
  183.                 attrs: {
  184.                     role: "navigation",
  185.                     "aria-label": "main navigation"
  186.                 }
  187.             }, [r("div", {
  188.                 staticClass: "navbar-brand"
  189.             }, [r("router-link", {
  190.                 attrs: {
  191.                     to: "/"
  192.                 }
  193.             }, [r("a", {
  194.                 staticClass: "navbar-item",
  195.                 attrs: {
  196.                     href: "https://praca.zse.krakow.pl"
  197.                 }
  198.             }, [r("img", {
  199.                 staticClass: "image logo",
  200.                 attrs: {
  201.                     src: s("cf05")
  202.                 }
  203.             }), r("strong", [t._v("Praca ZSE")])])]), t._m(0)], 1), r("div", {
  204.                 staticClass: "navbar-menu",
  205.                 attrs: {
  206.                     id: "navbar"
  207.                 }
  208.             }, [r("div", {
  209.                 staticClass: "navbar-start"
  210.             }, [r("router-link", {
  211.                 attrs: {
  212.                     to: "/"
  213.                 }
  214.             }, [r("a", {
  215.                 staticClass: "navbar-item"
  216.             }, [t._v("Przeglądaj ogłoszenia")])]), r("router-link", {
  217.                 attrs: {
  218.                     to: "/users"
  219.                 }
  220.             }, [r("a", {
  221.                 staticClass: "navbar-item"
  222.             }, [t._v("przeglądaj profile")])]), r("div", ["" != this.$store.getters.token ? r("a", {
  223.                 staticClass: "navbar-item",
  224.                 on: {
  225.                     click: t.showProfile
  226.                 }
  227.             }, [t._v("Profil")]) : t._e()]), r("div", [2 == this.$store.getters.accesLvl ? r("a", {
  228.                 staticClass: "navbar-item",
  229.                 on: {
  230.                     click: t.showAdmin
  231.                 }
  232.             }, [t._v("Panel Administratora")]) : t._e()])], 1), r("div", {
  233.                 staticClass: "navbar-end"
  234.             }, [r("div", {
  235.                 staticClass: "navbar-item"
  236.             }, [r("div", {
  237.                 staticClass: "buttons"
  238.             }, ["" == this.$store.getters.token ? r("router-link", {
  239.                 attrs: {
  240.                     to: "/register"
  241.                 }
  242.             }, [r("a", {
  243.                 key: "register",
  244.                 staticClass: "button is-primary"
  245.             }, [r("strong", [t._v("Zarejestruj się")])])]) : r("router-link", {
  246.                 attrs: {
  247.                     to: "/"
  248.                 }
  249.             }, [r("a", {
  250.                 key: "logout",
  251.                 staticClass: "button is-primary",
  252.                 on: {
  253.                     click: t.logout
  254.                 }
  255.             }, [r("strong", [t._v("Wyloguj się")])])]), "" == this.$store.getters.token ? r("router-link", {
  256.                 key: "login",
  257.                 attrs: {
  258.                     to: "/login"
  259.                 }
  260.             }, [r("a", {
  261.                 staticClass: "button is-light"
  262.             }, [t._v("Zaloguj się")])]) : t._e()], 1)])])])])
  263.         }
  264.           , o = [function() {
  265.             var t = this
  266.               , e = t.$createElement
  267.               , s = t._self._c || e;
  268.             return s("a", {
  269.                 staticClass: "navbar-burger burger",
  270.                 attrs: {
  271.                     role: "button",
  272.                     "aria-label": "menu",
  273.                     "aria-expanded": "false",
  274.                     "data-target": "navbar"
  275.                 }
  276.             }, [s("span", {
  277.                 attrs: {
  278.                     "aria-hidden": "true"
  279.                 }
  280.             }), s("span", {
  281.                 attrs: {
  282.                     "aria-hidden": "true"
  283.                 }
  284.             }), s("span", {
  285.                 attrs: {
  286.                     "aria-hidden": "true"
  287.                 }
  288.             })])
  289.         }
  290.         ]
  291.           , c = (s("ac6a"),
  292.         s("cebc"))
  293.           , l = s("2f62")
  294.           , u = {
  295.             name: "Navbar",
  296.             methods: {
  297.                 logout: function() {
  298.                     this.$store.commit("set", ""),
  299.                     this.$store.commit("setID", ""),
  300.                     this.$store.commit("setAccesLvl", ""),
  301.                     this.$router.push("/")
  302.                 },
  303.                 showProfile: function() {
  304.                     this.url = "/profile?id=".concat(this.$store.getters.id),
  305.                     console.log(this.url),
  306.                     this.$router.push(this.url)
  307.                 },
  308.                 showAdmin: function() {
  309.                     this.url = "/admin",
  310.                     this.$router.push(this.url)
  311.                 }
  312.             },
  313.             data: function() {
  314.                 return {
  315.                     url: ""
  316.                 }
  317.             },
  318.             computed: Object(c["a"])({}, Object(l["b"])(["id"]), {
  319.                 ComputedLocalState: function() {
  320.                     return this.url = "/profile?id=".concat(this.$store.getters.id),
  321.                     this.id
  322.                 }
  323.             }),
  324.             watch: {
  325.                 id: function(t, e) {
  326.                     console.log(t, e)
  327.                 }
  328.             }
  329.         };
  330.         document.addEventListener("DOMContentLoaded", function() {
  331.             var t = Array.prototype.slice.call(document.querySelectorAll(".navbar-burger"), 0);
  332.             t.length > 0 && t.forEach(function(t) {
  333.                 t.addEventListener("click", function() {
  334.                     var e = t.dataset.target
  335.                       , s = document.getElementById(e);
  336.                     t.classList.toggle("is-active"),
  337.                     s.classList.toggle("is-active")
  338.                 })
  339.             })
  340.         });
  341.         var d = u
  342.           , p = (s("b28f"),
  343.         s("2877"))
  344.           , h = Object(p["a"])(d, n, o, !1, null, "8b74d570", null)
  345.           , m = h.exports
  346.           , v = {
  347.             name: "App",
  348.             components: {
  349.                 Navbar: m
  350.             }
  351.         }
  352.           , f = v
  353.           , g = (s("dcef"),
  354.         Object(p["a"])(f, a, i, !1, null, "c8b4d7cc", null))
  355.           , _ = g.exports
  356.           , b = s("8c4f")
  357.           , w = function() {
  358.             var t = this
  359.               , e = t.$createElement
  360.               , s = t._self._c || e;
  361.             return s("div", {
  362.                 staticClass: "wrapper"
  363.             }, [s("searchInput", {
  364.                 on: {
  365.                     input: t.handleInput
  366.                 },
  367.                 model: {
  368.                     value: t.searchValue,
  369.                     callback: function(e) {
  370.                         t.searchValue = e
  371.                     },
  372.                     expression: "searchValue"
  373.                 }
  374.             }), s("AdvertisementsList", {
  375.                 attrs: {
  376.                     results: t.results
  377.                 }
  378.             }), "" == !this.$store.getters.token ? s("AddAdvertisementButton") : t._e()], 1)
  379.         }
  380.           , k = []
  381.           , y = s("bc3a")
  382.           , C = s.n(y)
  383.           , z = s("f7fe")
  384.           , j = s.n(z)
  385.           , $ = function() {
  386.             var t = this
  387.               , e = t.$createElement
  388.               , s = t._self._c || e;
  389.             return s("div", {
  390.                 staticClass: "field"
  391.             }, [s("div", {
  392.                 staticClass: "control"
  393.             }, [s("label", {
  394.                 attrs: {
  395.                     for: "search"
  396.                 }
  397.             }, [t._v("Wyszukaj")]), s("input", {
  398.                 staticClass: "input is-medium is-rounded is-primary",
  399.                 attrs: {
  400.                     type: "text",
  401.                     placeholder: "Czego szukasz?"
  402.                 },
  403.                 domProps: {
  404.                     value: t.value
  405.                 },
  406.                 on: {
  407.                     input: t.handleChange
  408.                 }
  409.             })])])
  410.         }
  411.           , E = []
  412.           , N = {
  413.             name: "SearchInput",
  414.             props: {
  415.                 value: {
  416.                     type: String,
  417.                     required: !0
  418.                 }
  419.             },
  420.             methods: {
  421.                 handleChange: function(t) {
  422.                     this.$emit("input", t.target.value)
  423.                 }
  424.             }
  425.         }
  426.           , x = N
  427.           , P = (s("dc76"),
  428.         Object(p["a"])(x, $, E, !1, null, "3fa91a7c", null))
  429.           , A = P.exports
  430.           , O = function() {
  431.             var t = this
  432.               , e = t.$createElement
  433.               , s = t._self._c || e;
  434.             return s("div", {
  435.                 staticClass: "advertisementsWrapper"
  436.             }, t._l(t.results, function(e) {
  437.                 return s("div", {
  438.                     key: e.id,
  439.                     staticClass: "box"
  440.                 }, [s("router-link", {
  441.                     attrs: {
  442.                         to: {
  443.                             path: "advertisement",
  444.                             query: {
  445.                                 id: e.id
  446.                             }
  447.                         }
  448.                     }
  449.                 }, [s("article", {
  450.                     staticClass: "media"
  451.                 }, [s("div", {
  452.                     staticClass: "media-left"
  453.                 }, [s("figure", {
  454.                     staticClass: "image is-64x64"
  455.                 }, [t._v("\n            " + t._s(e.signature.toUpperCase().substring(0, 2)) + "\n          ")])]), s("div", {
  456.                     staticClass: "media-content"
  457.                 }, [s("div", {
  458.                     staticClass: "content"
  459.                 }, [s("p", [s("strong", [t._v(t._s(e.title))]), s("br"), t._v("\n              " + t._s(e.signature) + "\n            ")])])])])])], 1)
  460.             }), 0)
  461.         }
  462.           , I = []
  463.           , L = {
  464.             name: "AdvertisementsList",
  465.             props: {
  466.                 results: {
  467.                     type: Array,
  468.                     required: !0
  469.                 }
  470.             },
  471.             methods: {}
  472.         }
  473.           , q = L
  474.           , S = (s("913f"),
  475.         Object(p["a"])(q, O, I, !1, null, "28a16e61", null))
  476.           , B = S.exports
  477.           , Z = function() {
  478.             var t = this
  479.               , e = t.$createElement
  480.               , s = t._self._c || e;
  481.             return s("div", {
  482.                 staticClass: "addAdverisementButton",
  483.                 attrs: {
  484.                     title: "Dodaj nowe ogłoszenie."
  485.                 },
  486.                 on: {
  487.                     click: t.redirect
  488.                 }
  489.             }, [s("span", [t._v("+")])])
  490.         }
  491.           , R = []
  492.           , V = {
  493.             name: "AddAdvertisementButton",
  494.             props: {},
  495.             methods: {
  496.                 redirect: function() {
  497.                     this.$router.push("/advertisement/add")
  498.                 }
  499.             }
  500.         }
  501.           , U = V
  502.           , D = (s("ea15"),
  503.         Object(p["a"])(U, Z, R, !1, null, "4454fdbe", null))
  504.           , H = D.exports
  505.           , W = "https://praca.zse.krakow.pl/api"
  506.           , T = {
  507.             name: "Home",
  508.             data: function() {
  509.                 return {
  510.                     searchValue: "",
  511.                     results: []
  512.                 }
  513.             },
  514.             components: {
  515.                 SearchInput: A,
  516.                 AdvertisementsList: B,
  517.                 AddAdvertisementButton: H
  518.             },
  519.             methods: {
  520.                 handleInput: j()(function() {
  521.                     var t = this;
  522.                     C.a.get("".concat(W, "/advertisements/search.php?s=").concat(this.searchValue)).then(function(e) {
  523.                         console.log(e.data.records),
  524.                         t.results = e.data.records
  525.                     }).catch(function(e) {
  526.                         t.results = {
  527.                             0: {
  528.                                 title: "Niestety, nic nie znaleziono.",
  529.                                 signature: "Błąd"
  530.                             }
  531.                         }
  532.                     })
  533.                 }, 500)
  534.             },
  535.             mounted: function() {
  536.                 var t = this;
  537.                 C.a.get("".concat(W, "/advertisements/read.php")).then(function(e) {
  538.                     console.log(e.data.records),
  539.                     t.results = e.data.records
  540.                 }).catch(function(t) {
  541.                     console.log(t)
  542.                 })
  543.             }
  544.         }
  545.           , M = T
  546.           , F = (s("a824"),
  547.         Object(p["a"])(M, w, k, !1, null, "5948f5a5", null))
  548.           , J = F.exports
  549.           , K = function() {
  550.             var t = this
  551.               , e = t.$createElement
  552.               , s = t._self._c || e;
  553.             return s("div", {
  554.                 staticClass: "wrapper"
  555.             }, [s("div", {
  556.                 staticClass: "box box-wrapper"
  557.             }, [s("div", {
  558.                 staticClass: "content"
  559.             }, [s("h2", [t._v(t._s(t.results.title))]), s("p", {
  560.                 staticClass: "description"
  561.             }, [t._v(t._s(t.results.description))]), s("br"), s("p", {
  562.                 staticClass: "signature"
  563.             }, [s("a", {
  564.                 on: {
  565.                     click: t.getCreator
  566.                 }
  567.             }, [t._v(t._s(t.results.signature))])]), s("br"), t.owned_by_user ? s("span", {
  568.                 staticClass: "edit",
  569.                 attrs: {
  570.                     title: "edytuj ogłoszenie"
  571.                 },
  572.                 on: {
  573.                     click: t.redirect
  574.                 }
  575.             }, [t._m(0)]) : t._e()])])])
  576.         }
  577.           , G = [function() {
  578.             var t = this
  579.               , e = t.$createElement
  580.               , s = t._self._c || e;
  581.             return s("p", [s("i", {
  582.                 staticClass: "far fa-edit"
  583.             })])
  584.         }
  585.         ]
  586.           , Q = "https://praca.zse.krakow.pl/api"
  587.           , X = {
  588.             name: "Advertisement",
  589.             data: function() {
  590.                 return {
  591.                     results: [],
  592.                     user_id: "",
  593.                     owned_by_user: !1
  594.                 }
  595.             },
  596.             components: {},
  597.             methods: {
  598.                 redirect: function() {
  599.                     this.$router.push("/advertisement/edit?id=".concat(this.$route.query.id))
  600.                 },
  601.                 getCreator: function() {
  602.                     this.url = "/profile?id=".concat(this.results.creator_id),
  603.                     this.$router.push(this.url)
  604.                 }
  605.             },
  606.             mounted: function() {
  607.                 var t = this;
  608.                 null != this.$route.query.id ? C.a.get("".concat(Q, "/advertisements/read_one.php?id=").concat(this.$route.query.id)).then(function(e) {
  609.                     t.results = e.data,
  610.                     t.user_id = t.$store.getters.id,
  611.                     t.user_id == t.results.creator_id ? t.owned_by_user = !0 : t.owned_by_user = !1
  612.                 }) : his.$router.push("/")
  613.             },
  614.             created: function() {}
  615.         }
  616.           , Y = X
  617.           , tt = (s("03fa"),
  618.         Object(p["a"])(Y, K, G, !1, null, "d590d698", null))
  619.           , et = tt.exports
  620.           , st = function() {
  621.             var t = this
  622.               , e = t.$createElement
  623.               , s = t._self._c || e;
  624.             return s("div", {
  625.                 staticClass: "wrapper container is-fluid"
  626.             }, [s("div", {
  627.                 staticClass: "box box-wrapper"
  628.             }, [s("div", {
  629.                 staticClass: "content"
  630.             }, [s("h2", [t._v("Zaloguj się")]), s("div", {
  631.                 staticClass: "field"
  632.             }, [s("div", {
  633.                 staticClass: "control has-text-centered"
  634.             }, [s("form", [s("input", {
  635.                 directives: [{
  636.                     name: "model",
  637.                     rawName: "v-model",
  638.                     value: t.email,
  639.                     expression: "email"
  640.                 }],
  641.                 staticClass: "input is-primary",
  642.                 attrs: {
  643.                     type: "email",
  644.                     placeholder: "email"
  645.                 },
  646.                 domProps: {
  647.                     value: t.email
  648.                 },
  649.                 on: {
  650.                     input: function(e) {
  651.                         e.target.composing || (t.email = e.target.value)
  652.                     }
  653.                 }
  654.             }), s("br"), s("input", {
  655.                 directives: [{
  656.                     name: "model",
  657.                     rawName: "v-model",
  658.                     value: t.password,
  659.                     expression: "password"
  660.                 }],
  661.                 staticClass: "input is-primary",
  662.                 attrs: {
  663.                     type: "password",
  664.                     placeholder: "hasło"
  665.                 },
  666.                 domProps: {
  667.                     value: t.password
  668.                 },
  669.                 on: {
  670.                     input: function(e) {
  671.                         e.target.composing || (t.password = e.target.value)
  672.                     }
  673.                 }
  674.             }), s("br"), s("a", {
  675.                 staticClass: "button is-primary",
  676.                 on: {
  677.                     click: t.login
  678.                 },
  679.                 nativeOn: {
  680.                     keyup: function(e) {
  681.                         return !e.type.indexOf("key") && t._k(e.keyCode, "enter", 13, e.key, "Enter") ? null : t.login(e)
  682.                     }
  683.                 }
  684.             }, [t._v("Zaloguj się")])])])]), s("div", {
  685.                 staticClass: "is-danger notification",
  686.                 class: {
  687.                     "is-invisible": t.hasNotError
  688.                 }
  689.             }, [s("p", [t._v("Podano błędny adres email lub hasło.")])])])])])
  690.         }
  691.           , rt = []
  692.           , at = "https://praca.zse.krakow.pl/api"
  693.           , it = {
  694.             name: "Login",
  695.             data: function() {
  696.                 return {
  697.                     email: "",
  698.                     password: "",
  699.                     token: "",
  700.                     hasNotError: !0,
  701.                     user_permission: "",
  702.                     user_id: ""
  703.                 }
  704.             },
  705.             components: {},
  706.             methods: {
  707.                 login: function() {
  708.                     var t = this;
  709.                     C.a.post("".concat(at, "/auth/login.php"), {
  710.                         email: "".concat(this.email),
  711.                         password: "".concat(this.password)
  712.                     }).then(function(e) {
  713.                         t.hasNotError = !0,
  714.                         t.token = e.data.token,
  715.                         t.$store.commit("set", t.token),
  716.                         C.a.post("".concat(at, "/auth/check.php"), {
  717.                             token: t.$store.getters.token
  718.                         }).then(function(e) {
  719.                             t.user_id = e.data.user_id,
  720.                             t.user_permission = e.data.user_permission,
  721.                             t.$store.commit("setID", t.user_id),
  722.                             console.log(),
  723.                             t.$store.commit("setAccesLvl", t.user_permission),
  724.                             t.$router.push("/")
  725.                         }).catch(function(e) {
  726.                             t.hasNotError = !1
  727.                         })
  728.                     }).catch(function(e) {
  729.                         t.hasNotError = !1
  730.                     })
  731.                 },
  732.                 mounted: function() {}
  733.             }
  734.         }
  735.           , nt = it
  736.           , ot = (s("ebf5"),
  737.         Object(p["a"])(nt, st, rt, !1, null, "c2f60e90", null))
  738.           , ct = ot.exports
  739.           , lt = function() {
  740.             var t = this
  741.               , e = t.$createElement
  742.               , s = t._self._c || e;
  743.             return s("div", {
  744.                 staticClass: "wrapper container is-fluid"
  745.             }, [s("div", {
  746.                 staticClass: "modal is-clipped",
  747.                 class: {
  748.                     "is-active": this.isPoliticyActive
  749.                 }
  750.             }, [s("div", {
  751.                 staticClass: "modal-background"
  752.             }), s("div", {
  753.                 staticClass: "modal-card"
  754.             }, [s("header", {
  755.                 staticClass: "modal-card-head"
  756.             }, [s("p", {
  757.                 staticClass: "modal-card-title"
  758.             }, [t._v("Regulamin")]), s("button", {
  759.                 staticClass: "delete",
  760.                 attrs: {
  761.                     "aria-label": "close"
  762.                 },
  763.                 on: {
  764.                     click: t.closePoliticy
  765.                 }
  766.             })]), t._m(0)])]), s("div", {
  767.                 staticClass: "box box-wrapper"
  768.             }, [s("div", {
  769.                 staticClass: "content"
  770.             }, [s("h2", [t._v("Zarejestruj się")]), s("div", {
  771.                 staticClass: "field"
  772.             }, [s("div", {
  773.                 staticClass: "control has-text-centered"
  774.             }, [s("form", [s("input", {
  775.                 directives: [{
  776.                     name: "model",
  777.                     rawName: "v-model",
  778.                     value: t.email,
  779.                     expression: "email"
  780.                 }],
  781.                 staticClass: "input is-primary",
  782.                 attrs: {
  783.                     type: "email",
  784.                     placeholder: "email"
  785.                 },
  786.                 domProps: {
  787.                     value: t.email
  788.                 },
  789.                 on: {
  790.                     input: [function(e) {
  791.                         e.target.composing || (t.email = e.target.value)
  792.                     }
  793.                     , t.handleInput]
  794.                 }
  795.             }), s("br"), s("input", {
  796.                 directives: [{
  797.                     name: "model",
  798.                     rawName: "v-model",
  799.                     value: t.password,
  800.                     expression: "password"
  801.                 }],
  802.                 staticClass: "input is-primary",
  803.                 attrs: {
  804.                     type: "password",
  805.                     placeholder: "hasło"
  806.                 },
  807.                 domProps: {
  808.                     value: t.password
  809.                 },
  810.                 on: {
  811.                     input: [function(e) {
  812.                         e.target.composing || (t.password = e.target.value)
  813.                     }
  814.                     , t.handleInput]
  815.                 }
  816.             }), s("br"), s("input", {
  817.                 directives: [{
  818.                     name: "model",
  819.                     rawName: "v-model",
  820.                     value: t.password2,
  821.                     expression: "password2"
  822.                 }],
  823.                 staticClass: "input is-primary",
  824.                 attrs: {
  825.                     type: "password",
  826.                     placeholder: "powtórz hasło"
  827.                 },
  828.                 domProps: {
  829.                     value: t.password2
  830.                 },
  831.                 on: {
  832.                     input: [function(e) {
  833.                         e.target.composing || (t.password2 = e.target.value)
  834.                     }
  835.                     , t.handleInput]
  836.                 }
  837.             }), s("br"), s("input", {
  838.                 directives: [{
  839.                     name: "model",
  840.                     rawName: "v-model",
  841.                     value: t.name,
  842.                     expression: "name"
  843.                 }],
  844.                 staticClass: "input is-primary",
  845.                 attrs: {
  846.                     type: "text",
  847.                     placeholder: "nazwa kontaktowa"
  848.                 },
  849.                 domProps: {
  850.                     value: t.name
  851.                 },
  852.                 on: {
  853.                     input: [function(e) {
  854.                         e.target.composing || (t.name = e.target.value)
  855.                     }
  856.                     , t.handleInput]
  857.                 }
  858.             }), s("br"), s("a", {
  859.                 staticClass: "button is-primary",
  860.                 on: {
  861.                     click: t.register,
  862.                     keyup: function(e) {
  863.                         return !e.type.indexOf("key") && t._k(e.keyCode, "enter", 13, e.key, "Enter") ? null : t.register(e)
  864.                     }
  865.                 }
  866.             }, [t._v("Zarejestruj się")])]), s("br"), s("p", [t._v("\n            Rejestrując się akceptujesz\n            "), s("span", {
  867.                 staticStyle: {
  868.                     color: "hsl(171, 100%, 41%)",
  869.                     cursor: "pointer"
  870.                 },
  871.                 on: {
  872.                     click: t.showPoliticy
  873.                 }
  874.             }, [t._v("regulamin.")])])])]), s("div", {
  875.                 staticClass: "is-danger notification",
  876.                 class: {
  877.                     "is-invisible": t.hasNotError
  878.                 }
  879.             }, [s("p", [t._v(t._s(this.error))])])])])])
  880.         }
  881.           , ut = [function() {
  882.             var t = this
  883.               , e = t.$createElement
  884.               , s = t._self._c || e;
  885.             return s("section", {
  886.                 staticClass: "modal-card-body"
  887.             }, [s("strong", [t._v("Polityka prywatności opisuje zasady przetwarzania przez nas informacji na Twój temat.")]), s("br"), s("p", [s("strong", [t._v("Informacje ogólne")]), s("br"), t._v("Ta polityka dotyczy Serwisu, funkcjonującego pod adresem : praca.zse.krakow.pl\n          "), s("br"), t._v("Administratorem danych osobowych jest: Zespół Szkół Energetycznych nr 9 w Krakowie Loretańska 16, 31-118 Kraków\n          "), s("br"), t._v("Adres kontaktowy poczty elektronicznej operatora: kacperszot1@gmail.com\n          "), s("br"), t._v("Operator jest Administratorem Twoich danych osobowych w odniesieniu do danych podanych dobrowolnie w Serwisie.\n          "), s("br"), t._v("Serwis wykorzystuje dane osobowe w następujących celach:\n          "), s("br"), t._v("Prowadzenie systemu ogłoszeń drobnych\n          "), s("br"), t._v("Prezentacja profil użytkownika innym użytkownikom\n          "), s("br"), t._v("Wyświetlanie ogłoszeń użytkowników\n          "), s("br"), t._v("Obsługa zapytań przez formularz\n          "), s("br"), t._v("Prezentacja oferty lub informacji\n          "), s("br"), t._v("Serwis realizuje funkcje pozyskiwania informacji o użytkownikach i ich zachowaniu w następujący sposób:\n          "), s("br"), t._v("Poprzez dobrowolnie wprowadzone w formularzach dane, które zostają wprowadzone do systemów Operatora.\n          "), s("br"), t._v("Poprzez zapisywanie w urządzeniach końcowych plików cookie (tzw. „ciasteczka”).\n          "), s("br")])])
  888.         }
  889.         ]
  890.           , dt = (s("7f7f"),
  891.         "https://praca.zse.krakow.pl/api")
  892.           , pt = {
  893.             name: "Register",
  894.             data: function() {
  895.                 return {
  896.                     email: "",
  897.                     password: "",
  898.                     password2: "",
  899.                     name: "",
  900.                     error: "",
  901.                     token: "",
  902.                     hasNotError: !0,
  903.                     isPoliticyActive: !1
  904.                 }
  905.             },
  906.             components: {},
  907.             methods: {
  908.                 register: function() {
  909.                     var t = this;
  910.                     this.hasNotError && C.a.post("".concat(dt, "/users/create.php"), {
  911.                         email: "".concat(this.email),
  912.                         password: "".concat(this.password),
  913.                         name: "".concat(this.name)
  914.                     }).then(function(e) {
  915.                         t.hasNotError = !0,
  916.                         console.log(e),
  917.                         t.$router.push("/login")
  918.                     }).catch(function(e) {
  919.                         t.hasNotError = !1,
  920.                         t.error = "Podany adres email jest już zajęty."
  921.                     })
  922.                 },
  923.                 closePoliticy: function() {
  924.                     this.isPoliticyActive = !1
  925.                 },
  926.                 showPoliticy: function() {
  927.                     this.isPoliticyActive = !0
  928.                 },
  929.                 handleInput: function() {
  930.                     /^(([^<>()[\]\\.,;:\s@\"]+(\.[^<>()[\]\\.,;:\s@\"]+)*)|(\".+\"))@((\[[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\])|(([a-zA-Z\-0-9]+\.)+[a-zA-Z]{2,}))$/.test(this.email) ? /[a-z]/.test(this.password) ? /[A-Z]/.test(this.password) ? /\d/.test(this.password) ? /[^a-zA-Z\d]/.test(this.password) ? this.password.length < 8 ? (this.error = "Hasło jest za krótkie.",
  931.                     this.hasNotError = !1) : this.password2 != this.password ? (this.error = "Hasła nie są identyczne",
  932.                     this.hasNotError = !1) : 0 === this.name.length ? (this.error = "Nazwa kontaktowa nie może pozostać pusta",
  933.                     this.hasNotError = !1) : this.hasNotError = !0 : (this.error = "Hasło nie zawiera znaków specjalnych.",
  934.                     this.hasNotError = !1) : (this.error = "Hasło nie zawiera liczb.",
  935.                     this.hasNotError = !1) : (this.error = "Hasło nie zawiera wielkich liter.",
  936.                     this.hasNotError = !1) : (this.error = "Hasło nie zawiera małych liter.",
  937.                     this.hasNotError = !1) : (this.error = "Podaj poprawny adres email.",
  938.                     this.hasNotError = !1)
  939.                 },
  940.                 mounted: function() {}
  941.             }
  942.         }
  943.           , ht = pt
  944.           , mt = (s("f975"),
  945.         Object(p["a"])(ht, lt, ut, !1, null, "6a57d69c", null))
  946.           , vt = mt.exports
  947.           , ft = function() {
  948.             var t = this
  949.               , e = t.$createElement
  950.               , s = t._self._c || e;
  951.             return s("div", {
  952.                 staticClass: "wrapper container is-fluid"
  953.             }, [s("div", {
  954.                 staticClass: "box box-wrapper"
  955.             }, [s("div", {
  956.                 staticClass: "content"
  957.             }, [s("h2", [t._v("Dodaj ogłoszenie")]), s("div", {
  958.                 staticClass: "field"
  959.             }, [s("div", {
  960.                 staticClass: "control has-text-centered"
  961.             }, [s("form", [s("input", {
  962.                 directives: [{
  963.                     name: "model",
  964.                     rawName: "v-model",
  965.                     value: t.title,
  966.                     expression: "title"
  967.                 }],
  968.                 staticClass: "input is-primary",
  969.                 attrs: {
  970.                     type: "text",
  971.                     placeholder: "tytuł ogłoszenia"
  972.                 },
  973.                 domProps: {
  974.                     value: t.title
  975.                 },
  976.                 on: {
  977.                     input: [function(e) {
  978.                         e.target.composing || (t.title = e.target.value)
  979.                     }
  980.                     , t.handleInput]
  981.                 }
  982.             }), s("br"), s("br"), s("textarea", {
  983.                 directives: [{
  984.                     name: "model",
  985.                     rawName: "v-model",
  986.                     value: t.description,
  987.                     expression: "description"
  988.                 }],
  989.                 staticClass: "textarea is-primary",
  990.                 attrs: {
  991.                     cols: "30",
  992.                     rows: "10",
  993.                     placeholder: "Opis ogłoszenia"
  994.                 },
  995.                 domProps: {
  996.                     value: t.description
  997.                 },
  998.                 on: {
  999.                     input: [function(e) {
  1000.                         e.target.composing || (t.description = e.target.value)
  1001.                     }
  1002.                     , t.handleInput]
  1003.                 }
  1004.             }), s("br"), s("input", {
  1005.                 directives: [{
  1006.                     name: "model",
  1007.                     rawName: "v-model",
  1008.                     value: t.signature,
  1009.                     expression: "signature"
  1010.                 }],
  1011.                 staticClass: "input is-primary",
  1012.                 attrs: {
  1013.                     type: "text",
  1014.                     placeholder: "podpis ogłoszenia np. Jan kowalski FirmaABC sp. z.o.o."
  1015.                 },
  1016.                 domProps: {
  1017.                     value: t.signature
  1018.                 },
  1019.                 on: {
  1020.                     input: [function(e) {
  1021.                         e.target.composing || (t.signature = e.target.value)
  1022.                     }
  1023.                     , t.handleInput]
  1024.                 }
  1025.             }), s("br"), s("br"), s("a", {
  1026.                 staticClass: "button is-primary",
  1027.                 on: {
  1028.                     click: t.add
  1029.                 }
  1030.             }, [t._v("Dodaj ogłoszenie")])]), s("br"), s("div", {
  1031.                 staticClass: "notification",
  1032.                 class: {
  1033.                     "is-invisible": this.start,
  1034.                     "is-danger": !this.hasNotError,
  1035.                     "is-success": this.hasNotError
  1036.                 }
  1037.             }, [s("p", [t._v(t._s(this.error))])])])])])])])
  1038.         }
  1039.           , gt = []
  1040.           , _t = "https://praca.zse.krakow.pl/api"
  1041.           , bt = {
  1042.             name: "AddAdvertisement",
  1043.             created: function() {
  1044.                 "" == this.$store.getters.token && this.$router.push("/")
  1045.             },
  1046.             data: function() {
  1047.                 return {
  1048.                     title: "",
  1049.                     description: "",
  1050.                     signature: "",
  1051.                     hasNotError: !0,
  1052.                     error: "",
  1053.                     start: !0
  1054.                 }
  1055.             },
  1056.             components: {},
  1057.             methods: {
  1058.                 add: function() {
  1059.                     var t = this;
  1060.                     this.start = !1,
  1061.                     0 === this.title.length ? (this.hasNotError = !1,
  1062.                     this.error = "Podaj tytuł ogłoszenia") : 0 === this.description.length ? (this.hasNotError = !1,
  1063.                     this.error = "Podaj opis ogłoszenia") : 0 === this.signature.length ? (this.hasNotError = !1,
  1064.                     this.error = "Podaj podpis ogłoszenia") : (this.start = !0,
  1065.                     this.hasNotError = !0),
  1066.                     this.hasNotError && C.a.post("".concat(_t, "/advertisements/create.php"), {
  1067.                         title: "".concat(this.title),
  1068.                         description: "".concat(this.description),
  1069.                         signature: "".concat(this.signature),
  1070.                         token: this.$store.getters.token
  1071.                     }).then(function(e) {
  1072.                         t.hasNotError = !0,
  1073.                         t.start = !1,
  1074.                         t.error = "Ogłoszenie zostało dodane i czeka na zatwierdzenie przez administratora."
  1075.                     }).catch(function(e) {
  1076.                         t.hasNotError = !1,
  1077.                         t.error = "Nie mogliśmy przetworzyć twojego ogłoszenia upewnij się, że wprowadzone dane są poprawne."
  1078.                     })
  1079.                 },
  1080.                 handleInput: function() {
  1081.                     this.start = !1,
  1082.                     0 === this.title.length ? (this.hasNotError = !1,
  1083.                     this.error = "Podaj tytuł ogłoszenia") : 0 === this.description.length ? (this.hasNotError = !1,
  1084.                     this.error = "Podaj opis ogłoszenia") : 0 === this.signature.length ? (this.hasNotError = !1,
  1085.                     this.error = "Podaj podpis ogłoszenia") : (this.hasNotError = !0,
  1086.                     this.start = !0)
  1087.                 }
  1088.             }
  1089.         }
  1090.           , wt = bt
  1091.           , kt = (s("41a3"),
  1092.         Object(p["a"])(wt, ft, gt, !1, null, "746fc298", null))
  1093.           , yt = kt.exports
  1094.           , Ct = function() {
  1095.             var t = this
  1096.               , e = t.$createElement
  1097.               , s = t._self._c || e;
  1098.             return s("div", {
  1099.                 staticClass: "wrapper container is-fluid"
  1100.             }, [s("div", {
  1101.                 staticClass: "box box-wrapper"
  1102.             }, [s("div", {
  1103.                 staticClass: "content"
  1104.             }, [s("h2", [t._v("Edytuj ogłoszenie")]), s("div", {
  1105.                 staticClass: "field"
  1106.             }, [s("div", {
  1107.                 staticClass: "control has-text-centered"
  1108.             }, [s("form", [s("input", {
  1109.                 directives: [{
  1110.                     name: "model",
  1111.                     rawName: "v-model",
  1112.                     value: t.title,
  1113.                     expression: "title"
  1114.                 }],
  1115.                 staticClass: "input is-primary",
  1116.                 attrs: {
  1117.                     type: "text"
  1118.                 },
  1119.                 domProps: {
  1120.                     value: t.title
  1121.                 },
  1122.                 on: {
  1123.                     input: [function(e) {
  1124.                         e.target.composing || (t.title = e.target.value)
  1125.                     }
  1126.                     , t.handleInput]
  1127.                 }
  1128.             }), s("br"), s("br"), s("textarea", {
  1129.                 directives: [{
  1130.                     name: "model",
  1131.                     rawName: "v-model",
  1132.                     value: t.description,
  1133.                     expression: "description"
  1134.                 }],
  1135.                 staticClass: "textarea is-primary",
  1136.                 attrs: {
  1137.                     cols: "30",
  1138.                     rows: "10"
  1139.                 },
  1140.                 domProps: {
  1141.                     value: t.description
  1142.                 },
  1143.                 on: {
  1144.                     input: [function(e) {
  1145.                         e.target.composing || (t.description = e.target.value)
  1146.                     }
  1147.                     , t.handleInput]
  1148.                 }
  1149.             }), s("br"), s("input", {
  1150.                 directives: [{
  1151.                     name: "model",
  1152.                     rawName: "v-model",
  1153.                     value: t.signature,
  1154.                     expression: "signature"
  1155.                 }],
  1156.                 staticClass: "input is-primary",
  1157.                 attrs: {
  1158.                     type: "text"
  1159.                 },
  1160.                 domProps: {
  1161.                     value: t.signature
  1162.                 },
  1163.                 on: {
  1164.                     input: [function(e) {
  1165.                         e.target.composing || (t.signature = e.target.value)
  1166.                     }
  1167.                     , t.handleInput]
  1168.                 }
  1169.             }), s("br"), s("br"), s("a", {
  1170.                 staticClass: "button is-primary",
  1171.                 on: {
  1172.                     click: t.save
  1173.                 }
  1174.             }, [t._v("Zapisz ogłoszenie")])]), s("br"), s("div", {
  1175.                 staticClass: "notification",
  1176.                 class: {
  1177.                     "is-invisible": this.start,
  1178.                     "is-danger": !this.hasNotError,
  1179.                     "is-success": this.hasNotError
  1180.                 }
  1181.             }, [s("p", [t._v(t._s(this.error))])])])])])])])
  1182.         }
  1183.           , zt = []
  1184.           , jt = "https://praca.zse.krakow.pl/api"
  1185.           , $t = {
  1186.             name: "EditAdvertisement",
  1187.             created: function() {
  1188.                 var t = this;
  1189.                 "" == this.$store.getters.token ? this.$router.push("/") : (C.a.post("".concat(jt, "/auth/check.php"), {
  1190.                     token: this.$store.getters.token
  1191.                 }).then(function(e) {
  1192.                     t.user_id = e.data.user_id
  1193.                 }).catch(function(e) {
  1194.                     console.log(e),
  1195.                     t.$router.push("/")
  1196.                 }),
  1197.                 C.a.get("".concat(jt, "/advertisements/read_one.php?id=").concat(this.$route.query.id)).then(function(e) {
  1198.                     console.log(e),
  1199.                     e.data.creator_id == t.user_id ? (t.id = e.data.id,
  1200.                     t.title = e.data.title,
  1201.                     t.description = e.data.description,
  1202.                     t.signature = e.data.signature) : (console.log("nice try"),
  1203.                     t.$router.push("/"))
  1204.                 }).catch(function(e) {
  1205.                     console.log(e),
  1206.                     t.$router.push("/")
  1207.                 }))
  1208.             },
  1209.             data: function() {
  1210.                 return {
  1211.                     title: "",
  1212.                     description: "",
  1213.                     signature: "",
  1214.                     hasNotError: !0,
  1215.                     error: "",
  1216.                     start: !0,
  1217.                     user_id: "",
  1218.                     id: ""
  1219.                 }
  1220.             },
  1221.             components: {},
  1222.             methods: {
  1223.                 save: function() {
  1224.                     var t = this;
  1225.                     this.start = !1,
  1226.                     0 === this.title.length ? (this.hasNotError = !1,
  1227.                     this.error = "Podaj tytuł ogłoszenia") : 0 === this.description.length ? (this.hasNotError = !1,
  1228.                     this.error = "Podaj opis ogłoszenia") : 0 === this.signature.length ? (this.hasNotError = !1,
  1229.                     this.error = "Podaj podpis ogłoszenia") : (this.start = !0,
  1230.                     this.hasNotError = !0),
  1231.                     this.hasNotError && C.a.post("".concat(jt, "/advertisements/update.php"), {
  1232.                         id: this.id,
  1233.                         title: this.title,
  1234.                         description: this.description,
  1235.                         signature: this.signature,
  1236.                         token: this.$store.getters.token
  1237.                     }).then(function(e) {
  1238.                         t.hasNotError = !0,
  1239.                         t.start = !1,
  1240.                         t.error = "Ogłoszenie zostało zapisane."
  1241.                     }).catch(function(e) {
  1242.                         t.hasNotError = !1,
  1243.                         t.error = "Nie mogliśmy przetworzyć twojego ogłoszenia."
  1244.                     })
  1245.                 },
  1246.                 handleInput: function() {
  1247.                     this.start = !1,
  1248.                     0 === this.title.length ? (this.hasNotError = !1,
  1249.                     this.error = "Podaj tytuł ogłoszenia") : 0 === this.description.length ? (this.hasNotError = !1,
  1250.                     this.error = "Podaj opis ogłoszenia") : 0 === this.signature.length ? (this.hasNotError = !1,
  1251.                     this.error = "Podaj podpis ogłoszenia") : (this.hasNotError = !0,
  1252.                     this.start = !0)
  1253.                 }
  1254.             }
  1255.         }
  1256.           , Et = $t
  1257.           , Nt = (s("10fe"),
  1258.         Object(p["a"])(Et, Ct, zt, !1, null, "fbbfdc82", null))
  1259.           , xt = Nt.exports
  1260.           , Pt = function() {
  1261.             var t = this
  1262.               , e = t.$createElement
  1263.               , s = t._self._c || e;
  1264.             return s("div", {
  1265.                 staticClass: "wrapper"
  1266.             }, [s("div", {
  1267.                 staticClass: "box box-wrapper"
  1268.             }, [s("div", {
  1269.                 staticClass: "content"
  1270.             }, [s("h2", [t._v(t._s(t.results.name))]), s("p", [s("strong", [t._v("Nazwa kontaktowa:")]), t._v("\n        " + t._s(t.results.name) + "\n      ")]), s("p", [s("strong", [t._v("Opis:")]), t._v("\n        " + t._s(t.results.description) + "\n      ")]), s("p", [s("strong", [t._v("Reputacja:")]), t._v("\n        " + t._s(t.results.rep) + "\n      ")]), s("p", [s("strong", [t._v("Adres email:")]), t._v("\n        " + t._s(t.results.email) + "\n      ")]), "" != this.$store.getters.token ? s("p", [s("a", {
  1271.                 staticClass: "button is-link",
  1272.                 attrs: {
  1273.                     disabled: !t.isAddRepoButtonActive
  1274.                 },
  1275.                 on: {
  1276.                     click: t.change_rep
  1277.                 }
  1278.             }, [t._v("Dodaj reputacje")])]) : t._e()])]), t.owned_by_user ? s("span", {
  1279.                 staticClass: "edit",
  1280.                 attrs: {
  1281.                     title: "edytuj profil"
  1282.                 },
  1283.                 on: {
  1284.                     click: t.redirect
  1285.                 }
  1286.             }, [t._m(0)]) : t._e()])
  1287.         }
  1288.           , At = [function() {
  1289.             var t = this
  1290.               , e = t.$createElement
  1291.               , s = t._self._c || e;
  1292.             return s("p", [s("i", {
  1293.                 staticClass: "far fa-edit"
  1294.             })])
  1295.         }
  1296.         ]
  1297.           , Ot = "https://praca.zse.krakow.pl/api"
  1298.           , It = {
  1299.             name: "Profile",
  1300.             data: function() {
  1301.                 return {
  1302.                     results: [],
  1303.                     owned_by_user: !1,
  1304.                     isAddRepoButtonActive: !1
  1305.                 }
  1306.             },
  1307.             components: {},
  1308.             methods: {
  1309.                 redirect: function() {
  1310.                     this.$router.push("/profile/edit?id=".concat(this.$route.query.id))
  1311.                 },
  1312.                 change_rep: function() {
  1313.                     var t = this;
  1314.                     C.a.post("".concat(Ot, "/users/change_rep.php?id=").concat(this.$route.query.id), {
  1315.                         token: this.$store.getters.token
  1316.                     }).then(function(e) {
  1317.                         C.a.get("".concat(Ot, "/users/read.php?id=").concat(t.$route.query.id)).then(function(e) {
  1318.                             t.results = e.data
  1319.                         }).catch(function(e) {
  1320.                             t.$router.push("/")
  1321.                         })
  1322.                     }).catch(function(e) {
  1323.                         C.a.get("".concat(Ot, "/users/read.php?id=").concat(t.$route.query.id)).then(function(e) {
  1324.                             t.results = e.data
  1325.                         }).catch(function(e) {
  1326.                             t.$router.push("/")
  1327.                         })
  1328.                     }).then(function() {
  1329.                         C.a.post("".concat(Ot, "/users/check_rep.php?id=").concat(t.$route.query.id), {
  1330.                             token: t.$store.getters.token
  1331.                         }).then(function(e) {
  1332.                             t.isAddRepoButtonActive = !1
  1333.                         }).catch(function(e) {
  1334.                             t.isAddRepoButtonActive = !0
  1335.                         })
  1336.                     })
  1337.                 }
  1338.             },
  1339.             mounted: function() {
  1340.                 var t = this;
  1341.                 null != this.$route.query.id ? (C.a.get("".concat(Ot, "/users/read.php?id=").concat(this.$route.query.id)).then(function(e) {
  1342.                     t.results = e.data,
  1343.                     t.$store.getters.id == t.results.id && (t.owned_by_user = !0)
  1344.                 }).catch(function(e) {
  1345.                     t.$router.push("/")
  1346.                 }),
  1347.                 C.a.post("".concat(Ot, "/users/check_rep.php?id=").concat(this.$route.query.id), {
  1348.                     token: this.$store.getters.token
  1349.                 }).then(function(e) {
  1350.                     t.isAddRepoButtonActive = !1
  1351.                 }).catch(function(e) {
  1352.                     t.isAddRepoButtonActive = !0
  1353.                 })) : his.$router.push("/")
  1354.             },
  1355.             created: function() {}
  1356.         }
  1357.           , Lt = It
  1358.           , qt = (s("937e"),
  1359.         Object(p["a"])(Lt, Pt, At, !1, null, "7400bf91", null))
  1360.           , St = qt.exports
  1361.           , Bt = function() {
  1362.             var t = this
  1363.               , e = t.$createElement
  1364.               , s = t._self._c || e;
  1365.             return s("div", {
  1366.                 staticClass: "wrapper container is-fluid"
  1367.             }, [s("div", {
  1368.                 staticClass: "box box-wrapper"
  1369.             }, [s("div", {
  1370.                 staticClass: "content"
  1371.             }, [s("h2", [t._v("Edytuj profil")]), s("div", {
  1372.                 staticClass: "field"
  1373.             }, [s("div", {
  1374.                 staticClass: "control has-text-centered"
  1375.             }, [s("form", [s("input", {
  1376.                 directives: [{
  1377.                     name: "model",
  1378.                     rawName: "v-model",
  1379.                     value: t.name,
  1380.                     expression: "name"
  1381.                 }],
  1382.                 staticClass: "input is-primary",
  1383.                 attrs: {
  1384.                     type: "text"
  1385.                 },
  1386.                 domProps: {
  1387.                     value: t.name
  1388.                 },
  1389.                 on: {
  1390.                     input: [function(e) {
  1391.                         e.target.composing || (t.name = e.target.value)
  1392.                     }
  1393.                     , t.handleInput]
  1394.                 }
  1395.             }), s("br"), s("br"), s("textarea", {
  1396.                 directives: [{
  1397.                     name: "model",
  1398.                     rawName: "v-model",
  1399.                     value: t.description,
  1400.                     expression: "description"
  1401.                 }],
  1402.                 staticClass: "textarea is-primary",
  1403.                 attrs: {
  1404.                     cols: "30",
  1405.                     rows: "10"
  1406.                 },
  1407.                 domProps: {
  1408.                     value: t.description
  1409.                 },
  1410.                 on: {
  1411.                     input: [function(e) {
  1412.                         e.target.composing || (t.description = e.target.value)
  1413.                     }
  1414.                     , t.handleInput]
  1415.                 }
  1416.             }), s("br"), s("br"), s("br"), s("a", {
  1417.                 staticClass: "button is-primary",
  1418.                 on: {
  1419.                     click: t.save
  1420.                 }
  1421.             }, [t._v("Zapisz Profil")])]), s("br"), s("div", {
  1422.                 staticClass: "notification",
  1423.                 class: {
  1424.                     "is-invisible": this.start,
  1425.                     "is-danger": !this.hasNotError,
  1426.                     "is-success": this.hasNotError
  1427.                 }
  1428.             }, [s("p", [t._v(t._s(this.error))])])])])])])])
  1429.         }
  1430.           , Zt = []
  1431.           , Rt = "https://praca.zse.krakow.pl/api"
  1432.           , Vt = {
  1433.             name: "EditProfile",
  1434.             mounted: function() {
  1435.                 var t = this;
  1436.                 "" == this.$store.getters.token ? this.$router.push("/") : C.a.get("".concat(Rt, "/users/read.php?id=").concat(this.$route.query.id)).then(function(e) {
  1437.                     t.results = e.data,
  1438.                     t.$store.getters.id == t.results.id ? (t.owned_by_user = !0,
  1439.                     t.name = t.results.name,
  1440.                     t.description = t.results.description,
  1441.                     t.id = t.results.id) : t.$router.push("/")
  1442.                 }).catch(function(e) {
  1443.                     t.$router.push("/")
  1444.                 })
  1445.             },
  1446.             data: function() {
  1447.                 return {
  1448.                     name: "",
  1449.                     description: "",
  1450.                     id: "",
  1451.                     hasNotError: !0,
  1452.                     error: "",
  1453.                     start: !0,
  1454.                     owned_by_user: !1
  1455.                 }
  1456.             },
  1457.             components: {},
  1458.             methods: {
  1459.                 save: function() {
  1460.                     var t = this;
  1461.                     this.start = !1,
  1462.                     0 === this.name.length ? (this.hasNotError = !1,
  1463.                     this.error = "Podaj nazwe kontaktową") : (this.start = !0,
  1464.                     this.hasNotError = !0),
  1465.                     this.hasNotError && C.a.post("".concat(Rt, "/users/update.php"), {
  1466.                         id: this.id,
  1467.                         name: this.name,
  1468.                         description: this.description,
  1469.                         token: this.$store.getters.token
  1470.                     }).then(function(e) {
  1471.                         t.hasNotError = !0,
  1472.                         t.start = !1,
  1473.                         t.error = "Profil został zapisany."
  1474.                     }).catch(function(e) {
  1475.                         t.hasNotError = !1,
  1476.                         t.error = "Nie mogliśmy przetworzyć twojego profilu."
  1477.                     })
  1478.                 },
  1479.                 handleInput: function() {
  1480.                     this.start = !1,
  1481.                     0 === this.name.length ? (this.hasNotError = !1,
  1482.                     this.error = "Podaj Nazwe kontaktową") : (this.start = !0,
  1483.                     this.hasNotError = !0)
  1484.                 }
  1485.             }
  1486.         }
  1487.           , Ut = Vt
  1488.           , Dt = (s("0f42"),
  1489.         Object(p["a"])(Ut, Bt, Zt, !1, null, "88fa5708", null))
  1490.           , Ht = Dt.exports
  1491.           , Wt = function() {
  1492.             var t = this
  1493.               , e = t.$createElement
  1494.               , s = t._self._c || e;
  1495.             return s("div", {
  1496.                 staticClass: "wrapper"
  1497.             }, [s("div", {
  1498.                 staticClass: "container"
  1499.             }, [s("h2", {
  1500.                 staticClass: "title"
  1501.             }, [t._v("Witaj w panelu Administratora")]), s("div", {
  1502.                 staticClass: "box"
  1503.             }, [s("div", {
  1504.                 staticClass: "columns"
  1505.             }, [s("div", {
  1506.                 staticClass: "column"
  1507.             }, [s("h3", {
  1508.                 staticClass: "title is-4"
  1509.             }, [t._v("Użytkownicy:")]), s("div", {
  1510.                 staticClass: "media"
  1511.             }, [s("div", {
  1512.                 staticClass: "media-content"
  1513.             }, t._l(t.users, function(e) {
  1514.                 return s("div", {
  1515.                     key: e.id,
  1516.                     staticClass: "box"
  1517.                 }, [s("router-link", {
  1518.                     attrs: {
  1519.                         to: {
  1520.                             path: "profile",
  1521.                             query: {
  1522.                                 id: e.id
  1523.                             }
  1524.                         }
  1525.                     }
  1526.                 }, [s("a", {
  1527.                     staticClass: "title is-5"
  1528.                 }, [t._v(t._s(e.name))])]), s("br"), s("a", {
  1529.                     staticClass: "button is-danger",
  1530.                     on: {
  1531.                         click: function(s) {
  1532.                             return t.delete_user(e.id)
  1533.                         }
  1534.                     }
  1535.                 }, [t._v("Usuń")])], 1)
  1536.             }), 0)])]), s("div", {
  1537.                 staticClass: "column"
  1538.             }, [s("h3", {
  1539.                 staticClass: "title is-4"
  1540.             }, [t._v("Ogłoszenia:")]), s("div", {
  1541.                 staticClass: "media"
  1542.             }, [s("div", {
  1543.                 staticClass: "media-content"
  1544.             }, t._l(t.advertisements, function(e) {
  1545.                 return s("div", {
  1546.                     key: e.id,
  1547.                     staticClass: "box"
  1548.                 }, [s("router-link", {
  1549.                     attrs: {
  1550.                         to: {
  1551.                             path: "advertisement",
  1552.                             query: {
  1553.                                 id: e.id
  1554.                             }
  1555.                         }
  1556.                     }
  1557.                 }, [s("a", {
  1558.                     staticClass: "title is-5"
  1559.                 }, [t._v(t._s(e.title))])]), s("br"), 0 == e.accepted ? s("a", {
  1560.                     staticClass: "button is-success",
  1561.                     on: {
  1562.                         click: function(s) {
  1563.                             return t.accept_advertisement(e.id)
  1564.                         }
  1565.                     }
  1566.                 }, [t._v("Akceptuj")]) : t._e(), s("a", {
  1567.                     staticClass: "button is-danger",
  1568.                     on: {
  1569.                         click: function(s) {
  1570.                             return t.delete_advertisement(e.id)
  1571.                         }
  1572.                     }
  1573.                 }, [t._v("Usuń")])], 1)
  1574.             }), 0)])])])])])])
  1575.         }
  1576.           , Tt = []
  1577.           , Mt = "https://praca.zse.krakow.pl/api"
  1578.           , Ft = {
  1579.             name: "Admin",
  1580.             data: function() {
  1581.                 return {
  1582.                     users: [],
  1583.                     advertisements: []
  1584.                 }
  1585.             },
  1586.             methods: {
  1587.                 delete_user: function(t) {
  1588.                     var e = this;
  1589.                     C.a.post("".concat(Mt, "/users/delete.php"), {
  1590.                         id: "".concat(t),
  1591.                         token: this.$store.getters.token
  1592.                     }).then(function(t) {
  1593.                         C.a.get("".concat(Mt, "/users/read_all.php")).then(function(t) {
  1594.                             e.users = t.data.records
  1595.                         }).catch(function(t) {
  1596.                             console.log(t)
  1597.                         })
  1598.                     }).catch(function(t) {
  1599.                         console.log(t)
  1600.                     })
  1601.                 },
  1602.                 delete_advertisement: function(t) {
  1603.                     var e = this;
  1604.                     C.a.post("".concat(Mt, "/advertisements/delete.php"), {
  1605.                         id: "".concat(t),
  1606.                         token: this.$store.getters.token
  1607.                     }).then(function(t) {
  1608.                         C.a.post("".concat(Mt, "/advertisements/read_admin.php"), {
  1609.                             token: e.$store.getters.token
  1610.                         }).then(function(t) {
  1611.                             e.advertisements = t.data.records
  1612.                         }).catch(function(t) {
  1613.                             console.log(t)
  1614.                         })
  1615.                     }).catch(function(t) {
  1616.                         console.log(t)
  1617.                     })
  1618.                 },
  1619.                 accept_advertisement: function(t) {
  1620.                     var e = this;
  1621.                     C.a.post("".concat(Mt, "/advertisements/accept.php"), {
  1622.                         id: "".concat(t),
  1623.                         token: this.$store.getters.token,
  1624.                         accepted: 1
  1625.                     }).then(function(t) {
  1626.                         C.a.post("".concat(Mt, "/advertisements/read_admin.php"), {
  1627.                             token: e.$store.getters.token
  1628.                         }).then(function(t) {
  1629.                             e.advertisements = t.data.records
  1630.                         }).catch(function(t) {
  1631.                             console.log(t)
  1632.                         })
  1633.                     }).catch(function(t) {
  1634.                         console.log(t)
  1635.                     })
  1636.                 }
  1637.             },
  1638.             mounted: function() {
  1639.                 var t = this;
  1640.                 "" != this.$store.getters.token && "2" == this.$store.getters.accesLvl || (console.log("al = ".concat(this.$store.getters.accesLvl)),
  1641.                 this.$router.push("/")),
  1642.                 C.a.post("".concat(Mt, "/advertisements/read_admin.php"), {
  1643.                     token: this.$store.getters.token
  1644.                 }).then(function(e) {
  1645.                     console.log(e.data.records),
  1646.                     t.advertisements = e.data.records
  1647.                 }).catch(function(t) {
  1648.                     console.log(t)
  1649.                 }),
  1650.                 C.a.get("".concat(Mt, "/users/read_all.php")).then(function(e) {
  1651.                     console.log(e.data.records),
  1652.                     t.users = e.data.records
  1653.                 }).catch(function(t) {
  1654.                     console.log(t)
  1655.                 })
  1656.             }
  1657.         }
  1658.           , Jt = Ft
  1659.           , Kt = (s("cd3e"),
  1660.         Object(p["a"])(Jt, Wt, Tt, !1, null, "2ee59a56", null))
  1661.           , Gt = Kt.exports
  1662.           , Qt = function() {
  1663.             var t = this
  1664.               , e = t.$createElement
  1665.               , s = t._self._c || e;
  1666.             return s("div", {
  1667.                 staticClass: "wrapper"
  1668.             }, [s("searchInput", {
  1669.                 on: {
  1670.                     input: t.handleInput
  1671.                 },
  1672.                 model: {
  1673.                     value: t.searchValue,
  1674.                     callback: function(e) {
  1675.                         t.searchValue = e
  1676.                     },
  1677.                     expression: "searchValue"
  1678.                 }
  1679.             }), s("UsersList", {
  1680.                 attrs: {
  1681.                     results: t.results
  1682.                 }
  1683.             })], 1)
  1684.         }
  1685.           , Xt = []
  1686.           , Yt = function() {
  1687.             var t = this
  1688.               , e = t.$createElement
  1689.               , s = t._self._c || e;
  1690.             return s("div", {
  1691.                 staticClass: "usersWrapper"
  1692.             }, t._l(t.results, function(e) {
  1693.                 return s("div", {
  1694.                     key: e.id,
  1695.                     staticClass: "box"
  1696.                 }, [s("router-link", {
  1697.                     attrs: {
  1698.                         to: {
  1699.                             path: "profile",
  1700.                             query: {
  1701.                                 id: e.id
  1702.                             }
  1703.                         }
  1704.                     }
  1705.                 }, [s("article", {
  1706.                     staticClass: "media"
  1707.                 }, [s("div", {
  1708.                     staticClass: "media-left"
  1709.                 }, [s("figure", {
  1710.                     staticClass: "image is-64x64"
  1711.                 }, [t._v("\n            " + t._s(e.name.toUpperCase().substring(0, 2)) + "\n          ")])]), s("div", {
  1712.                     staticClass: "media-content"
  1713.                 }, [s("div", {
  1714.                     staticClass: "content"
  1715.                 }, [s("p", [s("strong", [t._v(t._s(e.name))]), s("br"), t._v("\n              " + t._s(e.description.substring(0, 30)) + "\n            ")])])])])])], 1)
  1716.             }), 0)
  1717.         }
  1718.           , te = []
  1719.           , ee = {
  1720.             name: "UsersList",
  1721.             props: {
  1722.                 results: {
  1723.                     type: Array,
  1724.                     required: !0
  1725.                 }
  1726.             },
  1727.             methods: {}
  1728.         }
  1729.           , se = ee
  1730.           , re = (s("2e1c"),
  1731.         Object(p["a"])(se, Yt, te, !1, null, "50151814", null))
  1732.           , ae = re.exports
  1733.           , ie = "https://praca.zse.krakow.pl/api"
  1734.           , ne = {
  1735.             name: "SearchUser",
  1736.             data: function() {
  1737.                 return {
  1738.                     searchValue: "",
  1739.                     results: []
  1740.                 }
  1741.             },
  1742.             components: {
  1743.                 SearchInput: A,
  1744.                 UsersList: ae
  1745.             },
  1746.             methods: {
  1747.                 handleInput: j()(function() {
  1748.                     var t = this;
  1749.                     C.a.get("".concat(ie, "/users/search.php?s=").concat(this.searchValue)).then(function(e) {
  1750.                         console.log(e.data.records),
  1751.                         t.results = e.data.records
  1752.                     }).catch(function(e) {
  1753.                         t.results = {
  1754.                             0: {
  1755.                                 title: "Niestety, nic nie znaleziono.",
  1756.                                 signature: "Błąd"
  1757.                             }
  1758.                         }
  1759.                     })
  1760.                 }, 500)
  1761.             },
  1762.             mounted: function() {
  1763.                 var t = this;
  1764.                 C.a.get("".concat(ie, "/users/read_all.php")).then(function(e) {
  1765.                     console.log(e.data.records),
  1766.                     t.results = e.data.records
  1767.                 }).catch(function(t) {
  1768.                     console.log(t)
  1769.                 })
  1770.             }
  1771.         }
  1772.           , oe = ne
  1773.           , ce = (s("7714"),
  1774.         Object(p["a"])(oe, Qt, Xt, !1, null, "75ba6210", null))
  1775.           , le = ce.exports;
  1776.         r["a"].use(b["a"]);
  1777.         var ue = new b["a"]({
  1778.             routes: [{
  1779.                 path: "/",
  1780.                 name: "Home",
  1781.                 component: J
  1782.             }, {
  1783.                 path: "/advertisement",
  1784.                 name: "Advertisement",
  1785.                 component: et
  1786.             }, {
  1787.                 path: "/login",
  1788.                 name: "Login",
  1789.                 component: ct
  1790.             }, {
  1791.                 path: "/register",
  1792.                 name: "Register",
  1793.                 component: vt
  1794.             }, {
  1795.                 path: "/advertisement/add",
  1796.                 name: "AddAdvertisement",
  1797.                 component: yt
  1798.             }, {
  1799.                 path: "/advertisement/edit",
  1800.                 name: "EditAdvertisement",
  1801.                 component: xt
  1802.             }, {
  1803.                 path: "/profile",
  1804.                 name: "Profile",
  1805.                 component: St
  1806.             }, {
  1807.                 path: "/profile/edit",
  1808.                 name: "EditProfile",
  1809.                 component: Ht
  1810.             }, {
  1811.                 path: "/admin",
  1812.                 name: "Admin",
  1813.                 component: Gt
  1814.             }, {
  1815.                 path: "/users",
  1816.                 name: "users",
  1817.                 component: le
  1818.             }]
  1819.         });
  1820.         r["a"].use(l["a"]);
  1821.         var de = new l["a"].Store({
  1822.             state: {
  1823.                 token: "",
  1824.                 id: "",
  1825.                 accesLvl: ""
  1826.             },
  1827.             mutations: {
  1828.                 set: function(t, e) {
  1829.                     t.token = e
  1830.                 },
  1831.                 setID: function(t, e) {
  1832.                     t.id = e
  1833.                 },
  1834.                 setAccesLvl: function(t, e) {
  1835.                     t.accesLvl = e
  1836.                 }
  1837.             },
  1838.             actions: {},
  1839.             getters: {
  1840.                 token: function(t) {
  1841.                     return t.token
  1842.                 },
  1843.                 id: function(t) {
  1844.                     return t.id
  1845.                 },
  1846.                 accesLvl: function(t) {
  1847.                     return t.accesLvl
  1848.                 }
  1849.             }
  1850.         })
  1851.           , pe = s("9483");
  1852.         Object(pe["a"])("".concat("", "service-worker.js"), {
  1853.             ready: function() {
  1854.                 console.log("App is being served from cache by a service worker.\nFor more details, visit https://goo.gl/AFskqB")
  1855.             },
  1856.             registered: function() {
  1857.                 console.log("Service worker has been registered.")
  1858.             },
  1859.             cached: function() {
  1860.                 console.log("Content has been cached for offline use.")
  1861.             },
  1862.             updatefound: function() {
  1863.                 console.log("New content is downloading.")
  1864.             },
  1865.             updated: function() {
  1866.                 console.log("New content is available; please refresh.")
  1867.             },
  1868.             offline: function() {
  1869.                 console.log("No internet connection found. App is running in offline mode.")
  1870.             },
  1871.             error: function(t) {
  1872.                 console.error("Error during service worker registration:", t)
  1873.             }
  1874.         });
  1875.         s("92c6");
  1876.         r["a"].config.productionTip = !1,
  1877.         new r["a"]({
  1878.             router: ue,
  1879.             store: de,
  1880.             render: function(t) {
  1881.                 return t(_)
  1882.             }
  1883.         }).$mount("#app")
  1884.     },
  1885.     "5a61": function(t, e, s) {},
  1886.     "661f": function(t, e, s) {},
  1887.     7714: function(t, e, s) {
  1888.         "use strict";
  1889.         var r = s("89e4")
  1890.           , a = s.n(r);
  1891.         a.a
  1892.     },
  1893.     7852: function(t, e, s) {},
  1894.     "7cb8": function(t, e, s) {},
  1895.     "7ccc": function(t, e, s) {},
  1896.     "89e4": function(t, e, s) {},
  1897.     "913f": function(t, e, s) {
  1898.         "use strict";
  1899.         var r = s("07a3")
  1900.           , a = s.n(r);
  1901.         a.a
  1902.     },
  1903.     "934c": function(t, e, s) {},
  1904.     "937e": function(t, e, s) {
  1905.         "use strict";
  1906.         var r = s("1dd1")
  1907.           , a = s.n(r);
  1908.         a.a
  1909.     },
  1910.     a824: function(t, e, s) {
  1911.         "use strict";
  1912.         var r = s("7cb8")
  1913.           , a = s.n(r);
  1914.         a.a
  1915.     },
  1916.     b28f: function(t, e, s) {
  1917.         "use strict";
  1918.         var r = s("009b")
  1919.           , a = s.n(r);
  1920.         a.a
  1921.     },
  1922.     cd3e: function(t, e, s) {
  1923.         "use strict";
  1924.         var r = s("d506")
  1925.           , a = s.n(r);
  1926.         a.a
  1927.     },
  1928.     cf05: function(t, e, s) {
  1929.         t.exports = s.p + "img/logo.c903d1df.png"
  1930.     },
  1931.     d506: function(t, e, s) {},
  1932.     dc76: function(t, e, s) {
  1933.         "use strict";
  1934.         var r = s("661f")
  1935.           , a = s.n(r);
  1936.         a.a
  1937.     },
  1938.     dcef: function(t, e, s) {
  1939.         "use strict";
  1940.         var r = s("1b77")
  1941.           , a = s.n(r);
  1942.         a.a
  1943.     },
  1944.     e13a: function(t, e, s) {},
  1945.     ea15: function(t, e, s) {
  1946.         "use strict";
  1947.         var r = s("934c")
  1948.           , a = s.n(r);
  1949.         a.a
  1950.     },
  1951.     ebf5: function(t, e, s) {
  1952.         "use strict";
  1953.         var r = s("e13a")
  1954.           , a = s.n(r);
  1955.         a.a
  1956.     },
  1957.     f975: function(t, e, s) {
  1958.         "use strict";
  1959.         var r = s("42f0")
  1960.           , a = s.n(r);
  1961.         a.a
  1962.     }
  1963. });
  1964. //# sourceMappingURL=app.eb690666.js.map
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement