How to do it...

Follow the steps below to add a custom quick create form for kanban.

  1. Create a new minimal form view for the library.book.rent model, as follows:
<record id="library_book_rent_view_form_minimal" model="ir.ui.view">
<field name="name">Library Rent Form</field>
<field name="model">library.book.rent</field>
<field name="arch" type="xml">
<form>
<group>
<field name="book_id" domain="[('state', '=', 'available')]"/>
<field name="borrower_id"/>
</group>
</form>
</field>
</record>
  1. Add quick create options on the <kanban> tag, as follows:
<kanban default_group_by="stage_id" 
quick_create_view="my_library.library_book_rent_view_form_minimal"
on_create="quick_create">

Restart the server and update the module to apply the changes. Then, click on the plus icon in the column. This will enable kanban forms, as shown in the following image:

..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset