Přejít na obsah
Menu
You need to be registered to interact with the community.
This question has been flagged
1 Odpovědět
4177 Zobrazení
<record id="backup_scheduler" model="ir.cron">

    <field name="interval_type">days</field>

    <field name="name">Scheduler for Auto DB Backup To Folder</field>

    <field name="doall">False</field>

    <field name="active">False</field>

    <field name="interval_number">1</field>

    <field name="model_id" ref="backup.model_database_backup"/>

    <field name="state">code</field>

    <field name="code">model.schedule_auto_db_backup()</field>

</record>


this is my xml


# Compute how many time we should run the cron

effective_call_count = (

    1 if not missed_call_count  # run at least once

    else 1 if not job['doall']  # run once for all

    else missed_call_count if job['numbercall'] == -1  # run them all

    else min(missed_call_count, job['numbercall'])  # run maximum numbercall times

)

call_count_left = max(job['numbercall'] - effective_call_count, -1)


# The actual cron execution

for call in range(effective_call_count):

    ir_cron._callback(job['cron_name'], job['ir_actions_server_id'], job['id'])

this is my py


KeyError: 'doall'

please look into this iddue



this is my bug when i upgrade from 17 to 18 Please looking to this


Avatar
Zrušit
Nejlepší odpověď

Hi,

There is no "doall" field in "ir.cron" model in odoo 18.
(also "numbercall" field is also removed, but the cron works until it set to False)

Skip that line. Hope it works.
:)

Avatar
Zrušit
Related Posts Odpovědi Zobrazení Aktivita
0
čvc 25
410
0
čvc 25
1042
1
kvě 25
1522
1
dub 25
1530
1
čvn 25
1024