Announcement

Collapse
No announcement yet.

Creating an Order Form to Add Multiple Products at Once?

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

    Creating an Order Form to Add Multiple Products at Once?

    In MM5, Emporium Plus and Sebenza both had modules that created a product list that showed product name, price and a quantity box next to it, with an ADD TO CART button at the bottom. That way a user could go down the list and enter a quantity into the box and pop a bunch of products into the cart all at once then check out.

    The EP module no longer works in Miva 9.

    So might someone wise be able to post the page code that would accomplish that same task?

    Thanks!
    Allen Freeman
    http://ClevelandCreative.com
    http://www.StandardLegal.com

    #2
    Re: Creating an Order Form to Add Multiple Products at Once?

    This is a feature that will be built into Miva very soon. However here is some JavaScript code we use to accomplish this:


    Code:
    1. $(document).ready(function(){ var siteURL ="http://YOURSTOREDOMAIN/mm5/merchant.mvc"; $("#multiple-add").bind("submit",function(){ $("#multiple-add input[name='Product_Code']").each(function(index){ if($(this).val()!=""){ var qty = parseInt($("#multiple-add input[name='Quantity']").eq(index).val()); if(!isNaN(qty)&& qty >0){ var parameters ={}; parameters["Action"]="ADPR"; parameters["Product_code"]= $(this).val(); parameters["Quantity"]= qty; $(".product-attributes:eq("+index+") input[name*='Product_Attributes[']").each(function(ind){ parameters["Product_Attributes["+(ind+1)+"]:code"]= $(this).val(); parameters["Product_Attributes["+(ind+1)+"]:value"]= $(".product-attributes:eq("+index+") select[name*='Product_Attributes[']").eq(ind).val(); }); $.ajax({ 'type':"GET", 'url': siteURL, 'data': parameters, 'async':false }); } } }); }); });
    Attached are some full instructions as well.
    Attached Files
    Brennan Heyde
    VP Product
    Miva, Inc.
    [email protected]
    https://www.miva.com

    Comment


      #3
      Re: Creating an Order Form to Add Multiple Products at Once?

      Thx much Brennan, but I don't have enough knowledge to implement this as its presented for what I need to accomplish.

      I can't edit the existing CTGY page, as I still need it to function as-is.

      What I was hoping to create is a separate page, maybe called QUICK for "Quick Order Form", which I can link to as a stand-alone page for customers to use to quickly shop all products. But I can't figure out how to do that from here.

      Is it too much trouble to ask for the code and instructions to set this up as a brand new page called QUICK to function in this manner?

      And if it is too much trouble, any idea when 'very soon' is for this option to be included in v9?

      Thank you!
      Allen Freeman
      http://ClevelandCreative.com
      http://www.StandardLegal.com

      Comment


        #4
        Re: Creating an Order Form to Add Multiple Products at Once?

        And if it is too much trouble, any idea when 'very soon' is for this option to be included in v9?
        End of March is the goal.
        Thanks,

        Rick Wilson
        CEO
        Miva, Inc.
        [email protected]
        https://www.miva.com

        Comment


          #5
          Re: Creating an Order Form to Add Multiple Products at Once?

          If the code is created to set up a new, separate 'Quick Order' page for customers to shop list-style all the products available in the store with 'Add to Cart' buttons every 15-20 products or so, it would be much appreciated if that code was posted here.

          Otherwise, a notice when this new feature is available would be welcomed, too. Thanks guys.
          Allen Freeman
          http://ClevelandCreative.com
          http://www.StandardLegal.com

          Comment


            #6
            Re: Creating an Order Form to Add Multiple Products at Once?

            The feature will be in 9.0003 (our next release).
            Thanks,

            Rick Wilson
            CEO
            Miva, Inc.
            [email protected]
            https://www.miva.com

            Comment


              #7
              Re: Creating an Order Form to Add Multiple Products at Once?

              Thx Rick, but I must say that I'm still unclear how these 'version' updates are implemented.

              I only just activated Miva 9 for this client about 9-10 days ago, so I haven't experienced a version update yet.

              I've made a number of customizations to Pages and the css directly in the ReadyTheme Base.

              So do these version updates get posted without overwriting all of those changes? Or are the version changes only to things not in the ReadyTheme itself?

              (I hope I'm not expected to pick through code by hand to find and copy-over new version changes to currently customized pages for each new version update, or to have to find/remember and repost all of those customizations to newly overwritten files...)
              Allen Freeman
              http://ClevelandCreative.com
              http://www.StandardLegal.com

              Comment


                #8
                Re: Creating an Order Form to Add Multiple Products at Once?

                The ReadyTheme you are using is completely separate from the Version of Miva you are using. When Miva is updated it is done via a streaming update system similar to an Operating System update. Once updates are complete, new functionality will be available via the admin.

                Sometimes we release new features that require page template changes in order to use. In those cases you have to manually make the changes needed. The new sorting feature we're referring to will be part of 9.0003 and not require any manual changes from you in order to use. Once it is released and you run updates you will just have it.
                Brennan Heyde
                VP Product
                Miva, Inc.
                [email protected]
                https://www.miva.com

                Comment


                  #9
                  Re: Creating an Order Form to Add Multiple Products at Once?

                  Cool, thx for the clear answer Brennan.

                  I'll keep an eye out for the update and see if I can make it work as the old custom category page module did before...
                  Allen Freeman
                  http://ClevelandCreative.com
                  http://www.StandardLegal.com

                  Comment


                    #10
                    Re: Creating an Order Form to Add Multiple Products at Once?

                    I saw the email that 9.003 has been released.

                    Did the feature described in this post make it into the update, and can you provide any instruction to activate said feature?

                    Thanks...
                    Allen Freeman
                    http://ClevelandCreative.com
                    http://www.StandardLegal.com

                    Comment


                      #11
                      Re: Creating an Order Form to Add Multiple Products at Once?

                      Ah, I think I found the instructions:

                      http://www.miva.com/videos/articles/...-documentation
                      Allen Freeman
                      http://ClevelandCreative.com
                      http://www.StandardLegal.com

                      Comment


                        #12
                        Re: Creating an Order Form to Add Multiple Products at Once?

                        OK, so I read the instructions in the documentation link. But I could use some further help, please.

                        I have a category page called QUICK that I first used in v5:
                        http://adasignfactory.com/category/QUICK.html

                        But from the code on that page, I can't tell exactly what I should and should not edit to create this 'shop all products' page.

                        Here is the current code posted for the Template on QUICK:



                        <mvt:item name="html_profile" />
                        <head>
                        <title>&mvt:store:name;: Quick Order Form</title>
                        <base href="&mvt:global:basehref;" />
                        <mvt:item name="head" param="css_list" />
                        <mvt:item name="head" param="head_tag" />
                        <script type="text/javascript">
                        $(document).ready(function() {
                        var siteURL = "http://adasignfactory.com/mm5/merchant.mvc";
                        $("#multiple-add").bind("submit", function() {
                        $("#multiple-add input[name='Product_Code']").each(function(index) {
                        if ($(this).val() != "") {
                        var qty = parseInt($("#multiple-add input[name='Quantity']").eq(in
                        dex).val());
                        if (!isNaN(qty) && qty > 0) {
                        var parameters = {};
                        parameters["Action"] = "ADPR";
                        parameters["Product_code"] = $(this).val();
                        parameters["Quantity"] = qty;
                        $(".product-attributes:eq("+index+") input[name*='Product_Attrib
                        utes[']").each(function(ind) {
                        parameters["Product_Attributes["+(ind+1)+"]:code"] = $(this).v
                        al();
                        parameters["Product_Attributes["+(ind+1)+"]:value"] = $(".prod
                        uct-attributes:eq("+index+") select[name*='Product_Attributes[']").eq(ind).v
                        al();
                        });
                        $.ajax({
                        'type': "GET",
                        'url': siteURL,
                        'data': parameters,
                        'async': false
                        });
                        }
                        }
                        });
                        });
                        });
                        </script>
                        </head>
                        <body class="&mvt:page:code;" id="JS_&mvt:page:code;">
                        <div id="site-container">
                        <mvt:item name="hdft" param="global_header" />
                        <mvt:item name="navbar" />
                        <div class="items">
                        <div class="page-head">
                        <div class="container">
                        <div class="row">
                        <div class="col-md-12"><h1>QUICK ORDER FORM</h1></div>
                        </div>
                        <mvt:item name="hdft" param="header" />
                        </div>
                        </div>
                        <div class="content">
                        <div class="container">
                        <div class="row">
                        <div class="col-md-3 col-sm-3 hidden-xs">
                        <mvt:item name="category_tree" />
                        </div>
                        <div class="col-md-9 col-sm-9">
                        <mvt:item name="breadcrumbs" />
                        <mvt:if expr="l.settings:all_products:products_on_page_cou nt GT 1">
                        <div class="form-group pull-right">
                        <form method="get" action="&mvte:global:sessionurl;">
                        <input type="hidden" name="Screen" value="&mvte:global:Screen;" />
                        <input type="hidden" name="Store_Code" value="&mvte:global:Store_Code;" />
                        <input type="hidden" name="Category_Code" value="&mvte:global:Category_Code;" />
                        <input type="hidden" name="Product_Code" value="&mvte:global:Product_Code;" />
                        <input type="hidden" name="Search" value="&mvte:global:Search;" />
                        <input type="hidden" name="Per_Page" value="&mvte:global:Per_Page;" />
                        <select name="Sort_By" onchange="this.form.submit();" class="form-control">
                        <mvt:if expr="ISNULL g.Sort_By">
                        <option value="disp_order" selected="selected">Sort By</option>
                        <mvt:else>
                        <option value="disp_order">Sort By</option>
                        </mvt:if>
                        <mvt:if expr="g.Sort_By EQ 'name_asc'">
                        <option value="name_asc" selected="selected">Name (A-Z)</option>
                        <mvt:else>
                        <option value="name_asc">Name (A-Z)</option>
                        </mvt:if>
                        <mvt:if expr="g.Sort_By EQ 'name_desc'">
                        <option value="name_desc" selected="selected">Name (Z-A)</option>
                        <mvt:else>
                        <option value="name_desc">Name (Z-A)</option>
                        </mvt:if>
                        <mvt:if expr="g.Sort_By EQ 'bestsellers'">
                        <option value="bestsellers" selected="selected">Best Selling</option>
                        <mvt:else>
                        <option value="bestsellers">Best Selling</option>
                        </mvt:if>
                        <mvt:if expr="g.Sort_By EQ 'price_asc'">
                        <option value="price_asc" selected="selected">Lowest Price</option>
                        <mvt:else>
                        <option value="price_asc">Lowest Price</option>
                        </mvt:if>
                        <mvt:if expr="g.Sort_By EQ 'price_desc'">
                        <option value="price_desc" selected="selected">Highest Price</option>
                        <mvt:else>
                        <option value="price_desc">Highest Price</option>
                        </mvt:if>
                        <mvt:if expr="g.Sort_By EQ 'newest'">
                        <option value="newest" selected="selected">Newest Items</option>
                        <mvt:else>
                        <option value="newest">Newest Items</option>
                        </mvt:if>
                        </select>
                        <noscript><input type="submit" value="go"></noscript>
                        </form>
                        </div>
                        </mvt:if>
                        <div class="clearfix"></div>
                        <div class="row">


                        </div>
                        </div>
                        </div>
                        </div>
                        </div>
                        </div>
                        <mvt:item name="hdft" param="footer" />
                        <mvt:item name="hdft" param="global_footer" />
                        </div>
                        </body>
                        </html>





                        Candidly, I can't tell how I'm supposed to edit the above with the details outlined on
                        http://www.miva.com/videos/articles/...-documentation

                        Thank you!
                        Allen Freeman
                        http://ClevelandCreative.com
                        http://www.StandardLegal.com

                        Comment


                          #13
                          Re: Creating an Order Form to Add Multiple Products at Once?

                          Yes this was part of 9.0003. Here is an example on how it works:

                          http://www.miva.com/videos/articles/...-documentation
                          Brennan Heyde
                          VP Product
                          Miva, Inc.
                          [email protected]
                          https://www.miva.com

                          Comment


                            #14
                            Re: Creating an Order Form to Add Multiple Products at Once?

                            Originally posted by Brennan View Post
                            Yes this was part of 9.0003. Here is an example on how it works:

                            http://www.miva.com/videos/articles/...-documentation


                            Yessir, I saw that (said so in the two posts that follow the original). But that page doesn't explain things very well...
                            Allen Freeman
                            http://ClevelandCreative.com
                            http://www.StandardLegal.com

                            Comment


                              #15
                              Re: Creating an Order Form to Add Multiple Products at Once?

                              We're working on some more examples, but this is not a point and click feature. It is more of a tool that can be used for a number of different use cases.

                              We're going to update that page with some more examples soon to better illustrate how it works.
                              Brennan Heyde
                              VP Product
                              Miva, Inc.
                              [email protected]
                              https://www.miva.com

                              Comment

                              Working...
                              X