Project

General

Profile

Revision 7bde24ad

ID7bde24ad0efba8190771833f96cf5524e54969fd
Parent cea946f5
Child b82c4c03

Added by Francois POIROTTE over 8 years ago

[#1457] Rafraichissement AJAX dans VigiBoard

Change le mécanisme de rafraichissement du tableau de VigiBoard pour
utiliser de l'AJAX.
Réutilise le fichier "loader.js" pour obtenir un sablier lors du
chargement (et donc suppression des copies dans VigiMap/VigiGraph).
Le script "loader.js" est enrichi pour pouvoir ajouter la notion d'un
calque qui est rendu semi-opaque lors de l'exécution de la requête.

Change-Id: Idc537cd8b4f257af9fcd6ac8c6334deadd9d042a
Refs: #1457.
Reviewed-on: https://vigilo-dev.si.c-s.fr/review/1898
Tested-by: Build system <>
Reviewed-by: Francois POIROTTE <>

View differences:

vigiboard/tests/functional/test_search_form_misc.py
93 93
                'to_date': to_date,
94 94
            },
95 95
            extra_environ={'REMOTE_USER': 'user'})
96
        rows = response.lxml.xpath('//table[@class="vigitable"]/tbody/tr')
96
        rows = self.get_rows(response)
97 97
        print "There are %d rows in the result set" % len(rows)
98 98
        return len(rows)
99 99

  
......
108 108
            extra_environ={'REMOTE_USER': 'user'})
109 109

  
110 110
        # Il doit y avoir 1 seule ligne de résultats.
111
        rows = response.lxml.xpath('//table[@class="vigitable"]/tbody/tr')
111
        rows = self.get_rows(response)
112 112
        print "There are %d rows in the result set" % len(rows)
113 113
        assert_equal(len(rows), 1)
114 114

  
115 115
        # Il doit y avoir plusieurs colonnes dans la ligne de résultats.
116
        cols = response.lxml.xpath('//table[@class="vigitable"]/tbody/tr/td')
116
        cols = self.get_cells(response)
117 117
        print "There are %d columns in the result set" % len(cols)
118 118
        assert_true(len(cols) > 1)
119 119

  
......
129 129
        transaction.commit()
130 130

  
131 131
        # Il doit y avoir 1 seule ligne de résultats.
132
        rows = response.lxml.xpath('//table[@class="vigitable"]/tbody/tr')
132
        rows = self.get_rows(response)
133 133
        print "There are %d rows in the result set" % len(rows)
134 134
        assert_equal(len(rows), 1)
135 135

  
136 136
        # Il doit y avoir plusieurs colonnes dans la ligne de résultats.
137
        cols = response.lxml.xpath('//table[@class="vigitable"]/tbody/tr/td')
137
        cols = self.get_cells(response)
138 138
        print "There are %d columns in the result set" % len(cols)
139 139
        assert_true(len(cols) > 1)
140 140

  
......
157 157
            extra_environ={'REMOTE_USER': 'user'})
158 158

  
159 159
        # Il doit y avoir 1 seule ligne de résultats.
160
        rows = response.lxml.xpath('//table[@class="vigitable"]/tbody/tr')
160
        rows = self.get_rows(response)
161 161
        print "There are %d rows in the result set" % len(rows)
162 162
        assert_equal(len(rows), 1)
163 163

  
164 164
        # Il doit y avoir plusieurs colonnes dans la ligne de résultats.
165
        cols = response.lxml.xpath('//table[@class="vigitable"]/tbody/tr/td')
165
        cols = self.get_cells(response)
166 166
        print "There are %d columns in the result set" % len(cols)
167 167
        assert_true(len(cols) > 1)
168 168

  

Also available in: Unified diff