Browse Source

[ADD] emc: Filter for share type, cooperator and loan

pull/35/head
Rémy Taymans 5 years ago
parent
commit
a09c8b044e
  1. 2
      easy_my_coop/views/cooperator_register_view.xml
  2. 13
      easy_my_coop/views/product_view.xml
  3. 4
      easy_my_coop/views/subscription_request_view.xml
  4. 31
      easy_my_coop_loan/views/loan_view.xml

2
easy_my_coop/views/cooperator_register_view.xml

@ -60,7 +60,7 @@
<separator/> <separator/>
<group expand="0" name="group_by" string="Group By"> <group expand="0" name="group_by" string="Group By">
<filter name="entry_type" string="Entry type" context="{'group_by' : 'type'}" /> <filter name="entry_type" string="Entry type" context="{'group_by' : 'type'}" />
<filter name="date_month" string="Date Month" context="{'group_by': 'date'}"/>
<filter name="subscription_date" string="Subscription Date" context="{'group_by': 'date'}"/>
</group> </group>
</search> </search>
</field> </field>

13
easy_my_coop/views/product_view.xml

@ -36,6 +36,19 @@
</field> </field>
</record> </record>
<record id="share_product_filter" model="ir.ui.view">
<field name="name">product.template.share.filter</field>
<field name="model">product.template</field>
<field name="inherit_id" ref="product.product_template_search_view"/>
<field name="arch" type="xml">
<xpath expr="." position="inside">
<group expand="0" name="group_by" string="Group By">
<filter name="Creation Date" context="{'group_by': 'create_date'}"/>
</group>
</xpath>
</field>
</record>
<record id="share_product_action" model="ir.actions.act_window"> <record id="share_product_action" model="ir.actions.act_window">
<field name="name">Share type</field> <field name="name">Share type</field>
<field name="type">ir.actions.act_window</field> <field name="type">ir.actions.act_window</field>

4
easy_my_coop/views/subscription_request_view.xml

@ -104,14 +104,16 @@
<field name="arch" type="xml"> <field name="arch" type="xml">
<search string="Search Subscription Request"> <search string="Search Subscription Request">
<field name="name"/> <field name="name"/>
<field name="partner_id"/>
<separator/> <separator/>
<filter string="Draft" name="state_draft" domain="[('state','=','draft')]"/> <filter string="Draft" name="state_draft" domain="[('state','=','draft')]"/>
<filter string="Paid" name="state_paid" domain="[('state','=','paid')]"/>
<filter string="Done" name="state_done" domain="[('state','=','done')]"/> <filter string="Done" name="state_done" domain="[('state','=','done')]"/>
<separator/> <separator/>
<filter string="Not Validated" name="Not Validated" domain="[('validated', '=', False)]"/> <filter string="Not Validated" name="Not Validated" domain="[('validated', '=', False)]"/>
<group expand="0" name="group_by" string="Group By"> <group expand="0" name="group_by" string="Group By">
<filter name="request_type" string="Request type" context="{'group_by' : 'type'}" /> <filter name="request_type" string="Request type" context="{'group_by' : 'type'}" />
<filter name="date_month" string="Date Month" context="{'group_by': 'date'}"/>
<filter name="date" string="Request Date" context="{'group_by': 'date'}"/>
</group> </group>
</search> </search>
</field> </field>

31
easy_my_coop_loan/views/loan_view.xml

@ -109,6 +109,16 @@
</field> </field>
</record> </record>
<record id="view_loan_issue_filter" model="ir.ui.view">
<field name="name">Loans Issue Search</field>
<field name="model">loan.issue</field>
<field name="arch" type="xml">
<search string="Search Loan Issue">
<field name="name"/>
</search>
</field>
</record>
<record id="action_loan_issue" model="ir.actions.act_window"> <record id="action_loan_issue" model="ir.actions.act_window">
<field name="name">Loan Issues</field> <field name="name">Loan Issues</field>
<field name="res_model">loan.issue</field> <field name="res_model">loan.issue</field>
@ -192,4 +202,25 @@
</form> </form>
</field> </field>
</record> </record>
<record id="view_loan_issue_line_filter" model="ir.ui.view">
<field name="name">Loans Search</field>
<field name="model">loan.issue.line</field>
<field name="arch" type="xml">
<search string="Search Loans">
<field name="name"/>
<field name="partner_id"/>
<field name="loan_issue_id"/>
<separator/>
<filter string="Draft" name="state_draft" domain="[('state','=','draft')]"/>
<filter string="Paid" name="state_paid" domain="[('state','=','paid')]"/>
<filter string="Done" name="state_done" domain="[('state','=','done')]"/>
<filter string="Subscribed" name="state_subscribed" domain="[('state','=','subscribed')]"/>
<group expand="0" name="group_by" string="Group By">
<filter name="loan_issue_id" string="Loan Issue" context="{'group_by' : 'loan_issue_id'}" />
<filter name="date" string="Subscription Date" context="{'group_by': 'date'}"/>
</group>
</search>
</field>
</record>
</odoo> </odoo>
Loading…
Cancel
Save