Forum
07:31
10/09/2009
Hi,
today I used the row editing feature for the first time and I noticed an weird behavior in combination with formatters. It doesn't matter whether I use the “currency” or “number” formatter. Before I edit the row I have the value “125,00″. After an click on the row I am able to edit the field, but the editable value is now “12500″. After that I press escape or click on another row and the new value is “12.500,00″. That's strange, isn't it? I use the latest grid version 3.5.3
This is my grid setup
var lastSel;
$GridTbl = $('#sykGridTbl');
$GridTbl.jqGrid({
height: 300,
width: 600,
url: 'index.php?pageId=5009&getList=true',
editurl: 'index.php?pageId=5014',
colNames: ['Description', 'Info', 'Costs', 'Sum'],
colModel: [{name:'description', editable: true},
{name:'info', editable: true, width: 110},
{name:'costs', editable: true, width: 80, align: 'right', formatter: 'currency'},
{name:'sum', editable: true, width: 130, align: 'right', formatter: 'currency'}],
onSelectRow: function (id) {
if(id && id!==lastSel){
$GridTbl.restoreRow(lastSel);
lastSel=id;
}
$GridTbl.editRow(id, true);
}
});
This is my grid.locale-de.js
defaultValue:”0,00 ”},date:{dayNames:["So","Mo","Di","Mi","Do","Fr","Sa","Sonntag","Montag","Dienstag","Mittwoch","Donnerstag",
"Freitag","Samstag"],monthNames:["Jan","Feb","Mar","Apr","Mai","Jun","Jul","Aug","Sep","Okt","Nov","Dez","Januar",
"Februar","März","April","Mai","Juni","Juli","August","September","Oktober","November",
"Dezember"],AmPm:["am","pm","AM","PM"],S:function(b){return b<11||b>13?["st","nd","rd","th"][Math.min((b-1)%10,3)]:”th”},srcformat:”d.m.Y”,newformat:”d.m.Y”,masks:{ISO8601Long:”d.m.Y H:i:s”,ISO8601Short:”d.m.Y”,ShortDate:”j.n.Y”,LongDate:”l, d. F Y”,FullDateTime:”l, d. F Y G:i:s”,MonthDay:”d. F”,ShortTime:”G:i”,LongTime:”G:i:s”,SortableDateTime:”Y-m-d\\\\TH:i:s”,UniversalSortableDateTime:”Y-m-d H:i:sO”,YearMonth:”F Y”},reformatAfterEdit:false},baseLinkUrl:”",showAction:”",target:”",checkbox:{disabled:true},idName:”id”}}})(jQuery);
09:50
Moderators
30/10/2007
Hello,
Thanks. It is bug. Will see why is this.
Regards
Tony
For professional UI suites for Java Script and PHP visit us at our commercial products site - guriddo.net - by the very same guys that created jqGrid.
10:00
Moderators
30/10/2007
Hello,
Found the cause. Will publish the fix after some tests in GitHub
Tony
For professional UI suites for Java Script and PHP visit us at our commercial products site - guriddo.net - by the very same guys that created jqGrid.
11:40
Moderators
30/10/2007
Hello,
The fix is in 3.6 branch in GitHub
Regards
Tony
For professional UI suites for Java Script and PHP visit us at our commercial products site - guriddo.net - by the very same guys that created jqGrid.
07:59
10/09/2009
Hi Tony,
I've installed the new version but the behavior is still the same
Edit: I forgot to tell that I used another option at grid setup => datatype: "json"
Maybe that's the bug?
For easier diagnostic I uploaded my whole testcode at http://ul.to/kxhhe3
02:58
Moderators
30/10/2007
Hello,
It seems that you download the code from master branch. Please select jqgrid36 branch and download. Have tested with code from 36 branch and all work OK.
Thanks
Regards
Tony
For professional UI suites for Java Script and PHP visit us at our commercial products site - guriddo.net - by the very same guys that created jqGrid.
Most Users Ever Online: 715
Currently Online:
61 Guest(s)
Currently Browsing this Page:
1 Guest(s)
Top Posters:
OlegK: 1255
markw65: 179
kobruleht: 144
phicarre: 132
YamilBracho: 124
Renso: 118
Member Stats:
Guest Posters: 447
Members: 11373
Moderators: 2
Admins: 1
Forum Stats:
Groups: 1
Forums: 8
Topics: 10592
Posts: 31289
Newest Members:
, razia, Prankie, psky, praveen neelam, greg.valainis@pa-tech.comModerators: tony: 7721, Rumen[Trirand]: 81
Administrators: admin: 66