Files
gzth/yuthon_property/views/yuthon_property_views.xml
T
2024-09-08 20:24:41 +08:00

139 lines
7.1 KiB
XML

<?xml version="1.0" encoding="UTF-8" ?>
<odoo>
<record id="yuthon_property_tree" model="ir.ui.view">
<field name="name">yuthon.property.tree</field>
<field name="model">yuthon.property</field>
<field name="arch" type="xml">
<tree string="物业管理">
<field name="name"/>
<field name="property_precinct"/>
<field name="property_floor"/>
<field name="property_room"/>
<field name="property_house"/>
<field name="property_orientation"/>
<field name="property_use_id"/>
<field name="property_asset_type"/>
<field name="property_use_type"/>
<field name="property_use_time"/>
<field name="property_source"/>
<field name="property_rent_type"/>
<field name="state_id"/>
</tree>
</field>
</record>
<record id="yuthon_property_form" model="ir.ui.view">
<field name="name">yuthon.property.form</field>
<field name="model">yuthon.property</field>
<field name="arch" type="xml">
<form string="产品管理">
<sheet>
<field name="image_1920" widget="image" class="oe_avatar" options="{'preview_image': 'image_128'}"/>
<div class="oe_title">
<label for="name" string="名称"/>
<h1>
<field name="name" required="1"/>
</h1>
</div>
<group>
<group>
<field name="property_precinct"/>
<field name="property_floor"/>
<field name="property_room"/>
<field name="property_house"/>
<field name="property_orientation"/>
</group>
<group>
<field name="property_use_id"/>
<field name="property_asset_type"/>
<field name="property_use_type"/>
<field name="property_use_time"/>
<field name="property_rent_type"/>
<field name="state_id"/>
<field name="property_source"/>
</group>
</group>
<notebook>
<page string="描述">
<field name="description" widget="tinymce"/>
</page>
</notebook>
</sheet>
<div class="o_attachment_preview"/>
<div class="oe_chatter">
<field name="message_follower_ids" groups="base.group_user"/>
<field name="activity_ids"/>
<field name="message_ids"/>
</div>
</form>
</field>
</record>
<record id="yuthon_property_search" model="ir.ui.view">
<field name="name">yuthon.property.search</field>
<field name="model">yuthon.property</field>
<field name="arch" type="xml">
<search>
<filter string="可租" name="could" domain="[('property_rent_type', '=', 'could')]"/>
<filter string="不可租" name="could" domain="[('property_rent_type', '=', 'no')]"/>
<filter string="已租" name="done" domain="[('property_rent_type', '=', 'done')]"/>
<filter string="空置" name="none" domain="[('property_rent_type', '=', 'none')]"/>
<separator/>
<filter string="可租" name="could" domain="[('state_id', '=', 'could')]"/>
<group expand="0">
<filter name="group_statu" string="物业状态" context="{'group_by': 'state_id'}"/>
</group>
</search>
</field>
</record>
<!-- 后期根据客户需求完善 -->
<record id="yuthon_property_kanban" model="ir.ui.view">
<field name="name">yuthon.property.kanban</field>
<field name="model">yuthon.property</field>
<field name="arch" type="xml">
<kanban>
<field name="id"/>
<!-- <field name="lst_price"/>-->
<!-- <field name="activity_state"/>-->
<templates>
<t t-name="kanban-box">
<div class="oe_kanban_card oe_kanban_global_click">
<div class="o_kanban_image me-1">
<img t-att-src="kanban_image('product.product', 'image_128', record.id.raw_value)"
alt="Product" class="o_image_64_contain"/>
</div>
<div class="oe_kanban_details">
<div class="o_kanban_record_top mb-0">
<div class="o_kanban_record_headings">
<strong class="o_kanban_record_title">
<field name="name"/>
</strong>
</div>
<!-- <field name="priority" widget="priority"/>-->
</div>
<!-- <t t-if="record.default_code.value">[<field name="default_code"/>]-->
<!-- </t>-->
<!-- <div class="o_kanban_tags_section">-->
<!-- <field name="product_template_variant_value_ids"-->
<!-- groups="product.group_product_variant" widget="many2many_tags"-->
<!-- options="{'color_field': 'color'}"/>-->
<!-- </div>-->
<!-- <div name="product_lst_price" class="mt-1">-->
<!-- Price:-->
<!-- <field name="lst_price"></field>-->
<!-- </div>-->
<div name="tags"/>
</div>
</div>
</t>
</templates>
</kanban>
</field>
</record>
<record id="yuthon_property_action" model="ir.actions.act_window">
<field name="name">物业</field>
<field name="res_model">yuthon.property</field>
<field name="view_mode">kanban,tree,form</field>
<field name="search_view_id" ref="yuthon_property_search"/>
</record>
</odoo>