Thanks!

Problem solved.

// mika


On Wed, Apr 27, 2011 at 10:39 PM, hynekcer <[email protected]> wrote:

> You can copy some shipping modules to your project didectory and
> customize the validation method. See the comment in "valid" method of
> any shipping module.
>
>    def valid(self, order=None):
>        '''
>        Can do complex validation about whether or not this
>        option is valid. For example, may check to see if the
>        recipient is in an allowed country or location.
>        '''
>
>
> On 27 dub, 13:21, Mika Sjöman <[email protected]> wrote:
> > Hi
> >
> > We found a solution for this. Basically we solved it like this:
> >
> > --------------------
> >
> > 1. We first hide the payment options for the customer and put
> payment_method
> > in a hidden field with no value.
> >
> > 2. Second we put the submit button to type="blablabal", so they can not
> send
> > the form without running our JQuery script.
> >
> > 3. When the user click submit button, we let a onClick trigger JQuery
> that
> > checks if US has been choosen.
> >
> > 4. If it is US, set the payment_method hidden input field to AUTHORIZENET
> >
> > ELSE #if it is international
> >
> > Set payment_mehod to TRUSTCOMMERCE
> >
> > 5. Then we check that it really has been set, give warning if not to
> contact
> > us by email, and then finally submit the form.
> >
> > Cheers Mika
> >
> > On Wed, Apr 27, 2011 at 6:39 PM, Mika Sjöman <[email protected]>
> wrote:
> > > Hi
> >
> > > I have a requirement to separate payment modules for two different
> users:
> >
> > > US users have to use Authorize.net
> > > International have to use Trustcommerce for their payments.
> >
> > > The reasons are many, different organizations and comissions,
> fullfilment
> > > companies etc, so we have to separate the money and where the order
> emails
> > > go.
> >
> > > Is there any easy way to code so that /buy/checkout page will use
> > > authorize.net for the people who choose shipping to the US and
> > > international shipping will automatically be using Trustcommerce?
> >
> > > Cheers!
>
> --
> You received this message because you are subscribed to the Google Groups
> "Satchmo users" group.
> To post to this group, send email to [email protected].
> To unsubscribe from this group, send email to
> [email protected].
> For more options, visit this group at
> http://groups.google.com/group/satchmo-users?hl=en.
>
>

-- 
You received this message because you are subscribed to the Google Groups 
"Satchmo users" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/satchmo-users?hl=en.

Reply via email to