Hello,
My friend edited for me 'account' module, and when i try to update the module by GUI, i have an error that i can't figue out how to solve it :
" Validation error
The operation cannot be completed: another model requires the record to be deleted. If possible, archive it instead.
Model: Unknown (Unknown), Constraint: account_payment_register_move_line_rel_wizard_id_fkey "
I also tried to update the module from CLI ( sudo python3 odoo.py -d base_name -u account) but same problem, and i get this error :
" ERROR ***.sql_db: bad query: ALTER TABLE "account_payment_register_move_line_rel" ADD FOREIGN KEY ("wizard_id") REFERENCES "account_payment_register"("id") ON DELETE cascade
ERROR: insert or update on table "account_payment_register_move_line_rel" violates foreign key constraint "account_payment_register_move_line_rel_wizard_id_fkey"
DETAIL: Key (wizard_id)=(1) is not present in table "account_payment_register".
psycopg2.errors.ForeignKeyViolation: insert or update on table "account_payment_register_move_line_rel" violates foreign key constraint "account_payment_register_move_line_rel_wizard_id_fkey"
DETAIL: Key (wizard_id)=(1) is not present in table "account_payment_register". "
Please if anyone know or can give me a little help, i would be grateful for that, Thanks
Look for a new friend.
but before ask him to clean up the mess he has produced or restore the backup you have made before starting with violating all rules and recommendations. Otherwise troubleshoot the issue directly in the database.
i found a solution, i deleted "account_payment_register_move_line_rel" and updated ' account ' module, seems like everything workd fine untill now