Skip to content

chore: No implicit this in templates #4324

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Apr 16, 2020
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
8 changes: 4 additions & 4 deletions app/extensions/ember-table/template.hbs
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@

<table class="ui unstackable table">
{{yield (hash
api=api
head=(component "ember-thead" api=api)
body=(component "ember-tbody" api=api)
foot=(component "ember-tfoot" api=api)
api=this.api
head=(component "ember-thead" api=this.api)
body=(component "ember-tbody" api=this.api)
foot=(component "ember-tfoot" api=this.api)
)}}
</table>
2 changes: 1 addition & 1 deletion app/templates/account/applications.hbs
Original file line number Diff line number Diff line change
@@ -1 +1 @@
<Account::ApplicationSection @data={{model}} />
<Account::ApplicationSection @data={{this.model}} />
4 changes: 2 additions & 2 deletions app/templates/account/billing.hbs
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<div class="ui grid">
<div class="row">
<div class="{{if device.isMobile 'sixteen' 'three'}} wide column">
<div class="{{if this.device.isMobile 'sixteen' 'three'}} wide column">
<TabbedNavigation @isVertical={{true}}>
<LinkTo @route="account.billing.payment-info" class="item">
{{t 'Payment Information'}}
Expand All @@ -10,7 +10,7 @@
</LinkTo>
</TabbedNavigation>
</div>
<div class="{{if device.isMobile 'sixteen' 'thirteen'}} wide column">
<div class="{{if this.device.isMobile 'sixteen' 'thirteen'}} wide column">
{{outlet}}
</div>
</div>
Expand Down
2 changes: 1 addition & 1 deletion app/templates/account/billing/payment-info.hbs
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
<div class="ui basic {{if isLoading 'loading' ''}} segment">
<div class="ui basic {{if this.isLoading 'loading' ''}} segment">
<Forms::UserPaymentInfoForm />
</div>
2 changes: 1 addition & 1 deletion app/templates/account/danger-zone.hbs
Original file line number Diff line number Diff line change
@@ -1 +1 @@
<Account::DangerZone @data={{model}} />
<Account::DangerZone @data={{this.model}} />
2 changes: 1 addition & 1 deletion app/templates/account/email-preferences.hbs
Original file line number Diff line number Diff line change
@@ -1 +1 @@
<Account::EmailPreferencesSection @preferences={{model}} />
<Account::EmailPreferencesSection @preferences={{this.model}} />
8 changes: 4 additions & 4 deletions app/templates/account/password.hbs
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<Account::PasswordSection
@changePassword={{action "changePassword"}}
@passwordCurrent={{passwordCurrent}}
@passwordNew={{passwordNew}}
@passwordRepeat={{passwordRepeat}}
@isLoading={{isLoading}} />
@passwordCurrent={{this.passwordCurrent}}
@passwordNew={{this.passwordNew}}
@passwordRepeat={{this.passwordRepeat}}
@isLoading={{this.isLoading}} />
2 changes: 1 addition & 1 deletion app/templates/account/profile.hbs
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
<div class="sixteen wide column">
<Forms::UserProfileForm @user={{model}} @isLoading={{isLoading}} />
<Forms::UserProfileForm @user={{this.model}} @isLoading={{this.isLoading}} />
</div>
38 changes: 19 additions & 19 deletions app/templates/admin/content/events.hbs
Original file line number Diff line number Diff line change
Expand Up @@ -9,15 +9,15 @@
</h4>
</div>
<div class="eight wide column right aligned">
<button class="ui icon circular blue button {{if device.isMobile 'fluid'}}" {{action 'openModalFor' 'event-type'}}>
<button class="ui icon circular blue button {{if this.device.isMobile 'fluid'}}" {{action 'openModalFor' 'event-type'}}>
<i class="icon plus"></i>
</button>
</div>
</div>
<div class="ui divider"></div>
<table class="ui celled table">
<tbody>
{{#each model.eventTypes as |eventType|}}
{{#each this.model.eventTypes as |eventType|}}
<tr>
<td>
<div class="ui grid">
Expand Down Expand Up @@ -57,15 +57,15 @@
</h4>
</div>
<div class="eight wide column right aligned">
<button class="ui icon circular blue button {{if device.isMobile 'fluid'}}" {{action 'openModalFor' 'event-topic'}}>
<button class="ui icon circular blue button {{if this.device.isMobile 'fluid'}}" {{action 'openModalFor' 'event-topic'}}>
<i class="icon plus"></i>
</button>
</div>
</div>
<div class="ui divider"></div>
<table class="ui celled table">
<tbody>
{{#each model.eventTopics as |eventTopic|}}
{{#each this.model.eventTopics as |eventTopic|}}
<tr>
<td>
<div class="ui grid">
Expand Down Expand Up @@ -105,7 +105,7 @@
</h4>
</div>
<div class="eight wide column right aligned">
<button class="ui icon circular blue {{if disableEventSubtopic 'disabled'}} button {{if device.isMobile 'fluid'}}" {{action 'openModalFor' 'event-sub-topic'}}>
<button class="ui icon circular blue {{if this.disableEventSubtopic 'disabled'}} button {{if this.device.isMobile 'fluid'}}" {{action 'openModalFor' 'event-sub-topic'}}>
<i class="icon plus"></i>
</button>
</div>
Expand All @@ -119,16 +119,16 @@
<i class="dropdown icon"></i>
<div class="default text">{{t 'Select Event Topic'}}</div>
<div class="menu">
{{#each model.eventTopics as |topic|}}
{{#each this.model.eventTopics as |topic|}}
<div class="item" data-value="{{map-value mapper topic}}">{{topic.name}}</div>
{{/each}}
</div>
</UiDropdown>
</div>
{{#if model.eventSubTopics}}
{{#if this.model.eventSubTopics}}
<table class="ui celled table">
<tbody>
{{#each model.eventSubTopics as |subTopic|}}
{{#each this.model.eventSubTopics as |subTopic|}}
<tr>
<td>
<div class="ui grid">
Expand Down Expand Up @@ -164,18 +164,18 @@
</div>

<Modals::Admin::Content::NewEventTypeModal
@isOpen={{eventType.openModal}}
@name={{eventType.name}}
@addEventProperty={{action "addEventProperty" eventType}} />
@isOpen={{this.eventType.openModal}}
@name={{this.eventType.name}}
@addEventProperty={{action "addEventProperty" this.eventType}} />

<Modals::Admin::Content::NewEventTopicModal
@isOpen={{eventTopic.openModal}}
@name={{eventTopic.name}}
@addEventProperty={{action "addEventProperty" eventTopic}} />
@isOpen={{this.eventTopic.openModal}}
@name={{this.eventTopic.name}}
@addEventProperty={{action "addEventProperty" this.eventTopic}} />

<Modals::Admin::Content::NewEventSubTopicModal
@isOpen={{eventSubTopic.openModal}}
@model={{model}}
@eventSubTopic={{eventSubTopic}}
@eventTopic={{currentTopicSelected}}
@addEventProperty={{action "addEventProperty" eventSubTopic}} />
@isOpen={{this.eventSubTopic.openModal}}
@model={{this.model}}
@eventSubTopic={{this.eventSubTopic}}
@eventTopic={{this.currentTopicSelected}}
@addEventProperty={{action "addEventProperty" this.eventSubTopic}} />
2 changes: 1 addition & 1 deletion app/templates/admin/content/index.hbs
Original file line number Diff line number Diff line change
@@ -1 +1 @@
<Forms::Admin::Content::SocialLinksForm @socials={{model}} @save="saveSocials" @isLoading={{isLoading}} />
<Forms::Admin::Content::SocialLinksForm @socials={{this.model}} @save="saveSocials" @isLoading={{this.isLoading}} />
10 changes: 5 additions & 5 deletions app/templates/admin/content/pages.hbs
Original file line number Diff line number Diff line change
Expand Up @@ -6,15 +6,15 @@
<h3 class="ui header">{{t 'Pages'}}</h3>
</div>
<div class="column eight wide right aligned">
<button class="ui blue button" name="button" {{action 'updateCurrentPage' page 'create'}}>{{t 'Create Page'}}</button>
<button class="ui blue button" name="button" {{action 'updateCurrentPage' this.page 'create'}}>{{t 'Create Page'}}</button>
</div>
</div>
<div class="row">
<div class="column">
<h4 class="ui header">{{t 'Open Event:'}}</h4>
</div>
</div>
{{#each eventPages as |page|}}
{{#each this.eventPages as |page|}}
<div class="row">
<div class="column">
<div role="button" class="ui segment" {{action 'updateCurrentPage' page 'update'}}>
Expand All @@ -28,7 +28,7 @@
<h4 class="ui header">{{t 'Footer menu:'}}</h4>
</div>
</div>
{{#each footerPages as |page|}}
{{#each this.footerPages as |page|}}
<div class="row">
<div class="column">
<div role="button" class="ui segment" {{action 'updateCurrentPage' page 'update'}}>
Expand All @@ -39,8 +39,8 @@
{{/each}}
</div>
<div class="column eleven wide">
{{#if isFormOpen}}
<Forms::Admin::Content::PagesForm @data={{currentForm}} @save="savePage" @isCreate={{isCreate}} @isFormOpen={{isFormOpen}} />
{{#if this.isFormOpen}}
<Forms::Admin::Content::PagesForm @data={{this.currentForm}} @save="savePage" @isCreate={{this.isCreate}} @isFormOpen={{this.isFormOpen}} />
{{/if}}
</div>
</div>
Expand Down
2 changes: 1 addition & 1 deletion app/templates/admin/content/system-images.hbs
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
<div class="row">
<div class="three wide column">
<TabbedNavigation @isVertical={{true}}>
{{#each model as |topic|}}
{{#each this.model as |topic|}}
<LinkTo @route="admin.content.system-images.list" @model={{topic.id}} class="link item">
{{topic.name}}
</LinkTo>
Expand Down
4 changes: 2 additions & 2 deletions app/templates/admin/content/system-images/list.hbs
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<div class="ui grid segment">
{{#each data as |subTopic|}}
{{#each this.data as |subTopic|}}
<div class="eight wide column">
<h4>{{subTopic.name}}</h4>
<Widgets::SafeImage @isAvatar={{true}} @class="ui big image" @src={{if subTopic.placeholder.originalImageUrl subTopic.placeholder.originalImageUrl "/images/placeholders/avatar.png"}} />
Expand All @@ -12,4 +12,4 @@
</div>
{{/each}}
</div>
<Modals::ChangeImageModal @isOpen={{isModalOpen}} @placeholder={{selectedPlaceholder}} />
<Modals::ChangeImageModal @isOpen={{this.isModalOpen}} @placeholder={{this.selectedPlaceholder}} />
10 changes: 5 additions & 5 deletions app/templates/admin/content/translations.hbs
Original file line number Diff line number Diff line change
Expand Up @@ -7,24 +7,24 @@
<h4 class="ui header">{{t 'Language'}}</h4>
</div>
<div class="column eight wide">
<h4 class="ui header"> <a href="{{translations.sourceUrl}}">{{t 'Download .PO files'}}</a></h4>
<h4 class="ui header"> <a href="{{this.translations.sourceUrl}}">{{t 'Download .PO files'}}</a></h4>
</div>
</div>
{{#each model as |language|}}
{{#each this.model as |language|}}
<div class="row">
<div class="column eight wide">
{{get l10n.availableLocales language.code}}
{{get this.l10n.availableLocales language.code}}
</div>
<div class="column eight wide">
<button class="ui primary {{if isLoading 'loading'}} button" href="{{language.sourceUrl}}" {{action 'translationsDownload'}}>{{t 'Download' }}</button>
<button class="ui primary {{if this.isLoading 'loading'}} button" href="{{language.sourceUrl}}" {{action 'translationsDownload'}}>{{t 'Download' }}</button>
</div>
</div>
{{/each}}
</div>
</div>
<div class="column eight wide ui grid center aligned">
<h4 class="ui header">{{t 'Update .PO files :'}}</h4>
<Forms::Admin::Content::TranslationForm @languages={{model}} />
<Forms::Admin::Content::TranslationForm @languages={{this.model}} />
</div>
</div>
</div>
40 changes: 20 additions & 20 deletions app/templates/admin/index.hbs
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@
</div>
<div class="value">
<div class="ui teal label">
{{model.sessions.accepted}}
{{this.model.sessions.accepted}}
</div>
</div>
</div>
Expand All @@ -32,7 +32,7 @@
</div>
<div class="value">
<div class="ui yellow label">
{{model.sessions.pending}}
{{this.model.sessions.pending}}
</div>
</div>
</div>
Expand All @@ -42,7 +42,7 @@
</div>
<div class="value">
<div class="ui red label">
{{model.sessions.rejected}}
{{this.model.sessions.rejected}}
</div>
</div>
</div>
Expand All @@ -63,7 +63,7 @@
</div>
<div class="value">
<div class="ui teal label">
{{model.events.published}}
{{this.model.events.published}}
</div>
</div>
</div>
Expand All @@ -73,7 +73,7 @@
</div>
<div class="value">
<div class="ui yellow label">
{{model.events.draft}}
{{this.model.events.draft}}
</div>
</div>
</div>
Expand All @@ -83,7 +83,7 @@
</div>
<div class="value">
<div class="ui red label">
{{model.events.past}}
{{this.model.events.past}}
</div>
</div>
</div>
Expand All @@ -101,25 +101,25 @@
<tr>
<td>{{t 'In last 24 hours'}}</td>
<td class="right aligned">
{{model.mails.oneDay}}
{{this.model.mails.oneDay}}
</td>
</tr>
<tr>
<td>{{t 'In last 3 days'}}</td>
<td class="right aligned">
{{model.mails.threeDays}}
{{this.model.mails.threeDays}}
</td>
</tr>
<tr>
<td>{{t 'In last 7 days '}}</td>
<td class="right aligned">
{{model.mails.sevenDays}}
{{this.model.mails.sevenDays}}
</td>
</tr>
<tr>
<td>{{t 'In last 1 month '}}</td>
<td class="right aligned">
{{model.mails.thirtyDays}}
{{this.model.mails.thirtyDays}}
</td>
</tr>
</tbody>
Expand All @@ -140,23 +140,23 @@
<tbody>
<tr>
<td>{{t 'No. of Super Admins'}}</td>
<td class="right aligned">{{model.users.superAdmin}}</td>
<td class="right aligned">{{this.model.users.superAdmin}}</td>
</tr>
<tr>
<td>{{t 'No. of Admins'}}</td>
<td class="right aligned">{{model.users.admin}}</td>
<td class="right aligned">{{this.model.users.admin}}</td>
</tr>
<tr>
<td>{{t 'No. of Registered Users'}}</td>
<td class="right aligned">{{model.users.verified}}</td>
<td class="right aligned">{{this.model.users.verified}}</td>
</tr>
<tr>
<td>{{t 'No. of Unverified Users'}}</td>
<td class="right aligned">{{model.users.unverified}}</td>
<td class="right aligned">{{this.model.users.unverified}}</td>
</tr>
<tr>
<td>{{t 'No. of Total Users'}}</td>
<td class="right aligned">{{model.users.total}}</td>
<td class="right aligned">{{this.model.users.total}}</td>
</tr>
</tbody>
</table>
Expand All @@ -167,23 +167,23 @@
<tbody>
<tr>
<td>{{t 'No. of Owners'}}</td>
<td class="right aligned">{{model.users.owner}}</td>
<td class="right aligned">{{this.model.users.owner}}</td>
</tr>
<tr>
<td>{{t 'No. of Organizers'}}</td>
<td class="right aligned">{{model.users.organizer}}</td>
<td class="right aligned">{{this.model.users.organizer}}</td>
</tr>
<tr>
<td>{{t 'No. of Co-Organizers'}}</td>
<td class="right aligned">{{model.users.coorganizer}}</td>
<td class="right aligned">{{this.model.users.coorganizer}}</td>
</tr>
<tr>
<td>{{t 'No. of Track Organizers'}}</td>
<td class="right aligned">{{model.users.trackOrganizer}}</td>
<td class="right aligned">{{this.model.users.trackOrganizer}}</td>
</tr>
<tr>
<td>{{t 'No. of Attendees'}}</td>
<td class="right aligned">{{model.users.attendee}}</td>
<td class="right aligned">{{this.model.users.attendee}}</td>
</tr>
</tbody>
</table>
Expand Down
Loading