Welcome Guest, Not a member yet? Register   Sign In
Flexigrid - Lightweight but rich data grid

[eluser]paulopmx[/eluser]
@swhitlow, @ozskry

Please use firebug to see what the server is actually saying to flexigrid, usually this is where the mistake is coming from. or if you want give me an online url to test it myself.

@EvilBMP

Right now no. Next release yes.

Paulo

[eluser]Unknown[/eluser]
Hello from Luxembourg,

I need some help with the implementation of flexigrid.

I encontered some problems and can't find suitable solutions.

1 - Some columns won't sort ( processing occurs but never ends )

2 - Setting "sortable : false" seems to have no effect at all ( columns stays sortable )

3 - Quick search don't produce any results ( process occurs but grid show all the records, even one which doesn't match )

I'm not familiar with jQuery, Can someone help me? Thank you.

P.S. : Sorry for my poor english :-(

Code:
$("#Frame").flexigrid
            ({
                        url: 'php/ListeBiens.php',
                        dataType: 'xml',
                    colModel : [
                    {display: 'Ref.', name : 'reference', width : 100, sortable : true, align: 'center'},
                    {display: 'Act.', name : 'actif', width : 20, sortable : false, align: 'center'},
                    {display: 'Phts.', name : 'photos', width : 30, sortable : false, align: 'center'},
                    {display: 'Opération', name : 'operation', width : 65, sortable : false, align: 'center'},
                    {display: 'Type', name : 'type', width : 90, sortable : false, align: 'center'},
                    {display: 'Prix', name : 'numcode', width : 100, sortable : false, align: 'center'},
                    {display: 'Chbrs.', name : 'chambres', width : 40, sortable : false, align: 'center'},
                    {display: 'Surface', name : 'surface', width : 80, sortable : false, align: 'center'},
                    {display: 'Pays', name : 'pays', width : 90, sortable : false, align: 'center'},
                    {display: 'Commune', name : 'commune', width : 180, sortable : false, align: 'center'},
                    {display: 'No.', name : 'numero', width : 20, sortable : false, align: 'center'},
                    {display: 'Rue', name : 'rue', width : 120, sortable : false, align: 'center'}
                    ],
                        buttons : [
                            {name: 'Ajouter', bclass: 'add', onpress : ajoutBien},
                            {separator: true},
                            {name: 'Effacer', bclass: 'delete', onpress : test},
                            {separator: true},
                    {name: 'Modifier', bclass: 'edit', onpress : test},
                            {separator: true},
                    {name: 'Activer/Desactiver', bclass: 'activate', onpress : test},
                            {separator: true}
                            ],
                        searchitems : [
                            {display: 'Ref', name : 'reference', isdefault: true},
                    {display: 'Act.', name : 'actif'},
                    {display: 'Phts.', name : 'photos'},
                    {display: 'Opération', name : 'operation'},
                    {display: 'Type', name : 'type'},
                    {display: 'Prix', name : 'numcode'},
                    {display: 'Chbrs.', name : 'chambres'},
                    {display: 'Surface', name : 'surface'},
                    {display: 'Pays', name : 'pays'},
                    {display: 'Commune', name : 'commune'},
                    {display: 'No.', name : 'numero'},
                    {display: 'Rue', name : 'rue'}
                            ],
                        sortname: "reference",
                        sortorder: "asc",
                        usepager: true,
                        title: 'Liste des biens',
                        useRp: false,
                        rp: 15,
                        showTableToggleBtn: false,
                    resizable: false,
                pagestat: 'Affichage des biens de {from} a {to} sur {total} biens',
                 procmsg: 'Chargement en cours ...',
                nomsg: 'Aucun bien disponnible.',
                        height: 401,
                showToggleBtn: false
                    });

[eluser]ozskry[/eluser]
@ Lab Assistant

As I don't know how to use Firebug, here is an online url:

http://flexigrid.cary.be/

Cheers,
Cary

[eluser]Holla die Waldfee[/eluser]
Hi,

Cary, ur json.php just returns a "test"!

Holla

[eluser]ozskry[/eluser]
I don't understand. Personally, if I go to http://flexigrid.cary.be/json.php I receive this:

Quote:{
page: 1,
total: 623,
rows: [
{id:'651',cell:['651','settings_work_006','settings','Vectorized','Available','9Pk10w8D1emzPIL']},
{id:'650',cell:['650','settings_work_005','settings','Vectorized','Available','ZGqfv50wRsiw44S']},
{id:'649',cell:['649','settings_work_004','settings','Vectorized','Available','fHNuGg2JO4rSOu']},
{id:'648',cell:['648','settings_work_003','settings','Vectorized','Available','xbRoHaKRV7HavVO']},
{id:'647',cell:['647','settings_work_002','settings','Vectorized','Available','ipZp9tUDZXTS9mr']},
{id:'646',cell:['646','settings_work_001','settings','Vectorized','Available','CPtUYaMXMm8IGf4']},
{id:'645',cell:['645','settings_winter_013','settings','Vectorized','Available','4uLHgYj4FiVXSau']},
{id:'644',cell:['644','settings_winter_012','settings','Vectorized','Available','02nBkstgJ621bd']},
{id:'466',cell:['466','settings_winter_011','settings','Vectorized','Available','IvY02RkyX2pDbdB']},
{id:'319',cell:['319','settings_winter_010','settings','Vectorized','Available','t66coq3CvMS5VZD']}]
}

Cheers,
Cary

[eluser]Holla die Waldfee[/eluser]
hmmmmmmm... Strange. I do attache u a screenshot. It is made from the "firebug"-Debugview. Firebug is cool, it runs as an extension for firefox.
In the shown view, u have can see the transfered response from the PHP-File. When I do call the file directly, I get the right json-structure like u.
I would advice u to write a new, very simple PHP File (with a different filename ;-) ). The new file should just echo the json data.

Sorry for my bad (germanized) english ;-)


hope that helps

Holla

[eluser]ozskry[/eluser]
Ok. Problem solved. Thanks to your help and Firebug.

Cheers,
Cary

[eluser]Holla die Waldfee[/eluser]
Paulo,

is there a good and easy way to do two things:

1. make the grid single-selectable (just one row)
2. react on a click on a row

I know the sources (not well, but I can understand whats going on). And I have an idea how to do it. But I am afraid I will be cut of from any updates u will release in the future, when I patch the "hardcore-way"

Holla

[eluser]Holla die Waldfee[/eluser]
[quote author="ozskry" date="1211311998"]Ok. Problem solved. Thanks to your help and Firebug.

Cheers,
Cary[/quote]

nice :-)
Please write us ur solution, so anyone with the same problem will find its way...

Holla

[eluser]ozskry[/eluser]
[quote author="Holla die Waldfee" date="1211312403"]
Please write us ur solution, so anyone with the same problem will find its way...
[/quote]

An error in the javascript. I had [sortname: 'id'] in place of [sortname: 'id_ms_smurfs']. So, when I was accessing the json.php, the PHP script was working. But, inside the javascript, due to the wrong sortname, I had a query error. That's the reason you received "test".

Cheers,
Cary




Theme © iAndrew 2016 - Forum software by © MyBB