canteenlib 1.1.0-alpha.1 copy "canteenlib: ^1.1.0-alpha.1" to clipboard
canteenlib: ^1.1.0-alpha.1 copied to clipboard

Library for communication with the czech canteen food ordering system iCanteen

example/canteenlib_example.dart

import 'package:canteenlib/canteenlib.dart';

void main(List<String> args) {
  Canteen c = Canteen("https://kantyna.neco.cz");
  c.login("uzivatel", "heslo").then((value) {
    c.jidelnicekDen(den: DateTime.parse("2022-04-04")).then((t) async {
      print((await c.ziskejUzivatele()).kredit);
      c.objednat(t.jidla[0]).then(
        (value) {
          t.jidla[0] = value; // divně udělané ale nic lepšího teď nevymyslím
          print(t.jidla[0].objednano);
          print(t.jidla[0].orderUrl);
        },
      );
    });
  }).catchError((o) {
    print(o);
    return null;
  });
}
2
likes
0
pub points
40%
popularity

Publisher

verified publishertomprotiva.com

Library for communication with the czech canteen food ordering system iCanteen

Repository (GitHub)
View/report issues

Documentation

Documentation

License

unknown (LICENSE)

Dependencies

http

More

Packages that depend on canteenlib