You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@superset.apache.org by GitBox <gi...@apache.org> on 2019/07/30 10:55:26 UTC

[GitHub] [incubator-superset] gbrian opened a new issue #7948: Import role or copy paste role permissions

gbrian opened a new issue #7948: Import role or copy paste role permissions
URL: https://github.com/apache/incubator-superset/issues/7948
 
 
   **Is your feature request related to a problem? Please describe.**
   Not related to a problem but handy when dealing with environments
   
   **Describe the solution you'd like**
   I'd like to be able to paset CSV list of permissions into permissions selector
   
   Current workaround I'm using from console:
   
   ```
   var perms = "can list on DashboardModelView, can download dashboards on DashboardModelView, can download on DashboardModelView, can show on DashboardModelView, can list on DashboardModelViewAsync, can download dashboards on DashboardModelViewAsync, can download on DashboardModelViewAsync, can show on DashboardModelViewAsync, can list on DashboardAddView, can download dashboards on DashboardAddView, can download on DashboardAddView, can show on DashboardAddView, can dashboard on Superset, can fave dashboards by username on Superset, can csrf token on Superset, can recent activity on Superset, can fave dashboards on Superset, menu access on Dashboards";
   
   var sel = $('.my_select2.form-control[name="permissions"]');
   var options = sel.find("option");
   
   sel.val(perms.split(",")
   			.map(p => p.trim())
   			.map(p => $(options.filter((i, o) => $(o).text() == p)[0]).attr("value")))
   	.trigger('change');
   
   ```

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


With regards,
Apache Git Services

---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org