gabgren Posted March 13, 2014 Report Posted March 13, 2014 Hi ! how can i get what's linked to a task ? i can get task name, project that the task belong to, but i need to know which shot, sequence or asset is linked to this task. i messed with task.getLists but got no result thanks !
Mattias Seebergs Posted March 13, 2014 Report Posted March 13, 2014 Hi, Have a look at the getParents method. Sounds like it will return what you are looking for. Cheers
gabgren Posted March 19, 2014 Author Report Posted March 19, 2014 Hi !We are currently migrating from shotgun to ftrack, maybe we don't use it the right way so thank you if you can help us figure out! this getParents() brings me the Project the task belong to: [12] => [, 'showid': '8642d8c4-a609-11e3-9f93-6805ca0c3872', 'enddate': , 'name': 'iga2014_3164', 'projectschemeid': '2de30f32-a4d3-11e3-8c4e-6805ca0c3872', 'entityType': 'show', 'isglobal': False, 'thumbid': None, 'entityId': '8642d8c4-a609-11e3-9f93-6805ca0c3872', 'root': '', 'fullname': 'IGA2014_3164', 'diskid': '2325924e-f228-11e2-91ea-f23c91dfaa16'}')>]('{'sort':>('{'sort':>('{'sort':>('{'status':>('{'sort':>('{'sort':>('{'sort':>('{'sort':>('{'sort':>('{'status':>('{'status':>('{'status':>('{'status':> what i'm looking for is the 'folder hierarchy', or asset the task belongs to. for instance this task, 'Modeling', is in the project 'IGA2014_3164' but i need to know it's the modeling for the character 'Audrey', in the Asset Builds category. If you can, have a look at the screenshot of our ftrack project and you'll see what i'm talking about:http://imgur.com/e8UgYqV EDIT: i need to say that getAssets() returns an empty listThanks !
gabgren Posted March 19, 2014 Author Report Posted March 19, 2014 in other words, i need to get this line from a task: http://imgur.com/JwUsLMp
gabgren Posted March 19, 2014 Author Report Posted March 19, 2014 ok, found a way! thanks.allTasks = user.getTasks(states=[ftrack.NOT_STARTED, ftrack.IN_PROGRESS])for task in allTasks: allAssets = task.getParents() for asset in allAssets: name = asset.getName() parent = parent + ' / ' + name print parent
Mattias Seebergs Posted March 20, 2014 Report Posted March 20, 2014 Good to hear you found a way, looks like a possible solution
Recommended Posts
Archived
This topic is now archived and is closed to further replies.