Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: create ElementType #197

Merged
merged 4 commits into from
Dec 11, 2024
Merged

feat: create ElementType #197

merged 4 commits into from
Dec 11, 2024

Conversation

albert1413
Copy link
Contributor

@albert1413 albert1413 commented Dec 10, 2024

This pull request includes significant changes to the app/src/app directory, focusing on the addition of new fields and methods to various model classes and the creation of a new controller for managing element types.

New Controller:

Model Updates:

Data Mapping Enhancements:

  • Updated the mapDataToModel method in multiple model files to include updated_at and deleted_at fields:
    • Contract.php
    • Element.php
    • Incidence.php
    • Machine.php
    • Photo.php
    • Point.php
    • PruningType.php
    • Role.php
    • Route.php
    • Sensor.php
    • SensorHistory.php
    • Task.php
    • TaskType.php
    • TreeType.php
    • User.php
    • WorkOrder.php
    • WorkReport.php

Code Simplification:

@albert1413 albert1413 requested a review from a team as a code owner December 10, 2024 20:21
@github-actions github-actions bot added area/app/views Categorizes issue or PR as related to app/views. area/app/models Categorizes issue or PR as related to app/models. area/app/controllers Categorizes issue or PR as related to app/controllers. area/routes Categorizes issue or PR as related to routes or router. labels Dec 10, 2024
Copy link

codecov bot commented Dec 10, 2024

Codecov Report

Attention: Patch coverage is 0% with 224 lines in your changes missing coverage. Please review.

✅ All tests successful. No failed tests found.

Files with missing lines Patch % Lines
...rc/app/Controllers/Admin/ElementTypeController.php 0.00% 44 Missing ⚠️
app/src/app/Views/Admin/ElementType/Create.php 0.00% 36 Missing ⚠️
app/src/app/Views/Admin/ElementTypes.php 0.00% 32 Missing ⚠️
app/src/app/Models/BaseModel.php 0.00% 18 Missing ⚠️
app/src/app/Views/Admin/ElementType/Edit.php 0.00% 16 Missing ⚠️
app/src/app/Models/ElementType.php 0.00% 11 Missing ⚠️
app/src/app/Models/WorkReport.php 0.00% 9 Missing ⚠️
app/src/app/Models/ZonePredefined.php 0.00% 9 Missing ⚠️
app/src/app/Models/TaskType.php 0.00% 8 Missing ⚠️
app/src/app/Models/WorkOrder.php 0.00% 7 Missing ⚠️
... and 15 more
Additional details and impacted files
@@            Coverage Diff             @@
##              main    #197      +/-   ##
==========================================
- Coverage     5.75%   5.33%   -0.42%     
- Complexity     269     279      +10     
==========================================
  Files           86      91       +5     
  Lines         2347    2530     +183     
==========================================
  Hits           135     135              
- Misses        2212    2395     +183     
Files with missing lines Coverage Δ Complexity Δ
app/src/app/Models/Contract.php 0.00% <0.00%> (ø) 5.00 <0.00> (ø)
app/src/app/Models/Element.php 0.00% <0.00%> (ø) 5.00 <0.00> (ø)
app/src/app/Models/Incidence.php 0.00% <0.00%> (ø) 5.00 <0.00> (ø)
app/src/app/Models/Machine.php 0.00% <0.00%> (ø) 4.00 <0.00> (ø)
app/src/app/Models/Photo.php 0.00% <0.00%> (ø) 9.00 <0.00> (ø)
app/src/app/Models/Point.php 0.00% <0.00%> (ø) 2.00 <0.00> (ø)
app/src/app/Models/PruningType.php 0.00% <0.00%> (ø) 4.00 <0.00> (ø)
app/src/app/Models/Role.php 0.00% <0.00%> (ø) 2.00 <0.00> (ø)
app/src/app/Models/Route.php 0.00% <0.00%> (ø) 3.00 <0.00> (ø)
app/src/app/Models/SensorHistory.php 0.00% <0.00%> (ø) 3.00 <0.00> (ø)
... and 15 more

@0x1026 0x1026 added the kind/feature Categorizes issue or PR as related to a new feature. label Dec 10, 2024
app/src/routes/admin.php Outdated Show resolved Hide resolved
app/src/routes/admin.php Outdated Show resolved Hide resolved
app/src/app/Views/Admin/ElementTypes.php Outdated Show resolved Hide resolved
app/src/app/Views/Admin/ElementTypes.php Outdated Show resolved Hide resolved
app/src/app/Views/Admin/ElementTypes.php Outdated Show resolved Hide resolved
app/src/app/Controllers/Admin/ElementTypeController.php Outdated Show resolved Hide resolved
app/src/app/Controllers/Admin/ElementTypeController.php Outdated Show resolved Hide resolved
app/src/app/Controllers/Admin/ElementTypeController.php Outdated Show resolved Hide resolved
app/src/app/Controllers/Admin/ElementTypeController.php Outdated Show resolved Hide resolved
app/src/app/Controllers/Admin/ElementTypeController.php Outdated Show resolved Hide resolved
@github-actions github-actions bot removed the kind/feature Categorizes issue or PR as related to a new feature. label Dec 10, 2024
@0x1026 0x1026 added this to the Sprint 3 - Prototype milestone Dec 10, 2024
@0x1026 0x1026 requested a review from Copilot December 11, 2024 14:17

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot reviewed 26 out of 26 changed files in this pull request and generated no suggestions.

Co-authored-by: Hugoo <[email protected]>
Signed-off-by: albert1413 <[email protected]>
@albert1413 albert1413 merged commit ddab5b7 into main Dec 11, 2024
14 checks passed
@albert1413 albert1413 deleted the feat-elementType branch December 11, 2024 14:34
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area/app/controllers Categorizes issue or PR as related to app/controllers. area/app/models Categorizes issue or PR as related to app/models. area/app/views Categorizes issue or PR as related to app/views. area/routes Categorizes issue or PR as related to routes or router.
Projects
Status: Fet
Development

Successfully merging this pull request may close these issues.

2 participants