The 'column' filed type can be used with HasMany fields to set the foreign key according to the readme. But if I get it right this isn't the case, as it uses 'model_id' as foreign key even when this value is set.
It seems this line is where a possible fix can be applied (I solved it by a simple if statement checking if the 'column' value is available and using it instead of $this->fk() if so):
http://github.com/shadowhand/sprig/blob/master/classes/sprig.php#L355
The 'column' filed type can be used with HasMany fields to set the foreign key according to the readme. But if I get it right this isn't the case, as it uses 'model_id' as foreign key even when this value is set.
It seems this line is where a possible fix can be applied (I solved it by a simple if statement checking if the 'column' value is available and using it instead of $this->fk() if so):
http://github.com/shadowhand/sprig/blob/master/classes/sprig.php#L355