diff --git a/models/account_move.py b/models/account_move.py index 53c187b..ac4ace3 100755 --- a/models/account_move.py +++ b/models/account_move.py @@ -46,14 +46,12 @@ class AccountMove(models.Model): a.systempay_ref=False for t in a.transaction_ids: if t.systempay_raw_data: - raw1=t.systempay_raw_data.split(",") - vads_order_id_s=raw1[21].split(":") - # raw1=raw1.replace("\r", "") - # raw1=raw1.replace("'","\"") - # raise Warning(raw1) - # raw=json.loads(raw1) - - a.systempay_ref=vads_order_id_s[1].replace("'","") + raw=t.systempay_raw_data.split(",") + for r in raw: + r_s=r.split(":") + #_logger.error('vads:'+r_s[0]) + if r_s[0]==" 'vads_order_id'": + a.systempay_ref=r_s[1].replace("'","") break