Akopia Akopia Services

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

Re: [mv] Don't Know How To Title This Question



On Feb 4, 11:13am, OTR Comm wrote:
} Subject: Re: [mv] Don't Know How To Title This Question
} Bill Randle wrote:
} >
}
} > It's possible you could use the inventory database for this - I haven't
} > really used the inventory db, so I don't know for sure.
} >
} > The way I implemented this in the past was to add a "status" field to
} > the product database. This field would show the product status, e.g.:
} > SALE-PENDING, SOLD, SALE-FAILED, AVAILABLE. Each item that is displayed
} > simply checks the status field and displays the appropriate message.
} > It should be pretty straight forward to add some mv tags or [perl]
} > block to the checkout page to set the status field.
} >
} > The scenario I was doing this for was actually an auction, so it went
} > one step further and automatically sent email to the next highest
} > bidder when the status changed from SALE-PENDING to SALE-FAILED. After
} > processing any product records with the SALE-FAILED status, the status
} > field was changed to AVAILABLE. This was all done via a cron script that
} > ran every 5-10 minutes.
} >
} >         -Bill
} >
} Thanks for the idea, it looks like this should work okay.
}
} Now, another question.  How do/did you control the situation where
} someone did put the item in their cart, but for whatever reason, during
} their session, they just left the store without checkingout or maybe
} they saved their cart.  In other words, is there a way to put a time
} limit on how long someone can keep something in their cart without
} paying for it?
}
} This would also be useful if you wanted to allow someone to put a
} 'deposit' on an item to hold it until they determined if they really
} wanted/or could buy something.
}
} Thanks,
} Murrah Boswell

Sure. Just add a timestamp field to the database. At the time you
change the item status from AVAILABLE to SALE-PENDING, set the
"sale_time" (or whatever you call it) to the current time.

How you handle it can be done in a couple of different ways.
(1) whenever the item is accessed for display, the timestamp
    field is compared against the current time. If your hold
    time has elapsed, change the status to available and display
    the item as usual.

(2) have a cron job that runs periodically to check the products
    database for expired sales (those whose hold time is greater
    then your pre-determined limit) and reset the status field
    to AVAILABLE.

In both cases, whenever the status is changed, you may need to check
for any existing carts or saved carts containing that item and
remove it from the cart. In the case of a saved cart (where you have
a username), you could even send the user email letting them know
the hold time has expired and has been removed from their saved cart.
If you go that route, I would suggest option (2) as you probably
don't want to do all that processing during the display of search results.

	-Bill

_______________________________________________
Minivend-users mailing list
Minivend-users@minivend.com
http://www.minivend.com/mailman/listinfo/minivend-users


Search for: Match: Format: Sort by: