Skip to content

Commit

Permalink
Sync from monorepo: 2025-01-12 19:34:14 - # Korfbal
Browse files Browse the repository at this point in the history
## Update
- fixed buttons on player selector screen
- Fixed caching for docker container builds
- Moved countdownTimer so lookup should be fixed
  • Loading branch information
github-actions[bot] committed Jan 12, 2025
1 parent 4616054 commit 84a7377
Show file tree
Hide file tree
Showing 11 changed files with 16 additions and 14 deletions.
2 changes: 1 addition & 1 deletion apps/game_tracker/models/player_group.py
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ def save(self, *args, **kwargs):

if self.starting_type.name != "Reserve":
reserve_player_group = self.match_data.player_groups.get(
starting_type__name="Reserve"
starting_type__name="Reserve", team=self.team
)
for player in new_players:
if player in reserve_player_group.players.all():
Expand Down
2 changes: 1 addition & 1 deletion configs/webpack/webpack.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ module.exports = {
output: {
path: path.resolve(__dirname, 'static_workfile/webpack_bundles'),
filename: '[name].bundle.js',
publicPath: '/static_workfile/webpack_bundles/',
publicPath: '../../static_workfile/webpack_bundles/',
clean: true,
},
module: {
Expand Down
3 changes: 1 addition & 2 deletions docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,7 @@ services:
kwt-redis:
image: redis:latest
container_name: kwt-redis
restart: unless-stopped
networks:
- kwt-net

Expand All @@ -52,7 +53,6 @@ services:
- kwt-minio
environment:
- .env
restart: unless-stopped
networks:
- kwt-net

Expand All @@ -62,7 +62,6 @@ services:
command: python manage.py migrate
env_file:
- .env
restart: unless-stopped
networks:
- kwt-net

Expand Down
2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[project]
name = "KWT"
version = "1.2.4"
version = "1.2.5"

[tool.black]
line-length = 88
Expand Down
2 changes: 1 addition & 1 deletion static_workfile/js/features/clubs/clubDetail.js
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ window.addEventListener('DOMContentLoaded', () => {
const regex = /([a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{12})/;
const url = window.location.href;

const user_id = document.getElementById('user_id').innerText;
const user_id = document.getElementById('user_id').innerText.trim();
const matches = regex.exec(url);

const infoContainer = document.getElementById('info-container');
Expand Down
4 changes: 2 additions & 2 deletions static_workfile/js/features/matches/matchDetail.js
Original file line number Diff line number Diff line change
Expand Up @@ -5,16 +5,16 @@ import {
updateStatistics,
updateEvents,
} from '../../components/carousel/index.js';
import { CountdownTimer } from '../../components/countdown_timer/index.js';
import { initializeSocket, requestInitialData } from '../../utils/websockets/index.js';
import { cleanDomCarousel } from '../../utils/dom/';
import { CountdownTimer } from './common/index.js';

window.addEventListener('DOMContentLoaded', () => {
const carousel = document.querySelector('.carousel');
const buttons = document.querySelectorAll('.button');
const regex = /([a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{12})/;
const url = window.location.href;
const user_id = document.getElementById('user_id').innerText;
const user_id = document.getElementById('user_id').innerText.trim();
const matches = regex.exec(url);

let match_id;
Expand Down
2 changes: 1 addition & 1 deletion static_workfile/js/features/matches/matchTracker.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
import { CountdownTimer } from './common/index.js';
import { truncateMiddle } from '../../utils';
import {
createEventTypeDiv,
Expand All @@ -7,6 +6,7 @@ import {
getFormattedTime,
} from '../../utils/events';
import { resetSwipe, setupSwipeDelete, deleteButtonSetup } from '../../components/swipe_delete';
import { CountdownTimer } from '../../components/countdown_timer/index.js';
import { updatePlayerGroups } from '../../components/carousel';
import { initializeSocket, onMessageReceived } from '../../utils/websockets/index.js';
import { scoringButtonSetup, shotButtonReg } from '../../components/scoring_button/index.js';
Expand Down
11 changes: 7 additions & 4 deletions static_workfile/js/features/matches/playersSelector.js
Original file line number Diff line number Diff line change
Expand Up @@ -205,23 +205,26 @@ class PlayerGroupManager {
}

mapGroupIdsToTypeIds() {
// Map group IDs to type IDs
this.typeIds.forEach((typeId) => {
// We expect an element in the DOM with id == this typeId
const groupElement = document.getElementById(typeId);
if (groupElement) {
this.groupIdToTypeId[groupElement.innerText] = typeId;
this.groupIdToTypeId[groupElement.innerText.trim()] = typeId;
}
});

console.log("groupIdToTypeId: ", this.groupIdToTypeId);
}

mapTypeIdsToGroupIds() {
// Map type IDs to group IDs
this.typeIds.forEach((typeId) => {
const groupElement = document.getElementById(typeId);
if (groupElement) {
this.typeIdToGroupId[typeId] = groupElement.innerText;
this.typeIdToGroupId[typeId] = groupElement.innerText.trim();
}
});

console.log("typeIdToGroupId: ", this.typeIdToGroupId);
}

getPlayersGroupsData() {
Expand Down
2 changes: 1 addition & 1 deletion static_workfile/js/features/teams/teamDetail.js
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ window.addEventListener('DOMContentLoaded', () => {
const regex = /([a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{12})/;
const url = window.location.href;

const user_id = document.getElementById('user_id').innerText;
const user_id = document.getElementById('user_id').innerText.trim();
const matches = regex.exec(url);

const infoContainer = document.getElementById('info-container');
Expand Down

0 comments on commit 84a7377

Please sign in to comment.