Copied to clipboard

Flag this post as spam?

This post will be reported to the moderators as potential spam to be looked at


  • Bex 444 posts 555 karma points
    Oct 28, 2011 @ 12:02
    Bex
    0

    Membership to order documentation

    Hi Again..

    Everyone wants an ecommerce system...! 

    Is there any documentation on how the orders are linked to members? As I can't find any.

    For example how you link the orders to membership user?
    Is it automatic?
    Should the memberId appear in the MemberId column in the order table? If so when, as it doesn't appear when the first orderline is added via javascript or .net. Will it appear once the order has been completed?

    Then how do you get member's orders? I am looking at the javascript API documentation and can't find any mention and also in .net nothing to do with members is coming up on the intellisence on "Order" or TeaCommerce.Base or TeaCommerce.Library? Am I looking in the wrong place?

    Thanks

    Bex

     

  • Bex 444 posts 555 karma points
    Oct 28, 2011 @ 12:06
    Bex
    0

     I can't edit my post but having just posted this I have come across 

     

    GETFINALIZEDORDERSXMLFORMEMBER

    in the xslt extensions.. doh!

    How do you get at them in .net? or javascript if there is a way? 

  • Anders Burla 2560 posts 8256 karma points
    Oct 28, 2011 @ 12:14
    Anders Burla
    0

    Hi Bex

    Glad that everyone is looking for an ecommerce system and that you delivers it to them :)

    If a member is logged in - his id will get attached to the order when the payment form is generated ( the order approve page, just before payment ). You can always set the MemberId of the order using the .NET API. So you could hook into the orderFinalized event and auto create a new member and link the order.

    You get a members orders in xslt using the GetFinalizedOrdersXmlForMember( memberId ) - we dont have a Razor method as we had a small problem with caching. But in .NET you can use Order.OrdersXmlCache.Root.XPathSelectElements( "./order" ) to get all orders - or use xpath to select the right ones

    Will this help you in your job? :)

    Anders

  • Bex 444 posts 555 karma points
    Oct 28, 2011 @ 12:21
    Bex
    0

    Ah that's why I couldn't find it.. didn't realise I'd have to use the xml cache.

    Yep, that helps! Thanks very much.

     

     

  • Anders Burla 2560 posts 8256 karma points
    Oct 28, 2011 @ 12:24
    Anders Burla
    0

    The xml cache only contains the finalized orders - but yes it should have been Order objects - but we hope to make Tea Commerce even better for Umbraco 5 and have loads of nice things in it - and have it integrate with umbraco even more.

  • Bex 444 posts 555 karma points
    Oct 28, 2011 @ 12:24
    Bex
    0

    PS.. you can't set order.MemberId as "The set accessor is inaccessible". But I don't need it anyway, but thought I'd let you know!

  • Anders Burla 2560 posts 8256 karma points
    Oct 28, 2011 @ 13:01
    Anders Burla
    0

    Sorry for telling that you could - it will be available in the next release!

Please Sign in or register to post replies

Write your reply to:

Draft