在尝试执行以下操作时:
for line in blines:
line.account = get_customer(line.AccountCode)
尝试将值分配给以下内容时出现错误line.account
:
DetachedInstanceError: Parent instance <SunLedgerA at 0x16eda4d0> is not bound to a Session; lazy load operation of attribute 'account' cannot proceed
难道我做错了什么??