[eluser]OverZealous[/eluser] @Oblique
The error message is correct: your relationship is incorrectly defined. Relationships need to be fully defined on both sides. There is no way for DMZ to know how to assign the User in this context:
Code:
$user->save($frieght);
// OR
$freight->save($user);
That's why you need to fully define the relationship on both sides. If you want two different types of relationships, then you need two different relationships defined on both objects. You can still build a single query from two different relationships, like this:
Code:
$freight = new Freight();
$freight->distinct()->where_related_carrier($user)->or_where_related_creator($user)->get();
Alternatively, have you thought about having a single $has_many<->$has_many relationship and using join fields to define the type of relationship? (See Using Join Fields in the manual).
-------------------------
@tdktank59
Either you are not loading the object before you are saving it, or you are setting individual fields to NULL after loading it. DMZ only checks and saves the columns that have not changed since the last get or save.
-------------------------
General Update:
I have some updates to DMZ started, but I've been sick since last Thursday. If I can get over this, I'll got a new version of DMZ with a lot of performance-oriented changes and improvements out this week or next week.