Use pillar.auth.current_user instead of flask_login.current_user
This commit is contained in:
@@ -5,7 +5,6 @@ import logging
|
|||||||
|
|
||||||
import attr
|
import attr
|
||||||
import flask
|
import flask
|
||||||
import flask_login
|
|
||||||
|
|
||||||
from eve.methods.put import put_internal
|
from eve.methods.put import put_internal
|
||||||
from werkzeug import exceptions as wz_exceptions
|
from werkzeug import exceptions as wz_exceptions
|
||||||
@@ -16,6 +15,7 @@ from pillar.web.system_util import pillar_api
|
|||||||
from pillar.api.nodes.custom import register_patch_handler
|
from pillar.api.nodes.custom import register_patch_handler
|
||||||
from pillar.api.utils import node_setattr
|
from pillar.api.utils import node_setattr
|
||||||
from pillar import attrs_extra
|
from pillar import attrs_extra
|
||||||
|
from pillar.auth import current_user
|
||||||
|
|
||||||
from attract.node_types import node_type_shot, node_type_task, node_type_asset
|
from attract.node_types import node_type_shot, node_type_task, node_type_asset
|
||||||
|
|
||||||
@@ -101,7 +101,7 @@ class ShotAssetManager(object):
|
|||||||
node_props = dict(
|
node_props = dict(
|
||||||
name='New %s' % typename,
|
name='New %s' % typename,
|
||||||
project=project_id,
|
project=project_id,
|
||||||
user=flask_login.current_user.objectid,
|
user=current_user.objectid,
|
||||||
node_type=node_type['name'],
|
node_type=node_type['name'],
|
||||||
properties={
|
properties={
|
||||||
'status': node_type['dyn_schema']['status']['default'],
|
'status': node_type['dyn_schema']['status']['default'],
|
||||||
|
Reference in New Issue
Block a user