[18.0][MIG] hr_contract_rate: Migration to 18.0 #1629
<field name="amount" nolabel="1" required="1" />
<span>/</span>
<field name="amount_period" class="w-auto" nolabel="1" required="1" />
In 14.0, both amount and amount_period had required="1" in the form view. Since neither field is required=True on the Python model (to allow creating contracts via wage), dropping required="1" lets users in the UI save contracts with an empty amount or period. Restoring required="1" keeps the 14.0 behavior and prevents saving contracts without a rate.
All commit authors signed the Contributor License Agreement.
<!-- CLA BOT SIGNING COMMENT DO NOT EDIT -->
Good catch, applied. Thanks @BhaveshHeliconia.
@OCA/human-resources-maintainers could someone review this one?
Approved these changes.
LGTM!
This PR has the approved label and has been created more than 5 days ago. It should therefore be ready to merge by a maintainer (or a PSC member if the concerned addon has no declared maintainer). 🤖
/ocabot migration hr_contract_rate
/ocabot merge nobump
This PR looks fantastic, let's merge it!
Prepared branch 18.0-ocabot-merge-pr-1629-by-dreispt-bump-nobump, awaiting test results.
@dreispt The merge process could not be finalized, because command twine upload --disable-progress-bar --non-interactive --repository-url https://upload.pypi.org/legacy/ -u __token__ odoo_addon_hr_contract_rate-18.0.1.0.0.4-py3-none-any.whl failed with output:
Uploading distributions to https://upload.pypi.org/legacy/
Uploading odoo_addon_hr_contract_rate-18.0.1.0.0.4-py3-none-any.whl
[33mWARNING [0m Error during upload. Retry with the --verbose option for more details.
[31mERROR [0m HTTPError: 429 Too Many Requests from https://upload.pypi.org/legacy/
Too Many Requests
dreispt
nimarosa
Migration of
hr_contract_rateto 18.0 from 14.0 (it was not ported to 15.0-17.0, and #1401 for 16.0 was closed).Standard migration, module history preserved. Main changes:
env.post_init_hookremoved, the ORM already computes the stored fields on install.track_visibility->tracking.AMOUNT_PERIOD_SELECTIONexported so other modules can reuse the keys.[FIX]commit: writingwageon an hourly/daily/weekly contract leftapproximate_wageoutdated.I'm using it in production.
@OCA/hr-maintainers