JQGRID Frozen Columns - Duplicating information

Asked

Viewed 278 times

3

I am using the Frozen column option, as it is in the documentation, as follows:

 jQuery(grid_selector).jqGrid({
       url:urllst,
       datatype: 'json',
       height: 'auto',
       width: 'auto',
       ignoreCase: true,
            colNames:['UF','Macro região','Região','Cód.Municipio','Nome','População','Cód.Status','Cód.Perfil','Partido Prefeito','Partido Vice','Ativo ?' ],   // PONTO DE ALTERAÇÃO
            colModel:[ // PONTO DE ALTERAÇÃO
                {name:"uf",index:"uf", width:100, sorttype:'text', viewable: true, frozen: true,
                    stype:'text',
                    formoptions:{elmprefix:'*', label: 'UF:', rowpos:1, colpos:1},
                    editable:true,
                    editrules: {required: true},
                    edittype: 'custom',
                    classes: 'c',
                    editoptions: {style: "text-transform: uppercase",
                        'custom_element' : macro_uf_element,
                        'custom_value'   : macro_uf_value,
                    },
                    searchoptions: {
                        sopt:['eq','ne','lt','le','gt','ge','bw','in','ni','ew','en','cn','nc']
                    }
                },

and right after:

rowNum:11,
rowList:[10,20,30],
caption: "Frozen Header",
shrinkToFit: false,
jQuery(#TABELA).jqGrid('setFrozenColumns'); 

"Freeze" works, but the data gets duplicated, one over the other in the scroll, then set background with css, works but in this case Hover and Selection do not work in the frozen columns.

Photo: inserir a descrição da imagem aqui

  • you’ve already solved?

  • Actually no, I tried several things, I defined color by css, by the js itself, in this case the problem of transparency is solved, as I asked the question, the problem that the standard jqgrid selection and default Hover do not work in the columns with Frozen. I tried to create class for the 4 columns and the css call works when the mouse is on them but when I leave these 4 columns for again, I missed the day on this.

  • I am saying regarding this question ta duplicating? (I have already seen your other question ai try to solve at another time or another op) keeps repeating, has how to edit and put an image in your question, which language serves-side you use?

  • I’m going to take a print, yes on the one that is duplicating, so I’m using jqgrid, so javascript and jquery what I realized is that when I put the option frozem what it does is a kind of copy and put overlay the column so that the table is transparent so the information appears, when I set the color this problem disappears, I will put the prints.

  • Guys I’m still having this problem, someone knows how to help?

  • Sorry @Rafaeltheodoro did not visualize error on the screen, have to mark it, because by the jqgrid you did correct the Frozen, the same way I use, but I do the following, the Frozen column are always the first

  • @cavalsilva, I put the opation of Frozen in the first 4 columns, look at how the writings look on it, and as if it had "written" twice, and really it is, in the second photo I scroll and can observe that everything is duplicated, in the second line MARCRO | REGIAO has as record QQ, note that appears four times. That’s when I realized that Frozen makes a kind of copy of the data and jqgrid is in a transparent pattern. And when I set color the "Hover" and "select" options do not work in the "color" columns".

  • Also displays the JSON or XML output. Obg.

  • @cavalsilva hãn??

  • how do you return the result? How do you populate the grid? I call the database that returns me a JSON that fills the grid. This is what I’d like to see.

  • I do it the same way, BD and JSON

  • I get it, but put in the colmodel you set up and the json of the result to see if I can see something.

Show 7 more comments
No answers

Browser other questions tagged

You are not signed in. Login or sign up in order to post.