Can I show the stock level on a catalog page. So that users know that a product is sold out or how many are in stock!
Thx
|
Ubercart |
|
| Donate | Affiliates | Sponsors | ||
Stock level on catalog pageCan I show the stock level on a catalog page. So that users know that a product is sold out or how many are in stock! Thx I'm also interested in customizing the catalog page ... It would be nice if you had an option to show stock levels and a fast add to cart button or link. Less clicks for the users viewing the store. Good with CSS - Bad with Code. To show the "add to cart" button that's possible. I don't know where to set this option at this moment, but I thought you can do it by shop configuration and then catalog. But there you can't set the option to show the stock level on the catalog page. Have you guys checked out Inventory API & Simple Stock levels?: it is really sweet. If you can print out the levels of stock on admin, then yes, you will be able to do it front-end. U just need to add the "stocklevels" from /admin/content/types/product/fields Would be a nice addition.. Will post if I have success.. I'm currently working on code that provides Views integration for Ubercart Attributes: http://www.ubercart.org/contrib/3960 The code includes some Stock integration (i.e. you can choose to display only those products that are in stock). Including a stock level field as part of that code wouldn't be difficult. This would provide you the ability to make a view that showed the stock level of a product with a specific set of attribute options. The specific set of options could be chosen by an option select box in the Views edit page, and the default would be to show the stock level for a product with no attributes or attribute options. Admittedly, this doesn't get the Stock level built into Ubercart's catalog feature, but if you're comfortable using Views, this should do exactly what you want. I suspect I won't be able to work on this feature until sometime next week, but let me know if this is what you're looking for and I'll make sure to put it on my To-Do list. Maybe this is usefull to somebody: It displays a small table with the current stocklevel of all stock-enabled SKU's for a product. <?php Put it in the node.tpl.php, and print the var $stock_html in a proper place. Feel free to ask. Regards, Kees How do i make stock level by stores?. How do i make store level inventory for each product? How do i show which store the product is available? How do i show which store is nearer to a zip code (different ranges). Sweet keesje76, Cheers for the share mate! I'm finding this theme snippet to be a real gem as it dramatically cuts down customer questions about particular product attributes being in stock. Placing the < ? php print $stock_html ? > in < fieldset class=" collapsible collapsed" > < / fieldset > tags, allows the table to be displayed in a collapsed field, which reduces screen clutter. Two Questions: 2) Also, this snippet only displays a decrease in stock when an item has been purchased. Is there any way to make it display a decrease when a product has been added to a cart, but hasn't yet been purchased. ^_^ How do i make stock level by stores?. How do i make store level inventory for each product? How do i show which store the product is available? How do i show which store is nearer to a zip code (different ranges). Sorry, I don't know what youre talkin about. Ubercart IS a store. Just one. Good suggestion, thanks for sharing. 2) This is the nature of Ubercart stock levels. I personally like it the way it is. is that using the simple stock levels? Heyas Any update on this ? I sell a mixture of items that are "in stock" or "custom made" or "special ordered" Being able to show current Stock Level on product page helps provide a "Lead Time" for my customer base I am not good with coding so anything "point and shoot" is ideal for me Here's a simple way to display stock level for nodes, and also to remove the "add to cart" button if the stock is zero. Add the following to the template.php file in your sites/all/themes/YOUR_THEME_NAME directory, changing the function name according to your theme's name: function YOUR_THEME_NAME_uc_product_add_to_cart( $node ) {Note that there are some obvious limitations to this: I modified below code to allow for stock levels on product attributes. Not elegant, but it works // ######### BEGIN CUSTOM CODING RELATED TO STOCK DISPLAY ###############
Here's a simple way to display stock level for nodes, and also to remove the "add to cart" button if the stock is zero. Add the following to the template.php file in your sites/all/themes/YOUR_THEME_NAME directory, changing the function name according to your theme's name: function YOUR_THEME_NAME_uc_product_add_to_cart( $node ) {Note that there are some obvious limitations to this: Did anyone had succes displaying the stocklevels of options in the right order (same order as the options itself are ordered)? I'm struggling with this, I believe it's imposible. Any help greatly appreciated! More info and ugly fix for anyone interested: It works nice except... |
|
Joined: 12/07/2007