From 96b089ec8a8d54ec578950373c563fbcbbc75e86 Mon Sep 17 00:00:00 2001 From: "watcha.h@almacom.co.th" Date: Thu, 27 Aug 2015 08:03:34 +0700 Subject: [PATCH] migrate --- netforce_clinic/migrations/repost_invoice.py | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/netforce_clinic/migrations/repost_invoice.py b/netforce_clinic/migrations/repost_invoice.py index 90891e8..94fd6d9 100644 --- a/netforce_clinic/migrations/repost_invoice.py +++ b/netforce_clinic/migrations/repost_invoice.py @@ -43,7 +43,12 @@ class Migration(migration.Migration): for seq in get_model("sequence").search_browse([['type','in',['cust_invoice','clinic_invoice_noclaim']]]): for run in seq.running: run.delete() - for hdcase in get_model('clinic.hd.case').browse(ids): + dom2=[ + ['date','>=','2015-07-01'], + ['state','=','waiting_payment'], + ] + #for hdcase in get_model('clinic.hd.case').browse(ids): + for hdcase in get_model('clinic.hd.case').search_browse(dom2): print('remake_invoice ---> ', hdcase.number) ctx={ 'is_migrate': True,