preVersionfinish
This commit is contained in:
@@ -0,0 +1,80 @@
|
||||
import 'package:flutter/material.dart';
|
||||
import 'package:get/get.dart';
|
||||
|
||||
var kFontSizeDouble = 15.0;
|
||||
|
||||
var kTextSyleLittleGrey =
|
||||
TextStyle(fontSize: 12.0, color: Colors.grey.shade800);
|
||||
|
||||
var kTextSyleHeaderGrey =
|
||||
TextStyle(fontSize: 25.0, color: Colors.grey.shade800);
|
||||
|
||||
var kElevatetButtonStyleDrawer = ElevatedButton.styleFrom(
|
||||
backgroundColor: Colors.blueGrey,
|
||||
foregroundColor: Colors.white,
|
||||
padding: const EdgeInsets.symmetric(horizontal: 20, vertical: 10),
|
||||
textStyle: const TextStyle(fontSize: 16, fontWeight: FontWeight.bold),
|
||||
);
|
||||
|
||||
//DropDown Styles
|
||||
var kInputDecorationDropDownMenue = InputDecoration(
|
||||
//prefixIcon: Icon(Icons.date_range),
|
||||
hintText: 'User'.toUpperCase(),
|
||||
contentPadding: const EdgeInsets.all(10),
|
||||
hintStyle: TextStyle(letterSpacing: 2, fontSize: kFontSizeDouble),
|
||||
filled: true,
|
||||
fillColor: Colors.grey.shade400,
|
||||
errorStyle: const TextStyle(color: Colors.yellow),
|
||||
);
|
||||
|
||||
SnackbarController kDisplaySnackBarRed(String szInfoText) {
|
||||
return Get.snackbar('Info', szInfoText,
|
||||
backgroundColor: Colors.red[600],
|
||||
snackPosition: SnackPosition.TOP,
|
||||
colorText: Colors.white,
|
||||
snackStyle: SnackStyle.GROUNDED);
|
||||
}
|
||||
|
||||
SnackbarController kDisplaySnackBarGreen(String szInfoText) {
|
||||
return Get.snackbar('Info', szInfoText,
|
||||
backgroundColor: Colors.green[600],
|
||||
snackPosition: SnackPosition.TOP,
|
||||
colorText: Colors.black,
|
||||
snackStyle: SnackStyle.GROUNDED);
|
||||
}
|
||||
|
||||
//Setting Wait for Delete
|
||||
List<Map<String, dynamic>> kListMapSetting = [
|
||||
{'ContainerID': '', 'Info': ''}
|
||||
];
|
||||
|
||||
//Switching PROD/DEV
|
||||
String kStringEnvironment = '?';
|
||||
|
||||
Future<String?> kShowPopupDialog(
|
||||
String title,
|
||||
String content,
|
||||
String buttonLeftText,
|
||||
String buttonRightText,
|
||||
) async {
|
||||
return await Get.dialog<String>(
|
||||
AlertDialog(
|
||||
title: Text(title),
|
||||
content: Text(content),
|
||||
actions: [
|
||||
TextButton(
|
||||
onPressed: () {
|
||||
Navigator.of(Get.overlayContext!).pop('Abbrechen');
|
||||
},
|
||||
child: Text(buttonLeftText),
|
||||
),
|
||||
TextButton(
|
||||
onPressed: () {
|
||||
Navigator.of(Get.overlayContext!).pop('OK');
|
||||
},
|
||||
child: Text(buttonRightText),
|
||||
),
|
||||
],
|
||||
),
|
||||
);
|
||||
}
|
||||
@@ -0,0 +1,10 @@
|
||||
import 'dart:io';
|
||||
|
||||
class MyHttpOverrides extends HttpOverrides {
|
||||
@override
|
||||
HttpClient createHttpClient(SecurityContext? context) {
|
||||
return super.createHttpClient(context)
|
||||
..badCertificateCallback =
|
||||
(X509Certificate cert, String host, int port) => true;
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,11 @@
|
||||
|
||||
|
||||
import 'package:get/get.dart';
|
||||
import '../controller/home_controller.dart';
|
||||
|
||||
class SampleBindings extends Bindings {
|
||||
@override
|
||||
void dependencies() {
|
||||
Get.lazyPut<HomeController>(() => HomeController());
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,16 @@
|
||||
import 'package:get/get.dart';
|
||||
|
||||
import '../pages/home/home_view.dart';
|
||||
import './sample_bindings.dart';
|
||||
|
||||
class SampleRouts {
|
||||
static final sampleBindings = SampleBindings();
|
||||
static final samplePages = [
|
||||
GetPage(
|
||||
name: HomePage.routeName,
|
||||
binding: sampleBindings,
|
||||
page: () => const HomePage(),
|
||||
transition: Transition.leftToRight,
|
||||
),
|
||||
];
|
||||
}
|
||||
Reference in New Issue
Block a user