bryand Posted May 14, 2014 Report Share Posted May 14, 2014 Hi, Is there a way to get the Asset types from a schema?I'm trying to do the following: project = ftrack.getProject("Piggy Bank") for n in project.getTaskTypes(): print n.get("name") This works fine to return all task types but is there a way I can get only the Asset Build Types specified in the schema? in the case of "VFX_Scheme", it would returnCharacter, Prop, Environment, Matte Painting Thanks,Bryan Link to comment Share on other sites More sharing options...
Mattias Seebergs Posted May 15, 2014 Report Share Posted May 15, 2014 Hi Bryan, Unfortunately not at the moment. I have added a feature request ticket to add this in a coming version. Thanks,Mattias Link to comment Share on other sites More sharing options...
Mike Overbeck Posted October 24, 2019 Report Share Posted October 24, 2019 Has there been an update to this? I am running into the same problem with the JavascriptAPI. I'm trying to build a dropdown with all available Asset Build types for the current projectSchema in my UI. I've scoured the projectSchema entity and can't find the necessary data. -Mike O Link to comment Share on other sites More sharing options...
Lucas Correia Posted October 29, 2019 Report Share Posted October 29, 2019 Hi Mike, We have a helper method for obtaining the available statuses in the project schema, but it doesn't seem to be one for returning the available types at the moment. It is a bit complicated to follow the entity structure for the project/workflow schemas, so I did a first pass at a similar method which you can find here: https://bitbucket.org/snippets/ftrack/n79e8B It might need some more polish before it is read for general use, but I believe it should be enough for your use case. You can use it like so: getAvailableTypes( session, 'AssetBuild', 'caddd816-acb5-11e1-8668-f23c91df1211' ).then( types => console.info('Types', types) ); Regards, Lucas Link to comment Share on other sites More sharing options...
Mike Overbeck Posted October 30, 2019 Report Share Posted October 30, 2019 Thanks Lucas, I tried it out and it's perfect for what I need. -Mike O Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now