-
Notifications
You must be signed in to change notification settings - Fork 1.8k
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
fix: Disallow publish event without tickets #4674
Merged
iamareebjamal
merged 4 commits into
fossasia:development
from
Haider8:publish-without-ticket
Jul 31, 2020
Merged
Changes from 3 commits
Commits
Show all changes
4 commits
Select commit
Hold shift + click to select a range
6903b74
Disallow publish event without tickets
Haider8 afc43e8
Nest if statements
Haider8 823a462
Change confirm dialog and publish button color if event un-publishable
Haider8 3b94165
Merge branch 'development' of https://github.com/fossasia/open-event-…
Haider8 File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
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
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,12 +1,20 @@ | ||
<i class="black close icon"></i> | ||
<div class="header"> | ||
{{t 'Are you sure?'}} | ||
{{#if (or (eq this.state 'published') this.isEventPublishable)}} | ||
{{t 'Are you sure?'}} | ||
{{else}} | ||
{{t 'Incomplete event details'}} | ||
{{/if}} | ||
</div> | ||
<div class="content"> | ||
{{#if (eq this.state 'published')}} | ||
<p>{{t 'This will unpublish your event. It will not be accessible to the public on the Internet anymore if you continue. The data of the event will still be available on your dashboard, but tickets, call for speakers or any other features will no longer be available online. Do you want to unpublish your event now?'}}</p> | ||
{{else}} | ||
<p>{{t 'This will publish the event and the event will be visible on the Internet. Please confirm you want to publish your event.'}}</p> | ||
{{#if this.isEventPublishable}} | ||
<p>{{t 'This will publish the event and the event will be visible on the Internet. Please confirm you want to publish your event.'}}</p> | ||
{{else}} | ||
<p>{{t 'You need to add more details such as location and tickets to your event in order to publish it.'}}</p> | ||
{{/if}} | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. You have used tabs instead of spaces. Please use spaces |
||
{{/if}} | ||
</div> | ||
<div class="actions"> | ||
|
@@ -18,11 +26,17 @@ | |
{{t 'Cancel'}} | ||
</button> | ||
{{else}} | ||
<button type="button" class="ui green button" {{action this.togglePublishState}}> | ||
{{t 'Yes'}} | ||
</button> | ||
<button type="button" class="ui button" {{action 'toggleView'}}> | ||
{{t 'Cancel, Do Not Publish it Now'}} | ||
</button> | ||
{{#if this.isEventPublishable}} | ||
<button type="button" class="ui green button" {{action this.togglePublishState}}> | ||
{{t 'Yes'}} | ||
</button> | ||
<button type="button" class="ui button" {{action 'toggleView'}}> | ||
{{t 'Cancel, Do Not Publish it Now'}} | ||
</button> | ||
{{else}} | ||
<button type="button" class="ui button" {{action 'toggleView'}}> | ||
{{t 'Okay'}} | ||
</button> | ||
{{/if}} | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. You have used tabs instead of spaces. Please use spaces |
||
{{/if}} | ||
</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
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You have used tabs instead of spaces. Please use spaces