DiscoverModule/lib/provider_class/trials_provider.dart

17 lines
365 B
Dart

import 'package:discover_module/service.dart/service.dart';
import 'package:flutter/cupertino.dart';
class TrialsProvider extends ChangeNotifier {
final callapi = Callapi();
List trials = [];
List get trialsinfo => trials;
trialsdata(text) async {
final jsonres = await callapi.getalltrials(text);
trials = jsonres;
notifyListeners();
}
}