Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[18.0][MIG] hr_expense_advance_clearing #284

Open
wants to merge 95 commits into
base: 18.0
Choose a base branch
from
Open
Changes from 1 commit
Commits
Show all changes
95 commits
Select commit Hold shift + click to select a range
37978cc
[12.0][ADD] hr_expense_advance_clearing
kittiu Apr 26, 2019
7506e1a
[12.0][FIX] hr_expense_advance_clearing
kittiu Dec 9, 2019
c367d01
[IMP] : black, isort
kittiu Mar 20, 2020
f38b260
[13.0][MIG] hr_expense_advance_clearing
kittiu Mar 20, 2020
e16825d
[UPD] Update hr_expense_advance_clearing.pot
oca-travis Jun 12, 2020
a22153a
[UPD] README.rst
OCA-git-bot Jun 12, 2020
f47a619
[FIX] hr_expense_advance_clearing: analytic account visibility
chienandalu Sep 24, 2020
8fdc2fd
[13.0][UPD] Add Contributors
newtratip Oct 1, 2020
adfc9ec
hr_expense_advance_clearing 13.0.1.0.1
OCA-git-bot Oct 1, 2020
52e0012
[IMP] hr_expense_advance_clearing: hide analytics tags as well
chienandalu Nov 5, 2020
4424fd7
hr_expense_advance_clearing 13.0.1.1.0
OCA-git-bot Nov 6, 2020
8fd62c9
[FIX] rename fields residual
Saran440 Jan 7, 2021
61813ce
[UPD] Update hr_expense_advance_clearing.pot
oca-travis Jan 11, 2021
c1d0a17
hr_expense_advance_clearing 13.0.1.2.0
OCA-git-bot Jan 11, 2021
7bdca57
[14.0][MIG] hr_expense_advance_clearing
Saran440 Jan 18, 2021
988db68
[UPD] README.rst
OCA-git-bot May 1, 2021
73a3d5f
[FIX] hr_expense_advance_clearing: default_get return advance
Saran440 Jul 19, 2021
ab4cc7a
[UPD] Update hr_expense_advance_clearing.pot
oca-travis Jul 20, 2021
fc15d8c
hr_expense_advance_clearing 14.0.1.0.1
OCA-git-bot Jul 20, 2021
59dd457
[14.0][IMP] hr_expense_advance_clearing, add invisible fields
kittiu Jul 20, 2021
f152af9
hr_expense_advance_clearing 14.0.1.0.2
OCA-git-bot Jul 20, 2021
692027b
[14.0][IMP] hr_expense_advance_clearing, allow predefined clearing pr…
kittiu Jul 20, 2021
c38e740
[UPD] Update hr_expense_advance_clearing.pot
oca-travis Jul 21, 2021
91f790a
[UPD] README.rst
OCA-git-bot Jul 21, 2021
e452569
hr_expense_advance_clearing 14.0.1.1.0
OCA-git-bot Jul 21, 2021
300f069
[IMP] clearing tab on advance sheet
Saran440 Jul 21, 2021
809864e
[UPD] Update hr_expense_advance_clearing.pot
oca-travis Jul 21, 2021
c49119f
hr_expense_advance_clearing 14.0.1.2.0
OCA-git-bot Jul 21, 2021
2c027da
[14.0][IMP] hr_expense_advance_clearing, add invisible fields on tree…
kittiu Jul 25, 2021
6b5b7e9
hr_expense_advance_clearing 14.0.1.2.1
OCA-git-bot Jul 25, 2021
1920b80
[14.0][FIX] hr_expense_advance_clearing, fix access right on .read()
kittiu Jul 29, 2021
4f4bf0b
hr_expense_advance_clearing 14.0.1.2.2
OCA-git-bot Aug 19, 2021
df9c785
[IMP] hr_expense_advance_cleaing: show advance on employee view
Saran440 Aug 18, 2021
8c02f1d
[FIX] update context
Saran440 Oct 29, 2021
0f2b1d6
hr_expense_advance_clearing 14.0.1.2.3
OCA-git-bot Oct 29, 2021
bd823e5
[UPD] Update hr_expense_advance_clearing.pot
oca-travis Oct 30, 2021
54c5468
hr_expense_advance_clearing 14.0.1.3.0
OCA-git-bot Oct 30, 2021
a3e02a6
[14.0][IMP] hr_expense_advance_clearing, add menus Advance/Expense
kittiu Nov 2, 2021
40b1358
[UPD] Update hr_expense_advance_clearing.pot
oca-travis Nov 3, 2021
0f623b2
hr_expense_advance_clearing 14.0.1.4.0
OCA-git-bot Nov 3, 2021
1f6d6ed
[FIX] constrains with advance clearing
Saran440 Nov 9, 2021
5243bb9
[FIX] return advance multi line advance
Saran440 Nov 9, 2021
272e255
[14.0][ENH] hr_expense_advance_clearing, better expense_post_return_a…
kittiu Nov 11, 2021
072a99c
[UPD] Update hr_expense_advance_clearing.pot
oca-travis Nov 12, 2021
3ef058d
hr_expense_advance_clearing 14.0.1.4.1
OCA-git-bot Nov 12, 2021
3b8295b
[FIX] hr_expense_advance_clearing: add Clear Advance on tree view
ps-tubtim Nov 11, 2021
6341699
hr_expense_advance_clearing 14.0.1.4.2
OCA-git-bot Nov 16, 2021
a2fb16d
[FIX] skip_account_move_synchronization on post journal entries
Saran440 Nov 18, 2021
7ebfb42
hr_expense_advance_clearing 14.0.1.4.3
OCA-git-bot Nov 19, 2021
65f77eb
[14.0][FIX] hr_expense_advance_clearing, make expense_line_ids readon…
kittiu Nov 10, 2021
11b69d0
hr_expense_advance_clearing 14.0.1.4.4
OCA-git-bot Nov 22, 2021
e28794f
[FIX] onchange clearing advance for hooks
Saran440 Nov 22, 2021
0ff4c8b
hr_expense_advance_clearing 14.0.1.5.0
OCA-git-bot Nov 24, 2021
5c78b58
hr_expense_advance_clearing 14.0.1.5.1
OCA-git-bot Nov 24, 2021
46506c7
[FIX] hr_expense_advance_clearing: add context for clearing
ps-tubtim Nov 26, 2021
d828012
[FIX] default return advance
Saran440 Dec 21, 2021
4249c9f
hr_expense_advance_clearing 14.0.1.5.2
OCA-git-bot Dec 23, 2021
d8f551b
[FIX] return advance - redirect payment message
Saran440 Dec 28, 2021
92cb804
[UPD] Update hr_expense_advance_clearing.pot
oca-travis Dec 29, 2021
642f8dc
hr_expense_advance_clearing 14.0.1.5.3
OCA-git-bot Dec 29, 2021
1f047b8
hr_expense_advance_clearing 14.0.1.5.4
OCA-git-bot Jan 19, 2022
7c89259
[IMP] hr_expense_advance_clearing: black, isort, prettier
kittiu Mar 3, 2022
32812cb
[15.0][MIG] hr_expense_advance_clearing]
kittiu Mar 3, 2022
ed54441
[UPD] hr_expense_advance_clearing, use smart button instead of self o…
kittiu Mar 3, 2022
c18b893
[14.0][ENH] hr_expense_advance_clearing, not allow over return
kittiu May 28, 2022
e72fa58
[FIX] do not allow cancel PV related clearing or return
Saran440 Mar 26, 2022
40d2c69
[FIX] test script - tax include price https://github.com/odoo/odoo/co…
Saran440 Oct 5, 2022
9203ae3
[FIX] payment return advance can related to advance
Saran440 Oct 17, 2022
2fc4066
[UPD] Update hr_expense_advance_clearing.pot
Oct 28, 2022
e8c5df7
[UPD] README.rst
OCA-git-bot Oct 28, 2022
a017b9a
[14.0][FIX] hr_expense_advance_clearing: allow general user to create…
ps-tubtim Nov 14, 2022
35499e8
hr_expense_advance_clearing 15.0.1.0.1
OCA-git-bot Nov 28, 2022
cd68bec
[15.0][FIX] hr_expense_advance_clearing: zero unit price
ps-tubtim Feb 16, 2023
53e98fa
hr_expense_advance_clearing 15.0.1.1.0
OCA-git-bot Mar 9, 2023
8b36782
[FIX] update readme
Saran440 Feb 22, 2023
e90f153
[FIX] hr_expense_advance_clearing: change field not compute advance
Saran440 Mar 16, 2023
a9acba0
hr_expense_advance_clearing 15.0.1.2.0
OCA-git-bot Apr 28, 2023
280f1b4
[UPD] README.rst
OCA-git-bot Apr 28, 2023
8649c68
Added translation using Weblate (Italian)
mymage Jun 30, 2023
7416e91
Translated using Weblate (Italian)
mymage Jul 4, 2023
e9f9d4d
[UPD] README.rst
OCA-git-bot Sep 3, 2023
640cc0b
[MIG] hr_expense_advance_clearing: Migration to 16.0
Saran440 Sep 18, 2023
a1cbba0
[UPD] Update hr_expense_advance_clearing.pot
Nov 29, 2023
ae23ff0
Update translation files
weblate Nov 29, 2023
0679f9c
Translated using Weblate (Italian)
mymage Nov 30, 2023
464da14
[FIX] hr_expense_advance_clearing: clear advance partial
Saran440 Jun 24, 2024
037a33c
[BOT] post-merge updates
OCA-git-bot Jul 12, 2024
fd39fe1
[FIX] hr_expense_advance_clearing: fetch the product considering the …
marcelsavegnago Aug 2, 2024
01fbe01
[BOT] post-merge updates
OCA-git-bot Aug 15, 2024
7604acd
[FIX] hr_expense_advance_clearing: Fix + improve tests
victoralmau Nov 27, 2024
1c5964a
[BOT] post-merge updates
OCA-git-bot Nov 27, 2024
3740cca
[IMP] hr_expense_advance_clearing: pre-commit auto fixes
Saran440 Jul 19, 2024
9e088d2
[MIG] hr_expense_advance_clearing: Migration to 17.0
Saran440 Jul 19, 2024
8fdce63
[IMP] hr_expense_advance_clearing: pre-commit auto fixes
Saran440 Jan 14, 2025
06072ae
[MIG] hr_expense_advance_clearing: Migration to 18.0
Saran440 Jan 14, 2025
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
[FIX] hr_expense_advance_clearing: change field not compute advance
  • Loading branch information
Saran440 committed Jan 14, 2025
commit e90f1536258dc68a252d3103c72b3a8317050f9a
11 changes: 1 addition & 10 deletions hr_expense_advance_clearing/models/hr_expense_sheet.py
Original file line number Diff line number Diff line change
@@ -11,7 +11,7 @@ class HrExpenseSheet(models.Model):
_inherit = "hr.expense.sheet"

advance = fields.Boolean(
string="Employee Advance", compute="_compute_advance", store=True
string="Employee Advance",
)
advance_sheet_id = fields.Many2one(
comodel_name="hr.expense.sheet",
@@ -54,15 +54,6 @@ class HrExpenseSheet(models.Model):
help="Final regiter payment amount even after advance clearing",
)

@api.depends("expense_line_ids")
def _compute_advance(self):
for sheet in self:
if sheet.expense_line_ids:
sheet.advance = all(sheet.expense_line_ids.mapped("advance"))
else:
sheet.advance = self.env.context.get("default_advance", sheet.advance)
return

@api.constrains("advance_sheet_id", "expense_line_ids")
def _check_advance_expense(self):
advance_lines = self.expense_line_ids.filtered("advance")
Original file line number Diff line number Diff line change
@@ -110,6 +110,7 @@ def _create_expense_sheet(
"name": description,
"employee_id": expense.employee_id.id,
"expense_line_ids": [(6, 0, [expense.id])],
"advance": advance,
}
)
return expense_sheet
2 changes: 2 additions & 0 deletions hr_expense_advance_clearing/views/hr_expense_views.xml
Original file line number Diff line number Diff line change
@@ -192,6 +192,8 @@
<field
name="advance"
attrs="{'invisible': [('advance', '=', False)]}"
readonly="1"
force_save="1"
/>
<label for="advance" attrs="{'invisible': [('advance', '=', False)]}" />
</h1>