equal
deleted
inserted
replaced
50 """ |
50 """ |
51 #: db.Model subclass for which the form will gather information |
51 #: db.Model subclass for which the form will gather information |
52 model = soc.models.site_settings.SiteSettings |
52 model = soc.models.site_settings.SiteSettings |
53 |
53 |
54 #: list of model fields which will *not* be gathered by the form |
54 #: list of model fields which will *not* be gathered by the form |
55 exclude = ['inheritance_line', 'home'] |
55 exclude = ['inheritance_line', 'home', 'partial_path', 'link_name'] |
|
56 |
|
57 partial_path = forms.CharField(widget=forms.HiddenInput) |
|
58 |
|
59 link_name = forms.CharField(widget=forms.HiddenInput) |
56 |
60 |
57 |
61 |
58 class EditForm(CreateForm): |
62 class EditForm(CreateForm): |
59 """Django form displayed a Document is edited. |
63 """Django form displayed a Document is edited. |
60 """ |
64 """ |
128 |
132 |
129 keys = self._logic.getKeyFieldNames() |
133 keys = self._logic.getKeyFieldNames() |
130 values = self._logic.getMainKeyValues() |
134 values = self._logic.getMainKeyValues() |
131 key_values = dicts.zip(keys, values) |
135 key_values = dicts.zip(keys, values) |
132 |
136 |
133 return self.edit(request, page_name, **key_values) |
137 return self.edit(request, page_name, seed=key_values, **key_values) |
134 |
138 |
135 |
139 |
136 view = View() |
140 view = View() |
137 |
141 |
138 create = view.create |
142 create = view.create |