Purchase response: Apple vs Google

I was surprise and disappointed with Corona to see that the format of the store callback method parameter, event.transaction, was not the same for Apple and Google. I’m talking about the purchase date. For Apple the event.transaction.originalDate and event.transaction.date is in the format “2013-02-16 00:00:00” (and in GMT). The same property has a totally different format. For the google store callback parameters event.transaction.originalDate and event.transaction.date the format is like such, “Wed Feb 20 21:27:46 EST 2013”. Come on Corona, why couldn’t you format this for us in another property? When Amazon purchases comes out are we going to only have access to the seconds since the epoch?

Also, while I’m complaining, why isn’t there a well defined event.transaction laid out somewhere? If there is a page with all of the properties for event.transaction, please post it.

thanks [import]uid: 38348 topic_id: 36153 reply_id: 336153[/import]

I read about LuaDate, an independent 3rd party lua script written in about 2006. It allowed you to do some useful things with dates. I saw that you could load a date based off of a formatted date string (such as the google purchase date) and then access the date parts from the table that is created. It looks useful for thing such as:

local d = date(Wed Feb 20 21:27:46 EST 2013)
d:getyear() => 2013

Has anybody tried this and if so, can you post a copy to a reputable site such as gethub?

thanks,
Rob [import]uid: 38348 topic_id: 36153 reply_id: 144764[/import]

damn, I meant Github. I actually found it on GitHub it is provides all that the built in libraries lack for date conversion:

https://github.com/LuaDist/luadate/blob/master/date.doc.htm

cheers,
Rob [import]uid: 38348 topic_id: 36153 reply_id: 144841[/import]

I read about LuaDate, an independent 3rd party lua script written in about 2006. It allowed you to do some useful things with dates. I saw that you could load a date based off of a formatted date string (such as the google purchase date) and then access the date parts from the table that is created. It looks useful for thing such as:

local d = date(Wed Feb 20 21:27:46 EST 2013)
d:getyear() => 2013

Has anybody tried this and if so, can you post a copy to a reputable site such as gethub?

thanks,
Rob [import]uid: 38348 topic_id: 36153 reply_id: 144764[/import]

damn, I meant Github. I actually found it on GitHub it is provides all that the built in libraries lack for date conversion:

https://github.com/LuaDist/luadate/blob/master/date.doc.htm

cheers,
Rob [import]uid: 38348 topic_id: 36153 reply_id: 144841[/import]

I read about LuaDate, an independent 3rd party lua script written in about 2006. It allowed you to do some useful things with dates. I saw that you could load a date based off of a formatted date string (such as the google purchase date) and then access the date parts from the table that is created. It looks useful for thing such as:

local d = date(Wed Feb 20 21:27:46 EST 2013)
d:getyear() => 2013

Has anybody tried this and if so, can you post a copy to a reputable site such as gethub?

thanks,
Rob [import]uid: 38348 topic_id: 36153 reply_id: 144764[/import]

damn, I meant Github. I actually found it on GitHub it is provides all that the built in libraries lack for date conversion:

https://github.com/LuaDist/luadate/blob/master/date.doc.htm

cheers,
Rob [import]uid: 38348 topic_id: 36153 reply_id: 144841[/import]

I read about LuaDate, an independent 3rd party lua script written in about 2006. It allowed you to do some useful things with dates. I saw that you could load a date based off of a formatted date string (such as the google purchase date) and then access the date parts from the table that is created. It looks useful for thing such as:

local d = date(Wed Feb 20 21:27:46 EST 2013)
d:getyear() => 2013

Has anybody tried this and if so, can you post a copy to a reputable site such as gethub?

thanks,
Rob [import]uid: 38348 topic_id: 36153 reply_id: 144764[/import]

damn, I meant Github. I actually found it on GitHub it is provides all that the built in libraries lack for date conversion:

https://github.com/LuaDist/luadate/blob/master/date.doc.htm

cheers,
Rob [import]uid: 38348 topic_id: 36153 reply_id: 144841[/import]