Try and check how the comment field is done in the out of the box xslt. You just select it using jQuery and adds it to the list of things to save.
Here is the code from the starter kit <script type="text/javascript"> <![CDATA[ onSaving(function(){ var formObj = { "comments": jQuery("#comments").val(), "orderNotes": jQuery("#orderNotes").val() }; TeaCommerce.updateOrderPropertiesAdmin(]]><xsl:value-of select="$order/@id"/><![CDATA[,formObj, false); }); ]]> </script>
Adding T&T number in backend
Hey im just trying to create a form for adding to properties to an order in the inside the order. This could be used for track and numbers.
but its not quite saving it.
But shouldnt this be right ? I have this on my "adminorder.xslt"
Hi Rasmus
Try and check how the comment field is done in the out of the box xslt. You just select it using jQuery and adds it to the list of things to save.
Here is the code from the starter kit
<script type="text/javascript">
<![CDATA[
onSaving(function(){
var formObj = {
"comments": jQuery("#comments").val(),
"orderNotes": jQuery("#orderNotes").val()
};
TeaCommerce.updateOrderPropertiesAdmin(]]><xsl:value-of select="$order/@id"/><![CDATA[,formObj, false);
});
]]>
</script>
Kind regards
Anders
Arh didnt see that snippet in the top.
Awesome! and ofc it just works
is working on a reply...