enable own change state forms
This commit is contained in:
parent
037df7cb61
commit
693ffb7b63
3 changed files with 4 additions and 4 deletions
|
@ -299,7 +299,7 @@ class CreateObjectForm(ObjectForm):
|
||||||
def title(self):
|
def title(self):
|
||||||
if self.fixedType:
|
if self.fixedType:
|
||||||
#return _(u'Create %s') % self.typeConcept.title
|
#return _(u'Create %s') % self.typeConcept.title
|
||||||
return _(u'Create $type',
|
return _(u'Create $type',
|
||||||
mapping=dict(type=self.typeConcept.title))
|
mapping=dict(type=self.typeConcept.title))
|
||||||
else:
|
else:
|
||||||
return _(self.defaultTitle)
|
return _(self.defaultTitle)
|
||||||
|
@ -749,7 +749,7 @@ class EditConcept(EditObject):
|
||||||
if sibRelations:
|
if sibRelations:
|
||||||
maxOrder = max([r.order for r in sibRelations])
|
maxOrder = max([r.order for r in sibRelations])
|
||||||
if maxOrder > 0:
|
if maxOrder > 0:
|
||||||
return obj.assignParent(concept, predicate,
|
return obj.assignParent(concept, predicate,
|
||||||
order=maxOrder+1)
|
order=maxOrder+1)
|
||||||
obj.assignParent(concept, predicate)
|
obj.assignParent(concept, predicate)
|
||||||
|
|
||||||
|
|
|
@ -50,7 +50,7 @@ statefulActions = ('classification_quality',
|
||||||
def registerStatesPortlet(controller, view, statesDefs,
|
def registerStatesPortlet(controller, view, statesDefs,
|
||||||
region='portlet_right', priority=98):
|
region='portlet_right', priority=98):
|
||||||
cm = controller.macros
|
cm = controller.macros
|
||||||
stfs = [component.getAdapter(view.context, IStateful, name=std)
|
stfs = [component.getAdapter(view.context, IStateful, name=std)
|
||||||
for std in statesDefs]
|
for std in statesDefs]
|
||||||
cm.register(region, 'states', title=_(u'Workflow'),
|
cm.register(region, 'states', title=_(u'Workflow'),
|
||||||
subMacro=template.macros['portlet_states'],
|
subMacro=template.macros['portlet_states'],
|
||||||
|
|
|
@ -89,7 +89,7 @@
|
||||||
<li tal:repeat="action stf/getAvailableTransitionsForUser">
|
<li tal:repeat="action stf/getAvailableTransitionsForUser">
|
||||||
<a i18n:translate=""
|
<a i18n:translate=""
|
||||||
tal:define="baseUrl view/virtualTargetUrl;
|
tal:define="baseUrl view/virtualTargetUrl;
|
||||||
url string:$baseUrl/change_state.html?action=${action/name}&stdef=${stf/statesDefinition}"
|
url string:$baseUrl/${stf/formUrl|string:change_state.html}?action=${action/name}&stdef=${stf/statesDefinition}"
|
||||||
tal:attributes="href url;
|
tal:attributes="href url;
|
||||||
onClick string:objectDialog('change_state', '$url');;
|
onClick string:objectDialog('change_state', '$url');;
|
||||||
return false;"
|
return false;"
|
||||||
|
|
Loading…
Add table
Reference in a new issue