changed (hopefully) everything to new List with TextEditingControllers
time forgot to save sth ig
This commit is contained in:
@@ -6,7 +6,7 @@ import 'package:dio/dio.dart';
|
||||
import 'package:shared_preferences/shared_preferences.dart';
|
||||
|
||||
class HttpRequest {
|
||||
static Future<int> httpRequest({Map<String, dynamic>? saveDataMap, String? saveDataString}) async {
|
||||
static Future<int> httpRequest({Map<String, String>? saveDataMap, String? saveDataString}) async {
|
||||
// print(jsonEncode(place));
|
||||
|
||||
final dio = Dio();
|
||||
|
||||
@@ -5,7 +5,7 @@ import 'package:file_picker/file_picker.dart';
|
||||
import 'package:shared_preferences/shared_preferences.dart';
|
||||
|
||||
class SaveFileMethod {
|
||||
static Future<void> saveFile(Map<String, dynamic> place, String fileNameLocalization, String placeID) async {
|
||||
static Future<void> saveFile(Map<String, String> place, String fileNameLocalization, String placeID) async {
|
||||
String? selectedDirectory = await FilePicker.platform.getDirectoryPath();
|
||||
SharedPreferences prefs = await SharedPreferences.getInstance();
|
||||
String jsonPlace = jsonEncode(place);
|
||||
|
||||
@@ -2,7 +2,7 @@ import 'package:fforte/methods/place_db_helper.dart';
|
||||
|
||||
class SaveMainEntryMethod {
|
||||
static void saveEntry(
|
||||
{required Map<String, dynamic> entryData,
|
||||
{required Map<String, String> entryData,
|
||||
required bool isTemplate,
|
||||
bool sent = false}) async {
|
||||
var placeDB = PlaceDBHelper();
|
||||
@@ -15,7 +15,7 @@ class SaveMainEntryMethod {
|
||||
}
|
||||
|
||||
if (isTemplate) {
|
||||
await placeDB.deleteTemplateById(entryData["CID"]);
|
||||
await placeDB.deleteTemplateById(entryData["CID"]!);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -3,7 +3,7 @@ import 'package:fforte/interfaces/i_db.dart';
|
||||
import 'package:fforte/methods/excursion_db_helper.dart';
|
||||
import 'package:fforte/methods/place_db_helper.dart';
|
||||
|
||||
void saveTemplate(Map<String, dynamic> templateData, DatabasesEnum dbType,
|
||||
void saveTemplate(Map<String, String> templateData, DatabasesEnum dbType,
|
||||
bool update) async {
|
||||
IDb dbHelper;
|
||||
if (dbType == DatabasesEnum.place) {
|
||||
|
||||
Reference in New Issue
Block a user