修改sf定时任务不在部署时更新配置
This commit is contained in:
@@ -52,10 +52,10 @@ class JikimoWorkorderException(models.Model):
|
||||
|
||||
def _get_message(self, message_queue_ids):
|
||||
contents, _ = super(JikimoWorkorderException, self)._get_message(message_queue_ids)
|
||||
url = self.env['ir.config_parameter'].get_param('web.base.url')
|
||||
base_url = self.env['ir.config_parameter'].get_param('web.base.url')
|
||||
action_id = self.env.ref('mrp.mrp_production_action').id
|
||||
for index, content in enumerate(contents):
|
||||
exception_id = self.env['jikimo.workorder.exception'].browse(message_queue_ids[index].res_id)
|
||||
url = url + '/web#id=%s&view_type=form&action=%s' % (exception_id.workorder_id.production_id.id, action_id)
|
||||
url = base_url + '/web#id=%s&view_type=form&action=%s' % (exception_id.workorder_id.production_id.id, action_id)
|
||||
contents[index] = content.replace('{{url}}', url)
|
||||
return contents, message_queue_ids
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
<?xml version="1.0" encoding='UTF-8'?>
|
||||
<odoo>
|
||||
|
||||
<data noupdate="1">
|
||||
<record model="ir.cron" id="ir_cron_sf_static_resource_datasync">
|
||||
<field name="name">制造-配置:每日定时同步cloud的静态资源库</field>
|
||||
<field name="model_id" ref="model_res_config_settings"/>
|
||||
@@ -220,4 +220,5 @@
|
||||
<!-- <field name="numbercall">-1</field>-->
|
||||
<!-- <field name="doall" eval="False"/>-->
|
||||
<!-- </record>-->
|
||||
</data>
|
||||
</odoo>
|
||||
Reference in New Issue
Block a user