убрал дублирование уведомлений об уникальности в карточке договора
This commit is contained in:
parent
52b2861b18
commit
aeed371355
@ -57,11 +57,9 @@ public function confirmDeal(Deal $deal, Request $request)
|
|||||||
$deal->unique_until = $request->unique_until;
|
$deal->unique_until = $request->unique_until;
|
||||||
}
|
}
|
||||||
$agent->user->notify(new UniqueContact($deal));
|
$agent->user->notify(new UniqueContact($deal));
|
||||||
$deal->notify(new DealUnique());
|
|
||||||
} else {
|
} else {
|
||||||
$deal->status = DealStatus::NOT_UNIQUE;
|
$deal->status = DealStatus::NOT_UNIQUE;
|
||||||
$agent->user->notify(new NotUniqueContact($deal));
|
$agent->user->notify(new NotUniqueContact($deal));
|
||||||
$deal->notify(new DealNotUnique());
|
|
||||||
}
|
}
|
||||||
|
|
||||||
if (!$agent->bitrixId()) {
|
if (!$agent->bitrixId()) {
|
||||||
|
|||||||
@ -38,7 +38,7 @@ protected function rules()
|
|||||||
return [
|
return [
|
||||||
'contacts.*' => ['required', 'min:1'],
|
'contacts.*' => ['required', 'min:1'],
|
||||||
'contacts.*.firstName' => ['required', 'string', 'max:50'],
|
'contacts.*.firstName' => ['required', 'string', 'max:50'],
|
||||||
'contacts.*.secondName' => ['required', 'string', 'max:50'],
|
'contacts.*.secondName' => ['string', 'max:50'],
|
||||||
'contacts.*.phones.*' => 'required|string|regex:/^(\+7)([(]{1})([0-9]{3})([)]{1})([\s]{1})([0-9]{3})([-]{1})([0-9]{2})([-]{1})([0-9]{2})/',
|
'contacts.*.phones.*' => 'required|string|regex:/^(\+7)([(]{1})([0-9]{3})([)]{1})([\s]{1})([0-9]{3})([-]{1})([0-9]{2})([-]{1})([0-9]{2})/',
|
||||||
'selectedObjects' => 'required',
|
'selectedObjects' => 'required',
|
||||||
'agentId' => ['required'],
|
'agentId' => ['required'],
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user