Compare commits

...

2 commits

Author SHA1 Message Date
6ce4a1df4c fixed stuff 2024-11-06 21:24:12 +01:00
0f8462dc7c enforce startup order in docker-compose.yml 2024-11-06 21:13:44 +01:00
2 changed files with 27 additions and 6 deletions

View file

@ -6,11 +6,17 @@ services:
command: bash -c 'python manage.py migrate && python manage.py runserver 0.0.0.0:8000' command: bash -c 'python manage.py migrate && python manage.py runserver 0.0.0.0:8000'
environment: environment:
- HTTP_HOST=core - HTTP_HOST=core
#- DATABASE_URL - DB_HOST=db
- DB_PORT=3306
- DB_NAME=system3
- DB_USER=system3
- DB_PASSWORD=system3
volumes: volumes:
- ../../core:/code - ../../core:/code
ports: ports:
- "8000:8000" - "8000:8000"
depends_on:
- db
frontend: frontend:
build: build:
@ -23,6 +29,8 @@ services:
- ./vue.config.js:/web/vue.config.js - ./vue.config.js:/web/vue.config.js
ports: ports:
- "8080:8080" - "8080:8080"
depends_on:
- core
db: db:
image: mariadb image: mariadb
@ -31,3 +39,10 @@ services:
MARIADB_DATABASE: system3 MARIADB_DATABASE: system3
MARIADB_USER: system3 MARIADB_USER: system3
MARIADB_PASSWORD: system3 MARIADB_PASSWORD: system3
volumes:
- mariadb_data:/var/lib/mysql
ports:
- "3306:3306"
volumes:
mariadb_data:

View file

@ -83,7 +83,7 @@ export default {
ticket(val) { ticket(val) {
if (this.selected_state == null) { if (this.selected_state == null) {
this.selected_state = val.state; this.selected_state = val.state;
} }
if (this.selected_assignee == null) { if (this.selected_assignee == null) {
this.selected_assignee = val.assigned_to this.selected_assignee = val.assigned_to
} }
@ -102,6 +102,8 @@ export default {
return `ticket+${this.ticket.uuid}@${domain}`; return `ticket+${this.ticket.uuid}@${domain}`;
} }
}, },
//this.scheduleAfterInit(() => [this.fetchTicketStates(), this.loadTickets(), this.loadUsers(),
//this.fetchShippingVouchers()]);
methods: { methods: {
...mapActions(['deleteItem', 'markItemReturned', 'sendMail', 'updateTicketPartial', 'postComment']), ...mapActions(['deleteItem', 'markItemReturned', 'sendMail', 'updateTicketPartial', 'postComment']),
...mapActions(['loadTickets', 'fetchTicketStates', 'loadUsers', 'scheduleAfterInit']), ...mapActions(['loadTickets', 'fetchTicketStates', 'loadUsers', 'scheduleAfterInit']),
@ -134,8 +136,12 @@ export default {
}, },
}, },
mounted() { mounted() {
this.scheduleAfterInit(() => [this.fetchTicketStates(), this.loadTickets(), this.loadUsers(), this.scheduleAfterInit(() => [Promise.all([this.fetchTicketStates(), this.loadTickets(), this.loadUsers(), this.fetchShippingVouchers()]).then(()=>{
this.fetchShippingVouchers()]); this.selected_state = this.ticket.state;
this.selected_assignee = this.ticket.assigned_to
})]);
//this.scheduleAfterInit(() => [this.fetchTicketStates(), this.loadTickets(), this.loadUsers(),
//this.fetchShippingVouchers()]);
} }
}; };
</script> </script>