correction aux Multi en read-only

This commit is contained in:
fpeters 2004-04-10 23:22:25 +00:00
parent fda74ca65b
commit 147615d544
1 changed files with 2 additions and 6 deletions

View File

@ -932,12 +932,8 @@ class Multi(WidgetMixin, proxyWidgets.Multi):
def getModelHiddenLayout(self, slot, fields, children = 1):
countName = slot.getFieldOptionName('count')
count = slot.getKind().getMinCount(slot)
try:
count = max(count, int(slot.getFieldOption(
fields, 'count', default = '0')))
except ValueError:
pass
kind = slot.getKind()
count = kind.getItemsCount(slot, fields)
layout = X.array()
if count:
layout += X.input(name = countName, type = 'hidden', value = count)