hahahaha 0.0.2 copy "hahahaha: ^0.0.2" to clipboard
hahahaha: ^0.0.2 copied to clipboard

PlatformAndroidiOS
outdated

这是一个企业微信登陆的插件

example/lib/main.dart

import 'package:flutter/material.dart';
import 'package:hahahaha/hahahaha.dart';

void main() {
  runApp(const MyApp());
}

class MyApp extends StatefulWidget {
  const MyApp({Key? key}) : super(key: key);

  @override
  State<MyApp> createState() => _MyAppState();
}

class _MyAppState extends State<MyApp> {
  @override
  void initState() {
    super.initState();
  }

  @override
  Widget build(BuildContext context) {
    return MaterialApp(
      home: Scaffold(
        appBar: AppBar(
          title: const Text('Plugin example app'),
        ),
        body: Center(
          child: Column(
            mainAxisAlignment: MainAxisAlignment.center,
            children: [
              TextButton(
                onPressed: () async {
                  //注册企业微信
                  String appid = "wwauth50291a264ed6e2c0000019";
                  String corpid = "wx50291a264ed6e2c0";
                  String agentid = "1000019";

                  Hahahaha.registerApp(appid: appid, corpid: corpid, agentid: agentid);
                },
                child: const Text("注册"),
              ),
              TextButton(
                onPressed: () async {
                  Map map = await Hahahaha.sendReq();
                  debugPrint(map.toString());
                },
                child: const Text("登陆"),
              ),
            ],
          ),
        ),
      ),
    );
  }
}
0
likes
135
points
16
downloads

Publisher

unverified uploader

Weekly Downloads

这是一个企业微信登陆的插件

Repository (GitHub)
View/report issues

Documentation

API reference

License

BSD-3-Clause (license)

Dependencies

flutter

More

Packages that depend on hahahaha

Packages that implement hahahaha