mirror of
https://github.com/apache/superset.git
synced 2026-04-18 23:55:00 +00:00
[WIP] fix user specified JSON metadata not updating dashboard on refresh (#7027)
This commit is contained in:
committed by
Christine Chambers
parent
05be866117
commit
cc58f0e661
@@ -633,8 +633,9 @@ class DashboardModelView(SupersetModelView, DeleteMixin): # noqa
|
||||
}
|
||||
|
||||
def pre_add(self, obj):
|
||||
obj.slug = obj.slug.strip() or None
|
||||
obj.slug = obj.slug or None
|
||||
if obj.slug:
|
||||
obj.slug = obj.slug.strip()
|
||||
obj.slug = obj.slug.replace(' ', '-')
|
||||
obj.slug = re.sub(r'[^\w\-]+', '', obj.slug)
|
||||
if g.user not in obj.owners:
|
||||
|
||||
Reference in New Issue
Block a user