Quantcast
Channel: SCN : All Content - All Communities
Viewing all articles
Browse latest Browse all 3167

Get Entity SODataOfflineStore iOS - SMP3

$
0
0

Hi all,

 

I migrated the OnlineStore to the OfflineStore and I have some worries.

Requests that worked well on the OnlineStore no longer works on the OfflineStore.

I think that my definingRequest do not populate my local base.

 

On OnlineStore I used :

 

[self.onlineStorescheduleReadEntitySet:@"etplnrgrpSet"options:nil...]


And it's working fine.


On Offline I used :


    SODataOfflineStoreOptions *storeOptions = [[SODataOfflineStoreOptionsalloc] init];

    storeOptions.host = regData.serverHost;

    storeOptions.port = regData.serverPort;

    storeOptions.enableHttps = YES;

    storeOptions.urlSuffix = [NSStringstringWithFormat:@"/%@/%@", regData.resourcePath, regData.farmId];

    storeOptions.serviceRoot = [NSStringstringWithFormat:@"/%@", regData.applicationId];

    storeOptions.conversationManager = self.appDelegate.logonHandler.httpConvManager;

    [storeOptions addDefiningRequestWithName:@"req1" url:@"/etplnrgrpSet" retrieveStreams:false];

    offlineStore = [[SODataOfflineStorealloc] init];

   

    [offlineStoresetOfflineStoreDelegate:self];

    [offlineStoreopenStoreWithOptions:storeOptions error:&error];

 

And :

[self.offlineStorescheduleReadEntitySet:@"etplnrgrpSet"options:nil...]


And I receive an empty response.


Should the entity be declared in particular way on the server?

We can read the entitySet in the same way that Entity?


I tried to set definingRequest and scheduleReadEntitySet like :

     [self.onlineStorescheduleReadEntitySet:@"etplnrgrpSet"options:nil...]

     [storeOptions addDefiningRequestWithName:@"req1" url:@"/etplnrgrp" retrieveStreams:false];

But it's doesn't work.


The data base have too navigations property. Can I use them in OfflineStore? If so how?

How can I check that my local base well populated before making a request?

With a break point for example?



Regards.


Viewing all articles
Browse latest Browse all 3167

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>