diff options
author | 2010-07-29 18:19:53 +0200 | |
---|---|---|
committer | 2010-07-29 18:42:08 +0200 | |
commit | c0a9bd59dfaa637e677226e77e5cc2ed05d8013d (patch) | |
tree | 96d43dc86a253a7a1da0ef0437068eae0d338d4d | |
parent | Properly show 'Answer it!' links (diff) | |
download | recruiting-webapp-c0a9bd59dfaa637e677226e77e5cc2ed05d8013d.tar.gz recruiting-webapp-c0a9bd59dfaa637e677226e77e5cc2ed05d8013d.tar.bz2 recruiting-webapp-c0a9bd59dfaa637e677226e77e5cc2ed05d8013d.zip |
Improved way admins create questions
-rw-r--r-- | app/views/taglibs/nav.dryml | 2 | ||||
-rw-r--r-- | app/views/taglibs/pages.dryml | 2 | ||||
-rw-r--r-- | features/clean_ui.feature | 5 |
3 files changed, 6 insertions, 3 deletions
diff --git a/app/views/taglibs/nav.dryml b/app/views/taglibs/nav.dryml index 70756d6..038947d 100644 --- a/app/views/taglibs/nav.dryml +++ b/app/views/taglibs/nav.dryml @@ -3,7 +3,7 @@ <nav-item href="#{base_url}/">Home</nav-item> <nav-item with="&QuestionCategory"><ht key="question_categories.nav_item">Question Categories</ht></nav-item> <nav-item with="&QuestionGroup" action="category"><ht key="question_groups.nav_item">Question Groups</ht></nav-item> - <nav-item href="&suggest_questions_questions_path"><ht key="questions.nav_item">Suggestion Questions</ht></nav-item> + <nav-item href="&suggest_questions_questions_path" unless="¤t_user.administrator?"><ht key="questions.nav_item">Suggestion Questions</ht></nav-item> <nav-item href="&approve_questions_questions_path" if="¤t_user.questions_to_approve.count > 0"><ht key="questions.nav_item">Approve Questions</ht></nav-item> </navigation> </def> diff --git a/app/views/taglibs/pages.dryml b/app/views/taglibs/pages.dryml index 1d2297e..be66a67 100644 --- a/app/views/taglibs/pages.dryml +++ b/app/views/taglibs/pages.dryml @@ -67,6 +67,8 @@ <if test="&User.recruits_answered_all.count > 0"> <a with="&User" action="ready_recruits">Recruits that answered all questions</a>.<br/> </if> + + <a if="&this.administrator?" href="&new_question_path">New Question</a> </section> </section> diff --git a/features/clean_ui.feature b/features/clean_ui.feature index d0051cf..23ef052 100644 --- a/features/clean_ui.feature +++ b/features/clean_ui.feature @@ -40,8 +40,9 @@ Feature: Clean UI Scenario: Administrator creating new question Given I am logged in as administrator - When I follow "Suggestion Questions" - And I follow "New Question" + Then I should not see "Suggestion Questions" + + When I follow "New Question" Then I should not see "Approved" within ".section.content-body" And I should not see "User" within ".section.content-body" And I should see "You will add content in next step" |