Active
Project:
REST Server plist
Version:
6.x-1.1
Component:
User interface
Priority:
Normal
Category:
Support request
Assigned:
Unassigned
Reporter:
Created:
10 Oct 2011 at 12:29 UTC
Updated:
24 Oct 2011 at 10:56 UTC
I've been trying to update my iOS app and Drupal instance to use the recommended services module and I've set up the server as your screen cast shows. The connection seems to be happening ok but when I try to retrieve views data using the following code:
//make a new connection
DIOSConnect *session = [[DIOSConnect alloc] init];
if (!session.error)
{
NSLog(@"Connected!");
DIOSViews *views = [[DIOSViews alloc] initWithSession:session];
[views initViews];
[views addParam:@"test_view" forKey:@"view_name"];
[views runMethod];
if (!views.error)
{
NSLog(@"Views connected!");
data = [[views connResult] objectForKey:@"#data"];
}
else
{
NSLog(@"There is an error with the views");
}
I receive an error of "Cannot parse a NULL or zero-length data".
Can you recommend any solutions to this or point me in the direction of where I might be going wrong?
In the previous UI you could test calls to views in Drupal. Now you can't and also, the resources for views are not listed for new servers you create to use services.
Is it because views is not supported yet in this module?
Comments
Comment #1
scarer commentedI'm having a look at the module itself and noticed yep it definitely does not have support for views yet. I'll have a stab at the implementation and see how I go. Unless there is someone else to volunteer? Anyway, I probably need this functionality now rather than later so oh well I'll post up what I get working on here and you can decide if you want it to be rolled in. Or is this working and I'm just blind?
Comment #1.0
scarer commentedjust took out a little bit of code.