odoo18/addons_extensions/hr_recruitment_extended/views/hr_location.xml

69 lines
2.5 KiB
XML

<?xml version="1.0" encoding="UTF-8" ?>
<odoo>
<data>
<!-- Tree View (List View) -->
<record id="view_hr_location_tree" model="ir.ui.view">
<field name="name">hr.location.tree</field>
<field name="model">hr.location</field>
<field name="arch" type="xml">
<list string="Location">
<field name="location_name"/>
<field name="zip_code"/>
<field name="country_id"/>
<field name="state"/>
</list>
</field>
</record>
<!-- Form View -->
<record id="view_hr_location_form" model="ir.ui.view">
<field name="name">hr.location.form</field>
<field name="model">hr.location</field>
<field name="arch" type="xml">
<form string="Location">
<sheet>
<div class="row justify-content-between position-relative w-100 m-0 mb-2">
<div class="oe_title mw-75 ps-0 pe-2">
<h1 class="d-flex flex-row align-items-center">
<field name="location_name" placeholder="Location Name" required="True" style="font-size: min(4vw, 2.6rem);"/>
</h1>
</div>
</div>
<group>
<group>
<field name="country_id"/>
<field name="state"/>
</group>
<group>
<field name="zip_code"/>
</group>
</group>
</sheet>
</form>
</field>
</record>
<!-- Action to open Locations -->
<record id="action_hr_location" model="ir.actions.act_window">
<field name="name">Locations</field>
<field name="res_model">hr.location</field>
<field name="view_mode">list,form</field>
<field name="help" type="html">
<p class="o_view_nocontent_smiling_face">
Create a new Location
</p>
</field>
</record>
<menuitem
id="hr_location_menu"
name="Locations"
action="action_hr_location"
parent="hr_recruitment.menu_hr_recruitment_config_jobs"
sequence="5"/>
</data>
</odoo>