inquisitive Posted August 19, 2008 Share Posted August 19, 2008 Alright here is my dilemma...I am trying to create an e-commerce system that allow the following: Three types of logins 2 types are dealers 1 type is a distributer Now when distributers login they order and a certain percentage of their orders go to their specific dealer...I am not sure how to tie this together...I would have to either have each dealer made create a table and in that table all the dsitributers that they signed up...or create a number that is assigned to the distributer and every time that number makes a purchase then the specified percentage of their order goes to the dealer... I am just at a loss... Quote Link to comment Share on other sites More sharing options...
fenway Posted August 20, 2008 Share Posted August 20, 2008 What's confusing? Quote Link to comment Share on other sites More sharing options...
inquisitive Posted August 20, 2008 Author Share Posted August 20, 2008 the entire thing...but mainly setting it up so that everytime a user signs in the system recognizes them and someones dealer and when they make the purchase automatically assign the comission to the distributer. Quote Link to comment Share on other sites More sharing options...
fenway Posted August 21, 2008 Share Posted August 21, 2008 the entire thing...but mainly setting it up so that everytime a user signs in the system recognizes them and someones dealer and when they make the purchase automatically assign the comission to the distributer. I don't understand. Quote Link to comment Share on other sites More sharing options...
inquisitive Posted August 22, 2008 Author Share Posted August 22, 2008 what is there to understand... Basically it is setup like Amway and every other sales company out there...The dealers sign up distributers and because they signed that specific distributer up the overall company gives the dealer a commission based on the orders that the distributer makes...I was just wondering if there was a system out there already that handled commission payments...or if you could suggest a way of attacking this with a few examples of code just to get me on my way... My theory is to create a unique id which is assigned to each individual that creates an account on the site.... from there I just hit a wall...any help would be awesome Quote Link to comment Share on other sites More sharing options...
fenway Posted August 22, 2008 Share Posted August 22, 2008 Basically it is setup like Amway and every other sales company out there...The dealers sign up distributers and because they signed that specific distributer up the overall company gives the dealer a commission based on the orders that the distributer makes... So you just want to keep track of which distributor was signed up by which dealer? Quote Link to comment Share on other sites More sharing options...
Hooker Posted August 23, 2008 Share Posted August 23, 2008 Okay, i'm not sure i understand exactly what you want but it sounds like all you need to do is create an "orders" table, structured something like this (obviously with the rest of the order information tagged on): order_id dealer_id distributor_id cost commision Then on the insert calculate the commision based on the percentage defined and you can use it as a reference table to calculate how much a user has/hasn't got. Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.