Announcement

Collapse
No announcement yet.

Real Time Stock Display on SPP Section Link Layout

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    Real Time Stock Display on SPP Section Link Layout

    Anyone managed to get stock levels showing on an SPP listing page? Sometimes people have an add to cart at this level so seems sensible to relay stock info also i'd have thought. Just been asked by a customer and i have no idea at all on this area yet, but it seems a sensible requirement.

    #2
    Originally posted by leehack View Post
    Anyone managed to get stock levels showing on an SPP listing page? Sometimes people have an add to cart at this level so seems sensible to relay stock info also i'd have thought. Just been asked by a customer and i have no idea at all on this area yet, but it seems a sensible requirement.
    The stock display is handled by a javascript and I did some work on this during the V10 beta to handle negative values in suspend orders.

    The stock level is displayed by the layout 'Display Stock Quantities' and relies on the layout 'JavascriptSectionStockQuery' being in the page layout. I will have a look if it works at section level.

    Malcolm

    SellerDeck Accredited Partner,
    SellerDeck 2016 Extensions, and
    Custom Packages

    Comment


      #3
      Cheers Malcolm, he's found this thread so his hopes are all resting on you now.

      **makes sharp exit and notes down to study the real time stock mallarky**

      Comment


        #4
        Originally posted by leehack View Post
        Cheers Malcolm, he's found this thread so his hopes are all resting on you now.

        **makes sharp exit and notes down to study the real time stock mallarky**
        There is one problem to be solved to get it to work, watch this space

        Malcolm

        SellerDeck Accredited Partner,
        SellerDeck 2016 Extensions, and
        Custom Packages

        Comment


          #5
          Stock Levels on SPP sections

          Not as easy as it appeared but here is a working version http://stockplugin.toddesigns.com/ with two spp pages, also shows operation of the stock value adjustment, same two products are shown on a separate page without adjustment to show what happens when suspend level is changed..

          The actinic system uses an ajax call to get the information from the server via the perl scripts. When the page loads the javascript requests a list of product references and stock levels from the server. The data is held in files on the server that appear to be specific to a section so the server provides a list of product references and stock levels from a single file.

          The section page that holds single product pages doesn't have any products so Actinic doesn't provide the necessary data in the section file.

          To get this to work the software has to request data for each of the section pages the hold a product and in the end I modified the perl script by adding new code so that I could pass a list of section numbers from a section the holds a number of spp pages.

          All the normal pages work as before.

          The code also includes some modifications that relate to a modification I made to to stock control during beta testing, to deal with the display of stock levels if you set any value other than 1 in the suspend stock setting. Positive values above 1 reduce the displayed stock level and negative values increase the stock level.

          I modified the javascript to display the correct stock level whatever the setting in the suspend value, a message to allow backordering if stock was zero (hence the need to set negative values in the suspend setting).


          Limitations:

          If there are lots of pages then this will mean the server has to look up lots of files so it will slow down as size increases.

          It will not return data on products in the section, there shouldn't be any if you are using spp.


          EDIT 3/12/2012 to update the URL
          Last edited by malbro; 02-Jun-2010, 12:35 PM. Reason: new demo site

          Malcolm

          SellerDeck Accredited Partner,
          SellerDeck 2016 Extensions, and
          Custom Packages

          Comment


            #6
            The changes now include compensation for the stock suspend level, if the suspend level is set to any value other than 1 then the stock level displayed is modified in the standard Actinic code.

            An example is the digital camera which has a real stock level of 35 and a suspend level of 2 on the demo in previous post.

            On the spp page for the camera the stock displays as 34, i.e. only 34 are available to be sold even though there are 35 in stock. If you set a negative stock suspend level to allow sales even though you do not have the stock currently available say -10 then the display would be 46.

            The code on the top section to the spp pages includes the compensation for suspend level so it displays 35 even though the suspend level is set to 2.

            The plugin is now available from http://toddesigns.com/acatalog/displ...ock_level.html.

            Malcolm

            SellerDeck Accredited Partner,
            SellerDeck 2016 Extensions, and
            Custom Packages

            Comment


              #7
              Looks like this really coming together, well done. You're really getting into how the new stock system works.

              I hate to say this but isn't it easier to put cut down duplicates in the parent section instead of using section links though?

              Comment


                #8
                Well done for cracking it Malcolm, nice work.

                I must say I'm somewhat disappointed that actinic do not seem to have thought about this one though. There are hundreds if not thousands of people using this setup, its been a recommended setup in the AUG for years.

                This is the only automatic way of doing SPP which provides all of the required SEO fields, amongst other benefits. With the improvements to extended info shelved, people are seemingly left with a choice of restructuring or paying for a plugin to use a new feature just launched, (if they wish to show stock levels at section level). Not a great choice it would appear.

                Comment


                  #9
                  Yes you can use duplicates but that wasn't the original question, the plug-in also deals with the stock control feature whereby setting a negative suspend level increases the displayed stock level. There was some discussion on this in the beta test forum and I produced a way to get around the problem but it relied on using the same setting for all suspend levels, the new code can handle each suspend level separately and compensates for any setting.

                  The requirement there was to be able to still take orders by switching the 'Out of stock' message to 'Item can be backordered' and making Actinic allow orders even when there was zero real stock, and to display the real stock level not the adjusted one.

                  Malcolm

                  SellerDeck Accredited Partner,
                  SellerDeck 2016 Extensions, and
                  Custom Packages

                  Comment

                  Working...
                  X