Skip to content

Commit

Permalink
[ADD] electronic_store: done review changes
Browse files Browse the repository at this point in the history
  • Loading branch information
dhrs-odoo committed Mar 19, 2024
1 parent 4652ff9 commit f6a3ef6
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 4 deletions.
6 changes: 3 additions & 3 deletions electronic_store/__manifest__.py
Original file line number Diff line number Diff line change
Expand Up @@ -25,8 +25,8 @@
'theme_buzzy',
],
'data': [
# 'data/base_automation.xml',
# 'data/ir_actions_server.xml',
'data/base_automation.xml',
'data/ir_actions_server.xml',
'data/helpdesk_config.xml',
'data/res_config_settings.xml',
'data/ir_attachment_pre.xml',
Expand Down Expand Up @@ -78,5 +78,5 @@
],
'license': 'OPL-1',
'images': ['images/main.png'],
'maintenance_loc': 28,
'maintenance_loc': 31,
}
8 changes: 7 additions & 1 deletion electronic_store/data/ir_actions_server.xml
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,12 @@
<field name="name">warranty date update</field>
<field name="base_automation_id" ref="base_automation_1"/>
<field name="model_id" ref="stock.model_stock_move_line"/>
<field name="state">object_write</field>
<field name="state">code</field>
<field name="code"><![CDATA[
move_lines = records.search([("state", "=", "done"), ("picking_code", "=", "outgoing")])
records.write({
'x_warranty_date': datetime.datetime.today() + datetime.timedelta(record.product_id.expiration_time)
})
]]></field>
</record>
</odoo>

0 comments on commit f6a3ef6

Please sign in to comment.