Advertisement
Guest User

Untitled

a guest
Oct 19th, 2017
65
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Lua 2.28 KB | None | 0 0
  1. function(t, e, n) {
  2.     "use strict";
  3.     Object.defineProperty(e, "__esModule", {
  4.         value: !0
  5.     });
  6.     var s = n(13),
  7.         o = n.n(s),
  8.         i = n(12),
  9.         a = n.n(i),
  10.         r = n(4),
  11.         c = n(5);
  12.     e.default = {
  13.         components: {
  14.             List: a.a
  15.         },
  16.         data: function() {
  17.             return {
  18.                 title: "Téléphone",
  19.                 ignoreControls: !1,
  20.                 callList: [{
  21.                     display: "Police",
  22.                     subMenu: [{
  23.                         title: "Signaler un vol",
  24.                         eventName: "police",
  25.                         type: "Vole"
  26.                     }, {
  27.                         title: "Signaler une agression",
  28.                         eventName: "police",
  29.                         type: "Aggression"
  30.                     }, {
  31.                         title: "Autre",
  32.                         eventName: "police"
  33.                     }]
  34.                 }, {
  35.                     display: "Ambulance",
  36.                     subMenu: [{
  37.                         title: "Appel pour réanimation",
  38.                         eventName: "medic",
  39.                         type: "Une personne est dans le coma"
  40.                     }, {
  41.                         title: "Appel pour des soins",
  42.                         eventName: "medic",
  43.                         type: "J'ai besoin de soins"
  44.                     }]
  45.                 }]
  46.             }
  47.         },
  48.         methods: {
  49.             onSelect: function(t) {
  50.                 var e = this;
  51.                 !0 !== this.ignoreControls && (this.ignoreControls = !0, c.a.CreateModal({
  52.                     choix: [].concat(o()(t.subMenu), [{
  53.                         title: "Retour"
  54.                     }])
  55.                 }).then(function(t) {
  56.                     e.ignoreControls = !1, "Retour" !== t.title && r.a.callEvent(t.eventName, t.type)
  57.                 }))
  58.             },
  59.             onBackspace: function() {
  60.                 !0 !== this.ignoreControls && history.back()
  61.             }
  62.         },
  63.         created: function() {
  64.             this.$bus.$on("keyUpBackspace", this.onBackspace)
  65.         },
  66.         beforeDestroy: function() {
  67.             this.$bus.$off("keyUpBackspace", this.onBackspace)
  68.         }
  69.     }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement