Created
December 4, 2012 14:39
-
-
Save bxh-io/4204614 to your computer and use it in GitHub Desktop.
This file contains hidden or 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
{{#if isGlobalQuestion}} | |
{{#if content.global_answers.length}} | |
<a class="global-answers selected">{{content.number_of_community_answers}}</a> | |
{{else}} | |
No Community Answers | |
{{/if}} | |
{{else}} | |
{{#if content.global_answers.length}} | |
{{#if content.number_of_course_answers.length}} | |
<!-- If there are both course and global answers--> | |
<a {{action switchAnswers target="parentView"}} {{bindAttr class=":course-answers notGlobalAnswers:selected"}}>{{content.number_of_course_answers}} <span class="ss-icon"></span></a> | |
<a {{action switchAnswers target="parentView"}} {{bindAttr class=":global-answers notCourseAnswers:selected"}}>{{content.number_of_community_answers}}</a> | |
{{else}} | |
<!-- Only global answers --> | |
<span class="course-answers">{{content.number_of_community_answers}}</span> | |
<span>No Community Answers</span> | |
{{/if}} | |
{{else}} | |
<!-- No global answers here --> | |
{{#if content.number_of_course_answers.length}} | |
<!-- Some course answers but no global answers --> | |
<span class="course-answers">{{content.number_of_course_answers}}</span> | |
<span>No Community Answers</span> | |
{{else}} | |
No Answers at all | |
{{/if}} | |
{{/if}} | |
{{/if}} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment