jQuery.ListaDeCompras
4.0.37
See the version list below for details.
dotnet add package jQuery.ListaDeCompras --version 4.0.37
NuGet\Install-Package jQuery.ListaDeCompras -Version 4.0.37
<PackageReference Include="jQuery.ListaDeCompras" Version="4.0.37" />
paket add jQuery.ListaDeCompras --version 4.0.37
#r "nuget: jQuery.ListaDeCompras, 4.0.37"
// Install jQuery.ListaDeCompras as a Cake Addin #addin nuget:?package=jQuery.ListaDeCompras&version=4.0.37 // Install jQuery.ListaDeCompras as a Cake Tool #tool nuget:?package=jQuery.ListaDeCompras&version=4.0.37
jQuery.ListaDeCompras
jQuery plugin of the Lista de Compras platform
NPM - Node Package Manager
Este repositório está disponível no NPM com o nome jquerylistadecompras.
npm i jquerylistadecompras
NuGet - Package Manager for .NET
Este repositório está disponível no NPM com o nome jquery.listadecompras.
dotnet add package jquery.listadecompras
Lista de Compras (Editora Inovação) is a application that allows you create a list of available products selling in Vitrine do Artesanto or Tania Silva store and show it on any website with a link to the cart of the store.
With this plugin you can manage your lists, [TODO] account preferences and get the available products for building new lists.
Lista de Compras API documentation
The plugin working on Programa Arte Brasil:
And in the Canal do Artesanato:
Usage
To simple show a list in your page, creates a simple HTML element and call the plugin:
<div id="showListaDeCompras"></div>
Now call the plugin:
var listaDeCompras = $("#showListaDeCompras").listaDeCompras({
readKey : "your-read-key",
listId : 1, //The list ID
theme: "oliveDrab" //The list theme (availables: red, orange, green, blue, oliveDrab and default)
});
Options
You can pass options by the constructor or by the options method (see * Methods * above for more info)
Option | Description | Default value | Values |
---|---|---|---|
useProduction | Sets the platform environment | true | boolean:true|false |
readKey | The platform API key | null | string:your api key |
type | The display type (use table or ul/li elements) | table | string:table|list |
showPrices | Flag to show products prices or not | true | boolean:true|false |
listLoadSuccesfullyCallback | A callback function to trigger when the lists load succesfully | null | function |
listLoadErrorCallback | A callback function to trigger when cannot load the list (error | list dosen't exists) | null | function |
debug | A flag to enable or disable debugging | false | boolean:true|false |
maxProducts | Limit the maximum number of products displayed in the list | -1 | integer: -1 show all | N shows N |
theme | The plugin CSS theme | default | string: red, orange, blue, green, oliveDrab, default |
customCampaign | The utm_campaign string for the buy link | null | string |
headerText | The plugin header text | null | string |
css | This option allows you set custom CSS classes for some items of the plugin | ** default plugin classes ** | object: see table below |
** The CSS classes ** can be overrrinding by setting the CSS option with the following object:
Property | Description | Default value |
---|---|---|
itemQuantity | The item quantity field | quantity |
itemQuantityPlus | The item quantity increase button | plus |
itemQuantityLess | The item quantity decrease button | less |
itemAvailability | The item availability class to enable|disable the quantity field & buttons | availability |
itemAvailabilityIcon | The item availability icon | stockIcon |
buyButton | The buy button | buy |
cartTotal | The cart total descriptor | amount |
Methods
There are a few methods that can be called to operate the plugin programmatically
init: Initializes the plugin
$("#target").listaDeCompras("init");
destroy: Destroys the plugin (the list itself is also removed from the page)
$("#target").listaDeCompras("destroy");
load: Loads a specific list by it's id
$("#target").listaDeCompras("load", 1234); //try to load the list 1234
updateQuantity: Updates the selected quantity for a specified SKU in the list
$("#target").listaDeCompras("updateQuantity", 1, 10); //updates the quantity of SKU 1 to 10 units
addToCart: adds a sku to the cart, this is the same of adding 1 item of the product
$("#target").listaDeCompras("addToCart", new { SalesChannelId: 1000001, Stock: 10, Quantity: 1, Price: 10.9});//You should pass the sales channel id, available quantity, desired quantity and the price of the SKU
clearCart: Removes all products from the cart
$("#target").listaDeCompras("clearCart");
addEventListeners: Add event listeners to the plugin increase & decrease buttons, quantity fields and buy button
$("#target").listaDeCompras("addEventListeners");
getBuyLink: Gets the link to the store cart (with all sku & quantity) selecteds and the SEO params
var link = $("#target").listaDeCompras("getBuyLink");
window.open(link);
getCartTotal: Gets the current cart total
var total = $("#target").listaDeCompras("getCartTotal");
window.alert("Current cart is R$ " + total);
updateCartTotal: Updates the cart total (only if showPrices option is set to true), usefull when you add products or change the quantity of a product via JS
$("#target").listaDeCompras("updateCartTotal");
set: Sets an option after the plugin has been initialized
$("#target").listaDeCompras("set", "optionName", "optionValue");
get: Gets the current value for a option
$("#target").listaDeCompras("get","optionName");
debug: Debugs the current plugin to the console.log
$("#target").listaDeCompras("debug");
Learn more about Target Frameworks and .NET Standard.
This package has no dependencies.
NuGet packages
This package is not used by any NuGet packages.
GitHub repositories
This package is not used by any popular GitHub repositories.
Version | Downloads | Last updated |
---|---|---|
4.0.59 | 66 | 11/25/2024 |
4.0.58 | 66 | 11/18/2024 |
4.0.57 | 76 | 11/11/2024 |
4.0.56 | 73 | 11/4/2024 |
4.0.55 | 84 | 10/28/2024 |
4.0.53 | 87 | 10/21/2024 |
4.0.52 | 78 | 10/14/2024 |
4.0.51 | 83 | 10/7/2024 |
4.0.50 | 95 | 9/30/2024 |
4.0.49 | 79 | 9/23/2024 |
4.0.48 | 109 | 9/16/2024 |
4.0.47 | 104 | 9/15/2024 |
4.0.46 | 85 | 9/9/2024 |
4.0.45 | 82 | 9/2/2024 |
4.0.44 | 117 | 8/27/2024 |
4.0.43 | 124 | 8/26/2024 |
4.0.41 | 112 | 8/19/2024 |
4.0.40 | 119 | 8/12/2024 |
4.0.39 | 66 | 8/5/2024 |
4.0.38 | 76 | 7/29/2024 |
4.0.37 | 100 | 7/22/2024 |
4.0.36 | 82 | 7/11/2024 |
4.0.35 | 87 | 7/7/2024 |
4.0.34 | 73 | 7/6/2024 |
4.0.33 | 113 | 7/1/2024 |
4.0.32 | 96 | 6/24/2024 |
4.0.30 | 106 | 6/18/2024 |
4.0.29 | 109 | 6/17/2024 |
4.0.28 | 106 | 6/17/2024 |
4.0.27 | 106 | 6/17/2024 |
4.0.25 | 103 | 5/19/2024 |
4.0.24 | 116 | 4/22/2024 |
4.0.23 | 193 | 3/21/2024 |
4.0.22 | 191 | 2/14/2024 |
4.0.21 | 266 | 1/2/2024 |
4.0.20 | 291 | 11/5/2023 |
4.0.19 | 288 | 10/22/2023 |
4.0.18 | 243 | 10/22/2023 |
4.0.17 | 238 | 9/17/2023 |
4.0.16 | 143 | 7/19/2023 |
4.0.13 | 159 | 6/26/2023 |
4.0.12 | 172 | 6/5/2023 |
4.0.11 | 168 | 5/8/2023 |
4.0.10 | 153 | 5/8/2023 |
4.0.9 | 152 | 5/4/2023 |
4.0.8 | 175 | 4/11/2023 |
4.0.7 | 203 | 4/11/2023 |
4.0.6 | 159 | 4/11/2023 |
4.0.5 | 179 | 4/11/2023 |
4.0.4 | 195 | 4/11/2023 |
4.0.3 | 201 | 4/11/2023 |
4.0.2 | 183 | 4/4/2023 |
4.0.1 | 202 | 4/3/2023 |
4.0.0 | 224 | 3/27/2023 |
3.0.11 | 245 | 3/2/2023 |
3.0.10 | 257 | 1/30/2023 |
3.0.8 | 284 | 1/30/2023 |
3.0.7 | 288 | 1/30/2023 |
1.0.1 | 1,191 | 10/2/2017 |