EasyUI Forum
September 16, 2025, 01:22:59 PM *
Welcome, Guest. Please login or register.

Login with username, password and session length
News:
 
  Home Help Search Login Register  
  Show Posts
Pages: [1]
1  General Category / EasyUI for jQuery / ComboGrid select value and Ajax call on: April 09, 2013, 12:33:24 AM
I have a drop down field and when I select a value from drop down, an ajax call is made to submit the form

Code:
<script type="text/javascript">  
$(function(){
$('#comb').combogrid({ 
    panelWidth:500,   
    url: 'myservice', 
    idField:'id', 
    textField:'desc' 
    columns: [[ 
                {field:'Id',title:'Id',width:20}, 
                {field:'desc',title:'Desc',width:80}
            ]],
    onSelect: function(index, row) {
   $.ajax({
                url: 'myjsp.jsp',
                method: 'GET',
                data: {
            val: row.dummy
            },
           success: function(response) {

        }
    });
}
});
}); 

</script>

The problem is when I try to receive the value using request.getParameter value is null even though val is correctly passed as I can see header information like

Code:
out.println("value  "+request.getParameter("val"));%>
Why request.getParameter is null when ajax call is made?
2  General Category / EasyUI for jQuery / Re: Change default date format in datagrid on: April 05, 2013, 10:47:39 AM
Getting error

SyntaxError: missing : after property id
[Break On This Error]    

Code:
...Date', width:40, sortable:false, editor:'text', formatter="formatProductDate"}
3  General Category / EasyUI for jQuery / Re: Change default date format in datagrid on: April 05, 2013, 10:00:32 AM
Quote
<th data-options="field:'fn',formatter:formatDate" width="80">Date</th>

<script>
function formatDate(value,row){
  var d = new Date(value);
  return $.fn.datebox.defaults.formatter(d);
}
</script>

I have date field defined as

Code:
{field:'productDate',title:'Date', width:40, sortable:false, editor:'text'},

so how can use formatter?
4  General Category / EasyUI for jQuery / Change default date format in datagrid on: April 04, 2013, 11:22:01 AM
Hello

I have been looking to change the default date format of dates which appears in datagrid as
Code:
Apr 2, 2013
.

I would like to change the format to e.g.
Code:
mm/dd/yyyy
rather than changing in database.

Thanks
5  General Category / EasyUI for jQuery / Re: Jquery EasyUI combogrid selected value on: April 04, 2013, 10:24:43 AM
Thanks, this has solved my problem.

I have another question, is is possible to bring results when minimum characters are typed, e.g. if 4 characters are typed then bring out the results rather than for each key stroke.

Regards
6  General Category / EasyUI for jQuery / Re: Pass multiple parameters to Controller class while removing records on: April 04, 2013, 07:46:16 AM
Thanks stworthy, this helped.
7  General Category / EasyUI for jQuery / Pass multiple parameters to Controller class while removing records on: April 04, 2013, 05:58:29 AM
Hello

How can I pass multiple parameters while removing records from datagrid?

This is the code I have taken from example
Code:
$.post('controller?flag=remove',{id:row.id},function(result){

My columns which are defined in html tables are prjId and prjDate which I would like to pass to my controller.

How can I do this?

P.S. When I looking Firebug console I could see only remove being passed as parameter.

Thanks
8  General Category / EasyUI for jQuery / Jquery EasyUI combogrid selected value on: April 04, 2013, 04:30:43 AM
I have the following Combogrid for autocomplete drop down

Code:
$('#product').combogrid({  
    panelWidth:500, 
    url: 'myservice', 
    idField:'prodId', 
    textField:'desc', 
    mode:'remote', 
    fitColumns:true, 
    columns: [[ 
                {field:'prodId',title:'Product No',width:10}, 
                {field:'desc',title:'Desc',width:75}
            ]]
});
When user selects a value from drop down, I would like to set the description of the selected product to another input field.

How can I do this?
Pages: [1]
Powered by MySQL Powered by PHP Powered by SMF 1.1.18 | SMF © 2013, Simple Machines Valid XHTML 1.0! Valid CSS!