-
Notifications
You must be signed in to change notification settings - Fork 4
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
43 changed files
with
673 additions
and
634 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -108,44 +108,35 @@ | |
<h5 class='footer-header' itemprop='name'> | ||
Stichting Sociëteit Flux | ||
</h5> | ||
<table class='table table-sm'> | ||
<table class='table table-sm mw-100'> | ||
<tbody> | ||
<tr> | ||
<td class='footer-table-cell'> | ||
<FaIcon @icon='envelope' /> | ||
<FaIcon @icon='globe' /> | ||
</td> | ||
<td class='footer-table-cell'> | ||
<a | ||
class='footer-text' | ||
href='mailto:[email protected]' | ||
itemprop='email' | ||
content='[email protected]' | ||
itemprop='url' | ||
href='https://societeitflux.nl' | ||
target='_blank' | ||
> | ||
secretaris@societeitflux.nl | ||
www.societeitflux.nl | ||
</a> | ||
</td> | ||
</tr> | ||
|
||
<tr | ||
itemprop='contactPoint' | ||
itemscope | ||
itemtype='https://schema.org/ContactPoint' | ||
> | ||
<tr> | ||
<td class='footer-table-cell'> | ||
<FaIcon | ||
@icon='phone' | ||
itemprop='contactType' | ||
content='customer support' | ||
/> | ||
<FaIcon @icon='phone' /> | ||
</td> | ||
<td class='footer-table-cell'> | ||
<a | ||
class='footer-text' | ||
href='tel:+31612234738' | ||
itemprop='telephone' | ||
content='+31612234738' | ||
href='https://societeitflux.nl/#/contact' | ||
target='_blank' | ||
> | ||
06-12234738 | ||
Neem contact op | ||
</a> | ||
</td> | ||
</tr> | ||
|
@@ -166,22 +157,6 @@ | |
</a> | ||
</td> | ||
</tr> | ||
|
||
<tr> | ||
<td class='footer-table-cell'> | ||
<FaIcon @icon='globe' /> | ||
</td> | ||
<td class='footer-table-cell'> | ||
<a | ||
class='footer-text' | ||
itemprop='url' | ||
href='http://www.societeitflux.nl' | ||
target='_blank' | ||
> | ||
www.societeitflux.nl | ||
</a> | ||
</td> | ||
</tr> | ||
</tbody> | ||
</table> | ||
</div> | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,28 +1,27 @@ | ||
import { inject as service } from '@ember/service'; | ||
import Controller from '@ember/controller'; | ||
import { isInvalidResponse } from 'ember-fetch/errors'; | ||
import { tracked } from '@glimmer/tracking'; | ||
import { action } from '@ember/object'; | ||
|
||
export default Controller.extend({ | ||
fetch: service(), | ||
errorMessage: null, | ||
actions: { | ||
async generateAlias() { | ||
this.set('errorMessage', null); | ||
const response = await this.fetch.post( | ||
`/activities/${this.model.id}/generate_alias` | ||
); | ||
|
||
if (response.ok) { | ||
const json = await response.json(); | ||
this.set('alias', json.data.alias); | ||
this.set('expires_at', json.data.expires_at); | ||
} else if (isInvalidResponse(response)) { | ||
const json = await response.json(); | ||
this.set( | ||
'errorMessage', | ||
json.errors ? json.errors[0].detail : response | ||
); | ||
} | ||
}, | ||
}, | ||
}); | ||
export default class GenerateAliasController extends Controller { | ||
@service fetch; | ||
@tracked errorMessage = null; | ||
@tracked alias; | ||
@tracked expiresAt; | ||
@action | ||
async generateAlias() { | ||
this.errorMessage = null; | ||
const response = await this.fetch.post( | ||
`/activities/${this.model.id}/generate_alias` | ||
); | ||
if (response.ok) { | ||
const json = await response.json(); | ||
this.alias = json.data.alias; | ||
this.expiresAt = json.data.expires_at; | ||
} else if (isInvalidResponse(response)) { | ||
const json = await response.json(); | ||
this.errorMessage = json.errors ? json.errors[0].detail : response; | ||
} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,54 +1,66 @@ | ||
import Controller from '@ember/controller'; | ||
import { sort } from '@ember/object/computed'; | ||
|
||
export default Controller.extend({ | ||
showAllergyInfo: true, | ||
showCheckbox: true, | ||
currentTab: 'form', // Possible options: [ form, consumptionList ] | ||
options: ['Bier', 'Fris'], | ||
newOption: '', | ||
additionalEmptyRows: 5, | ||
showRobertHofstra: true, | ||
|
||
sortedString: Object.freeze(['userFullName']), | ||
sortedResponses: sort('model.form.responses', 'sortedString'), | ||
|
||
actions: { | ||
print() { | ||
const { title } = this.model; | ||
const popup = window.open('', 'PRINT', 'height=400,width=600'); | ||
|
||
popup.document.write( | ||
`<html><head><title>Inschrijflijst ${title}</title>` | ||
); | ||
popup.document.write('<link rel="stylesheet" href="/assets/vendor.css">'); | ||
popup.document.write( | ||
'<link rel="stylesheet" href="/assets/amber-ui.css">' | ||
); | ||
popup.document.write( | ||
'</head><body onload="window.print()" onfocus="setTimeout(window.close, 500)">' | ||
); | ||
popup.document.write(document.getElementById('printarea').innerHTML); | ||
popup.document.write('</body></html>'); | ||
popup.document.close(); // Necessary for IE >= 10 | ||
popup.focus(); // Necessary for IE >= 10*/ | ||
}, | ||
selectForm() { | ||
this.set('currentTab', 'form'); | ||
}, | ||
selectConsumptionList() { | ||
this.set('currentTab', 'consumptionList'); | ||
}, | ||
removeOption(index) { | ||
this.options.removeAt(index, 1); | ||
}, | ||
addOption() { | ||
const option = this.newOption; | ||
this.options.pushObject(option); | ||
this.set('newOption', ''); | ||
}, | ||
reorderItems(itemModels) { | ||
this.set('options', itemModels); | ||
}, | ||
}, | ||
}); | ||
import { tracked } from '@glimmer/tracking'; | ||
import { action } from '@ember/object'; | ||
|
||
const tabs = ['form', 'consumptionList']; | ||
const formTab = tabs[0]; | ||
const consumptionListTab = tabs[1]; | ||
|
||
export default class PrintEnrolledController extends Controller { | ||
@tracked showAllergyInfo = true; | ||
@tracked showCheckbox = true; | ||
@tracked currentTab = formTab; | ||
@tracked options = ['Bier', 'Fris']; | ||
@tracked newOption = ''; | ||
@tracked showRobertHofstra = true; | ||
additionalEmptyRows = 5; | ||
|
||
get sortedResponses() { | ||
return this.model.form.get('responses').sortBy('userFullName'); | ||
} | ||
|
||
@action | ||
print() { | ||
const { title } = this.model; | ||
const popup = window.open('', 'PRINT', 'height=400,width=600'); | ||
|
||
popup.document.write(`<html><head><title>Inschrijflijst ${title}</title>`); | ||
popup.document.write('<link rel="stylesheet" href="/assets/vendor.css"/>'); | ||
popup.document.write( | ||
'<link rel="stylesheet" href="/assets/amber-ui.css"/>' | ||
); | ||
popup.document.write( | ||
'</head><body onload="window.print()" onfocus="setTimeout(window.close, 500)">' | ||
); | ||
popup.document.write(document.getElementById('printarea').innerHTML); | ||
popup.document.write('</body></html>'); | ||
popup.document.close(); // Necessary for IE >= 10 | ||
popup.focus(); // Necessary for IE >= 10*/ | ||
} | ||
|
||
@action | ||
selectForm() { | ||
this.currentTab = formTab; | ||
} | ||
|
||
@action | ||
selectConsumptionList() { | ||
this.currentTab = consumptionListTab; | ||
} | ||
|
||
@action | ||
removeOption(index) { | ||
this.options.removeAt(index, 1); | ||
} | ||
|
||
@action | ||
addOption() { | ||
this.options.pushObject(this.newOption); | ||
this.newOption = ''; | ||
} | ||
|
||
@action | ||
reorderItems(itemModels) { | ||
this.options = itemModels; | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,16 +1,11 @@ | ||
import { inject as service } from '@ember/service'; | ||
import Controller from '@ember/controller'; | ||
import { computed } from '@ember/object'; | ||
import { isNone } from '@ember/utils'; | ||
|
||
export default Controller.extend({ | ||
flashNotice: service('flash-notice'), | ||
canSubmitResponse: computed( | ||
'model.form', | ||
'model.form.currentUserCanRespond', | ||
function () { | ||
const { form } = this.model; | ||
return !isNone(form) && form.get('currentUserCanRespond'); | ||
} | ||
), | ||
}); | ||
export default class ShowActivityController extends Controller { | ||
@service flashNotice; | ||
get canSubmitResponse() { | ||
const { form } = this.model; | ||
return !isNone(form) && form.get('currentUserCanRespond'); | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,7 +1,8 @@ | ||
import { inject as service } from '@ember/service'; | ||
import Controller from '@ember/controller'; | ||
|
||
export default Controller.extend({ | ||
session: service(), | ||
layoutManager: service('layout-manager'), | ||
}); | ||
export default class ApplicationController extends Controller { | ||
@service session; | ||
|
||
@service layoutManager; | ||
} |
Oops, something went wrong.