Merge branch 'develop' into features/import_models

This commit is contained in:
snipe 2024-11-13 15:51:36 +00:00 committed by GitHub
commit 220902a8b4
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
4 changed files with 41 additions and 39 deletions

View file

@ -117,6 +117,7 @@ class Importer extends Component
public function updatingTypeOfImport($type) public function updatingTypeOfImport($type)
{ {
// go through each header, find a matching field to try and map it to. // go through each header, find a matching field to try and map it to.
foreach ($this->headerRow as $i => $header) { foreach ($this->headerRow as $i => $header) {
// do we have something mapped already? // do we have something mapped already?
@ -552,7 +553,6 @@ class Importer extends Component
$this->field_map = null; $this->field_map = null;
foreach ($this->headerRow as $element) { foreach ($this->headerRow as $element) {
if (isset($this->activeFile->field_map[$element])) { if (isset($this->activeFile->field_map[$element])) {
$this->field_map[] = $this->activeFile->field_map[$element]; $this->field_map[] = $this->activeFile->field_map[$element];
} else { } else {
@ -595,8 +595,6 @@ class Importer extends Component
$this->message = trans('admin/hardware/message.import.file_delete_error'); $this->message = trans('admin/hardware/message.import.file_delete_error');
$this->message_type = 'danger'; $this->message_type = 'danger';
} }
public function clearMessage() public function clearMessage()

View file

@ -117,6 +117,9 @@ class SlackSettingsForm extends Component
public function updatedwebhookEndpoint() { public function updatedwebhookEndpoint() {
$this->teams_webhook_deprecated = !Str::contains($this->webhook_endpoint, 'workflows'); $this->teams_webhook_deprecated = !Str::contains($this->webhook_endpoint, 'workflows');
} }
public function updatedwebhookEndpoint() {
$this->teams_webhook_deprecated = !Str::contains($this->webhook_endpoint, 'workflows');
}
private function isButtonDisabled() { private function isButtonDisabled() {
if (empty($this->webhook_endpoint)) { if (empty($this->webhook_endpoint)) {

View file

@ -145,6 +145,7 @@ class ImportFactory extends Factory
} }
/** /**
* Create an asset model import type. * Create an asset model import type.
* *