エントリーの編集
エントリーの編集は全ユーザーに共通の機能です。
必ずガイドラインを一読の上ご利用ください。
記事へのコメント1件
- 注目コメント
- 新着コメント
注目コメント算出アルゴリズムの一部にLINEヤフー株式会社の「建設的コメント順位付けモデルAPI」を使用しています
- バナー広告なし
- ミュート機能あり
- ダークモード搭載
関連記事
How to create an object for a Django model with a many to many field?
You cannot create m2m relations from unsaved objects. If you have the pks, try this: sample_objec... You cannot create m2m relations from unsaved objects. If you have the pks, try this: sample_object = Sample() sample_object.save() sample_object.users.add(1,2) Update: After reading the saverio's answer, I decided to investigate the issue a bit more in depth. Here are my findings. This was my original suggestion. It works, but isn't optimal. (Note: I'm using Bars and a Foo instead of Users and a S
2014/06/26 リンク