Commit before anti gravity ! :)

This commit is contained in:
Thomas Fransolet 2026-02-27 13:52:54 +01:00
parent d212f9f31c
commit 9e06afb29e
20 changed files with 67 additions and 38 deletions

View File

@ -15,7 +15,7 @@ class CheckInputContainer extends StatefulWidget {
this.icon, this.icon,
required this.label, required this.label,
required this.onChanged, required this.onChanged,
this.fontSize = 20 this.fontSize = 18
}) : super(key: key); }) : super(key: key);
@override @override
@ -51,12 +51,9 @@ class _CheckInputContainerState extends State<CheckInputContainer> {
size: 25.0, size: 25.0,
), ),
), ),
AutoSizeText( Text(
widget.label, widget.label,
style: new TextStyle(fontSize: widget.fontSize, fontWeight: FontWeight.w300), style: new TextStyle(fontSize: widget.fontSize, fontWeight: FontWeight.w300)
maxLines: 2,
maxFontSize: widget.fontSize,
textAlign: TextAlign.center,
), ),
], ],
) )

View File

@ -6,6 +6,7 @@ class DropDownInputContainer extends StatefulWidget {
final List<String> values; final List<String> values;
final String? initialValue; final String? initialValue;
final ValueChanged<String>? onChange; final ValueChanged<String>? onChange;
final double fontSize;
const DropDownInputContainer({ const DropDownInputContainer({
Key? key, Key? key,
@ -13,6 +14,7 @@ class DropDownInputContainer extends StatefulWidget {
required this.values, required this.values,
this.initialValue, this.initialValue,
this.onChange, this.onChange,
this.fontSize = 18,
}) : super(key: key); }) : super(key: key);
@override @override
@ -36,7 +38,7 @@ class _DropDownInputContainerState extends State<DropDownInputContainer> {
alignment: AlignmentDirectional.centerStart, alignment: AlignmentDirectional.centerStart,
child: Text( child: Text(
widget.label, widget.label,
style: TextStyle(fontSize: 25, fontWeight: FontWeight.w300), style: TextStyle(fontSize: widget.fontSize, fontWeight: FontWeight.w300),
), ),
), ),
Padding( Padding(

View File

@ -22,7 +22,7 @@ class GeolocInputContainer extends StatefulWidget {
required this.initialValue, required this.initialValue,
required this.onChanged, required this.onChanged,
this.isSmall = false, this.isSmall = false,
this.fontSize = 25, this.fontSize = 18,
this.fontSizeText = 20, this.fontSizeText = 20,
}) : super(key: key); }) : super(key: key);
@ -43,12 +43,9 @@ class _GeolocInputContainerState extends State<GeolocInputContainer> {
children: [ children: [
Align( Align(
alignment: AlignmentDirectional.centerStart, alignment: AlignmentDirectional.centerStart,
child: AutoSizeText( child: Text(
widget.label, widget.label,
style: TextStyle(fontSize: widget.fontSize, fontWeight: FontWeight.w300), style: TextStyle(fontSize: widget.fontSize, fontWeight: FontWeight.w300),
maxLines: 2,
maxFontSize: widget.fontSize,
textAlign: TextAlign.center,
), ),
), ),
Padding( Padding(

View File

@ -50,9 +50,9 @@ class MultiStringInputContainer extends StatelessWidget {
alignment: AlignmentDirectional.centerStart, alignment: AlignmentDirectional.centerStart,
child: Text( child: Text(
label, label,
style: const TextStyle( style: TextStyle(
fontWeight: FontWeight.w400, fontWeight: FontWeight.w400,
fontSize: 16, fontSize: fontSize,
), ),
), ),
), ),

View File

@ -22,7 +22,7 @@ class NumberInputContainer extends StatelessWidget {
this.isUrl = false, this.isUrl = false,
this.isSmall = false, this.isSmall = false,
this.maxLength = 50, this.maxLength = 50,
this.fontSize = 25, this.fontSize = 18.0,
this.fontSizeText = 20, this.fontSizeText = 20,
}) : super(key: key); }) : super(key: key);
@ -34,12 +34,9 @@ class NumberInputContainer extends StatelessWidget {
children: [ children: [
Align( Align(
alignment: AlignmentDirectional.centerStart, alignment: AlignmentDirectional.centerStart,
child: AutoSizeText( child: Text(
label, label,
style: TextStyle(fontSize: fontSize, fontWeight: FontWeight.w300), style: TextStyle(fontSize: fontSize, fontWeight: FontWeight.w300),
maxLines: 2,
maxFontSize: fontSize,
textAlign: TextAlign.center,
), ),
), ),
Padding( Padding(

View File

@ -11,12 +11,14 @@ class PDFFileInputContainer extends StatefulWidget {
final String label; final String label;
List<OrderedTranslationAndResourceDTO> initialValue; List<OrderedTranslationAndResourceDTO> initialValue;
final ValueChanged<List<OrderedTranslationAndResourceDTO>> onChanged; final ValueChanged<List<OrderedTranslationAndResourceDTO>> onChanged;
final double fontSize;
PDFFileInputContainer({ PDFFileInputContainer({
Key? key, Key? key,
this.color = kSecond, this.color = kSecond,
required this.label, required this.label,
required this.initialValue, required this.initialValue,
required this.onChanged, required this.onChanged,
this.fontSize = 18.0,
}) : super(key: key); }) : super(key: key);
@override @override
@ -39,12 +41,12 @@ class _PDFFileInputContainerState extends State<PDFFileInputContainer> {
children: [ children: [
Align( Align(
alignment: AlignmentDirectional.centerStart, alignment: AlignmentDirectional.centerStart,
child: Text(widget.label, style: TextStyle(fontSize: 25, fontWeight: FontWeight.w300)) child: Text(widget.label, style: TextStyle(fontSize: widget.fontSize, fontWeight: FontWeight.w300))
), ),
Padding( Padding(
padding: const EdgeInsets.all(8.0), padding: const EdgeInsets.all(8.0),
child: Container( child: Container(
width: size.width *0.15, width: size.width *0.16,
child: InkWell( child: InkWell(
onTap: () { onTap: () {
List<OrderedTranslationAndResourceDTO> newValues = <OrderedTranslationAndResourceDTO>[]; List<OrderedTranslationAndResourceDTO> newValues = <OrderedTranslationAndResourceDTO>[];

View File

@ -58,9 +58,9 @@ class _ResourceInputContainerState extends State<ResourceInputContainer> {
alignment: AlignmentDirectional.centerStart, alignment: AlignmentDirectional.centerStart,
child: Text( child: Text(
widget.label, widget.label,
style: const TextStyle( style: TextStyle(
fontWeight: FontWeight.w400, fontWeight: FontWeight.w400,
fontSize: 16, fontSize: widget.fontSize,
), ),
), ),
), ),

View File

@ -17,7 +17,7 @@ class SingleSelectContainer extends StatefulWidget {
this.initialValue = "", this.initialValue = "",
required this.inputValues, required this.inputValues,
this.onChanged, this.onChanged,
this.fontSize = 25, this.fontSize = 18,
this.fontSizeText = 20, this.fontSizeText = 20,
}) : super(key: key); }) : super(key: key);
@ -43,12 +43,9 @@ class _SingleSelectContainerState extends State<SingleSelectContainer> {
children: [ children: [
Align( Align(
alignment: AlignmentDirectional.centerStart, alignment: AlignmentDirectional.centerStart,
child: AutoSizeText( child: Text(
widget.label, widget.label,
style: TextStyle(fontSize: widget.fontSize, fontWeight: FontWeight.w300), style: TextStyle(fontSize: widget.fontSize, fontWeight: FontWeight.w300),
maxLines: 2,
maxFontSize: widget.fontSize,
textAlign: TextAlign.center,
), ),
), ),
Padding( Padding(

View File

@ -8,6 +8,7 @@ class SliderInputContainer extends StatefulWidget {
final int min; final int min;
final int max; final int max;
final ValueChanged<double> onChanged; final ValueChanged<double> onChanged;
final double fontSize;
const SliderInputContainer({ const SliderInputContainer({
Key? key, Key? key,
this.color = kSecond, this.color = kSecond,
@ -16,6 +17,7 @@ class SliderInputContainer extends StatefulWidget {
required this.min, required this.min,
required this.max, required this.max,
required this.onChanged, required this.onChanged,
this.fontSize = 18.0,
}) : super(key: key); }) : super(key: key);
@override @override
@ -38,7 +40,7 @@ class _SliderInputContainerState extends State<SliderInputContainer> {
children: [ children: [
Align( Align(
alignment: AlignmentDirectional.centerStart, alignment: AlignmentDirectional.centerStart,
child: Text(widget.label, style: TextStyle(fontSize: 25, fontWeight: FontWeight.w300)) child: Text(widget.label, style: TextStyle(fontSize: widget.fontSize, fontWeight: FontWeight.w300))
), ),
Padding( Padding(
padding: const EdgeInsets.all(10.0), padding: const EdgeInsets.all(10.0),

View File

@ -1,5 +1,6 @@
import 'package:flutter/cupertino.dart'; import 'package:flutter/cupertino.dart';
import 'package:flutter/material.dart'; import 'package:flutter/material.dart';
import 'package:manager_app/Components/check_input_container.dart';
import 'package:manager_app/Components/multi_string_input_container.dart'; import 'package:manager_app/Components/multi_string_input_container.dart';
import 'package:manager_app/Components/resource_input_container.dart'; import 'package:manager_app/Components/resource_input_container.dart';
import 'package:manager_api_new/api.dart'; import 'package:manager_api_new/api.dart';
@ -60,6 +61,16 @@ class _AgendaConfigState extends State<AgendaConfig> {
child: Row( child: Row(
mainAxisAlignment: MainAxisAlignment.spaceAround, mainAxisAlignment: MainAxisAlignment.spaceAround,
children: [ children: [
CheckInputContainer(
label: "En ligne :",
isChecked: agendaDTO.isOnlineAgenda!,
onChanged: (value) {
setState(() {
agendaDTO.isOnlineAgenda = value;
widget.onChanged(agendaDTO);
});
},
),
SingleSelectContainer( SingleSelectContainer(
label: "Service carte :", label: "Service carte :",
color: Colors.black, color: Colors.black,

View File

@ -10,12 +10,14 @@ class CategoryInputContainer extends StatefulWidget {
final String label; final String label;
List<CategorieDTO> initialValue; List<CategorieDTO> initialValue;
final ValueChanged<List<CategorieDTO>> onChanged; final ValueChanged<List<CategorieDTO>> onChanged;
final double fontSize;
CategoryInputContainer({ CategoryInputContainer({
Key? key, Key? key,
this.color = kSecond, this.color = kSecond,
required this.label, required this.label,
required this.initialValue, required this.initialValue,
required this.onChanged, required this.onChanged,
this.fontSize = 18,
}) : super(key: key); }) : super(key: key);
@override @override
@ -40,7 +42,7 @@ class _CategoryInputContainerState extends State<CategoryInputContainer> {
children: [ children: [
Align( Align(
alignment: AlignmentDirectional.centerStart, alignment: AlignmentDirectional.centerStart,
child: Text(widget.label, style: TextStyle(fontSize: 25, fontWeight: FontWeight.w300)) child: Text(widget.label, style: TextStyle(fontSize: widget.fontSize, fontWeight: FontWeight.w300))
), ),
Padding( Padding(
padding: const EdgeInsets.all(8.0), padding: const EdgeInsets.all(8.0),

View File

@ -131,9 +131,10 @@ class _MapConfigState extends State<MapConfig> {
child: Column( child: Column(
children: [ children: [
Container( Container(
height: size.height * 0.3, height: size.height * 0.25,
width: double.infinity, width: double.infinity,
child: Column( child: Column(
mainAxisAlignment: MainAxisAlignment.spaceEvenly,
children: [ children: [
Row( Row(
mainAxisAlignment: MainAxisAlignment.spaceAround, mainAxisAlignment: MainAxisAlignment.spaceAround,

View File

@ -108,7 +108,7 @@ class _MenuConfigState extends State<MenuConfig> {
} else { } else {
if (snapshot.connectionState == ConnectionState.done) { if (snapshot.connectionState == ConnectionState.done) {
var rawList = snapshot.data; var rawList = snapshot.data;
rawSubsections = jsonDecode(jsonEncode(snapshot.data)); rawSubsections = snapshot.data != null ? jsonDecode(jsonEncode(snapshot.data)) : [];
rawSubsections = rawSubsections.map((json) => SectionDTO.fromJson(json)).toList(); rawSubsections = rawSubsections.map((json) => SectionDTO.fromJson(json)).toList();
List<SectionDTO> sectionList = rawSubsections.whereType<SectionDTO>().toList(); List<SectionDTO> sectionList = rawSubsections.whereType<SectionDTO>().toList();
@ -166,6 +166,7 @@ class _MenuConfigState extends State<MenuConfig> {
{ {
newSubsection.instanceId = (appContext.getContext() as ManagerAppContext).instanceId; newSubsection.instanceId = (appContext.getContext() as ManagerAppContext).instanceId;
newSubsection.isBeacon = false; newSubsection.isBeacon = false;
newSubsection.isActive = true;
await (appContext.getContext() as ManagerAppContext).clientAPI!.sectionApi!.sectionCreate(newSubsection); await (appContext.getContext() as ManagerAppContext).clientAPI!.sectionApi!.sectionCreate(newSubsection);
showNotification(kSuccess, kWhite, 'La sous section a été créée avec succès', context, null); showNotification(kSuccess, kWhite, 'La sous section a été créée avec succès', context, null);
setState(() { setState(() {

View File

@ -39,7 +39,7 @@ class _PDFConfigState extends State<PDFConfig> {
return Center( return Center(
child: Container( child: Container(
height: 70, height: 70,
width: 425, width: 440,
child: PDFFileInputContainer( child: PDFFileInputContainer(
label: "Fichiers PDF :", label: "Fichiers PDF :",
initialValue: pdfDTO.pdfs != null ? pdfDTO.pdfs! : [], initialValue: pdfDTO.pdfs != null ? pdfDTO.pdfs! : [],

View File

@ -214,7 +214,6 @@ class _SectionDetailScreenState extends State<SectionDetailScreen> {
CheckInputContainer( CheckInputContainer(
label: "Beacon :", label: "Beacon :",
isChecked: sectionDTO.isBeacon!, isChecked: sectionDTO.isBeacon!,
fontSize: 25,
onChanged: (value) { onChanged: (value) {
setState(() { setState(() {
sectionDTO.isBeacon = value; sectionDTO.isBeacon = value;

View File

@ -1,4 +1,4 @@
// Openapi Generator last run: : 2025-11-27T16:46:46.408321 // Openapi Generator last run: : 2026-02-27T13:23:36.794687
import 'package:openapi_generator_annotations/openapi_generator_annotations.dart'; import 'package:openapi_generator_annotations/openapi_generator_annotations.dart';
@Openapi( @Openapi(

View File

@ -4,7 +4,7 @@
"info": { "info": {
"title": "Manager Service", "title": "Manager Service",
"description": "API Manager Service", "description": "API Manager Service",
"version": "Version Alpha 0.0" "version": "Version Alpha"
}, },
"servers": [ "servers": [
{ {
@ -8275,6 +8275,9 @@
"type": "object", "type": "object",
"additionalProperties": false, "additionalProperties": false,
"properties": { "properties": {
"isOnlineAgenda": {
"type": "boolean"
},
"resourceIds": { "resourceIds": {
"type": "array", "type": "array",
"nullable": true, "nullable": true,

View File

@ -3,7 +3,7 @@ API Manager Service
This Dart package is automatically generated by the [OpenAPI Generator](https://openapi-generator.tech) project: This Dart package is automatically generated by the [OpenAPI Generator](https://openapi-generator.tech) project:
- API version: Version Alpha 0.0 - API version: Version Alpha
- Generator version: 7.9.0 - Generator version: 7.9.0
- Build package: org.openapitools.codegen.languages.DartClientCodegen - Build package: org.openapitools.codegen.languages.DartClientCodegen

View File

@ -27,6 +27,7 @@ Name | Type | Description | Notes
**meterZoneGPS** | **int** | | [optional] **meterZoneGPS** | **int** | | [optional]
**isBeacon** | **bool** | | [optional] **isBeacon** | **bool** | | [optional]
**beaconId** | **int** | | [optional] **beaconId** | **int** | | [optional]
**isOnlineAgenda** | **bool** | | [optional]
**resourceIds** | [**List<TranslationDTO>**](TranslationDTO.md) | | [optional] [default to const []] **resourceIds** | [**List<TranslationDTO>**](TranslationDTO.md) | | [optional] [default to const []]
**agendaMapProvider** | [**AgendaDTOAllOfAgendaMapProvider**](AgendaDTOAllOfAgendaMapProvider.md) | | [optional] **agendaMapProvider** | [**AgendaDTOAllOfAgendaMapProvider**](AgendaDTOAllOfAgendaMapProvider.md) | | [optional]
**events** | [**List<EventAgendaDTO>**](EventAgendaDTO.md) | | [optional] [default to const []] **events** | [**List<EventAgendaDTO>**](EventAgendaDTO.md) | | [optional] [default to const []]

View File

@ -32,6 +32,7 @@ class AgendaDTO {
this.meterZoneGPS, this.meterZoneGPS,
this.isBeacon, this.isBeacon,
this.beaconId, this.beaconId,
this.isOnlineAgenda,
this.resourceIds = const [], this.resourceIds = const [],
this.agendaMapProvider, this.agendaMapProvider,
this.events = const [], this.events = const [],
@ -99,6 +100,14 @@ class AgendaDTO {
int? beaconId; int? beaconId;
///
/// Please note: This property should have been non-nullable! Since the specification file
/// does not include a default value (using the "default:" property), however, the generated
/// source code must fall back to having a nullable type.
/// Consider adding a "default:" property in the specification file to hide this note.
///
bool? isOnlineAgenda;
List<TranslationDTO>? resourceIds; List<TranslationDTO>? resourceIds;
MapProvider? agendaMapProvider; MapProvider? agendaMapProvider;
@ -128,6 +137,7 @@ class AgendaDTO {
other.meterZoneGPS == meterZoneGPS && other.meterZoneGPS == meterZoneGPS &&
other.isBeacon == isBeacon && other.isBeacon == isBeacon &&
other.beaconId == beaconId && other.beaconId == beaconId &&
other.isOnlineAgenda == isOnlineAgenda &&
_deepEquality.equals(other.resourceIds, resourceIds) && _deepEquality.equals(other.resourceIds, resourceIds) &&
other.agendaMapProvider == agendaMapProvider && other.agendaMapProvider == agendaMapProvider &&
_deepEquality.equals(other.events, events); _deepEquality.equals(other.events, events);
@ -154,13 +164,14 @@ class AgendaDTO {
(meterZoneGPS == null ? 0 : meterZoneGPS!.hashCode) + (meterZoneGPS == null ? 0 : meterZoneGPS!.hashCode) +
(isBeacon == null ? 0 : isBeacon!.hashCode) + (isBeacon == null ? 0 : isBeacon!.hashCode) +
(beaconId == null ? 0 : beaconId!.hashCode) + (beaconId == null ? 0 : beaconId!.hashCode) +
(isOnlineAgenda == null ? 0 : isOnlineAgenda!.hashCode) +
(resourceIds == null ? 0 : resourceIds!.hashCode) + (resourceIds == null ? 0 : resourceIds!.hashCode) +
(agendaMapProvider == null ? 0 : agendaMapProvider!.hashCode) + (agendaMapProvider == null ? 0 : agendaMapProvider!.hashCode) +
(events == null ? 0 : events!.hashCode); (events == null ? 0 : events!.hashCode);
@override @override
String toString() => String toString() =>
'AgendaDTO[id=$id, label=$label, title=$title, description=$description, isActive=$isActive, imageId=$imageId, imageSource=$imageSource, configurationId=$configurationId, isSubSection=$isSubSection, parentId=$parentId, type=$type, dateCreation=$dateCreation, order=$order, instanceId=$instanceId, latitude=$latitude, longitude=$longitude, meterZoneGPS=$meterZoneGPS, isBeacon=$isBeacon, beaconId=$beaconId, resourceIds=$resourceIds, agendaMapProvider=$agendaMapProvider, events=$events]'; 'AgendaDTO[id=$id, label=$label, title=$title, description=$description, isActive=$isActive, imageId=$imageId, imageSource=$imageSource, configurationId=$configurationId, isSubSection=$isSubSection, parentId=$parentId, type=$type, dateCreation=$dateCreation, order=$order, instanceId=$instanceId, latitude=$latitude, longitude=$longitude, meterZoneGPS=$meterZoneGPS, isBeacon=$isBeacon, beaconId=$beaconId, isOnlineAgenda=$isOnlineAgenda, resourceIds=$resourceIds, agendaMapProvider=$agendaMapProvider, events=$events]';
Map<String, dynamic> toJson() { Map<String, dynamic> toJson() {
final json = <String, dynamic>{}; final json = <String, dynamic>{};
@ -259,6 +270,11 @@ class AgendaDTO {
} else { } else {
json[r'beaconId'] = null; json[r'beaconId'] = null;
} }
if (this.isOnlineAgenda != null) {
json[r'isOnlineAgenda'] = this.isOnlineAgenda;
} else {
json[r'isOnlineAgenda'] = null;
}
if (this.resourceIds != null) { if (this.resourceIds != null) {
json[r'resourceIds'] = this.resourceIds; json[r'resourceIds'] = this.resourceIds;
} else { } else {
@ -317,6 +333,7 @@ class AgendaDTO {
meterZoneGPS: mapValueOfType<int>(json, r'meterZoneGPS'), meterZoneGPS: mapValueOfType<int>(json, r'meterZoneGPS'),
isBeacon: mapValueOfType<bool>(json, r'isBeacon'), isBeacon: mapValueOfType<bool>(json, r'isBeacon'),
beaconId: mapValueOfType<int>(json, r'beaconId'), beaconId: mapValueOfType<int>(json, r'beaconId'),
isOnlineAgenda: mapValueOfType<bool>(json, r'isOnlineAgenda'),
resourceIds: TranslationDTO.listFromJson(json[r'resourceIds']), resourceIds: TranslationDTO.listFromJson(json[r'resourceIds']),
agendaMapProvider: MapProvider.fromJson(json[r'agendaMapProvider']), agendaMapProvider: MapProvider.fromJson(json[r'agendaMapProvider']),
events: EventAgendaDTO.listFromJson(json[r'events']), events: EventAgendaDTO.listFromJson(json[r'events']),