jQWidgets Forums
Forum Replies Created
-
Author
-
understood. thank you dimitar
hi dimitar
why you use this “!” in here
return !($(“#input1”).val().length > 0 && input.val().length == 0);
what the purpose of using it?
hi
i have a prob here. i have four fields:
agreement no:<input> agreement date:<input>
purchase order no:<input> purchase order date:<input>now i have problem to validate this fields.
user must insert either agreement no or purchase order no.(optional) if any of this field is filled, the date also must be filled in.
for example if user insert agreement no, the agreement data also must be insert.
can anyone help me on how to do this validation.. thank you
thank dimitar..
April 10, 2014 at 3:06 am in reply to: calculate sum of column values in jqgrid calculate sum of column values in jqgrid #52827hi dimitar
seems we cannot maintain both (aggerates & status bar) in a grid, is there a way where i can get the sum and display it on a textbox?
April 9, 2014 at 9:38 am in reply to: calculate sum of column values in jqgrid calculate sum of column values in jqgrid #52777thanks dimitar. i managed to do it.
once i did the aggerates function, my status bar in the grid gone missing.
is there a way to maintain both(aggerates & status bar) in a grid?
hi peter
var value = $(“#grid”).jqxGrid(‘getcellvalue’, 1, ‘firstname’);
it works. but i dont want to specified the value ‘1’. i want it automatically get selected cell value without specifying. is it possible?
hi peter
thanks you. it works.
how if i want to get a datafield value on a selected row. i have tried but its on giving index of d row.
var clnt = $('#customersGrid').jqxGrid('getselectedrowindexes', "ClientCode");
ClientCode is the datafield.
hi peter
it works. thanks for your help.
i would like to ask you one more thing. is there a way to refresh the grid after new row is added??
thanks peter. its working now.
i changed both null value to ().
var commit = $(“#jqxgrid”).jqxGrid(‘addrow’, {}, {});
hi peter
i tried, but still not working.
// create new row. $("#addrowbutton").on('click', function () { //var datarow = generaterow(); var commit = $("#jqxgrid").jqxGrid('addrow', {}, null); });
hi peter,
i am using the latest jQwidgets 2.8.3, yet the autorowheight is still not working. here is my sample code.
$(document).ready(function () {
var theme = ‘ui-redmond’;var key = $(‘#key’).attr(‘value’);
var initView = function () {
$.getJSON(“include/display_issue.php?id=”+key, function(data) {
$(‘#jqxView’).html(data);
});
}var initGrid = function () {
var source =
{
datatype: “json”,
datafields: [
{ name: ‘engineer’, type: ‘string’ },
{ name: ‘action’, type: ‘string’ },
{ name: ‘mode’, type: ‘string’ },
{ name: ‘date’, type: ‘date’ },
],
root: “data”,
url: ‘include/view_chrono.php?id=’+key,
sortcolumn: ‘date’,
sortdirection: ‘asc’
};
var dataAdapter = new $.jqx.dataAdapter(source, { async: false, loadError: function (xhr, status, error) { alert(‘Error loading “‘ + source.url + ‘” : ‘ + error); } });
$(“#jqxGrid”).jqxGrid(
{
width: ‘100%’,
height: ‘100%’,
source: dataAdapter,
theme: theme,
autorowheight: true,
autoheight: true,
sortable: true,
filterable: true,
altrows: true,
columns: [
{ text: ‘Engineer’, datafield: ‘engineer’, width: 90 },
{ text: ‘Action’, datafield: ‘action’},
{ text: ‘Mode’, datafield: ‘mode’, width: 150 },
{ text: ‘Date’, datafield: ‘date’, cellsformat: ‘dd-MM-yyyy’, width: 110 },
]
});
}// init widgets.
var initWidgets = function (tab) {
switch (tab) {
case 0:
initView();
break;
case 1:
initGrid();
break;
}
}
$(‘#jqxTabs’).jqxTabs({ width: 900, height: ‘auto’, theme: theme, initTabContent: initWidgets });
});dear Peter,
i already tried that but its still not working.
hii Dimitar,
i already tried many ways but looks none is working.
can you assist me on how to export the grid to a varible??
Hi Dimitar,
i still dont get you. how the save-file.php should be. any example of it.
-
AuthorPosts