Commit 41651308 by Brian Talbot

Studio - revises dashboard logic to handle authorship cases specifically (WIP)

parent 5e9760d6
...@@ -44,9 +44,11 @@ ...@@ -44,9 +44,11 @@
<h3 class="sr">${_("Page Actions")}</h3> <h3 class="sr">${_("Page Actions")}</h3>
<ul> <ul>
<li class="nav-item"> <li class="nav-item">
<!-- if can create courses -->
% if not disable_course_creation: % if not disable_course_creation:
<a href="#" class="button new-button new-course-button"><i class="icon-plus"></i> ${_("New Course")}</a> <a href="#" class="button new-button new-course-button"><i class="icon-plus"></i> ${_("New Course")}</a>
<!-- if cannot create courses -->
% elif settings.MITX_FEATURES.get('STAFF_EMAIL',''): % elif settings.MITX_FEATURES.get('STAFF_EMAIL',''):
<a href="mailto:${settings.MITX_FEATURES.get('STAFF_EMAIL','')}">${_("Email staff to create course")}</a> <a href="mailto:${settings.MITX_FEATURES.get('STAFF_EMAIL','')}">${_("Email staff to create course")}</a>
% endif % endif
...@@ -58,92 +60,17 @@ ...@@ -58,92 +60,17 @@
</div> </div>
<div class="wrapper-content wrapper"> <div class="wrapper-content wrapper">
<!-- if user is verified/registered studio user -->
% if user.is_active:
<section class="content"> <section class="content">
<article class="content-primary" role="main"> <article class="content-primary" role="main">
% if user.is_active:
<div class="introduction">
<h2 class="title">${_("Welcome, %(name)s!") % dict(name= user.username)}</h2>
<div class="copy">
<p>${_("Here are all of the courses you currently have access to in Studio:")}</p>
</div>
</div>
<div class="my-classes"> <!-- if no courses and can create courses -->
<ul class="class-list">
%for course, url, lms_link in sorted(courses, key=lambda s: s[0].lower() if s[0] is not None else ''):
<li>
<a class="class-link" href="${url}" class="class-name">
<span class="class-name">${course}</span>
</a>
<a href="${lms_link}" rel="external" class="button view-button view-live-button">View Live</a>
</li>
%endfor
</ul>
</div>
% else: <!-- if no courses and cannot create courses -->
<div class="introduction">
<h2 class="title">${_("Thanks for signing up, %(name)s!") % dict(name= user.username)}</h2>
</div>
<div class="notice notice-incontext notice-instruction notice-instruction-verification"> <!-- if has courses -->
<div class="msg">
<h3 class="title">${_('We need to verify your email address')}</h3>
<div class="copy">
<p>${_('Almost there! In order to complete your sign up we need you verify your $emailaddress email address. An activation message and next steps should be waiting for you there.')}</p>
</div>
</div>
</div>
% endif
</article>
<aside class="content-supplementary" role="complimentary">
% if user.is_active:
<div class="bit">
<h3 class="title title-3">${_('Need help?')}</h3>
<p>${_('If you are new to Studio and having trouble getting started, there are a few things that may be of help:')}</p>
<ol>
<li class="nav-item">
<a href="http://files.edx.org/Getting_Started_with_Studio.pdf" title="This is a PDF Document">${_('Get started by reading Studio\'s Documentation')}</a>
</li>
<li class="nav-item">
<a href="http://help.edge.edx.org/discussion/new" class="show-tender" title="Use our feedback tool, Tender, to share your feedback">${_('Request help with Studio')}</a>
</li>
</ol>
</div>
% if disable_course_creation and settings.MITX_FEATURES.get('STAFF_EMAIL',''):
<div class="bit">
<h3 class="title title-3">${_('Can I author courses in Studio?')}</h3>
<p>${_('In order to create courses in Studio, you must')} <a href="mailto:${settings.MITX_FEATURES.get('STAFF_EMAIL','')}">${_("contact edX staff to help you create a course")}</a></p>
</div>
% endif
% else:
<div class="bit">
<h3 class="title title-3">${_('Need help?')}</h3>
<p>${_('Please check your Junk or Spam folders in case our email isn\'t in your INBOX. Still can\'t find the verification email? Request help via the link below.')}</p>
<ol class='list-actions'>
<li class="action-item">
<a href="http://help.edge.edx.org/discussion/new" class="show-tender" title="Use our feedback tool, Tender, to share your feedback">Request help with your Studio account</a>
</li>
</ol>
</div>
% endif
</aside>
</section>
</div>
<div class="wrapper-content wrapper">
<!-- if user is verified/registered studio user -->
% if user.is_active:
<section class="content">
<article class="content-primary" role="main">
<div class="introduction"> <div class="introduction">
<h2 class="title">${_("Welcome, %(name)s!") % dict(name= user.username)}</h2> <h2 class="title">${_("Welcome, %(name)s!") % dict(name= user.username)}</h2>
...@@ -176,7 +103,7 @@ ...@@ -176,7 +103,7 @@
<p>${_('edX Studio is a hosted solution for our xConsortium partners and selected guests. Courses for which you are a team member appear above for you to edit, while Course Authorship privileges are granted by edX. Our team will evaluate your request and provide you feedback within 24 hours during the work week.')}</p> <p>${_('edX Studio is a hosted solution for our xConsortium partners and selected guests. Courses for which you are a team member appear above for you to edit, while Course Authorship privileges are granted by edX. Our team will evaluate your request and provide you feedback within 24 hours during the work week.')}</p>
</div> </div>
!-- if request is unrequested -->
%if course_creator_status = "unrequested": %if course_creator_status = "unrequested":
<div class="status status-authorship is-unrequested"> <div class="status status-authorship is-unrequested">
<h4 class="title">${_('Your Authorship Request Status:')}</h4> <h4 class="title">${_('Your Authorship Request Status:')}</h4>
...@@ -188,6 +115,7 @@ ...@@ -188,6 +115,7 @@
</ul> </ul>
</div> </div>
!-- if request is pending -->
%elif course_creator_status = "pending": %elif course_creator_status = "pending":
<div class="status status-authorship has-status is-pending"> <div class="status status-authorship has-status is-pending">
<h4 class="title">${_('Your Authorship Request Status:')}</h4> <h4 class="title">${_('Your Authorship Request Status:')}</h4>
...@@ -202,6 +130,7 @@ ...@@ -202,6 +130,7 @@
</dl> </dl>
</div> </div>
!-- if request is denied -->
%elif course_creator_status = "denied": %elif course_creator_status = "denied":
<div class="status status-authorship has-status is-denied"> <div class="status status-authorship has-status is-denied">
<h4 class="title">${_('Your Authorship Request Status:')}</h4> <h4 class="title">${_('Your Authorship Request Status:')}</h4>
...@@ -236,6 +165,7 @@ ...@@ -236,6 +165,7 @@
</ol> </ol>
</div> </div>
<!-- if course creation happens through edX staff -->
% if disable_course_creation and settings.MITX_FEATURES.get('STAFF_EMAIL',''): % if disable_course_creation and settings.MITX_FEATURES.get('STAFF_EMAIL',''):
<div class="bit"> <div class="bit">
<h3 class="title title-3">${_('Can I create courses in Studio?')}</h3> <h3 class="title title-3">${_('Can I create courses in Studio?')}</h3>
...@@ -243,12 +173,14 @@ ...@@ -243,12 +173,14 @@
</div> </div>
% endif % endif
<!-- if request is unrequested -->
% if not disable_course_creation and course_creator_status = "unrequested": % if not disable_course_creation and course_creator_status = "unrequested":
<div class="bit"> <div class="bit">
<h3 class="title title-3">${_('Can I create courses in Studio?')}</h3> <h3 class="title title-3">${_('Can I create courses in Studio?')}</h3>
<p>${_('In order to create courses in Studio, you must have authorship rights to create your own course.')}</p> <p>${_('In order to create courses in Studio, you must have authorship rights to create your own course.')}</p>
</div> </div>
<!-- if request is denied -->
% elif not disable_course_creation and course_creator_status = "denied": % elif not disable_course_creation and course_creator_status = "denied":
<div class="bit"> <div class="bit">
<h3 class="title title-3">${_('Can I create courses in Studio?')}</h3> <h3 class="title title-3">${_('Can I create courses in Studio?')}</h3>
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment