@ozdao/prometheus-framework 0.2.248 → 0.2.249
Sign up to get free protection for your applications and to get access to all the features.
- package/dist/prometheus-framework/src/components/Feed/Feed.vue.cjs +1 -1
- package/dist/prometheus-framework/src/components/Feed/Feed.vue.js +1 -1
- package/dist/prometheus-framework/src/components/FieldBig/FieldBig.vue.cjs +1 -1
- package/dist/prometheus-framework/src/components/FieldBig/FieldBig.vue.js +1 -1
- package/dist/prometheus-framework/src/components/LocationMarker/LocationMarker.vue2.cjs +1 -1
- package/dist/prometheus-framework/src/components/LocationMarker/LocationMarker.vue2.js +1 -1
- package/dist/prometheus-framework/src/components/Slider/Slider.vue.cjs +1 -1
- package/dist/prometheus-framework/src/components/Slider/Slider.vue.js +1 -1
- package/dist/prometheus-framework/src/components/UploadImageMultiple/UploadImageMultiple.vue.cjs +1 -1
- package/dist/prometheus-framework/src/components/UploadImageMultiple/UploadImageMultiple.vue.js +1 -1
- package/dist/prometheus-framework/src/modules/auth/views/components/layouts/Auth.vue.cjs +4 -4
- package/dist/prometheus-framework/src/modules/auth/views/components/layouts/Auth.vue.js +4 -4
- package/dist/prometheus-framework/src/modules/auth/views/components/pages/EnterCode.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/auth/views/components/pages/EnterCode.vue.js +1 -1
- package/dist/prometheus-framework/src/modules/auth/views/components/pages/EnterPassword.vue.cjs +3 -3
- package/dist/prometheus-framework/src/modules/auth/views/components/pages/EnterPassword.vue.js +3 -3
- package/dist/prometheus-framework/src/modules/auth/views/components/pages/Invite.vue.cjs +3 -3
- package/dist/prometheus-framework/src/modules/auth/views/components/pages/Invite.vue.js +3 -3
- package/dist/prometheus-framework/src/modules/auth/views/components/pages/ResetPassword.vue.cjs +3 -3
- package/dist/prometheus-framework/src/modules/auth/views/components/pages/ResetPassword.vue.js +3 -3
- package/dist/prometheus-framework/src/modules/auth/views/components/pages/SignIn.vue.cjs +3 -3
- package/dist/prometheus-framework/src/modules/auth/views/components/pages/SignIn.vue.js +3 -3
- package/dist/prometheus-framework/src/modules/auth/views/components/pages/SignUp.vue.cjs +3 -3
- package/dist/prometheus-framework/src/modules/auth/views/components/pages/SignUp.vue.js +3 -3
- package/dist/prometheus-framework/src/modules/community/components/layouts/Community.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/community/components/layouts/Community.vue.js +1 -1
- package/dist/prometheus-framework/src/modules/community/components/pages/BlogPost.vue.cjs +2 -2
- package/dist/prometheus-framework/src/modules/community/components/pages/BlogPost.vue.js +2 -2
- package/dist/prometheus-framework/src/modules/community/components/pages/Community.vue.cjs +4 -4
- package/dist/prometheus-framework/src/modules/community/components/pages/Community.vue.js +4 -4
- package/dist/prometheus-framework/src/modules/community/components/pages/CreateBlogPost.vue.cjs +3 -3
- package/dist/prometheus-framework/src/modules/community/components/pages/CreateBlogPost.vue.js +3 -3
- package/dist/prometheus-framework/src/modules/community/components/sections/HotPosts.vue.cjs +2 -2
- package/dist/prometheus-framework/src/modules/community/components/sections/HotPosts.vue.js +2 -2
- package/dist/prometheus-framework/src/modules/constructor/components/elements/Embed.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/constructor/components/elements/Embed.vue.js +1 -1
- package/dist/prometheus-framework/src/modules/events/components/elements/ButtonCheck.vue.cjs +37 -75
- package/dist/prometheus-framework/src/modules/events/components/elements/ButtonCheck.vue.cjs.map +1 -1
- package/dist/prometheus-framework/src/modules/events/components/elements/ButtonCheck.vue.js +38 -76
- package/dist/prometheus-framework/src/modules/events/components/elements/ButtonCheck.vue.js.map +1 -1
- package/dist/prometheus-framework/src/modules/events/components/elements/ButtonJoin.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/events/components/elements/ButtonJoin.vue.js +1 -1
- package/dist/prometheus-framework/src/modules/events/components/pages/EditEvent.vue.cjs +3 -3
- package/dist/prometheus-framework/src/modules/events/components/pages/EditEvent.vue.js +3 -3
- package/dist/prometheus-framework/src/modules/events/components/pages/EditEventTickets.vue.cjs +3 -3
- package/dist/prometheus-framework/src/modules/events/components/pages/EditEventTickets.vue.js +3 -3
- package/dist/prometheus-framework/src/modules/events/components/pages/Event.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/events/components/pages/Event.vue.js +1 -1
- package/dist/prometheus-framework/src/modules/events/components/pages/EventsBackoffice.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/events/components/pages/EventsBackoffice.vue.js +1 -1
- package/dist/prometheus-framework/src/modules/events/components/sections/Feed.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/events/components/sections/Feed.vue.js +1 -1
- package/dist/prometheus-framework/src/modules/events/components/sections/List.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/events/components/sections/List.vue.js +1 -1
- package/dist/prometheus-framework/src/modules/gallery/components/pages/Gallery.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/gallery/components/pages/Gallery.vue.js +1 -1
- package/dist/prometheus-framework/src/modules/gallery/components/sections/BackofficeGallery.vue.cjs +4 -4
- package/dist/prometheus-framework/src/modules/gallery/components/sections/BackofficeGallery.vue.js +4 -4
- package/dist/prometheus-framework/src/modules/globals/views/components/blocks/BlockSearch.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/globals/views/components/blocks/BlockSearch.vue.js +1 -1
- package/dist/prometheus-framework/src/modules/globals/views/components/blocks/CardHeader.vue.cjs +2 -2
- package/dist/prometheus-framework/src/modules/globals/views/components/blocks/CardHeader.vue.js +2 -2
- package/dist/prometheus-framework/src/modules/globals/views/components/layouts/Client.vue.cjs +2 -2
- package/dist/prometheus-framework/src/modules/globals/views/components/layouts/Client.vue.js +2 -2
- package/dist/prometheus-framework/src/modules/globals/views/components/partials/Header.vue.cjs +2 -2
- package/dist/prometheus-framework/src/modules/globals/views/components/partials/Header.vue.js +2 -2
- package/dist/prometheus-framework/src/modules/globals/views/components/partials/NavigationBar.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/globals/views/components/partials/NavigationBar.vue.js +1 -1
- package/dist/prometheus-framework/src/modules/globals/views/components/sections/SectionPageTitle.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/globals/views/components/sections/SectionPageTitle.vue.js +1 -1
- package/dist/prometheus-framework/src/modules/legal/components/pages/Legal.vue.cjs +3 -3
- package/dist/prometheus-framework/src/modules/legal/components/pages/Legal.vue.js +3 -3
- package/dist/prometheus-framework/src/modules/orders/components/pages/OrderBackoffice.vue.cjs +2 -2
- package/dist/prometheus-framework/src/modules/orders/components/pages/OrderBackoffice.vue.js +2 -2
- package/dist/prometheus-framework/src/modules/orders/components/pages/OrderCreateBackoffice.vue.cjs +5 -5
- package/dist/prometheus-framework/src/modules/orders/components/pages/OrderCreateBackoffice.vue.js +5 -5
- package/dist/prometheus-framework/src/modules/orders/components/pages/Orders.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/orders/components/pages/Orders.vue.js +1 -1
- package/dist/prometheus-framework/src/modules/orders/components/sections/FormAddCustomer.vue.cjs +3 -3
- package/dist/prometheus-framework/src/modules/orders/components/sections/FormAddCustomer.vue.js +3 -3
- package/dist/prometheus-framework/src/modules/orders/components/sections/FormCustomerDetails.vue.cjs +2 -2
- package/dist/prometheus-framework/src/modules/orders/components/sections/FormCustomerDetails.vue.js +2 -2
- package/dist/prometheus-framework/src/modules/orders/components/sections/FormDelivery.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/orders/components/sections/FormDelivery.vue.js +1 -1
- package/dist/prometheus-framework/src/modules/orders/components/sections/FormPayment.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/orders/components/sections/FormPayment.vue.js +1 -1
- package/dist/prometheus-framework/src/modules/organizations/components/elements/ButtonToggleMembership.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/organizations/components/elements/ButtonToggleMembership.vue.js +1 -1
- package/dist/prometheus-framework/src/modules/organizations/components/pages/DepartmentEdit.vue.cjs +6 -6
- package/dist/prometheus-framework/src/modules/organizations/components/pages/DepartmentEdit.vue.js +6 -6
- package/dist/prometheus-framework/src/modules/organizations/components/pages/Members.vue.cjs +2 -2
- package/dist/prometheus-framework/src/modules/organizations/components/pages/Members.vue.js +2 -2
- package/dist/prometheus-framework/src/modules/organizations/components/pages/Organization.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/organizations/components/pages/Organization.vue.js +1 -1
- package/dist/prometheus-framework/src/modules/organizations/components/pages/OrganizationEdit.vue.cjs +5 -5
- package/dist/prometheus-framework/src/modules/organizations/components/pages/OrganizationEdit.vue.js +5 -5
- package/dist/prometheus-framework/src/modules/organizations/components/pages/Organizations.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/organizations/components/pages/Organizations.vue.js +1 -1
- package/dist/prometheus-framework/src/modules/organizations/components/sections/Documents.vue.cjs +4 -4
- package/dist/prometheus-framework/src/modules/organizations/components/sections/Documents.vue.js +4 -4
- package/dist/prometheus-framework/src/modules/organizations/components/sections/Feed.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/organizations/components/sections/Feed.vue.js +1 -1
- package/dist/prometheus-framework/src/modules/organizations/components/sections/MembersAdd.vue.cjs +3 -3
- package/dist/prometheus-framework/src/modules/organizations/components/sections/MembersAdd.vue.js +3 -3
- package/dist/prometheus-framework/src/modules/organizations/components/sections/Organizations.vue.cjs +5 -5
- package/dist/prometheus-framework/src/modules/organizations/components/sections/Organizations.vue.js +5 -5
- package/dist/prometheus-framework/src/modules/pages/pages.client.cjs +672 -671
- package/dist/prometheus-framework/src/modules/pages/pages.client.js +672 -671
- package/dist/prometheus-framework/src/modules/pages/views/components/blocks/CardPage.vue.cjs +3 -3
- package/dist/prometheus-framework/src/modules/pages/views/components/blocks/CardPage.vue.js +3 -3
- package/dist/prometheus-framework/src/modules/pages/views/components/pages/PageEdit.vue.cjs +2 -2
- package/dist/prometheus-framework/src/modules/pages/views/components/pages/PageEdit.vue.js +2 -2
- package/dist/prometheus-framework/src/modules/pages/views/components/partials/SidebarPages.vue.cjs +2 -2
- package/dist/prometheus-framework/src/modules/pages/views/components/partials/SidebarPages.vue.js +2 -2
- package/dist/prometheus-framework/src/modules/products/components/blocks/CardPosition.vue.cjs +2 -2
- package/dist/prometheus-framework/src/modules/products/components/blocks/CardPosition.vue.js +2 -2
- package/dist/prometheus-framework/src/modules/products/components/blocks/Images360.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/products/components/blocks/Images360.vue.js +1 -1
- package/dist/prometheus-framework/src/modules/products/components/blocks/ImagesThumbnails.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/products/components/blocks/ImagesThumbnails.vue.js +1 -1
- package/dist/prometheus-framework/src/modules/products/components/blocks/LeftoverPositions.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/products/components/blocks/LeftoverPositions.vue.js +1 -1
- package/dist/prometheus-framework/src/modules/products/components/blocks/ListPositions.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/products/components/blocks/ListPositions.vue.js +1 -1
- package/dist/prometheus-framework/src/modules/products/components/pages/Categories.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/products/components/pages/Categories.vue.js +1 -1
- package/dist/prometheus-framework/src/modules/products/components/pages/CategoryEdit.vue.cjs +3 -3
- package/dist/prometheus-framework/src/modules/products/components/pages/CategoryEdit.vue.js +3 -3
- package/dist/prometheus-framework/src/modules/products/components/pages/EditLeftover.vue.cjs +3 -3
- package/dist/prometheus-framework/src/modules/products/components/pages/EditLeftover.vue.js +3 -3
- package/dist/prometheus-framework/src/modules/products/components/pages/Leftovers.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/products/components/pages/Leftovers.vue.js +1 -1
- package/dist/prometheus-framework/src/modules/products/components/pages/ProductEdit.vue.cjs +4 -4
- package/dist/prometheus-framework/src/modules/products/components/pages/ProductEdit.vue.js +4 -4
- package/dist/prometheus-framework/src/modules/products/components/pages/ProductRecommmendation.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/products/components/pages/ProductRecommmendation.vue.js +1 -1
- package/dist/prometheus-framework/src/modules/products/components/pages/Products.vue.cjs +2 -2
- package/dist/prometheus-framework/src/modules/products/components/pages/Products.vue.js +2 -2
- package/dist/prometheus-framework/src/modules/products/components/sections/EditModifications.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/products/components/sections/EditModifications.vue.js +1 -1
- package/dist/prometheus-framework/src/modules/products/components/sections/EditProductInfo.vue.cjs +4 -4
- package/dist/prometheus-framework/src/modules/products/components/sections/EditProductInfo.vue.js +4 -4
- package/dist/prometheus-framework/src/modules/products/components/sections/PopularProducts.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/products/components/sections/PopularProducts.vue.js +1 -1
- package/dist/prometheus-framework/src/modules/products/components/sections/SectionProduct.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/products/components/sections/SectionProduct.vue.js +1 -1
- package/dist/prometheus-framework/src/modules/reports/components/sections/FormReport.vue.cjs +3 -3
- package/dist/prometheus-framework/src/modules/reports/components/sections/FormReport.vue.js +3 -3
- package/dist/prometheus-framework/src/modules/spots/components/blocks/SpotMemberModify.vue.cjs +2 -2
- package/dist/prometheus-framework/src/modules/spots/components/blocks/SpotMemberModify.vue.js +2 -2
- package/dist/prometheus-framework/src/modules/spots/components/layouts/Spots.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/spots/components/layouts/Spots.vue.js +1 -1
- package/dist/prometheus-framework/src/modules/spots/components/pages/Map.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/spots/components/pages/Map.vue.js +1 -1
- package/dist/prometheus-framework/src/modules/spots/components/pages/SpotEdit.vue.cjs +5 -5
- package/dist/prometheus-framework/src/modules/spots/components/pages/SpotEdit.vue.js +5 -5
- package/dist/prometheus-framework/src/modules/users/components/pages/Profile.vue.cjs +3 -3
- package/dist/prometheus-framework/src/modules/users/components/pages/Profile.vue.js +3 -3
- package/dist/prometheus-framework/src/modules/users/components/pages/ProfileBlogposts.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/users/components/pages/ProfileBlogposts.vue.js +1 -1
- package/dist/prometheus-framework/src/modules/users/components/pages/ProfileEdit.vue.cjs +3 -3
- package/dist/prometheus-framework/src/modules/users/components/pages/ProfileEdit.vue.js +3 -3
- package/dist/prometheus-framework/src/modules/wallet/views/components/blocks/CardDeposit.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/wallet/views/components/blocks/CardDeposit.vue.js +1 -1
- package/dist/prometheus-framework/src/modules/wallet/views/components/blocks/CryptoDeposit.vue.cjs +2 -2
- package/dist/prometheus-framework/src/modules/wallet/views/components/blocks/CryptoDeposit.vue.js +2 -2
- package/dist/prometheus-framework/src/modules/wallet/views/components/pages/Wallet.vue.cjs +3 -3
- package/dist/prometheus-framework/src/modules/wallet/views/components/pages/Wallet.vue.js +3 -3
- package/package.json +1 -1
- package/src/modules/events/components/elements/ButtonCheck.vue +24 -20
package/dist/prometheus-framework/src/modules/events/components/elements/ButtonCheck.vue.cjs
CHANGED
@@ -2,8 +2,8 @@
|
|
2
2
|
Object.defineProperties(exports, { __esModule: { value: true }, [Symbol.toStringTag]: { value: "Module" } });
|
3
3
|
const vue = require("vue");
|
4
4
|
const index = require("../../../../../../node_modules/@capacitor-mlkit/barcode-scanning/dist/esm/index.cjs");
|
5
|
-
const Button = require("../../../../components/Button/Button.
|
6
|
-
|
5
|
+
const Button = require("../../../../components/Button/Button.vue2.cjs");
|
6
|
+
require("../../store/tickets.cjs");
|
7
7
|
;/* empty css */
|
8
8
|
const _hoisted_1 = {
|
9
9
|
key: 0,
|
@@ -14,18 +14,16 @@ const _hoisted_2 = {
|
|
14
14
|
class: "zoom-ratio-wrapper"
|
15
15
|
};
|
16
16
|
const _hoisted_3 = ["min", "max"];
|
17
|
-
const SCAN_TIMEOUT = 2500;
|
18
17
|
const _sfc_main = {
|
19
18
|
__name: "ButtonCheck",
|
20
19
|
emits: ["qrcodecheck"],
|
21
20
|
setup(__props, { emit: __emit }) {
|
22
|
-
const emits = __emit;
|
23
21
|
const error = vue.ref("");
|
24
22
|
const isScanning = vue.ref(false);
|
25
23
|
const isTorchAvailable = vue.ref(false);
|
26
24
|
const minZoomRatio = vue.ref(void 0);
|
27
25
|
const maxZoomRatio = vue.ref(void 0);
|
28
|
-
|
26
|
+
vue.ref(false);
|
29
27
|
vue.onMounted(async () => {
|
30
28
|
const { supported } = await index.BarcodeScanner.isSupported();
|
31
29
|
if (!supported) {
|
@@ -40,26 +38,9 @@ const _sfc_main = {
|
|
40
38
|
async function startScan() {
|
41
39
|
var _a, _b;
|
42
40
|
try {
|
43
|
-
const { camera } = await index.BarcodeScanner.checkPermissions();
|
44
|
-
if (camera !== "granted") {
|
45
|
-
const { camera: newStatus } = await index.BarcodeScanner.requestPermissions();
|
46
|
-
if (newStatus !== "granted") {
|
47
|
-
throw new Error("Camera permission is required to scan barcodes");
|
48
|
-
}
|
49
|
-
}
|
50
41
|
(_a = document.querySelector("body")) == null ? void 0 : _a.classList.add("barcode-scanner-active");
|
51
42
|
(_b = document.querySelector("html")) == null ? void 0 : _b.classList.add("barcode-scanner-active-html");
|
52
43
|
isScanning.value = true;
|
53
|
-
await index.BarcodeScanner.addListener("barcodeScanned", async (result) => {
|
54
|
-
if (!isProcessing.value) {
|
55
|
-
await processBarcode(result.barcode);
|
56
|
-
}
|
57
|
-
});
|
58
|
-
await index.BarcodeScanner.startScan();
|
59
|
-
const { zoomRatio: min } = await index.BarcodeScanner.getMinZoomRatio();
|
60
|
-
const { zoomRatio: max } = await index.BarcodeScanner.getMaxZoomRatio();
|
61
|
-
minZoomRatio.value = min;
|
62
|
-
maxZoomRatio.value = max;
|
63
44
|
} catch (e) {
|
64
45
|
error.value = e.message;
|
65
46
|
alert(`Error: ${error.value}`);
|
@@ -78,30 +59,6 @@ const _sfc_main = {
|
|
78
59
|
alert(`Error stopping scan: ${error.value}`);
|
79
60
|
}
|
80
61
|
}
|
81
|
-
async function processBarcode(barcode) {
|
82
|
-
if (isProcessing.value) return;
|
83
|
-
isProcessing.value = true;
|
84
|
-
try {
|
85
|
-
if (!barcode || !barcode.rawValue) {
|
86
|
-
throw new Error("Invalid barcode data");
|
87
|
-
}
|
88
|
-
console.log("barcode is", barcode);
|
89
|
-
const response = await tickets.actions.update({
|
90
|
-
_id: barcode.rawValue,
|
91
|
-
status: "used",
|
92
|
-
check: true
|
93
|
-
});
|
94
|
-
alert("Ticket checked. And it's all right!");
|
95
|
-
emits("qrcodecheck");
|
96
|
-
} catch (e) {
|
97
|
-
console.error(e);
|
98
|
-
alert(`Ticket is not found, already used or deactivated!`);
|
99
|
-
} finally {
|
100
|
-
setTimeout(() => {
|
101
|
-
isProcessing.value = false;
|
102
|
-
}, SCAN_TIMEOUT);
|
103
|
-
}
|
104
|
-
}
|
105
62
|
async function setZoomRatio(event) {
|
106
63
|
const zoomRatio = parseFloat(event.target.value);
|
107
64
|
await index.BarcodeScanner.setZoomRatio({ zoomRatio });
|
@@ -120,35 +77,40 @@ const _sfc_main = {
|
|
120
77
|
])),
|
121
78
|
_: 1
|
122
79
|
}),
|
123
|
-
isScanning.value ? (vue.openBlock(), vue.
|
124
|
-
|
125
|
-
|
126
|
-
|
127
|
-
|
128
|
-
|
129
|
-
|
130
|
-
|
131
|
-
|
132
|
-
|
133
|
-
|
134
|
-
|
135
|
-
|
136
|
-
|
137
|
-
|
138
|
-
|
139
|
-
|
140
|
-
|
141
|
-
|
142
|
-
|
143
|
-
|
144
|
-
|
145
|
-
|
146
|
-
|
147
|
-
|
148
|
-
|
149
|
-
|
150
|
-
|
151
|
-
|
80
|
+
isScanning.value ? (vue.openBlock(), vue.createBlock(vue.Teleport, {
|
81
|
+
key: 0,
|
82
|
+
to: "body"
|
83
|
+
}, [
|
84
|
+
isScanning.value ? (vue.openBlock(), vue.createElementBlock("div", _hoisted_1, [
|
85
|
+
_cache[3] || (_cache[3] = vue.createElementVNode("div", { class: "square" }, null, -1)),
|
86
|
+
minZoomRatio.value !== void 0 && maxZoomRatio.value !== void 0 ? (vue.openBlock(), vue.createElementBlock("div", _hoisted_2, [
|
87
|
+
vue.createElementVNode("input", {
|
88
|
+
type: "range",
|
89
|
+
min: minZoomRatio.value,
|
90
|
+
max: maxZoomRatio.value,
|
91
|
+
onInput: setZoomRatio
|
92
|
+
}, null, 40, _hoisted_3)
|
93
|
+
])) : vue.createCommentVNode("", true),
|
94
|
+
vue.createVNode(Button.default, {
|
95
|
+
onClick: stopScan,
|
96
|
+
class: "bg-white t-black stop-scan-button"
|
97
|
+
}, {
|
98
|
+
default: vue.withCtx(() => _cache[1] || (_cache[1] = [
|
99
|
+
vue.createTextVNode("Stop Scan")
|
100
|
+
])),
|
101
|
+
_: 1
|
102
|
+
}),
|
103
|
+
isTorchAvailable.value ? (vue.openBlock(), vue.createBlock(Button.default, {
|
104
|
+
key: 1,
|
105
|
+
onClick: toggleTorch,
|
106
|
+
class: "bg-white torch-button"
|
107
|
+
}, {
|
108
|
+
default: vue.withCtx(() => _cache[2] || (_cache[2] = [
|
109
|
+
vue.createTextVNode(" Toggle Torch ")
|
110
|
+
])),
|
111
|
+
_: 1
|
112
|
+
})) : vue.createCommentVNode("", true)
|
113
|
+
])) : vue.createCommentVNode("", true)
|
152
114
|
])) : vue.createCommentVNode("", true)
|
153
115
|
]);
|
154
116
|
};
|
package/dist/prometheus-framework/src/modules/events/components/elements/ButtonCheck.vue.cjs.map
CHANGED
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"ButtonCheck.vue.cjs","sources":["../../../../../../../src/modules/events/components/elements/ButtonCheck.vue"],"sourcesContent":["<template>\n <div>\n <Button @click=\"startScan\" class=\"bg-main button-small radius-extra button\">\n Check Tickets\n </Button>\n <div v-if=\"isScanning\" class=\"barcode-scanner-modal\">\n <div class=\"square\"></div>\n <div class=\"zoom-ratio-wrapper\" v-if=\"minZoomRatio !== undefined && maxZoomRatio !== undefined\">\n <input type=\"range\" :min=\"minZoomRatio\" :max=\"maxZoomRatio\" @input=\"setZoomRatio\" />\n </div>\n <Button @click=\"stopScan\" class=\"bg-white t-black stop-scan-button\">Stop Scan</Button>\n <Button v-if=\"isTorchAvailable\" @click=\"toggleTorch\" class=\"bg-white torch-button\">\n Toggle Torch\n </Button>\n </div>\n </div>\n</template>\n\n<script setup>\nimport { ref, onMounted, onUnmounted } from 'vue'\nimport { BarcodeScanner } from '@capacitor-mlkit/barcode-scanning'\nimport Button from '@pf/src/components/Button/Button.vue'\nimport * as tickets from '@pf/src/modules/events/store/tickets'\n\nconst emits = defineEmits(['qrcodecheck'])\nconst error = ref('')\nconst isScanning = ref(false)\nconst isTorchAvailable = ref(false)\nconst minZoomRatio = ref(undefined)\nconst maxZoomRatio = ref(undefined)\nconst isProcessing = ref(false)\n\nonMounted(async () => {\n const { supported } = await BarcodeScanner.isSupported()\n if (!supported) {\n error.value = 'Barcode scanning is not supported on this device'\n }\n const { available } = await BarcodeScanner.isTorchAvailable()\n isTorchAvailable.value = available\n})\n\nonUnmounted(async () => {\n await stopScan()\n})\n\nconst SCAN_TIMEOUT =
|
1
|
+
{"version":3,"file":"ButtonCheck.vue.cjs","sources":["../../../../../../../src/modules/events/components/elements/ButtonCheck.vue"],"sourcesContent":["<template>\n <div>\n <Button @click=\"startScan\" class=\"bg-main button-small radius-extra button\">\n Check Tickets\n </Button>\n \n <teleport to=\"body\" v-if=\"isScanning\">\n <div v-if=\"isScanning\" class=\"barcode-scanner-modal\">\n <div class=\"square\"></div>\n <div class=\"zoom-ratio-wrapper\" v-if=\"minZoomRatio !== undefined && maxZoomRatio !== undefined\">\n <input type=\"range\" :min=\"minZoomRatio\" :max=\"maxZoomRatio\" @input=\"setZoomRatio\" />\n </div>\n <Button @click=\"stopScan\" class=\"bg-white t-black stop-scan-button\">Stop Scan</Button>\n <Button v-if=\"isTorchAvailable\" @click=\"toggleTorch\" class=\"bg-white torch-button\">\n Toggle Torch\n </Button>\n </div>\n </teleport>\n </div>\n</template>\n\n<script setup>\nimport { ref, onMounted, onUnmounted } from 'vue'\nimport { BarcodeScanner } from '@capacitor-mlkit/barcode-scanning'\nimport Button from '@pf/src/components/Button/Button.vue'\nimport * as tickets from '@pf/src/modules/events/store/tickets'\n\nconst emits = defineEmits(['qrcodecheck'])\nconst error = ref('')\nconst isScanning = ref(false)\nconst isTorchAvailable = ref(false)\nconst minZoomRatio = ref(undefined)\nconst maxZoomRatio = ref(undefined)\nconst isProcessing = ref(false)\n\nonMounted(async () => {\n const { supported } = await BarcodeScanner.isSupported()\n if (!supported) {\n error.value = 'Barcode scanning is not supported on this device'\n }\n const { available } = await BarcodeScanner.isTorchAvailable()\n isTorchAvailable.value = available\n})\n\nonUnmounted(async () => {\n await stopScan()\n})\n\nconst SCAN_TIMEOUT = 1000 // 5 секунд (можно изменить по вашему усмотрению)\n\nasync function startScan() {\n try {\n // const { camera } = await BarcodeScanner.checkPermissions()\n // if (camera !== 'granted') {\n // const { camera: newStatus } = await BarcodeScanner.requestPermissions()\n // if (newStatus !== 'granted') {\n // throw new Error('Camera permission is required to scan barcodes')\n // }\n // }\n document.querySelector('body')?.classList.add('barcode-scanner-active')\n document.querySelector('html')?.classList.add('barcode-scanner-active-html')\n isScanning.value = true\n // await BarcodeScanner.addListener('barcodeScanned', async (result) => {\n // if (!isProcessing.value) {\n // await processBarcode(result.barcode)\n // }\n // })\n // await BarcodeScanner.startScan()\n // const { zoomRatio: min } = await BarcodeScanner.getMinZoomRatio()\n // const { zoomRatio: max } = await BarcodeScanner.getMaxZoomRatio()\n // minZoomRatio.value = min\n // maxZoomRatio.value = max\n } catch (e) {\n error.value = e.message\n alert(`Error: ${error.value}`)\n }\n}\n\nasync function stopScan() {\n try {\n document.querySelector('body')?.classList.remove('barcode-scanner-active')\n document.querySelector('html')?.classList.remove('barcode-scanner-active-html')\n isScanning.value = false\n await BarcodeScanner.stopScan()\n await BarcodeScanner.removeAllListeners()\n } catch (e) {\n error.value = e.message\n alert(`Error stopping scan: ${error.value}`)\n }\n}\n\nasync function processBarcode(barcode) {\n if (isProcessing.value) return;\n isProcessing.value = true;\n \n try {\n if (!barcode || !barcode.rawValue) {\n throw new Error('Invalid barcode data');\n }\n console.log('barcode is', barcode);\n\n const response = await tickets.actions.update({\n _id: barcode.rawValue,\n status: 'used',\n check: true\n });\n\n alert(\"Ticket checked. And it's all right!\");\n emits('qrcodecheck');\n } catch (e) {\n console.error(e);\n alert(`Ticket is not found, already used or deactivated!`);\n } finally {\n // Устанавливаем таймаут перед следующим сканированием\n setTimeout(() => {\n isProcessing.value = false;\n }, SCAN_TIMEOUT);\n }\n}\n\nasync function setZoomRatio(event) {\n const zoomRatio = parseFloat(event.target.value)\n await BarcodeScanner.setZoomRatio({ zoomRatio })\n}\n\nasync function toggleTorch() {\n await BarcodeScanner.toggleTorch()\n}\n</script>\n\n<style>\n.barcode-scanner-modal {\n visibility: visible;\n position: fixed;\n top: 0;\n left: 100%;\n width: 100%;\n height: 100%;\n background-color: rgba(0, 0, 0, 0);\n display: flex;\n flex-direction: column;\n justify-content: center;\n align-items: center;\n}\n\n.square {\n width: 200px;\n height: 200px;\n border: 2px solid white;\n border-radius: 10px;\n}\n\n.zoom-ratio-wrapper {\n width: 80%;\n margin-top: 20px;\n}\n\n.stop-scan-button,\n.torch-button {\n margin-top: 20px;\n}\n\n/* Existing styles */\nbody.barcode-scanner-active {\n left: -100%;\n/* visibility: hidden !important;*/\n background: transparent !important;\n --background: transparent;\n --ion-background-color: transparent;\n}\n\nhtml.barcode-scanner-active-html {\n background: transparent !important;\n}\n</style>\n"],"names":["ref","onMounted","BarcodeScanner","onUnmounted"],"mappings":";;;;;;;;;;;;;;;;;;;;AA4BA,UAAM,QAAQA,IAAG,IAAC,EAAE;AACpB,UAAM,aAAaA,IAAG,IAAC,KAAK;AAC5B,UAAM,mBAAmBA,IAAG,IAAC,KAAK;AAClC,UAAM,eAAeA,IAAG,IAAC,MAAS;AAClC,UAAM,eAAeA,IAAG,IAAC,MAAS;AACbA,QAAG,IAAC,KAAK;AAE9BC,QAAAA,UAAU,YAAY;AACpB,YAAM,EAAE,UAAS,IAAK,MAAMC,MAAAA,eAAe,YAAa;AACxD,UAAI,CAAC,WAAW;AACd,cAAM,QAAQ;AAAA,MACf;AACD,YAAM,EAAE,UAAS,IAAK,MAAMA,MAAAA,eAAe,iBAAkB;AAC7D,uBAAiB,QAAQ;AAAA,IAC3B,CAAC;AAEDC,QAAAA,YAAY,YAAY;AACtB,YAAM,SAAU;AAAA,IAClB,CAAC;AAID,mBAAe,YAAY;;AACzB,UAAI;AAQF,uBAAS,cAAc,MAAM,MAA7B,mBAAgC,UAAU,IAAI;AAC9C,uBAAS,cAAc,MAAM,MAA7B,mBAAgC,UAAU,IAAI;AAC9C,mBAAW,QAAQ;AAAA,MAWpB,SAAQ,GAAG;AACV,cAAM,QAAQ,EAAE;AAChB,cAAM,UAAU,MAAM,KAAK,EAAE;AAAA,MAC9B;AAAA,IACH;AAEA,mBAAe,WAAW;;AACxB,UAAI;AACF,uBAAS,cAAc,MAAM,MAA7B,mBAAgC,UAAU,OAAO;AACjD,uBAAS,cAAc,MAAM,MAA7B,mBAAgC,UAAU,OAAO;AACjD,mBAAW,QAAQ;AACnB,cAAMD,MAAAA,eAAe,SAAU;AAC/B,cAAMA,MAAAA,eAAe,mBAAoB;AAAA,MAC1C,SAAQ,GAAG;AACV,cAAM,QAAQ,EAAE;AAChB,cAAM,wBAAwB,MAAM,KAAK,EAAE;AAAA,MAC5C;AAAA,IACH;AA+BA,mBAAe,aAAa,OAAO;AACjC,YAAM,YAAY,WAAW,MAAM,OAAO,KAAK;AAC/C,YAAMA,qBAAe,aAAa,EAAE,WAAW;AAAA,IACjD;AAEA,mBAAe,cAAc;AAC3B,YAAMA,MAAAA,eAAe,YAAa;AAAA,IACpC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
|
@@ -1,7 +1,7 @@
|
|
1
|
-
import { ref, onMounted, onUnmounted, openBlock, createElementBlock, createVNode, withCtx, createTextVNode, createElementVNode, createCommentVNode
|
1
|
+
import { ref, onMounted, onUnmounted, openBlock, createElementBlock, createVNode, withCtx, createTextVNode, createBlock, Teleport, createElementVNode, createCommentVNode } from "vue";
|
2
2
|
import { BarcodeScanner } from "../../../../../../node_modules/@capacitor-mlkit/barcode-scanning/dist/esm/index.js";
|
3
|
-
import _sfc_main$1 from "../../../../components/Button/Button.
|
4
|
-
import
|
3
|
+
import _sfc_main$1 from "../../../../components/Button/Button.vue2.js";
|
4
|
+
import "../../store/tickets.js";
|
5
5
|
/* empty css */
|
6
6
|
const _hoisted_1 = {
|
7
7
|
key: 0,
|
@@ -12,18 +12,16 @@ const _hoisted_2 = {
|
|
12
12
|
class: "zoom-ratio-wrapper"
|
13
13
|
};
|
14
14
|
const _hoisted_3 = ["min", "max"];
|
15
|
-
const SCAN_TIMEOUT = 2500;
|
16
15
|
const _sfc_main = {
|
17
16
|
__name: "ButtonCheck",
|
18
17
|
emits: ["qrcodecheck"],
|
19
18
|
setup(__props, { emit: __emit }) {
|
20
|
-
const emits = __emit;
|
21
19
|
const error = ref("");
|
22
20
|
const isScanning = ref(false);
|
23
21
|
const isTorchAvailable = ref(false);
|
24
22
|
const minZoomRatio = ref(void 0);
|
25
23
|
const maxZoomRatio = ref(void 0);
|
26
|
-
|
24
|
+
ref(false);
|
27
25
|
onMounted(async () => {
|
28
26
|
const { supported } = await BarcodeScanner.isSupported();
|
29
27
|
if (!supported) {
|
@@ -38,26 +36,9 @@ const _sfc_main = {
|
|
38
36
|
async function startScan() {
|
39
37
|
var _a, _b;
|
40
38
|
try {
|
41
|
-
const { camera } = await BarcodeScanner.checkPermissions();
|
42
|
-
if (camera !== "granted") {
|
43
|
-
const { camera: newStatus } = await BarcodeScanner.requestPermissions();
|
44
|
-
if (newStatus !== "granted") {
|
45
|
-
throw new Error("Camera permission is required to scan barcodes");
|
46
|
-
}
|
47
|
-
}
|
48
39
|
(_a = document.querySelector("body")) == null ? void 0 : _a.classList.add("barcode-scanner-active");
|
49
40
|
(_b = document.querySelector("html")) == null ? void 0 : _b.classList.add("barcode-scanner-active-html");
|
50
41
|
isScanning.value = true;
|
51
|
-
await BarcodeScanner.addListener("barcodeScanned", async (result) => {
|
52
|
-
if (!isProcessing.value) {
|
53
|
-
await processBarcode(result.barcode);
|
54
|
-
}
|
55
|
-
});
|
56
|
-
await BarcodeScanner.startScan();
|
57
|
-
const { zoomRatio: min } = await BarcodeScanner.getMinZoomRatio();
|
58
|
-
const { zoomRatio: max } = await BarcodeScanner.getMaxZoomRatio();
|
59
|
-
minZoomRatio.value = min;
|
60
|
-
maxZoomRatio.value = max;
|
61
42
|
} catch (e) {
|
62
43
|
error.value = e.message;
|
63
44
|
alert(`Error: ${error.value}`);
|
@@ -76,30 +57,6 @@ const _sfc_main = {
|
|
76
57
|
alert(`Error stopping scan: ${error.value}`);
|
77
58
|
}
|
78
59
|
}
|
79
|
-
async function processBarcode(barcode) {
|
80
|
-
if (isProcessing.value) return;
|
81
|
-
isProcessing.value = true;
|
82
|
-
try {
|
83
|
-
if (!barcode || !barcode.rawValue) {
|
84
|
-
throw new Error("Invalid barcode data");
|
85
|
-
}
|
86
|
-
console.log("barcode is", barcode);
|
87
|
-
const response = await actions.update({
|
88
|
-
_id: barcode.rawValue,
|
89
|
-
status: "used",
|
90
|
-
check: true
|
91
|
-
});
|
92
|
-
alert("Ticket checked. And it's all right!");
|
93
|
-
emits("qrcodecheck");
|
94
|
-
} catch (e) {
|
95
|
-
console.error(e);
|
96
|
-
alert(`Ticket is not found, already used or deactivated!`);
|
97
|
-
} finally {
|
98
|
-
setTimeout(() => {
|
99
|
-
isProcessing.value = false;
|
100
|
-
}, SCAN_TIMEOUT);
|
101
|
-
}
|
102
|
-
}
|
103
60
|
async function setZoomRatio(event) {
|
104
61
|
const zoomRatio = parseFloat(event.target.value);
|
105
62
|
await BarcodeScanner.setZoomRatio({ zoomRatio });
|
@@ -118,35 +75,40 @@ const _sfc_main = {
|
|
118
75
|
])),
|
119
76
|
_: 1
|
120
77
|
}),
|
121
|
-
isScanning.value ? (openBlock(),
|
122
|
-
|
123
|
-
|
124
|
-
|
125
|
-
|
126
|
-
|
127
|
-
|
128
|
-
|
129
|
-
|
130
|
-
|
131
|
-
|
132
|
-
|
133
|
-
|
134
|
-
|
135
|
-
|
136
|
-
|
137
|
-
|
138
|
-
|
139
|
-
|
140
|
-
|
141
|
-
|
142
|
-
|
143
|
-
|
144
|
-
|
145
|
-
|
146
|
-
|
147
|
-
|
148
|
-
|
149
|
-
|
78
|
+
isScanning.value ? (openBlock(), createBlock(Teleport, {
|
79
|
+
key: 0,
|
80
|
+
to: "body"
|
81
|
+
}, [
|
82
|
+
isScanning.value ? (openBlock(), createElementBlock("div", _hoisted_1, [
|
83
|
+
_cache[3] || (_cache[3] = createElementVNode("div", { class: "square" }, null, -1)),
|
84
|
+
minZoomRatio.value !== void 0 && maxZoomRatio.value !== void 0 ? (openBlock(), createElementBlock("div", _hoisted_2, [
|
85
|
+
createElementVNode("input", {
|
86
|
+
type: "range",
|
87
|
+
min: minZoomRatio.value,
|
88
|
+
max: maxZoomRatio.value,
|
89
|
+
onInput: setZoomRatio
|
90
|
+
}, null, 40, _hoisted_3)
|
91
|
+
])) : createCommentVNode("", true),
|
92
|
+
createVNode(_sfc_main$1, {
|
93
|
+
onClick: stopScan,
|
94
|
+
class: "bg-white t-black stop-scan-button"
|
95
|
+
}, {
|
96
|
+
default: withCtx(() => _cache[1] || (_cache[1] = [
|
97
|
+
createTextVNode("Stop Scan")
|
98
|
+
])),
|
99
|
+
_: 1
|
100
|
+
}),
|
101
|
+
isTorchAvailable.value ? (openBlock(), createBlock(_sfc_main$1, {
|
102
|
+
key: 1,
|
103
|
+
onClick: toggleTorch,
|
104
|
+
class: "bg-white torch-button"
|
105
|
+
}, {
|
106
|
+
default: withCtx(() => _cache[2] || (_cache[2] = [
|
107
|
+
createTextVNode(" Toggle Torch ")
|
108
|
+
])),
|
109
|
+
_: 1
|
110
|
+
})) : createCommentVNode("", true)
|
111
|
+
])) : createCommentVNode("", true)
|
150
112
|
])) : createCommentVNode("", true)
|
151
113
|
]);
|
152
114
|
};
|
package/dist/prometheus-framework/src/modules/events/components/elements/ButtonCheck.vue.js.map
CHANGED
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"ButtonCheck.vue.js","sources":["../../../../../../../src/modules/events/components/elements/ButtonCheck.vue"],"sourcesContent":["<template>\n <div>\n <Button @click=\"startScan\" class=\"bg-main button-small radius-extra button\">\n Check Tickets\n </Button>\n <div v-if=\"isScanning\" class=\"barcode-scanner-modal\">\n <div class=\"square\"></div>\n <div class=\"zoom-ratio-wrapper\" v-if=\"minZoomRatio !== undefined && maxZoomRatio !== undefined\">\n <input type=\"range\" :min=\"minZoomRatio\" :max=\"maxZoomRatio\" @input=\"setZoomRatio\" />\n </div>\n <Button @click=\"stopScan\" class=\"bg-white t-black stop-scan-button\">Stop Scan</Button>\n <Button v-if=\"isTorchAvailable\" @click=\"toggleTorch\" class=\"bg-white torch-button\">\n Toggle Torch\n </Button>\n </div>\n </div>\n</template>\n\n<script setup>\nimport { ref, onMounted, onUnmounted } from 'vue'\nimport { BarcodeScanner } from '@capacitor-mlkit/barcode-scanning'\nimport Button from '@pf/src/components/Button/Button.vue'\nimport * as tickets from '@pf/src/modules/events/store/tickets'\n\nconst emits = defineEmits(['qrcodecheck'])\nconst error = ref('')\nconst isScanning = ref(false)\nconst isTorchAvailable = ref(false)\nconst minZoomRatio = ref(undefined)\nconst maxZoomRatio = ref(undefined)\nconst isProcessing = ref(false)\n\nonMounted(async () => {\n const { supported } = await BarcodeScanner.isSupported()\n if (!supported) {\n error.value = 'Barcode scanning is not supported on this device'\n }\n const { available } = await BarcodeScanner.isTorchAvailable()\n isTorchAvailable.value = available\n})\n\nonUnmounted(async () => {\n await stopScan()\n})\n\nconst SCAN_TIMEOUT =
|
1
|
+
{"version":3,"file":"ButtonCheck.vue.js","sources":["../../../../../../../src/modules/events/components/elements/ButtonCheck.vue"],"sourcesContent":["<template>\n <div>\n <Button @click=\"startScan\" class=\"bg-main button-small radius-extra button\">\n Check Tickets\n </Button>\n \n <teleport to=\"body\" v-if=\"isScanning\">\n <div v-if=\"isScanning\" class=\"barcode-scanner-modal\">\n <div class=\"square\"></div>\n <div class=\"zoom-ratio-wrapper\" v-if=\"minZoomRatio !== undefined && maxZoomRatio !== undefined\">\n <input type=\"range\" :min=\"minZoomRatio\" :max=\"maxZoomRatio\" @input=\"setZoomRatio\" />\n </div>\n <Button @click=\"stopScan\" class=\"bg-white t-black stop-scan-button\">Stop Scan</Button>\n <Button v-if=\"isTorchAvailable\" @click=\"toggleTorch\" class=\"bg-white torch-button\">\n Toggle Torch\n </Button>\n </div>\n </teleport>\n </div>\n</template>\n\n<script setup>\nimport { ref, onMounted, onUnmounted } from 'vue'\nimport { BarcodeScanner } from '@capacitor-mlkit/barcode-scanning'\nimport Button from '@pf/src/components/Button/Button.vue'\nimport * as tickets from '@pf/src/modules/events/store/tickets'\n\nconst emits = defineEmits(['qrcodecheck'])\nconst error = ref('')\nconst isScanning = ref(false)\nconst isTorchAvailable = ref(false)\nconst minZoomRatio = ref(undefined)\nconst maxZoomRatio = ref(undefined)\nconst isProcessing = ref(false)\n\nonMounted(async () => {\n const { supported } = await BarcodeScanner.isSupported()\n if (!supported) {\n error.value = 'Barcode scanning is not supported on this device'\n }\n const { available } = await BarcodeScanner.isTorchAvailable()\n isTorchAvailable.value = available\n})\n\nonUnmounted(async () => {\n await stopScan()\n})\n\nconst SCAN_TIMEOUT = 1000 // 5 секунд (можно изменить по вашему усмотрению)\n\nasync function startScan() {\n try {\n // const { camera } = await BarcodeScanner.checkPermissions()\n // if (camera !== 'granted') {\n // const { camera: newStatus } = await BarcodeScanner.requestPermissions()\n // if (newStatus !== 'granted') {\n // throw new Error('Camera permission is required to scan barcodes')\n // }\n // }\n document.querySelector('body')?.classList.add('barcode-scanner-active')\n document.querySelector('html')?.classList.add('barcode-scanner-active-html')\n isScanning.value = true\n // await BarcodeScanner.addListener('barcodeScanned', async (result) => {\n // if (!isProcessing.value) {\n // await processBarcode(result.barcode)\n // }\n // })\n // await BarcodeScanner.startScan()\n // const { zoomRatio: min } = await BarcodeScanner.getMinZoomRatio()\n // const { zoomRatio: max } = await BarcodeScanner.getMaxZoomRatio()\n // minZoomRatio.value = min\n // maxZoomRatio.value = max\n } catch (e) {\n error.value = e.message\n alert(`Error: ${error.value}`)\n }\n}\n\nasync function stopScan() {\n try {\n document.querySelector('body')?.classList.remove('barcode-scanner-active')\n document.querySelector('html')?.classList.remove('barcode-scanner-active-html')\n isScanning.value = false\n await BarcodeScanner.stopScan()\n await BarcodeScanner.removeAllListeners()\n } catch (e) {\n error.value = e.message\n alert(`Error stopping scan: ${error.value}`)\n }\n}\n\nasync function processBarcode(barcode) {\n if (isProcessing.value) return;\n isProcessing.value = true;\n \n try {\n if (!barcode || !barcode.rawValue) {\n throw new Error('Invalid barcode data');\n }\n console.log('barcode is', barcode);\n\n const response = await tickets.actions.update({\n _id: barcode.rawValue,\n status: 'used',\n check: true\n });\n\n alert(\"Ticket checked. And it's all right!\");\n emits('qrcodecheck');\n } catch (e) {\n console.error(e);\n alert(`Ticket is not found, already used or deactivated!`);\n } finally {\n // Устанавливаем таймаут перед следующим сканированием\n setTimeout(() => {\n isProcessing.value = false;\n }, SCAN_TIMEOUT);\n }\n}\n\nasync function setZoomRatio(event) {\n const zoomRatio = parseFloat(event.target.value)\n await BarcodeScanner.setZoomRatio({ zoomRatio })\n}\n\nasync function toggleTorch() {\n await BarcodeScanner.toggleTorch()\n}\n</script>\n\n<style>\n.barcode-scanner-modal {\n visibility: visible;\n position: fixed;\n top: 0;\n left: 100%;\n width: 100%;\n height: 100%;\n background-color: rgba(0, 0, 0, 0);\n display: flex;\n flex-direction: column;\n justify-content: center;\n align-items: center;\n}\n\n.square {\n width: 200px;\n height: 200px;\n border: 2px solid white;\n border-radius: 10px;\n}\n\n.zoom-ratio-wrapper {\n width: 80%;\n margin-top: 20px;\n}\n\n.stop-scan-button,\n.torch-button {\n margin-top: 20px;\n}\n\n/* Existing styles */\nbody.barcode-scanner-active {\n left: -100%;\n/* visibility: hidden !important;*/\n background: transparent !important;\n --background: transparent;\n --ion-background-color: transparent;\n}\n\nhtml.barcode-scanner-active-html {\n background: transparent !important;\n}\n</style>\n"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;AA4BA,UAAM,QAAQ,IAAI,EAAE;AACpB,UAAM,aAAa,IAAI,KAAK;AAC5B,UAAM,mBAAmB,IAAI,KAAK;AAClC,UAAM,eAAe,IAAI,MAAS;AAClC,UAAM,eAAe,IAAI,MAAS;AACb,QAAI,KAAK;AAE9B,cAAU,YAAY;AACpB,YAAM,EAAE,UAAS,IAAK,MAAM,eAAe,YAAa;AACxD,UAAI,CAAC,WAAW;AACd,cAAM,QAAQ;AAAA,MACf;AACD,YAAM,EAAE,UAAS,IAAK,MAAM,eAAe,iBAAkB;AAC7D,uBAAiB,QAAQ;AAAA,IAC3B,CAAC;AAED,gBAAY,YAAY;AACtB,YAAM,SAAU;AAAA,IAClB,CAAC;AAID,mBAAe,YAAY;;AACzB,UAAI;AAQF,uBAAS,cAAc,MAAM,MAA7B,mBAAgC,UAAU,IAAI;AAC9C,uBAAS,cAAc,MAAM,MAA7B,mBAAgC,UAAU,IAAI;AAC9C,mBAAW,QAAQ;AAAA,MAWpB,SAAQ,GAAG;AACV,cAAM,QAAQ,EAAE;AAChB,cAAM,UAAU,MAAM,KAAK,EAAE;AAAA,MAC9B;AAAA,IACH;AAEA,mBAAe,WAAW;;AACxB,UAAI;AACF,uBAAS,cAAc,MAAM,MAA7B,mBAAgC,UAAU,OAAO;AACjD,uBAAS,cAAc,MAAM,MAA7B,mBAAgC,UAAU,OAAO;AACjD,mBAAW,QAAQ;AACnB,cAAM,eAAe,SAAU;AAC/B,cAAM,eAAe,mBAAoB;AAAA,MAC1C,SAAQ,GAAG;AACV,cAAM,QAAQ,EAAE;AAChB,cAAM,wBAAwB,MAAM,KAAK,EAAE;AAAA,MAC5C;AAAA,IACH;AA+BA,mBAAe,aAAa,OAAO;AACjC,YAAM,YAAY,WAAW,MAAM,OAAO,KAAK;AAC/C,YAAM,eAAe,aAAa,EAAE,WAAW;AAAA,IACjD;AAEA,mBAAe,cAAc;AAC3B,YAAM,eAAe,YAAa;AAAA,IACpC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
|
@@ -1,7 +1,7 @@
|
|
1
1
|
"use strict";
|
2
2
|
Object.defineProperties(exports, { __esModule: { value: true }, [Symbol.toStringTag]: { value: "Module" } });
|
3
3
|
const vue = require("vue");
|
4
|
-
const Button = require("../../../../components/Button/Button.
|
4
|
+
const Button = require("../../../../components/Button/Button.vue2.cjs");
|
5
5
|
require("../../../auth/views/store/auth.cjs");
|
6
6
|
const tickets = require("../../store/tickets.cjs");
|
7
7
|
;/* empty css */
|
@@ -1,5 +1,5 @@
|
|
1
1
|
import { openBlock, createBlock, withCtx, createTextVNode, toDisplayString } from "vue";
|
2
|
-
import _sfc_main$1 from "../../../../components/Button/Button.
|
2
|
+
import _sfc_main$1 from "../../../../components/Button/Button.vue2.js";
|
3
3
|
import "../../../auth/views/store/auth.js";
|
4
4
|
import { actions } from "../../store/tickets.js";
|
5
5
|
/* empty css */
|
@@ -8,8 +8,8 @@ const vueDatepicker = require("../../../../../../node_modules/@vuepic/vue-datepi
|
|
8
8
|
;/* empty css */
|
9
9
|
;/* empty css */
|
10
10
|
const Block = require("../../../../components/Block/Block.vue.cjs");
|
11
|
-
const Popup = require("../../../../components/Popup/Popup.
|
12
|
-
const Field = require("../../../../components/Field/Field.
|
11
|
+
const Popup = require("../../../../components/Popup/Popup.vue2.cjs");
|
12
|
+
const Field = require("../../../../components/Field/Field.vue2.cjs");
|
13
13
|
const BlockTags = require("../../../../components/FieldTags/BlockTags.vue.cjs");
|
14
14
|
const Checkbox = require("../../../../components/Checkbox/Checkbox.vue.cjs");
|
15
15
|
;/* empty css */
|
@@ -17,7 +17,7 @@ const Upload = require("../../../../components/Upload/Upload.vue.cjs");
|
|
17
17
|
const UploadImage = require("../../../../components/UploadImage/UploadImage.vue.cjs");
|
18
18
|
const EditImages = require("../../../../components/EditImages/EditImages.vue.cjs");
|
19
19
|
const Feed = require("../../../../components/Feed/Feed.vue.cjs");
|
20
|
-
const Button = require("../../../../components/Button/Button.
|
20
|
+
const Button = require("../../../../components/Button/Button.vue2.cjs");
|
21
21
|
const Card = require("../../../globals/views/components/blocks/Card.vue.cjs");
|
22
22
|
const IconDelete = require("../../../icons/navigation/IconDelete.vue.cjs");
|
23
23
|
const vueRouter = require("vue-router");
|
@@ -6,8 +6,8 @@ import Vn from "../../../../../../node_modules/@vuepic/vue-datepicker/dist/vue-d
|
|
6
6
|
/* empty css */
|
7
7
|
/* empty css */
|
8
8
|
import _sfc_main$4 from "../../../../components/Block/Block.vue.js";
|
9
|
-
import _sfc_main$7 from "../../../../components/Popup/Popup.
|
10
|
-
import Field from "../../../../components/Field/Field.
|
9
|
+
import _sfc_main$7 from "../../../../components/Popup/Popup.vue2.js";
|
10
|
+
import Field from "../../../../components/Field/Field.vue2.js";
|
11
11
|
import _sfc_main$8 from "../../../../components/FieldTags/BlockTags.vue.js";
|
12
12
|
import _sfc_main$2 from "../../../../components/Checkbox/Checkbox.vue.js";
|
13
13
|
/* empty css */
|
@@ -15,7 +15,7 @@ import Upload from "../../../../components/Upload/Upload.vue.js";
|
|
15
15
|
import _sfc_main$1 from "../../../../components/UploadImage/UploadImage.vue.js";
|
16
16
|
import _sfc_main$3 from "../../../../components/EditImages/EditImages.vue.js";
|
17
17
|
import _sfc_main$a from "../../../../components/Feed/Feed.vue.js";
|
18
|
-
import _sfc_main$b from "../../../../components/Button/Button.
|
18
|
+
import _sfc_main$b from "../../../../components/Button/Button.vue2.js";
|
19
19
|
import _sfc_main$9 from "../../../globals/views/components/blocks/Card.vue.js";
|
20
20
|
import _sfc_main$5 from "../../../icons/navigation/IconDelete.vue.js";
|
21
21
|
import { useRoute, useRouter } from "vue-router";
|
package/dist/prometheus-framework/src/modules/events/components/pages/EditEventTickets.vue.cjs
CHANGED
@@ -3,9 +3,9 @@ Object.defineProperties(exports, { __esModule: { value: true }, [Symbol.toString
|
|
3
3
|
const vue = require("vue");
|
4
4
|
const Feed = require("../../../../components/Feed/Feed.vue.cjs");
|
5
5
|
const Block = require("../../../../components/Block/Block.vue.cjs");
|
6
|
-
const Popup = require("../../../../components/Popup/Popup.
|
7
|
-
const Field = require("../../../../components/Field/Field.
|
8
|
-
const Button = require("../../../../components/Button/Button.
|
6
|
+
const Popup = require("../../../../components/Popup/Popup.vue2.cjs");
|
7
|
+
const Field = require("../../../../components/Field/Field.vue2.cjs");
|
8
|
+
const Button = require("../../../../components/Button/Button.vue2.cjs");
|
9
9
|
const ButtonCheck = require("../elements/ButtonCheck.vue.cjs");
|
10
10
|
const IconDelete = require("../../../icons/navigation/IconDelete.vue.cjs");
|
11
11
|
const IconAdd = require("../../../icons/navigation/IconAdd.vue.cjs");
|
package/dist/prometheus-framework/src/modules/events/components/pages/EditEventTickets.vue.js
CHANGED
@@ -1,9 +1,9 @@
|
|
1
1
|
import { ref, onMounted, unref, openBlock, createElementBlock, createElementVNode, createVNode, withCtx, Fragment, renderList, createTextVNode, toDisplayString, createBlock, createCommentVNode } from "vue";
|
2
2
|
import _sfc_main$7 from "../../../../components/Feed/Feed.vue.js";
|
3
3
|
import _sfc_main$3 from "../../../../components/Block/Block.vue.js";
|
4
|
-
import _sfc_main$2 from "../../../../components/Popup/Popup.
|
5
|
-
import Field from "../../../../components/Field/Field.
|
6
|
-
import _sfc_main$6 from "../../../../components/Button/Button.
|
4
|
+
import _sfc_main$2 from "../../../../components/Popup/Popup.vue2.js";
|
5
|
+
import Field from "../../../../components/Field/Field.vue2.js";
|
6
|
+
import _sfc_main$6 from "../../../../components/Button/Button.vue2.js";
|
7
7
|
import _sfc_main$1 from "../elements/ButtonCheck.vue.js";
|
8
8
|
import _sfc_main$5 from "../../../icons/navigation/IconDelete.vue.js";
|
9
9
|
import _sfc_main$4 from "../../../icons/navigation/IconAdd.vue.js";
|
@@ -1,7 +1,7 @@
|
|
1
1
|
"use strict";
|
2
2
|
Object.defineProperties(exports, { __esModule: { value: true }, [Symbol.toStringTag]: { value: "Module" } });
|
3
3
|
const vue = require("vue");
|
4
|
-
;/* empty css
|
4
|
+
;/* empty css */
|
5
5
|
const HeroEvent = require("../sections/HeroEvent.vue.cjs");
|
6
6
|
const SectionMainGuest = require("../sections/SectionMainGuest.vue.cjs");
|
7
7
|
const SectionSpecialGuests = require("../sections/SectionSpecialGuests.vue.cjs");
|
@@ -1,5 +1,5 @@
|
|
1
1
|
import { ref, onMounted, openBlock, createElementBlock, createVNode, TransitionGroup, withCtx, Fragment, renderList, createCommentVNode, createBlock, normalizeStyle, createElementVNode, normalizeClass, resolveDynamicComponent, mergeProps } from "vue";
|
2
|
-
/* empty css
|
2
|
+
/* empty css */
|
3
3
|
import HeroEvent from "../sections/HeroEvent.vue.js";
|
4
4
|
import _sfc_main$1 from "../sections/SectionMainGuest.vue.js";
|
5
5
|
import _sfc_main$2 from "../sections/SectionSpecialGuests.vue.js";
|
package/dist/prometheus-framework/src/modules/events/components/pages/EventsBackoffice.vue.cjs
CHANGED
@@ -2,7 +2,7 @@
|
|
2
2
|
Object.defineProperties(exports, { __esModule: { value: true }, [Symbol.toStringTag]: { value: "Module" } });
|
3
3
|
const vue = require("vue");
|
4
4
|
const vueRouter = require("vue-router");
|
5
|
-
const Tab = require("../../../../components/Tab/Tab.
|
5
|
+
const Tab = require("../../../../components/Tab/Tab.vue2.cjs");
|
6
6
|
const Feed = require("../../../../components/Feed/Feed.vue.cjs");
|
7
7
|
const CardEvent = require("../blocks/CardEvent.vue.cjs");
|
8
8
|
const auth = require("../../../auth/views/store/auth.cjs");
|
package/dist/prometheus-framework/src/modules/events/components/pages/EventsBackoffice.vue.js
CHANGED
@@ -1,6 +1,6 @@
|
|
1
1
|
import { ref, watch, openBlock, createElementBlock, createElementVNode, unref, createCommentVNode, createBlock, createVNode, withCtx, Fragment, renderList, withModifiers } from "vue";
|
2
2
|
import { useRoute, useRouter } from "vue-router";
|
3
|
-
import _sfc_main$1 from "../../../../components/Tab/Tab.
|
3
|
+
import _sfc_main$1 from "../../../../components/Tab/Tab.vue2.js";
|
4
4
|
import _sfc_main$2 from "../../../../components/Feed/Feed.vue.js";
|
5
5
|
import _sfc_main$3 from "../blocks/CardEvent.vue.js";
|
6
6
|
import { state } from "../../../auth/views/store/auth.js";
|
@@ -1,7 +1,7 @@
|
|
1
1
|
"use strict";
|
2
2
|
Object.defineProperties(exports, { __esModule: { value: true }, [Symbol.toStringTag]: { value: "Module" } });
|
3
3
|
const vue = require("vue");
|
4
|
-
;/* empty css
|
4
|
+
;/* empty css */
|
5
5
|
const EmptyState = require("../../../../components/EmptyState/EmptyState.vue.cjs");
|
6
6
|
const CardEvent = require("../blocks/CardEvent.vue.cjs");
|
7
7
|
const SkeletonEvent = require("../../../icons/skeletons/SkeletonEvent.vue.cjs");
|
@@ -1,5 +1,5 @@
|
|
1
1
|
import { ref, onMounted, openBlock, createElementBlock, createVNode, TransitionGroup, withCtx, Fragment, renderList, createBlock, createCommentVNode, Transition } from "vue";
|
2
|
-
/* empty css
|
2
|
+
/* empty css */
|
3
3
|
import _sfc_main$1 from "../../../../components/EmptyState/EmptyState.vue.js";
|
4
4
|
import _sfc_main$2 from "../blocks/CardEvent.vue.js";
|
5
5
|
import SkeletonEvent from "../../../icons/skeletons/SkeletonEvent.vue.js";
|
@@ -1,7 +1,7 @@
|
|
1
1
|
"use strict";
|
2
2
|
Object.defineProperties(exports, { __esModule: { value: true }, [Symbol.toStringTag]: { value: "Module" } });
|
3
3
|
const vue = require("vue");
|
4
|
-
;/* empty css
|
4
|
+
;/* empty css */
|
5
5
|
const EmptyState = require("../../../../components/EmptyState/EmptyState.vue.cjs");
|
6
6
|
const CardEvent = require("../blocks/CardEvent.vue.cjs");
|
7
7
|
const SkeletonEventShort = require("../../../icons/skeletons/SkeletonEventShort.vue.cjs");
|
@@ -1,5 +1,5 @@
|
|
1
1
|
import { ref, onMounted, openBlock, createElementBlock, createVNode, TransitionGroup, withCtx, Fragment, renderList, createBlock, createCommentVNode, Transition, normalizeClass } from "vue";
|
2
|
-
/* empty css
|
2
|
+
/* empty css */
|
3
3
|
import _sfc_main$1 from "../../../../components/EmptyState/EmptyState.vue.js";
|
4
4
|
import _sfc_main$2 from "../blocks/CardEvent.vue.js";
|
5
5
|
import SkeletonEventShort from "../../../icons/skeletons/SkeletonEventShort.vue.js";
|
@@ -2,7 +2,7 @@
|
|
2
2
|
Object.defineProperties(exports, { __esModule: { value: true }, [Symbol.toStringTag]: { value: "Module" } });
|
3
3
|
const vue = require("vue");
|
4
4
|
const Feed = require("../../../../components/Feed/Feed.vue.cjs");
|
5
|
-
const Popup = require("../../../../components/Popup/Popup.
|
5
|
+
const Popup = require("../../../../components/Popup/Popup.vue2.cjs");
|
6
6
|
const PhotoViewer = require("../../../../components/PhotoViewer/PhotoViewer.vue.cjs");
|
7
7
|
const SectionPageTitle = require("../../../globals/views/components/sections/SectionPageTitle.vue.cjs");
|
8
8
|
const gallery = require("../../store/gallery.cjs");
|
@@ -1,6 +1,6 @@
|
|
1
1
|
import { ref, openBlock, createElementBlock, createVNode, withCtx, unref, isRef, Fragment, renderList, createElementVNode } from "vue";
|
2
2
|
import _sfc_main$4 from "../../../../components/Feed/Feed.vue.js";
|
3
|
-
import _sfc_main$2 from "../../../../components/Popup/Popup.
|
3
|
+
import _sfc_main$2 from "../../../../components/Popup/Popup.vue2.js";
|
4
4
|
import _sfc_main$3 from "../../../../components/PhotoViewer/PhotoViewer.vue.js";
|
5
5
|
import _sfc_main$1 from "../../../globals/views/components/sections/SectionPageTitle.vue.js";
|
6
6
|
import gallery from "../../store/gallery.js";
|
package/dist/prometheus-framework/src/modules/gallery/components/sections/BackofficeGallery.vue.cjs
CHANGED
@@ -2,12 +2,12 @@
|
|
2
2
|
Object.defineProperties(exports, { __esModule: { value: true }, [Symbol.toStringTag]: { value: "Module" } });
|
3
3
|
const vue = require("vue");
|
4
4
|
const vueRouter = require("vue-router");
|
5
|
-
;/* empty css
|
6
|
-
const Button = require("../../../../components/Button/Button.
|
7
|
-
;/* empty css
|
5
|
+
;/* empty css */
|
6
|
+
const Button = require("../../../../components/Button/Button.vue2.cjs");
|
7
|
+
;/* empty css */
|
8
8
|
const Chips = require("../../../../components/Chips/Chips.vue.cjs");
|
9
9
|
;/* empty css */
|
10
|
-
const Popup = require("../../../../components/Popup/Popup.
|
10
|
+
const Popup = require("../../../../components/Popup/Popup.vue2.cjs");
|
11
11
|
const Feed = require("../../../../components/Feed/Feed.vue.cjs");
|
12
12
|
const PhotoViewer = require("../../../../components/PhotoViewer/PhotoViewer.vue.cjs");
|
13
13
|
const auth = require("../../../auth/views/store/auth.cjs");
|