Let the statisticsForms model return the total signups instead of the form model
- added unit test for getTotalSignups() method
This commit is contained in:
@ -39,11 +39,6 @@ class Form extends Model {
|
||||
return parent::save();
|
||||
}
|
||||
|
||||
function withSignups() {
|
||||
$this->signups = StatisticsForms::where('form_id', $this->id)->count();
|
||||
return $this;
|
||||
}
|
||||
|
||||
static function search($orm, $search = '') {
|
||||
return $orm->whereLike('name', '%'.$search.'%');
|
||||
}
|
||||
|
Reference in New Issue
Block a user