mercredi 6 mai 2015

Relational query using parse-cloud rest API

I am trying to fetch data from parse-cloud using parse-rest-api,but don't know what's going wrong. I have four classes in parse-cloud

  1. Album : User can be tagged to album. An admin can have multiple albums.

  2. User : Contains all users including admin.

  3. AlbumUsers : Contains all users tagged to a album. Contains albumId,userId.

  4. AdminUsers : Contains all the users tagged in albums of admin.

So now i want to get all the users of logged in admin who's not included in currently open album.

And this is my query for parse-rest-api :

           where: { albumId: { "$inQuery":{where:{createdBy: this.get('session.userId'), objectId : {"$ne" : this.modal('album').id}}},"className":"Album"},status: 'tagged'}})

It keeps sending back error 102 : bad type for %!s(MISSING)




Aucun commentaire:

Enregistrer un commentaire