Compare commits
No commits in common. "85922bdac0ece5dd55afdc5ef48798b7ac67368f" and "3291e9b439f4d56dd52fcbbe8b21ed55e5909cb7" have entirely different histories.
85922bdac0
...
3291e9b439
|
|
@ -171,6 +171,13 @@ public function store(Request $request)
|
||||||
if ($paymentsImport) {
|
if ($paymentsImport) {
|
||||||
$entities = ['contracts', 'accounts', 'payments'];
|
$entities = ['contracts', 'accounts', 'payments'];
|
||||||
}
|
}
|
||||||
|
if (in_array('activities', $entities, true)) {
|
||||||
|
$actionId = data_get($data, 'meta.activity_action_id');
|
||||||
|
$decisionId = data_get($data, 'meta.activity_decision_id');
|
||||||
|
if (! $actionId || ! $decisionId) {
|
||||||
|
abort(422, 'Activities import requires selecting both a default action and decision.');
|
||||||
|
}
|
||||||
|
}
|
||||||
$template = ImportTemplate::create([
|
$template = ImportTemplate::create([
|
||||||
'uuid' => (string) Str::uuid(),
|
'uuid' => (string) Str::uuid(),
|
||||||
'name' => $data['name'],
|
'name' => $data['name'],
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue
Block a user