开发者

restkit JSON ios - putObject - send type info

i m using restkit on ios, and trying to use the putObject method i m able to use it and send data with this format:

{"name":"Wet shirt night at Marquee","id":1,"idIcon":1,"note":78,"description":"connard","url":0}

however my web service is expecting something like: {"event":{{"name":"Wet shirt night at Marquee","id":1,"idIcon":1,"note":78,"description":"connard","url":0}}

see the difference, the type name "event" at the beginning

do you guys have any idea how to set up restkit to send the 开发者_运维技巧object type name with the object data?

Thx!


solution:

RKObjectMappable.m

RKObjectMappableGetPropertiesByElement

return a dictionary with object: your mapped dictionary key: your type name

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜