Skip to content

WIP Label Editor#18938

Draft
Godmartinz wants to merge 71 commits into
grokability:developfrom
Godmartinz:Label_customization
Draft

WIP Label Editor#18938
Godmartinz wants to merge 71 commits into
grokability:developfrom
Godmartinz:Label_customization

adds translations to Create label modal

ba0c856
Select commit
Loading
Failed to load commit list.
Codacy Production / Codacy Static Code Analysis required action Jun 25, 2026 in 0s

22 new issues (0 max.) of at least severity.

Codacy Here is an overview of what got changed by this pull request:

Issues
======
+ Solved 2
- Added 22
           

Complexity increasing per file
==============================
- resources/assets/js/snipeit.js  78
- app/Models/Labels/Tapes/Brother/TZe_62mm_Landscape_A.php  29
- app/Models/Labels/Sheets/Avery/_3490_A.php  29
- app/Rules/UrlEncrypted.php  4
- app/Models/Labels/Tapes/Brother/TZe_24mm_E.php  30
- app/Models/Labels/Sheets/Avery/L7162_B.php  30
- app/Models/Labels/Tapes/Generic/Continuous_Landscape_0_59in_A.php  43
- app/Rules/IPv4Encrypted.php  4
- app/Console/Commands/LdapTroubleshooter.php  121
- routes/scim.php  1
- routes/web/kits.php  1
- routes/web.php  8
- app/Rules/DateEncrypted.php  4
- tests/Feature/Settings/ShowSetUpPageTest.php  34
- app/Models/Labels/RectangleSheet.php  14
- routes/web/components.php  1
- app/Presenters/ConsumablePresenter.php  4
- app/Http/Controllers/LabelsController.php  69
- app/Rules/EmailEncrypted.php  4
- app/Rules/ValidJson.php  2
- app/Services/Saml.php  42
- app/Services/PredefinedKitCheckoutService.php  32
- app/Rules/AlphaEncrypted.php  4
- app/Console/Commands/RestoreFromBackup.php  85
- routes/web/consumables.php  1
- app/Http/Controllers/Api/LabelsController.php  8
- app/Http/Transformers/LabelsTransformer.php  10
- app/Models/Labels/Tapes/Dymo/LabelWriter_1933081.php  32
- app/Models/Labels/Sheets/Avery/_5520_A.php  29
- app/Models/Labels/Label.php  103
- app/Models/Labels/Tapes/Brother/TZe_24mm_B.php  25
- app/Models/Setting.php  47
- routes/web/models.php  1
- app/Rules/IPEncrypted.php  4
- app/Rules/BooleanEncrypted.php  4
- database/factories/AssetFactory.php  95
- app/Models/Labels/Tapes/Brother/TZe_24mm_A.php  22
- upgrade.php  9
- app/Rules/UserCannotSwitchCompaniesIfItemsAssigned.php  5
- app/Models/Labels/Tapes/Generic/Tape_53mm_A.php  22
- app/Listeners/CheckoutablesCheckedOutInBulkListener.php  32
- app/Models/Labels/Tapes/Brother/TZe_24mm_D.php  26
- app/Models/Labels/Tapes/Dymo/LabelWriter_2112283.php  32
- app/Traits/DisablesDebugbar.php  2
- app/Models/Labels/DefaultLabel.php  51
- app/Presenters/LabelPresenter.php  1
- app/Models/Labels/Sheets/Avery/L4736_A.php  25
- app/Models/Labels/Sheets/Avery/L7162_A.php  25
- app/Rules/RegexEncrypted.php  4
- routes/web/locations.php  1
- app/Http/Requests/StoreLabelSettings.php  6
- app/Models/Labels/Sheets/Avery/L7163_A.php  34
- app/Models/Labels/Sheet.php  34
- app/Rules/UniqueUndeleted.php  5
- app/Models/Labels/Sheets/Avery/_5267_A.php  30
- app/Services/SnipeTranslator.php  7
- app/Models/Labels/Sheets/Avery/_5520_B.php  26
- database/migrations/2025_07_16_142036_clean_checkout_acceptances.php  2
- app/View/Label.php  55
- app/Models/Labels/Tapes/Dymo/LabelWriter_11354.php  34
- app/Rules/AssetCannotBeCheckedOutToNondeployableStatus.php  10
- routes/web/accessories.php  1
- app/Models/Labels/Tapes/Brother/TZe_18mm_A.php  15
- app/Presenters/MaintenancesPresenter.php  2
- app/Models/Labels/Sheets/Avery/L6009_A.php  25
- app/Rules/NumericEncrypted.php  4
- app/Models/Labels/Tapes/Brother/TZe_241.php  18
- app/Rules/IPv6Encrypted.php  4
- app/Models/Labels/Tapes/Brother/TZe_12mm_A.php  15
- routes/console.php  3
- routes/web/fields.php  1
- app/Rules/MacEncrypted.php  4
- app/Models/Labels/Tapes/Generic/Continuous_53mm_A.php  20
- app/Models/Labels/Tapes/Brother/TZe_24mm_C.php  23
- database/migrations/2026_04_07_141412_add_locations_parent_id_index.php  2
- database/migrations/2026_04_07_141930_accessories_checkout_assigned_to_index.php  2
- app/Models/Labels/CustomLabels/Concerns/HasCustomLabelContentProperties.php  29
- app/Models/Labels/CustomLabels/Concerns/HasCustomLabelSupports.php  12
- app/Models/Labels/CustomLabels/Concerns/HasCustomLabelEditorConfig.php  1
- app/Models/Labels/CustomLabels/Concerns/SeedsCustomLabelFromTemplate.php  32
- app/Models/Labels/CustomLabels/CustomSheetLabel.php  41
- app/Models/Labels/CustomUserLabel.php  30
- database/migrations/2026_03_23_184904_create_custom_labels_table.php  2
- app/Models/Labels/CustomLabels/CustomTapeLabel.php  70
- app/Models/Labels/CustomLabels/Concerns/RenderCustomLabelContent.php  89
- app/Http/Requests/ImportCustomLabelRequest.php  5
- app/Services/CustomLabelImportValidator.php  14
- app/Models/Labels/CustomLabels/Concerns/HasCustomLabelEditorSections.php  1
- app/Models/Labels/CustomLabels/Concerns/BuildsCustomLabelLayout.php  11
         

See the complete overview on Codacy

Annotations

Check notice on line 45 in app/Http/Controllers/LabelsController.php

See this annotation in the file changed.

@codacy-production codacy-production / Codacy Static Code Analysis

app/Http/Controllers/LabelsController.php#L45

The method show uses an else expression. Else clauses are basically not necessary and you can simplify the code by not using them.

Check warning on line 112 in app/Http/Controllers/LabelsController.php

See this annotation in the file changed.

@codacy-production codacy-production / Codacy Static Code Analysis

app/Http/Controllers/LabelsController.php#L112

The method update() has 100 lines of code. Current threshold is set to 100. Avoid really long methods.

Check warning on line 313 in app/Http/Controllers/LabelsController.php

See this annotation in the file changed.

@codacy-production codacy-production / Codacy Static Code Analysis

app/Http/Controllers/LabelsController.php#L313

The method create() has 106 lines of code. Current threshold is set to 100. Avoid really long methods.

Check warning on line 12 in app/Models/Labels/CustomLabels/Concerns/HasCustomLabelEditorSections.php

See this annotation in the file changed.

@codacy-production codacy-production / Codacy Static Code Analysis

app/Models/Labels/CustomLabels/Concerns/HasCustomLabelEditorSections.php#L12

The method editorSections() has 165 lines of code. Current threshold is set to 100. Avoid really long methods.

Check warning on line 232 in app/Models/Labels/CustomLabels/Concerns/RenderCustomLabelContent.php

See this annotation in the file changed.

@codacy-production codacy-production / Codacy Static Code Analysis

app/Models/Labels/CustomLabels/Concerns/RenderCustomLabelContent.php#L232

Avoid unused parameters such as '$record'.

Check warning on line 282 in app/Models/Labels/CustomLabels/Concerns/RenderCustomLabelContent.php

See this annotation in the file changed.

@codacy-production codacy-production / Codacy Static Code Analysis

app/Models/Labels/CustomLabels/Concerns/RenderCustomLabelContent.php#L282

The method resolveTextBox() has an NPath complexity of 292. The configured NPath complexity threshold is 200.

Check warning on line 387 in app/Models/Labels/CustomLabels/Concerns/RenderCustomLabelContent.php

See this annotation in the file changed.

@codacy-production codacy-production / Codacy Static Code Analysis

app/Models/Labels/CustomLabels/Concerns/RenderCustomLabelContent.php#L387

Avoid unused parameters such as '$logoBox'.

Check warning on line 430 in app/Models/Labels/CustomLabels/Concerns/RenderCustomLabelContent.php

See this annotation in the file changed.

@codacy-production codacy-production / Codacy Static Code Analysis

app/Models/Labels/CustomLabels/Concerns/RenderCustomLabelContent.php#L430

Avoid unused parameters such as '$record'.

Check warning on line 444 in app/Models/Labels/CustomLabels/Concerns/RenderCustomLabelContent.php

See this annotation in the file changed.

@codacy-production codacy-production / Codacy Static Code Analysis

app/Models/Labels/CustomLabels/Concerns/RenderCustomLabelContent.php#L444

Avoid unused parameters such as '$record'.

Check warning on line 96 in app/Models/Labels/CustomLabels/Concerns/SeedsCustomLabelFromTemplate.php

See this annotation in the file changed.

@codacy-production codacy-production / Codacy Static Code Analysis

app/Models/Labels/CustomLabels/Concerns/SeedsCustomLabelFromTemplate.php#L96

The method seedLegacyContentFromTemplate() has an NPath complexity of 256. The configured NPath complexity threshold is 200.

Check warning on line 15 in app/Models/Labels/CustomLabels/CustomSheetLabel.php

See this annotation in the file changed.

@codacy-production codacy-production / Codacy Static Code Analysis

app/Models/Labels/CustomLabels/CustomSheetLabel.php#L15

The class CustomSheetLabel has 20 fields. Consider redesigning CustomSheetLabel to keep the number of fields under 15.

Check warning on line 234 in app/Models/Labels/CustomLabels/CustomSheetLabel.php

See this annotation in the file changed.

@codacy-production codacy-production / Codacy Static Code Analysis

app/Models/Labels/CustomLabels/CustomSheetLabel.php#L234

The method buildLayout() has 115 lines of code. Current threshold is set to 100. Avoid really long methods.

Check warning on line 15 in app/Models/Labels/CustomLabels/CustomTapeLabel.php

See this annotation in the file changed.

@codacy-production codacy-production / Codacy Static Code Analysis

app/Models/Labels/CustomLabels/CustomTapeLabel.php#L15

The class CustomTapeLabel has 11 non-getter- and setter-methods. Consider refactoring CustomTapeLabel to keep number of methods under 10.

Check warning on line 15 in app/Models/Labels/CustomLabels/CustomTapeLabel.php

See this annotation in the file changed.

@codacy-production codacy-production / Codacy Static Code Analysis

app/Models/Labels/CustomLabels/CustomTapeLabel.php#L15

The class CustomTapeLabel has an overall complexity of 58 which is very high. The configured complexity threshold is 50.

Check warning on line 221 in app/Models/Labels/CustomLabels/CustomTapeLabel.php

See this annotation in the file changed.

@codacy-production codacy-production / Codacy Static Code Analysis

app/Models/Labels/CustomLabels/CustomTapeLabel.php#L221

The method buildLayout() has 180 lines of code. Current threshold is set to 100. Avoid really long methods.

Check warning on line 221 in app/Models/Labels/CustomLabels/CustomTapeLabel.php

See this annotation in the file changed.

@codacy-production codacy-production / Codacy Static Code Analysis

app/Models/Labels/CustomLabels/CustomTapeLabel.php#L221

The method buildLayout() has an NPath complexity of 360. The configured NPath complexity threshold is 200.

Check notice on line 250 in app/Models/Labels/CustomLabels/CustomTapeLabel.php

See this annotation in the file changed.

@codacy-production codacy-production / Codacy Static Code Analysis

app/Models/Labels/CustomLabels/CustomTapeLabel.php#L250

The method buildLayout uses an else expression. Else clauses are basically not necessary and you can simplify the code by not using them.

Check warning on line 450 in app/Models/Labels/CustomLabels/CustomTapeLabel.php

See this annotation in the file changed.

@codacy-production codacy-production / Codacy Static Code Analysis

app/Models/Labels/CustomLabels/CustomTapeLabel.php#L450

Avoid unused parameters such as '$record'.

Check notice on line 55 in app/Models/Labels/CustomUserLabel.php

See this annotation in the file changed.

@codacy-production codacy-production / Codacy Static Code Analysis

app/Models/Labels/CustomUserLabel.php#L55

The method availableBaseLabels uses an else expression. Else clauses are basically not necessary and you can simplify the code by not using them.

Check warning on line 189 in app/Services/CustomLabelImportValidator.php

See this annotation in the file changed.

@codacy-production codacy-production / Codacy Static Code Analysis

app/Services/CustomLabelImportValidator.php#L189

The method attributes() has 123 lines of code. Current threshold is set to 100. Avoid really long methods.

Check notice on line 70 in app/View/Label.php

See this annotation in the file changed.

@codacy-production codacy-production / Codacy Static Code Analysis

app/View/Label.php#L70

The method render uses an else expression. Else clauses are basically not necessary and you can simplify the code by not using them.

Check warning on line 19 in upgrade.php

See this annotation in the file changed.

@codacy-production codacy-production / Codacy Static Code Analysis

upgrade.php#L19

The function url_get_contents() contains an exit expression.