That is the exact example I based my code on. It's the standard code from the starter kid. I only included the two new inputs and the properties parameter on the AddOrUpdateOrderLine input.
I see you are using an ajaxform css class, so this will probably post back the form using AJAX (and Jquery Form plugin). You can look at the result of this POST in the "network" tab of the browser (Chrome / Firefox/firebug) to look what the result of the POST is. I found this very helpful when debugging issues with the HTML api inside a ajaxified form.
But, as Anders said, update to 2.2 first if not up to date.
@Rody removing the ajaxForm class doesnt make any difference. The page makes a full post back no matter if the class in there or not. So I can't really catch the result from the post as the page reloads. Or can I?
Kasper, you probably don't have the Jquery.form plugin loaded then. But that is no problem, if the page does a full postback and the site still works, this means the page is posted to /base/TC/FormPost.aspx and the orderline should be processed by teacommerce.
Can you post the exact form information shown in the NETWORK tab in the browser which is posted to the FormPost.aspx?
I didn't know you could save the network log on full page post backs. That's awesome.
Here it is:
So my custom properties in the post (red underline). I fear that this is just me that has misunderstood the documentation.
I thought the custom properties on my order lines would be stored in the tea commerce orderline table in the database.
I guess it's stored in the umbraco property tables? But how am I suppose to get a hold on them again?
AddOrUpdateOrderLine custom properties HTML API
I am trying to add some custom properties to my orderlines. I've followed the documentation, but nothing seems to happen. The DB values are just NULL.
Am I doing anything wrong?
Running latest Tea Commerce? Else update :)
If you are - is the subscription property in the DB for the order line? As these are order line properties
Kind regards
Anders
Using start kit 3.2. And yes - order lines.
Tried the example code from here and make it really simple and see if that works?
http://documentation.teacommerce.net/html-api/order-line/addorupdateorderline/
Try example 2
Kind regards
Anders
That is the exact example I based my code on. It's the standard code from the starter kid. I only included the two new inputs and the properties parameter on the AddOrUpdateOrderLine input.
Be sure to update to Tea Commerce 2.2. Then test again.
I see you are using an ajaxform css class, so this will probably post back the form using AJAX (and Jquery Form plugin). You can look at the result of this POST in the "network" tab of the browser (Chrome / Firefox/firebug) to look what the result of the POST is. I found this very helpful when debugging issues with the HTML api inside a ajaxified form.
But, as Anders said, update to 2.2 first if not up to date.
Good point Rody. I didn't notice that. I will look into it.
No luck after updating to 2.2. Will look into the ajax post thingo.
@Rody removing the ajaxForm class doesnt make any difference. The page makes a full post back no matter if the class in there or not. So I can't really catch the result from the post as the page reloads. Or can I?
Kasper, you probably don't have the Jquery.form plugin loaded then. But that is no problem, if the page does a full postback and the site still works, this means the page is posted to /base/TC/FormPost.aspx and the orderline should be processed by teacommerce.
Can you post the exact form information shown in the NETWORK tab in the browser which is posted to the FormPost.aspx?
I didn't know you could save the network log on full page post backs. That's awesome. Here it is:
So my custom properties in the post (red underline). I fear that this is just me that has misunderstood the documentation. I thought the custom properties on my order lines would be stored in the tea commerce orderline table in the database. I guess it's stored in the umbraco property tables? But how am I suppose to get a hold on them again?
Nope, they are stored in the Teacommerce_CustomOrderLineProperty table. You can just get them in your order whenever using a Teacommerce Order object, from let's say the Razor API: http://documentation.teacommerce.net/razor-api/order/getcurrentorder/
Haha oh what I totally missed that table. That is awesome. Thanks alot!
is working on a reply...