Clean up kind handling in the front

This commit is contained in:
Zoe Roux
2023-12-18 15:03:04 +01:00
parent 7b035411c0
commit 2e0a0e5eb0
25 changed files with 78 additions and 117 deletions
@@ -17,7 +17,6 @@
// along with Kyoo. If not, see <https://www.gnu.org/licenses/>.
using System;
using System.Collections.Generic;
using System.ComponentModel.DataAnnotations;
using Kyoo.Abstractions.Controllers;
using Kyoo.Abstractions.Models.Attributes;
@@ -18,7 +18,6 @@
using System;
using System.Linq;
using System.Security.Claims;
using System.Threading.Tasks;
using Kyoo.Abstractions.Controllers;
using Kyoo.Abstractions.Models;
@@ -25,6 +25,7 @@ using Kyoo.Abstractions.Models.Attributes;
using Microsoft.AspNetCore.Http;
using Newtonsoft.Json;
using Newtonsoft.Json.Serialization;
using static System.Text.Json.JsonNamingPolicy;
namespace Kyoo.Core.Api
{
@@ -99,7 +100,7 @@ namespace Kyoo.Core.Api
PropertyName = "kind",
UnderlyingName = "kind",
PropertyType = typeof(string),
ValueProvider = new FixedValueProvider(type.Name),
ValueProvider = new FixedValueProvider(CamelCase.ConvertName(type.Name)),
Readable = true,
Writable = false,
TypeNameHandling = TypeNameHandling.None,