jQWidgets Forums

Forum Replies Created

Viewing 8 posts - 1 through 8 (of 8 total)
  • Author
    Posts
  • in reply to: Setting Combobox Value Setting Combobox Value #80786

    4xjbh
    Participant

    Yes there was combobox data with the binding. But you were correct, the lack of the attribute–value pair labels was the problem.

    in reply to: Form Model Binding Form Model Binding #80744

    4xjbh
    Participant

    Can you recommend a good practice for populating form fields after retrieving the data with the adapter if you have a lot of inputs, checkboxes etc (Single record)

    Doing the following doesn’t look right…. would using an array and looping thing through inputs, checkboxes, etc be the best way?

    $(“#first”).jqxInput().val(record[‘first’]);
    $(“#last”).jqxInput().val(record[‘last’]);
    $(“#employee”).jqxCheckBox().val(record[‘is_employee’]);
    $(“#locked”).jqxCheckBox().val(record[‘locked’]);
    $(“#is_client”).jqxCheckBox().val(record[‘is_client’]);
    ……
    …… many more inputs


    4xjbh
    Participant

    Peter,

    Thanks for the response. I thought I had done this correctly so I have started from scratch. A single html file with no external css apart from jqw and bootstrap. I am getting the same result and with no errors in the console…

    https://docs.google.com/uc?id=0B28B-lQBlEIAbFRtVElkcmxxVnc&export=download

    
    <!doctype html>
    
    <html lang="en">
    <head>
        <meta charset="utf-8">
        <meta name="viewport" content="width=device-width, initial-scale=1.0">
    
        <title>JQWidgets</title>
    
        <link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.6/css/bootstrap.min.css"
              integrity="sha384-1q8mTJOASx8j1Au+a5WDVnPi2lkFfwwEAa8hDDdjZlpLegxhjVME1fgjWPGmkzs7"
              crossorigin="anonymous">
        <link rel="stylesheet" href="../../jqwidgets/styles/jqx.base.css">
        <link rel="stylesheet" href="../../jqwidgets/styles/jqx.bootstrap.css">
    
        <script src="//code.jquery.com/jquery-2.1.3.min.js"></script>
        <script src="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.6/js/bootstrap.min.js"
                integrity="sha384-0mSbJDEHialfmuBBQP6A4Qrprq5OVfW37PRR3j5ELqxss1yVqOtnepnHVP9aJ7xS"
                crossorigin="anonymous"></script>
        <script type="text/javascript" src="../../jqwidgets/jqxcore.js"></script>
        <script type="text/javascript" src="../../jqwidgets/jqxdata.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/jqxlistbox.js"></script>
        <script type="text/javascript" src="../../jqwidgets/jqxcombobox.js"></script>
    </head>
    <body>
    <div class="container" style="padding-top: 20px">
    
        <div class = 'form-group col-md-8' >
            <label for="jqxcombobox">Combobox:</label>
            <div id="jqxcombobox" class="form-control"></div>
        </div>
    
    </div>
    
    <script>
        $(document).ready(function () {
    
            /* Start of Combobox */
            var source = [
                "Affogato",
                "Americano",
                "Bicerin",
                "Breve",
                "Café Bombón",
                "Café au lait",
                "Caffé Corretto",
                "Café Crema",
                "Caffé Latte",
            ];
            // Create a jqxComboBox
            $("#jqxcombobox").jqxComboBox({ source: source });
            // disable the sixth item.
            $("#jqxcombobox").jqxComboBox('disableAt', 5);
        });
    </script>
    </body>
    </html>
    
    in reply to: Remote Data Bind Noob Remote Data Bind Noob #80272

    4xjbh
    Participant

    Should be “datatype: “json”


    4xjbh
    Participant

    Thanks, I have sent info through to the support email address.


    4xjbh
    Participant

    I am loading jqx-all.js and all combos are divs and text fields are inputs. A blank fom no errors are reported when selecting inputs, once data populates form and grid from json data the error occurs.

    in reply to: Combobox Validation Combobox Validation #30525

    4xjbh
    Participant

    Thanks Peter.

    Selecting an item in the list validates ok. The alert I have included here displays a length of 3 which is correct but if I clear the input and validate again the length is still 3 and no validation alert tags are displayed.

    { input: “#company_id”, message: “Client is required.”, action: “blur”,
    rule: function (input, comkmit) {
    var value = $(“#company_id”).val();
    // alert(value.length);
    if (value.length > 0 ) { return true; } else {return false;}
    }
    },
    { input: “#email”, message: “Invalid e-mail!”, action: “keyup”, rule: “email” }] });

    This may help. http://youtu.be/e2sehrzsDqM

    in reply to: Combobox Validation Combobox Validation #30385

    4xjbh
    Participant

    rule is actually

    { input: “#company_id”, message: “Company is required.”, action: “keyup,blur”, rule: “required” }

Viewing 8 posts - 1 through 8 (of 8 total)