Project

General

Profile

Bug #8906

plantage à l'affichage d'un formdef dans la fabrique, si sa catégorie a été supprimée

Added by Frédéric Péters over 9 years ago. Updated over 9 years ago.

Status:
Fermé
Priority:
Normal
Target version:
Start date:
07 November 2015
Due date:
% Done:

0%

Estimated time:
Patch proposed:
Yes
Planning:

Description

Exception:
  type = '<type 'exceptions.AttributeError'>', value = ''NoneType' object has no attribute 'name''

Stack trace (most recent call first):
  File "/home/fred/src/eo/wcs/wcs/admin/forms.py", line 369, in _q_index
   367         r += add_option_line('options/category', _('Category'),
   368                 self.formdef.category_id and
>  369                 self.formdef.category.name or C_('category|None'))
   370         r += htmltext('</ul>')
   371         r += htmltext('</div>')

Files

Associated revisions

Revision 115d8d1a (diff)
Added by Frédéric Péters over 9 years ago

misc: protect against removed category (#8906)

History

#1

Updated by Frédéric Péters over 9 years ago

#2

Updated by Thomas Noël over 9 years ago

Ack

En parallèle, est-ce qu'on ferait en sorte qu'une suppression de catégorie vide les formdef.category_id ?

#3

Updated by Frédéric Péters over 9 years ago

  • Status changed from En cours to Résolu (à déployer)
commit 115d8d1aba4c33989949e20117812360e438ebec
Author: Frédéric Péters <fpeters@entrouvert.com>
Date:   Sat Nov 7 14:17:48 2015 +0100

    misc: protect against removed category (#8906)
#4

Updated by Frédéric Péters over 9 years ago

J'avais zappé ce commentaire :

En parallèle, est-ce qu'on ferait en sorte qu'une suppression de catégorie vide les formdef.category_id ?

Et en fait, c'est déjà le cas. (sauf quand on vient jouer via le filesystem, bien sûr)

#5

Updated by Frédéric Péters over 9 years ago

  • Status changed from Résolu (à déployer) to Fermé
  • Target version set to v1.22

Also available in: Atom PDF