Little test with AI + Add the equipment (#8)

Tests using local LLM AI to add comments in the C# files
For the flights tunnel, show the total to day/hours
For the jump, add the equipment (now just with the wingsuit)

Reviewed-on: #8
Co-authored-by: sandre <perso@sebastienandre.com>
Co-committed-by: sandre <perso@sebastienandre.com>
This commit was merged in pull request #8.
This commit is contained in:
2026-05-16 09:24:13 +00:00
committed by sandre
parent 0ebdbca549
commit ceed44f997
70 changed files with 12142 additions and 10444 deletions
@@ -1,10 +1,10 @@
using AutoMapper;
using System.Collections.Generic;
using AutoMapper;
using Microsoft.AspNetCore.Cors;
using Microsoft.AspNetCore.Mvc;
using skydiveLogs_api.DataContract;
using skydiveLogs_api.Domain;
using skydiveLogs_api.DomainBusiness.Interfaces;
using System.Collections.Generic;
namespace skydiveLogs_api.Controllers
{
@@ -23,7 +23,10 @@ namespace skydiveLogs_api.Controllers
#region Public Methods
// DELETE: api/ApiWithActions/5
/// <summary>
/// Deletes a gear item by its ID.
/// </summary>
/// <param name="id">The gear ID to delete.</param>
[HttpDelete("{id}")]
[EnableCors]
public void Delete(int id)
@@ -31,17 +34,23 @@ namespace skydiveLogs_api.Controllers
_gearService.DeleteGearById(id);
}
// GET: api/Gear
/// <summary>
/// Retrieves a list of all gear items.
/// </summary>
/// <returns>A collection of GearResp objects containing all gear data.</returns>
[HttpGet]
[EnableCors]
public IEnumerable<GearResp> Get()
{
//var result = _gearService.GetAllGears(ConnectedUser);
var result = _gearService.GetAllGears();
return _mapper.Map<IEnumerable<GearResp>>(result);
}
// GET: api/Gear/5
/// <summary>
/// Retrieves a gear item by its ID.
/// </summary>
/// <param name="id">The gear ID to retrieve.</param>
/// <returns>A GearResp object containing the gear details.</returns>
[HttpGet("{id}")]
[EnableCors]
public GearResp Get(int id)
@@ -50,7 +59,10 @@ namespace skydiveLogs_api.Controllers
return _mapper.Map<GearResp>(result);
}
// POST: api/Gear
/// <summary>
/// Adds a new gear item to the system.
/// </summary>
/// <param name="value">GearReq object containing the new gear data.</param>
[HttpPost]
[EnableCors]
public void Post([FromBody] GearReq value)
@@ -58,7 +70,11 @@ namespace skydiveLogs_api.Controllers
_gearService.AddNewGear(_mapper.Map<Gear>(value));
}
// PUT: api/Gear/5
/// <summary>
/// Updates an existing gear item.
/// </summary>
/// <param name="id">The gear ID to update.</param>
/// <param name="value">GearReq object containing the updated gear data.</param>
[HttpPut("{id}")]
[EnableCors]
public void Put(int id, [FromBody] GearReq value)
@@ -76,4 +92,4 @@ namespace skydiveLogs_api.Controllers
#endregion Private Fields
}
}
}