Skip to content

A free open source IT asset/license management system

add integration settings to company edit page

Godfrey M3489db24816b
diff --git a/app/Livewire/SlackSettingsForm.php b/app/Livewire/SlackSettingsForm.php
index 3f8933b226..11127c2182 100644
--- a/app/Livewire/SlackSettingsForm.php
+++ b/app/Livewire/SlackSettingsForm.php
@@ -83,6 +83,9 @@ class SlackSettingsForm extends Component
public function mount(?Company $company = null)
{
+ if ($company) {
+ $this->company = $company;
+ }
$this->authorizeWebhookManagement();
diff --git a/resources/lang/en-US/general.php b/resources/lang/en-US/general.php
index a339d98742..0275945237 100644
--- a/resources/lang/en-US/general.php
+++ b/resources/lang/en-US/general.php
@@ -373,6 +373,8 @@ return [
'signature' => 'Signature',
'signed_off_by' => 'Signed Off By',
'skin' => 'Skin',
+ 'integration_settings' => 'Integration Settings',
+ 'integration_settings_help' => 'Configure webhook integrations settings for this company.',
'webhook_msg_note' => 'A notification will be sent via webhook',
'webhook_test_msg' => 'Oh hai! It looks like your :app integration with Snipe-IT is working!',
'some_features_disabled' => 'DEMO MODE: Some features are disabled for this installation.',
diff --git a/resources/views/companies/edit.blade.php b/resources/views/companies/edit.blade.php
index 16643b5610..312267ddf3 100644
--- a/resources/views/companies/edit.blade.php
+++ b/resources/views/companies/edit.blade.php
@@ -74,6 +74,10 @@
/>
<x-input.image-upload :item="$item" :imagePath="app('companies_upload_path')" />
+ <x-form.legend help_text="{{trans('general.integration_settings_help')}}">
+ {{ trans('general.integration_settings') }}
+ </x-form.legend>
+ <livewire:slack-settings-form :company="$item"/>
<fieldset name="color-preferences">
<x-form.legend help_text="{{ trans('general.tag_color_help') }}">