Forum Replies Created

Viewing 15 posts - 1 through 15 (of 17 total)
  • Author
    Posts
  • in reply to: What object to use What object to use #106352

    nostromo
    Participant

    The example is excellent.

    But in reality there are 3 alternatives: blank, yes, no.

    Maybe using jqxDropDownList?

    As there are only 3 options I want to use the most appropriate case.

    in reply to: Tag aggregates Tag aggregates #105888

    nostromo
    Participant

    Excellent, the code tells me the rows with data, but I still have the problem of how to remove the tag “In Stock:”

    If I change to “”: I keep getting the : and the result.

    I just need the result

    aggregates: [{ ‘In Stock’:
    function (aggregatedValue, currentValue) {
    if (currentValue) {
    return aggregatedValue + 1;
    }
    return aggregatedValue;
    }
    }]

    in reply to: Tag aggregates Tag aggregates #105868

    nostromo
    Participant

    understood, but my problem now goes by the count function, this gives me the total rows of the column, but I need to know the number of cells not empty in the column.

    What would be the way to evaluate that?

    in reply to: Problem color head json Problem color head json #102830

    nostromo
    Participant

    Excellent!!!

    in reply to: checkbox problem .js checkbox problem .js #102766

    nostromo
    Participant

    The problem was the chrome cache.

    Thank you

    in reply to: checkbox problem .js checkbox problem .js #102762

    nostromo
    Participant

    Probe with version 5.6.0 of jqwidgets and it works without problems,
    it seems that the problem is with version 6.1.0

    in reply to: checkbox problem .js checkbox problem .js #102761

    nostromo
    Participant

    This is the error:

    jquery-3.2.1.min.js:2 Uncaught TypeError: this.isMaterialized is not a function
    at b.(anonymous function).render (http://slayer.inia.cl/jqwidgets/jqxcheckbox.js:8:3986)
    at b.(anonymous function).createInstance (http://slayer.inia.cl/jqwidgets/jqxcheckbox.js:8:749)
    at Object.a.jqx.applyWidget (jqxcore.js:14)
    at HTMLDivElement.<anonymous> (jqxcore.js:14)
    at Function.each (jquery-3.2.1.min.js:2)
    at r.fn.init.each (jquery-3.2.1.min.js:2)
    at r.fn.init.a.fn.(anonymous function) [as jqxCheckBox] (http://slayer.inia.cl/jqwidgets/jqxcore.js:14:67439)
    at b.(anonymous function)._rendercheckboxcell (http://slayer.inia.cl/jqwidgets/jqxgrid.js:7:162442)
    at _rendercell (jqxgrid.js:7)
    at b.(anonymous function)._rendervisualcell (http://slayer.inia.cl/jqwidgets/jqxgrid.js:7:156004)

    in reply to: align headers align headers #102746

    nostromo
    Participant

    Excellent, it worked.

    I’m actually using the version jQWidgets v5.6.0

    Thank you very much for your time

    in reply to: align headers align headers #102731

    nostromo
    Participant

    Dear, your example works excellent in JSFiddle, but if I reply it as is in my site it does not have the same effect as I see in the example.

    example: if I apply 25px to the style in your example the headings are left as I want, but in my site they move but very little. If I go down to 10, it does not go up much either, something I must have wrong, I attach my complete code to see if you can help me.

    I’m using chrome

    <!doctype html>
    <html>
    <head>
    <meta charset=”utf-8″>
    <title>Documento sin título</title>
    <link rel=”stylesheet” href=”/jqwidgets/styles/jqx.base.css” type=”text/css” />
    <link rel=”stylesheet” href=”/jqwidgets/styles/jqx.energyblue.css” type=”text/css” />
    <script type=”text/javascript” src=”/jquery/jquery-3.2.1.min.js”></script>
    <script type=”text/javascript” src=”/jqwidgets/jqxcore.js”></script>
    <script type=”text/javascript” src=”/jqwidgets/jqxbuttons.js”></script>
    <script type=”text/javascript” src=”/jqwidgets/jqxscrollbar.js”></script>
    <script type=”text/javascript” src=”/jqwidgets/jqxdata.js”></script>
    <script type=”text/javascript” src=”/jqwidgets/jqxgrid.js”></script>
    <script type=”text/javascript” src=”/jqwidgets/jqxgrid.selection.js”></script>

    <script language=”javascript” type=”text/javascript”>
    $(document).ready(function(){
    var data = new Array();
    var firstNames = [
    “Andrew”, “Nancy”, “Shelley”, “Regina”, “Yoshi”, “Antoni”, “Mayumi”, “Ian”, “Peter”, “Lars”, “Petra”, “Martin”, “Sven”, “Elio”, “Beate”, “Cheryl”, “Michael”, “Guylene”];
    var lastNames = [
    “Fuller”, “Davolio”, “Burke”, “Murphy”, “Nagase”, “Saavedra”, “Ohno”, “Devling”, “Wilson”, “Peterson”, “Winkler”, “Bein”, “Petersen”, “Rossi”, “Vileid”, “Saylor”, “Bjorn”, “Nodier”];
    var productNames = [
    “Black Tea”, “Green Tea”, “Caffe Espresso”, “Doubleshot Espresso”, “Caffe Latte”, “White Chocolate Mocha”, “Cramel Latte”, “Caffe Americano”, “Cappuccino”, “Espresso Truffle”, “Espresso con Panna”, “Peppermint Mocha Twist”];
    var priceValues = [
    “2.25”, “1.5”, “3.0”, “3.3”, “4.5”, “3.6”, “3.8”, “2.5”, “5.0”, “1.75”, “3.25”, “4.0”];
    for (var i = 0; i < 100; i++) {
    var row = {};
    var productindex = Math.floor(Math.random() * productNames.length);
    var price = parseFloat(priceValues[productindex]);
    var quantity = 1 + Math.round(Math.random() * 10);
    row[“firstname”] = firstNames[Math.floor(Math.random() * firstNames.length)];
    row[“lastname”] = lastNames[Math.floor(Math.random() * lastNames.length)];
    row[“productname”] = productNames[productindex];
    row[“price”] = price;
    row[“quantity”] = quantity;
    row[“total”] = price * quantity;
    data[i] = row;
    }
    var source = {
    localdata: data,
    datatype: “array”
    };
    var dataAdapter = new $.jqx.dataAdapter(source, {
    loadComplete: function (data) {},
    loadError: function (xhr, status, error) {}
    });
    $(“#jqxgrid”).jqxGrid({
    theme: ‘energyblue’,
    altrows: true,
    width: 500,
    source: dataAdapter,
    columnsheight: 50,
    columns: [{
    text: ‘First Name’,
    datafield: ‘firstname’,
    width: 100
    }, {
    text: ‘Last Name’,
    datafield: ‘lastname’,
    width: 100
    }, {
    text: ‘Product’,
    datafield: ‘productname’,
    width: 180
    }, {
    text: ‘Quantity’,
    datafield: ‘quantity’,
    width: 80,
    cellsalign: ‘right’
    }, {
    text: ‘Unit Price’,
    datafield: ‘price’,
    width: 90,
    cellsalign: ‘right’,
    cellsformat: ‘c2’
    }, {
    text: ‘Total’,
    datafield: ‘total’,
    width: 100,
    cellsalign: ‘right’,
    cellsformat: ‘c2’
    }]
    });
    });
    </script>

    <style type=”text/css”>
    .jqx-grid-column-header div { line-height: 25px !important; }
    </style>
    </head>

    <body>
    <div id=”jqxgrid”></div>
    </body>
    </html>

    • This reply was modified 1 year, 6 months ago by  nostromo.
    in reply to: Name of the edited column Name of the edited column #102697

    nostromo
    Participant

    I found this and it works args.datafield

    It will be the right thing?

    updaterow: function (rowid, rowdata, commit) {

    console.log(args.datafield);

    commit(true);
    },

    in reply to: enabled / disabled Checkbox enabled / disabled Checkbox #97316

    nostromo
    Participant
    in reply to: column header text color column header text color #78217

    nostromo
    Participant

    Excelent!

    in reply to: column header text color column header text color #78059

    nostromo
    Participant

    this is my code:

    $(“#btnFiltrar”).on(‘click’, function () {
    $(‘#personal .jqx-grid-column-header:eq(0)’).css(‘color’, ‘#3F0’);
    });

    #personal is my grid

    $(“#personal”).jqxGrid(
    {
    width: 1100, //20 pixeles mas que la suma de las columnas
    height: 550,
    source: dataAdapter,
    theme: ‘shinyblack’,
    rowsheight: 20,
    localization: getLocalization(),
    columns: [
    { text: ‘Nombre’, datafield: ‘nombre’, width: 260, pinned: true },
    { text: ‘Rut’, datafield: ‘rut’, width: 100 },
    { text: ‘1’, datafield: ‘d1’, width: 1, align: ‘center’, cellclassname: colorFondo },
    { text: ‘2’, datafield: ‘d2’, width: 1, align: ‘center’, cellclassname: colorFondo },
    { text: ‘3’, datafield: ‘d3’, width: 1, align: ‘center’, cellclassname: colorFondo },
    { text: ’31’, datafield: ‘d31’, width: 1, align: ‘center’, cellclassname: colorFondo, hidden: oculta31 }
    ]
    });

    Pressing the button #btnFiltrar, should change the color of text in the header of the column, but does not function .

    with the sample code either, you could guide me I’m doing wrong?

    var firstNameCell = $(‘div .jqx-grid-column-header:eq(0)’);
    firstNameCell.css(‘background-color’, ‘rosybrown’);

    in reply to: current time current time #70503

    nostromo
    Participant

    already solved it , I had to add value: new Date()

    in reply to: current time current time #70502

    nostromo
    Participant

    ivailo, OK, so what I have, but the time is me 0:00,
    and I want you to give me the current time.

    example: 30-04-2015 00:00

    I need

    30-04-2015 and current time

Viewing 15 posts - 1 through 15 (of 17 total)