﻿function cartCallBack(Element) {
    var inputColor = $(".comboColors")[0];
    if (inputColor != undefined) var txtColor = inputColor.value;

    var inputPower = $(".comboPower")[0];
    if (inputPower != undefined) var txtPower = inputPower.value;
    
    var AddProductData = new Array();

    AddProductData["Quantity"] = 1;
    if (txtColor != undefined) {
        if (txtColor != '') { AddProductData["UserData1"] = txtColor; }
    }

    if (txtPower != undefined) {
        if (txtPower != '') { AddProductData["UserData2"] = txtPower; }
    }


    $.blockUI(
    {
        message: 'Zboží bylo přidáno do košíku.....',
        css: {
            fontSize: '20px',
            fontWeight: 'bold',
            border: 'none', 
            padding: '15px', 
            backgroundColor: '#000', 
            '-webkit-border-radius': '10px',
            '-moz-border-radius': '10px', 
            opacity: 0.5, 
            color: '#fff'
        }, 
        overlayCSS: {
            backgroundColor: '#000',
            opacity: 0.4
        }
    });
 
    setTimeout($.unblockUI, 2000); 


    return AddProductData;
}


