500 # display one explicit inline-creation view |
500 # display one explicit inline-creation view |
501 if form.should_display_inline_creation_form(rschema, existant, card): |
501 if form.should_display_inline_creation_form(rschema, existant, card): |
502 w(form.view('inline-creation', None, etype=targettype, |
502 w(form.view('inline-creation', None, etype=targettype, |
503 peid=entity.eid, ptype=entity.e_schema, |
503 peid=entity.eid, ptype=entity.e_schema, |
504 rtype=rschema, role=role)) |
504 rtype=rschema, role=role)) |
|
505 existant = True |
505 # we can create more than one related entity, we thus display a link |
506 # we can create more than one related entity, we thus display a link |
506 # to add new related entities |
507 # to add new related entities |
507 if form.should_display_add_new_relation_link(rschema, existant, card): |
508 if form.should_display_add_new_relation_link(rschema, existant, card): |
508 divid = "addNew%s%s%s:%s" % (targettype, rschema, role, entity.eid) |
509 divid = "addNew%s%s%s:%s" % (targettype, rschema, role, entity.eid) |
509 w(u'<div class="inlinedform" id="%s" cubicweb:limit="true">' |
510 w(u'<div class="inlinedform" id="%s" cubicweb:limit="true">' |