Akopia Akopia Services

[Date Prev][Date Next][Thread Prev][Thread Next][Minivend by date ][Minivend by thread ]

Re: [mv] Discount by user log in



******    message to minivend-users from Ed LaFrance <edlafrance@printexusa.com>     ******



At 05:40 PM 4/11/00 +1000, you wrote:
>******    message to minivend-users from "Geoff" 
><minivend@hq.com.au>     ******
>
>What is the best method to apply a discount by user when they log in?

The docs have a section about the use of the [discount] tag which is quite 
clear.  What is doesn't explicitly tell you is that you will probably want 
to create a field in userdb to store the discount amount for each customer 
(I assume you want to do a one-rate discount for each registered customer 
who qualifies).  You can reference the value in this field (if one exists) 
when doing discount calculations for the currently logged user:

[if data session logged_in]
[then]
         [if data userdb::discount_amount::[data session username]]
                 [discount]**calcs here ***[/discount]
         [/if]
[/then]
[/if]

The above code snip is just an untested example to suggest how you might 
use a value stored in userdb field called "discount_amount" to calculate 
the discount for a logged user.

- Ed L.

Printex Marking Technologies
12113 Kirkham Rd.
Poway, CA  92064  U.S.A.
858-513-2418
800-982-1928
858-513-2419 FAX
http://www.printexusa.com

-
To unsubscribe from the list, DO NOT REPLY to this message.  Instead, send
email with 'UNSUBSCRIBE minivend-users' in the body to Majordomo@minivend.com.
Archive of past messages: http://www.minivend.com/minivend/minivend-list


Search for: Match: Format: Sort by: