문제

I'm using the following code to fill one of the cells of a new row with a default value, but this is not working (the cell is empty). Is this code ok?

var parameters =
                {
                    rowID: "new_row",
                    initdata: {
                        IdField: $('#IdField').val(),
                        Description: $('#IdField option:selected').text()
                    },
                    position: "first",
                    useDefValues: false,
                    useFormatter: false,
                    addRowParams: { extraparam: {} }
                };

            $("#containerGrid").jqGrid('addRow', rowid, parameters);
도움이 되었습니까?

해결책

Problem solved by removing the rowid parameter from the addRow method.

$("#containerGrid").jqGrid('addRow', parameters);
라이센스 : CC-BY-SA ~와 함께 속성
제휴하지 않습니다 StackOverflow
scroll top