def machaccnt_pay_dispatch_clear(mch_ant_bef, mach_pay_up_obj): """支付记账数据清理""" for table_name in mch_ant_bef.keys(): SqlSave.delete_amt_info(table_name=table_name, trans_no=mach_pay_up_obj.trans_no) for oder_id in mach_pay_up_obj.oder_no_list: SqlSave.delete_mch_accnt_balance_record(oder_id=oder_id)
def machaccnt_promotion_refund_dispatch_clear(exe_data): """活动退款记账数据清理""" trans_no = Base.get_trans_no(exe_data) table_name = [ Constants.TableName.HIS_ACCNT_PREPAY, Constants.TableName.HIS_ACCNT_PROFILE, Constants.TableName.HIS_ACCNT_MCH_SUB ] for t_n in table_name: SqlSave.delete_amt_info(table_name=t_n, trans_no=trans_no)
def err_data_clear(exe_data, trans_no=True): """特殊清理方法""" if trans_no is True: trans_no = Base.get_trans_no(exe_data) else: trans_no = trans_no table_name = [ Constants.TableName.HIS_ACCNT_PREPAY, Constants.TableName.HIS_ACCNT_ONWAY, Constants.TableName.HIS_ACCNT_PROFILE, Constants.TableName.HIS_ACCNT_MCH_SUB ] oder_id = [ 'test1', 'test2', 'test3', 'test4', 'test5', 'test6', 'test10' ] for table_name in table_name: SqlSave.delete_amt_info(table_name=table_name, trans_no=trans_no) for id in oder_id: SqlSave.delete_mch_accnt_balance_record(oder_id=id)
def machaccnt_promotion_dispatch_clear(mch_ant_bef, mach_pay_up_obj): """活动记账数据清理""" for table_name in mch_ant_bef.keys(): SqlSave.delete_amt_info(table_name=table_name, trans_no=mach_pay_up_obj.trans_no)