Enabling the button by default is fine, but there should be a course
setting which defines the workflow type, and if that workflow type is not
Studio, then this button should not be displayed.  The course setting can
be a manually defined one, made in the policy file.


On Thu, Mar 20, 2014 at 12:56 PM, Giulio Gratta <notifications@github.com>wrote:

> In lms/djangoapps/courseware/courses.py:
>
> > +
> > +def get_cms_block_link(block, page):
> > +    """
> > +    Returns a link to block_index for editing the course in cms,
> > +    assuming that the block is actually cms-backed.
> > +    """
> > +    locator = loc_mapper().translate_location(
> > +        block.location.course_id, block.location, False, True
> > +    )
> > +    return "//" + settings.CMS_BASE + locator.url_reverse(page, '')
> > +
> > +def get_studio_url(course_id, page):
> > +    """
> > +    Get the Studio URL of the page that is passed in.
> > +    """
> > +    is_studio_course = (modulestore().get_modulestore_type(course_id) == MONGO_MODULESTORE_TYPE)
>
> @ichuang <https://github.com/ichuang> - could you live with this
> compromise, that @jinpa <https://github.com/jinpa> suggested?
> enable this button by default, but you could imagine an "advanced setting"
> field (or policy.json key/value) that would allow particular courses to
> choose to not display it.
>
> --
> Reply to this email directly or view it on GitHub<https://github.com/edx/edx-platform/pull/2552/files#r10804249>
> .
>