master
cody 5 months ago
parent 3ba9d2b2a4
commit 94c2ec7d55

@ -31,6 +31,7 @@ class Orders extends SoftDeletesModel
*/
public function needAgreements()
{
dd($this->paramedic_id , $this->project->agreement);
if ($this->paramedic_id && $this->project->agreement == 1
&& strtotime($this->created_at) >= strtotime(Orders::AGREEMENT_START_DATE)
&& ($this->orderAgreementByLast()->isEmpty() || ($this->orderAgreementByLast()->isNotEmpty() && $this->orderAgreementByLast()->paramedic_id != $this->paramedic_id))) {

Loading…
Cancel
Save