upetch_paysquare_service 0.0.4 copy "upetch_paysquare_service: ^0.0.4" to clipboard
upetch_paysquare_service: ^0.0.4 copied to clipboard

outdated

A new Flutter plugin.

example/lib/main.dart

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

main() => runApp(MyApp());

class MyApp extends StatelessWidget {
  @override
  Widget build(BuildContext context) {
    return MaterialApp(
      home: Scaffold(
        body: Center(
            child: RaisedButton(
          onPressed: () {
            _showRazorPayView();
          },
          child: Text("Show RazorPay", textDirection: TextDirection.ltr),
        )),
      ),
    );
  }

  Future<Null> _showRazorPayView() async {
    String apikey = "API_KEY";

    Map<String, dynamic> options = Map();
    options.putIfAbsent("name", () => "Testing");
    options.putIfAbsent("image", () => "");
    options.putIfAbsent("description", () => "Testing");
    options.putIfAbsent("amount", () => "100");
    options.putIfAbsent("email", () => "test@test.com");
    options.putIfAbsent("contact", () => "100");
    options.putIfAbsent("currency", () => "INR");
    options.putIfAbsent("api_key", () => apikey);

    Map<dynamic, dynamic> paymentResponse = Map();
    paymentResponse =
        await UpetchPaysquareService.openRazorPaymentDialog(options);
    print("response $paymentResponse");
  }
}
0
likes
0
pub points
0%
popularity

Publisher

unverified uploader

A new Flutter plugin.

Repository (GitHub)
View/report issues

License

unknown (LICENSE)

Dependencies

flutter

More

Packages that depend on upetch_paysquare_service