Debian Codegraph @

addons/hr_holidays/static/tests/mock_server/mock_models/hr_employee.js

raw
1 import { hrModels } from "@hr/../tests/hr_test_helpers";
2 import { fields } from "@web/../tests/web_test_helpers";
3
4 export class HrEmployee extends hrModels.HrEmployee {
5 _name = "hr.employee";
6
7 name = fields.Char();
8 leave_date_to = fields.Date();
9 user_id = fields.Many2one({ relation: "res.users" });
10
11 _get_store_avatar_card_fields() {
12 return [...super._get_store_avatar_card_fields(), "leave_date_to"];
13 }
14
15 _records = [
16 {
17 id: 100,
18 name: "Richard",
19 department_id: 11,
20 },
21 {
22 id: 200,
23 name: "Jane",
24 department_id: 11,
25 },
26 ];
27 }