'Set workflow\'s importable attribute and slug.'

@web.expose
@web.require_login('use    Galaxy    workflows')
def set_accessible_async(self, trans, id=None, accessible=False):

    stored = self.get_stored_workflow(trans, id)
    importable = (accessible in ['True', 'true', 't', 'T'])
    if (stored and (stored.importable != importable)):
        if importable:
            self._make_item_accessible(trans.sa_session, stored)
        else:
            stored.importable = importable
        trans.sa_session.flush()
    return
