23 lines
660 B
Dart
23 lines
660 B
Dart
|
import 'package:konectar_events/contacts_module/service.dart/service.dart';
|
||
|
import 'package:konectar_events/contacts_module/storage_hive/traning_data/crud_training.dart';
|
||
|
import 'package:flutter/cupertino.dart';
|
||
|
|
||
|
class TrainigProvider extends ChangeNotifier {
|
||
|
final apicall = Callapi();
|
||
|
List tralist = [];
|
||
|
|
||
|
List get traininglist => tralist;
|
||
|
|
||
|
traininginfo(text) async {
|
||
|
print("Location_Text");
|
||
|
final email_result = await apicall.gettrainingdata(text);
|
||
|
tralist = email_result;
|
||
|
notifyListeners();
|
||
|
}
|
||
|
|
||
|
storeTraining(row) async {
|
||
|
final trainingresult = await apicall.gettrainingdata(row);
|
||
|
await addtraining(trainingresult);
|
||
|
}
|
||
|
}
|