AddStoragePolicy adds the "storage_policy" edges to the StoragePolicy entity.
(s ...*StoragePolicy)
| 186 | |
| 187 | // AddStoragePolicy adds the "storage_policy" edges to the StoragePolicy entity. |
| 188 | func (nu *NodeUpdate) AddStoragePolicy(s ...*StoragePolicy) *NodeUpdate { |
| 189 | ids := make([]int, len(s)) |
| 190 | for i := range s { |
| 191 | ids[i] = s[i].ID |
| 192 | } |
| 193 | return nu.AddStoragePolicyIDs(ids...) |
| 194 | } |
| 195 | |
| 196 | // Mutation returns the NodeMutation object of the builder. |
| 197 | func (nu *NodeUpdate) Mutation() *NodeMutation { |
nothing calls this directly
no test coverage detected