Compare commits
2 Commits
29e4660cf6
...
0e6c40b8f9
| Author | SHA1 | Date |
|---|---|---|
|
|
0e6c40b8f9 | |
|
|
1f4ea58abe |
|
|
@ -20,7 +20,7 @@ class RiceShrimpWeeklyPriceUpdateRequest extends FormRequest
|
|||
'week' => [
|
||||
'filled',
|
||||
'int',
|
||||
Rule::exists(Keywords::class, 'id')->where(function ($query) {
|
||||
Rule::exists(Keywords::class, 'key')->where(function ($query) {
|
||||
return $query->where('type_key', 'weeks-per-year');
|
||||
}),
|
||||
],
|
||||
|
|
|
|||
|
|
@ -17,7 +17,7 @@ class RiceShrimpWeeklyPrice extends Model
|
|||
|
||||
public function weekObj()
|
||||
{
|
||||
return $this->belongsTo(Keywords::class, 'week');
|
||||
return $this->belongsTo(Keywords::class, 'week', 'key');
|
||||
}
|
||||
|
||||
public function createdBy()
|
||||
|
|
|
|||
Loading…
Reference in New Issue