@everymatrix/casino-tournaments-page-controller 0.0.88 → 0.0.92
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/index.html
CHANGED
|
@@ -29,20 +29,7 @@
|
|
|
29
29
|
</h1>
|
|
30
30
|
</header>
|
|
31
31
|
|
|
32
|
-
<
|
|
33
|
-
<casino-tournaments-page-controller session="3a621d62-1a5e-40fb-89d1-36f1cd0af643" userid="3657535" showleaderboard="true" endpoint="https://opapuat-gr-api.stage.norway.everymatrix.com/v1" cmsendpoint="https://casinouat.pamestoixima.gr/apijson/en/tournaments/906333318049055456" lang="en" loginevent="Login" registerevent="Register" tourid="906333318049055456"></casino-tournaments-page-controller>
|
|
34
|
-
</div>
|
|
35
|
-
|
|
36
|
-
<script>
|
|
37
|
-
let sessionTopic = window.emWidgets.topic('player:session');
|
|
38
|
-
|
|
39
|
-
setTimeout(() => {
|
|
40
|
-
sessionTopic.next({
|
|
41
|
-
sessionID: '4278aba8-18be-4319-b970-9f081298100c',
|
|
42
|
-
userID: '3657535'
|
|
43
|
-
});
|
|
44
|
-
}, 2000);
|
|
45
|
-
</script>
|
|
32
|
+
<casino-tournaments-page-controller session="00dfe978-5f2d-4f1c-a215-e588d5d2dcce" userid="3657535" showleaderboard="true" endpoint="https://opapuat-gr-api.stage.norway.everymatrix.com/v1" cmsendpoint="https://casinouat.pamestoixima.gr/apijson/en/tournaments/906333318049055456" lang="en" loginevent="Login" registerevent="Register" tourid="906718378904103143"></casino-tournaments-page-controller>
|
|
46
33
|
|
|
47
34
|
</body>
|
|
48
35
|
</html>
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@everymatrix/casino-tournaments-page-controller",
|
|
3
|
-
"version": "0.0.
|
|
3
|
+
"version": "0.0.92",
|
|
4
4
|
"main": "dist/casino-tournaments-page-controller.js",
|
|
5
5
|
"svelte": "src/index.ts",
|
|
6
6
|
"scripts": {
|
|
@@ -37,5 +37,5 @@
|
|
|
37
37
|
"publishConfig": {
|
|
38
38
|
"access": "public"
|
|
39
39
|
},
|
|
40
|
-
"gitHead": "
|
|
40
|
+
"gitHead": "d6dd244dc16fd1b84ab8194494c58fbacab554ef"
|
|
41
41
|
}
|
|
@@ -45,19 +45,21 @@
|
|
|
45
45
|
|
|
46
46
|
if (data && data.length > 0) {
|
|
47
47
|
data.forEach((item) => {
|
|
48
|
-
if (item.
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
48
|
+
if (item.unqualified == false) {
|
|
49
|
+
if (item.userID == playerID) {
|
|
50
|
+
firstRowAvailable = true;
|
|
51
|
+
firstRowData = {
|
|
52
|
+
Position: item.rank,
|
|
53
|
+
Name: item.shortName,
|
|
54
|
+
Score: item.score,
|
|
55
|
+
};
|
|
56
|
+
} else {
|
|
57
|
+
tableData.push({
|
|
58
|
+
Position: item.rank,
|
|
59
|
+
Name: item.shortName,
|
|
60
|
+
Score: item.score,
|
|
61
|
+
});
|
|
62
|
+
}
|
|
61
63
|
}
|
|
62
64
|
});
|
|
63
65
|
}
|
|
@@ -83,6 +85,10 @@
|
|
|
83
85
|
.then((res:any) => res.json())
|
|
84
86
|
.then((res:any) => {
|
|
85
87
|
tournamentDetails = res.item;
|
|
88
|
+
|
|
89
|
+
if (res.state == 'Unstarted') {
|
|
90
|
+
showleaderboard = false;
|
|
91
|
+
}
|
|
86
92
|
});
|
|
87
93
|
}
|
|
88
94
|
|
|
@@ -93,10 +99,6 @@
|
|
|
93
99
|
reqHeaders.append('language', lang);
|
|
94
100
|
reqHeaders.append('platform', getDevice(userAgent));
|
|
95
101
|
|
|
96
|
-
if (isLoggedIn) {
|
|
97
|
-
reqHeaders.append("X-SessionID", sessionID);
|
|
98
|
-
}
|
|
99
|
-
|
|
100
102
|
let requestOptions = {
|
|
101
103
|
method: 'GET',
|
|
102
104
|
headers: reqHeaders,
|
|
@@ -175,7 +177,7 @@
|
|
|
175
177
|
});
|
|
176
178
|
|
|
177
179
|
$: session && userid && setSession();
|
|
178
|
-
$: tourid && endpoint && initialLoad();
|
|
180
|
+
$: tourid && endpoint && session && initialLoad();
|
|
179
181
|
$: tourid && cmsendpoint && getDataFromCMS();
|
|
180
182
|
</script>
|
|
181
183
|
|