Skip to content

Commit

Permalink
perf: 账号支持批量更新
Browse files Browse the repository at this point in the history
  • Loading branch information
O-Jiangweidong authored and BaiJiangJie committed Feb 4, 2024
1 parent be80663 commit d1f31f0
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion apps/accounts/serializers/account/account.py
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@ def set_initial_value(self):
for data in initial_data:
if not data.get('asset') and not self.instance:
raise serializers.ValidationError({'asset': UniqueTogetherValidator.missing_message})
asset = data.get('asset') or self.instance.asset
asset = data.get('asset') or getattr(self.instance, 'asset', None)
self.from_template_if_need(data)
self.set_uniq_name_if_need(data, asset)

Expand Down

0 comments on commit d1f31f0

Please sign in to comment.