722 edition view's combobox. |
722 edition view's combobox. |
723 |
723 |
724 If `eid` is None in one of these couples, it should be |
724 If `eid` is None in one of these couples, it should be |
725 interpreted as a separator in case vocabulary results are grouped |
725 interpreted as a separator in case vocabulary results are grouped |
726 """ |
726 """ |
727 from cubicweb.web.form import EntityFieldsForm |
|
728 from logilab.common.testlib import mock_object |
727 from logilab.common.testlib import mock_object |
729 form = EntityFieldsForm(self.req, entity=self) |
728 form = self.vreg.select_object('forms', 'edition', self.req, entity=self) |
730 field = mock_object(name=rtype, role=role) |
729 field = mock_object(name=rtype, role=role) |
731 return form.form_field_vocabulary(field, limit) |
730 return form.form_field_vocabulary(field, limit) |
732 |
731 |
733 def unrelated_rql(self, rtype, targettype, role, ordermethod=None, |
732 def unrelated_rql(self, rtype, targettype, role, ordermethod=None, |
734 vocabconstraints=True): |
733 vocabconstraints=True): |