Няма описание
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798
  1. import 'dart:async';
  2. import 'dart:convert';
  3. import 'dart:typed_data';
  4. import 'package:connectivity_plus/connectivity_plus.dart';
  5. import 'package:double_back_to_close/double_back_to_close.dart';
  6. import 'package:flutter/cupertino.dart';
  7. import 'package:flutter/material.dart';
  8. import 'package:fluttertoast/fluttertoast.dart';
  9. import 'package:focus_detector/focus_detector.dart';
  10. import 'package:google_fonts/google_fonts.dart';
  11. import 'package:employee_selfservice_mobile/Screens/Menu/About/about_screen.dart';
  12. import 'package:employee_selfservice_mobile/Screens/Menu/Absensi/absensi_screen.dart';
  13. import 'package:employee_selfservice_mobile/Screens/Menu/AjukanCuti/ajukancuti_screen.dart';
  14. import 'package:employee_selfservice_mobile/Screens/Menu/Reimburse/reimburse_screen.dart';
  15. import 'package:employee_selfservice_mobile/Screens/Menu/SlipGaji/slipgaji_screen.dart';
  16. import 'package:employee_selfservice_mobile/Screens/Menu/SuratTugas/surattugas_screen.dart';
  17. import 'package:employee_selfservice_mobile/Screens/Settings/settings_screen.dart';
  18. import 'package:lottie/lottie.dart';
  19. import 'package:progress_dialog_null_safe/progress_dialog_null_safe.dart';
  20. import 'package:shared_preferences/shared_preferences.dart';
  21. import 'dart:developer' as logDev;
  22. import '../Settings/RequestHttp/getDetail_post.dart';
  23. import '../Settings/RequestHttp/getProfileImage_post.dart';
  24. import 'package:internet_connection_checker/internet_connection_checker.dart';
  25. var _imageToShow;
  26. late String nameShared;
  27. String name = "",
  28. statusDetail = "",
  29. dateOfBirth = "",
  30. phone = "",
  31. email = "",
  32. address = "",
  33. position = "";
  34. class HomeView extends StatefulWidget {
  35. @override
  36. _HomeView createState() => _HomeView();
  37. }
  38. class _HomeView extends State<HomeView> {
  39. late StreamSubscription subscription;
  40. bool isDeviceConnected = false;
  41. bool isAlertSet = false;
  42. @override
  43. initState() {
  44. getConnectivity();
  45. getDetail();
  46. _imageToShow = AssetImage('assets/images/ic_administrator.png');
  47. WidgetsBinding.instance.addPostFrameCallback((_) async {
  48. getProfileImage();
  49. });
  50. super.initState();
  51. }
  52. getConnectivity() =>
  53. subscription = Connectivity().onConnectivityChanged.listen(
  54. (ConnectivityResult result) async {
  55. isDeviceConnected = await InternetConnectionChecker().hasConnection;
  56. if (!isDeviceConnected && isAlertSet == false) {
  57. showDialogBox();
  58. setState(() => isAlertSet = true);
  59. }
  60. },
  61. );
  62. @override
  63. void dispose() {
  64. subscription.cancel();
  65. super.dispose();
  66. }
  67. //Get Profile image
  68. getProfileImage() async {
  69. final SharedPreferences prefs = await SharedPreferences.getInstance();
  70. final session = prefs.getString('session');
  71. ProgressDialog loading = ProgressDialog(context);
  72. loading = ProgressDialog(context,
  73. type: ProgressDialogType.normal,
  74. isDismissible: false,
  75. showLogs: true);
  76. loading.style(
  77. message: 'Please Wait .....',
  78. borderRadius: 5,
  79. backgroundColor: Colors.white,
  80. progressWidget: CircularProgressIndicator(),
  81. elevation: 10.0,
  82. padding: EdgeInsets.all(10),
  83. insetAnimCurve: Curves.easeInOut,
  84. progress: 0.0,
  85. maxProgress: 100.0,
  86. progressTextStyle: TextStyle(
  87. color: Colors.black, fontSize: 10.0, fontWeight: FontWeight.w400),
  88. messageTextStyle: TextStyle(
  89. color: Colors.black,
  90. fontSize: 15.0,
  91. fontWeight: FontWeight.w600));
  92. loading.show();
  93. GetProfileImage_Post.connectToAPI(session!).then((valueResult) async {
  94. Map<String, dynamic> object = json.decode(valueResult);
  95. if (object.containsKey("result").toString() == "true") {
  96. String status = object['result']['status'].toString();
  97. logDev.log(status, name: "STATUS GET PROFILE");
  98. if (status == "success") {
  99. String photo = object['result']['photo'].toString();
  100. if (photo == "false") {
  101. setState(() {
  102. _imageToShow = AssetImage('assets/images/ic_administrator.png');
  103. });
  104. } else if (photo != "false") {
  105. Uint8List decodedBytes = Base64Decoder().convert(photo);
  106. setState(() {
  107. _imageToShow = Image
  108. .memory(decodedBytes, gaplessPlayback: true)
  109. .image;
  110. });
  111. }
  112. await loading.hide();
  113. } else if (status == "failed") {
  114. String message = object['result']['message'].toString();
  115. Fluttertoast.showToast(
  116. msg: message,
  117. toastLength: Toast.LENGTH_LONG,
  118. gravity: ToastGravity.CENTER,
  119. timeInSecForIosWeb: 1,
  120. textColor: Colors.white,
  121. fontSize: 16.0);
  122. }
  123. await loading.hide();
  124. } else {
  125. Fluttertoast.showToast(
  126. msg: "Server Response Error",
  127. toastLength: Toast.LENGTH_SHORT,
  128. gravity: ToastGravity.CENTER,
  129. timeInSecForIosWeb: 1,
  130. textColor: Colors.white,
  131. fontSize: 16.0);
  132. await loading.hide();
  133. }
  134. });
  135. return _imageToShow;
  136. }
  137. //GetDetail
  138. getDetail() async {
  139. GetDetail_Post.connectToAPI().then((valueResult) async {
  140. Map<String, dynamic> object = json.decode(valueResult);
  141. if (object.containsKey("result").toString() == "true") {
  142. statusDetail = object['result']['status'].toString();
  143. String message = object['result']['message'].toString();
  144. if (statusDetail == "failed" || message == "User Not Found") {
  145. Fluttertoast.showToast(
  146. msg: message + ", Please login again!",
  147. toastLength: Toast.LENGTH_SHORT,
  148. gravity: ToastGravity.CENTER,
  149. timeInSecForIosWeb: 1,
  150. textColor: Colors.white,
  151. fontSize: 16.0);
  152. } else if (statusDetail != "failed") {
  153. name = object['result']['name'].toString();
  154. dateOfBirth = object['result']['date_of_birth'].toString();
  155. phone = object['result']['phone'].toString();
  156. email = object['result']['email'].toString();
  157. address = object['result']['address'].toString();
  158. position = object['result']['position'].toString();
  159. var prefs = await SharedPreferences.getInstance();
  160. await prefs.setString('position', position);
  161. }
  162. } else {
  163. Fluttertoast.showToast(
  164. msg: "Server Response Error",
  165. toastLength: Toast.LENGTH_SHORT,
  166. gravity: ToastGravity.CENTER,
  167. timeInSecForIosWeb: 1,
  168. textColor: Colors.white,
  169. fontSize: 16.0);
  170. }
  171. });
  172. }
  173. int _selectedIndex = 0;
  174. void _onItemTapped(int index) {
  175. setState(() {
  176. _selectedIndex = index;
  177. if (index == 0) {
  178. }
  179. });
  180. }
  181. @override
  182. Widget build(BuildContext context) {
  183. return MaterialApp(
  184. home: DoubleBack(
  185. /*onFirstBackPress: (context) {
  186. final snackBar = SnackBar(content: Text("Double Back Press to Exit"));
  187. ScaffoldMessenger.of(context).showSnackBar(snackBar);
  188. },*/
  189. message: "Double Back Press to Exit",
  190. background: Colors.black38,
  191. backgroundRadius: 10,
  192. textStyle: TextStyle(
  193. fontSize: 16, fontWeight: FontWeight.bold, color: Colors.white),
  194. child: Scaffold(
  195. resizeToAvoidBottomInset: false,
  196. //backgroundColor: Colors.white,
  197. body: Stack(
  198. children: <Widget>[
  199. //Background(),
  200. //HomeScreen(),
  201. BottomNavBar()
  202. ],
  203. )),
  204. ),
  205. );
  206. }
  207. showDialogBox() => showCupertinoDialog<String>(
  208. context: context,
  209. builder: (BuildContext context) => CupertinoAlertDialog(
  210. title: const Text('No Connection'),
  211. content: const Text('Please check your internet connectivity'),
  212. actions: <Widget>[
  213. Column(
  214. children: [
  215. SizedBox(
  216. width: 250,
  217. height: 250,
  218. child: LottieBuilder.asset(
  219. //'assets/animation/animation_no_internet.json',
  220. 'assets/animation/animation_no_internet_3.json',
  221. repeat: true),
  222. ),
  223. ],
  224. ),
  225. TextButton(
  226. onPressed: () async {
  227. Navigator.pop(context, 'Cancel');
  228. setState(() => isAlertSet = false);
  229. isDeviceConnected = await InternetConnectionChecker().hasConnection;
  230. if (!isDeviceConnected && isAlertSet == false) {
  231. showDialogBox();
  232. setState(() => isAlertSet = true);
  233. }
  234. },
  235. child: const Text('Retry'),
  236. ),
  237. ],
  238. ),
  239. );
  240. }
  241. class BottomNavBar extends StatefulWidget {
  242. const BottomNavBar({Key? key}) : super(key: key);
  243. @override
  244. State<BottomNavBar> createState() => _BottomNavBarState();
  245. }
  246. class _BottomNavBarState extends State<BottomNavBar> {
  247. List<Widget> _widgetOptions = <Widget>[
  248. HomeScreen(),
  249. ReimburseScreen(),
  250. SettingsScreen(),
  251. ];
  252. int _selectedIndex = 0;
  253. void _onItemTapped(int index) {
  254. setState(() {
  255. _selectedIndex = index;
  256. });
  257. }
  258. @override
  259. Widget build(BuildContext context) {
  260. return Scaffold(
  261. body: _widgetOptions.elementAt(_selectedIndex),
  262. bottomNavigationBar: BottomNavigationBar(
  263. items: const <BottomNavigationBarItem>[
  264. BottomNavigationBarItem(
  265. icon: Icon(Icons.home),
  266. label: 'Home',
  267. ),
  268. BottomNavigationBarItem(
  269. icon: Icon(Icons.notifications),
  270. label: 'Notification',
  271. ),BottomNavigationBarItem(
  272. icon: Icon(Icons.person),
  273. label: 'Profile',
  274. ),
  275. ],
  276. currentIndex: _selectedIndex,
  277. selectedItemColor: Colors.white,
  278. backgroundColor: Color(0xFF5666b7),
  279. onTap: _onItemTapped),
  280. );
  281. }
  282. }
  283. class HomeScreen extends StatefulWidget {
  284. @override
  285. State<HomeScreen> createState() => _HomeScreenState();
  286. }
  287. class _HomeScreenState extends State<HomeScreen> {
  288. //Get Profile image
  289. getProfileImage() async {
  290. final SharedPreferences prefs = await SharedPreferences.getInstance();
  291. final session = prefs.getString('session');
  292. GetProfileImage_Post.connectToAPI(session!).then((valueResult) async {
  293. Map<String, dynamic> object = json.decode(valueResult);
  294. if (object.containsKey("result").toString() == "true") {
  295. String status = object['result']['status'].toString();
  296. logDev.log(status, name: "STATUS GET PROFILE");
  297. if (status == "success") {
  298. String photo = object['result']['photo'].toString();
  299. if (photo == "false") {
  300. setState(() {
  301. _imageToShow = AssetImage('assets/images/ic_administrator.png');
  302. });
  303. } else if (photo != "false") {
  304. Uint8List decodedBytes = Base64Decoder().convert(photo);
  305. //logDev.log(decodedBytes.toString(), name: "DECODED BYTES photo");
  306. setState(() {
  307. _imageToShow = Image.memory(decodedBytes, gaplessPlayback: true).image;
  308. });
  309. }
  310. } else if (status == "failed") {
  311. String message = object['result']['message'].toString();
  312. Fluttertoast.showToast(
  313. msg: message,
  314. toastLength: Toast.LENGTH_LONG,
  315. gravity: ToastGravity.CENTER,
  316. timeInSecForIosWeb: 1,
  317. textColor: Colors.white,
  318. fontSize: 16.0);
  319. }
  320. } else {
  321. Fluttertoast.showToast(
  322. msg: "Server Response Error",
  323. toastLength: Toast.LENGTH_SHORT,
  324. gravity: ToastGravity.CENTER,
  325. timeInSecForIosWeb: 1,
  326. textColor: Colors.white,
  327. fontSize: 16.0);
  328. }
  329. });
  330. return _imageToShow;
  331. }
  332. @override
  333. Widget build(BuildContext context) {
  334. var size = MediaQuery.of(context).size;
  335. return FocusDetector(
  336. /*onVisibilityGained: (){
  337. getProfileImage();
  338. },
  339. onVisibilityLost: (){
  340. getProfileImage();
  341. },
  342. onFocusLost: (){
  343. getProfileImage();
  344. },*/
  345. onFocusGained: (){
  346. getProfileImage();
  347. },
  348. /* onForegroundLost: (){
  349. getProfileImage();
  350. },
  351. onForegroundGained: (){
  352. getProfileImage();
  353. },*/
  354. child: Scaffold(
  355. body: SingleChildScrollView(
  356. child: Stack(
  357. children: <Widget>[
  358. Container(
  359. height: size.height * 0.3,
  360. decoration: BoxDecoration(
  361. gradient: LinearGradient(
  362. begin: Alignment.topRight,
  363. end: Alignment.bottomRight,
  364. colors: [
  365. Color(0xFF4858A7),
  366. Color(0xFF6474C6),
  367. //Color(0xFF8C99DD),
  368. ])),
  369. ),
  370. SafeArea(
  371. child: Padding(
  372. padding: EdgeInsets.all(20),
  373. child: Column(
  374. children: <Widget>[
  375. /* Align(
  376. alignment: Alignment.topRight,
  377. child: InkWell(
  378. child: Container(
  379. alignment: Alignment.center,
  380. height: 40,
  381. width: 40,
  382. child: Image.asset('assets/images/ic_settings.png')),
  383. onTap: () {
  384. Navigator.push(
  385. context,
  386. MaterialPageRoute(
  387. builder: (context) => SettingsScreen()));
  388. },
  389. ),
  390. ),*/
  391. Container(
  392. child: Stack(
  393. alignment: Alignment.topLeft,
  394. children: [
  395. Container(
  396. margin: EdgeInsets.only(top: (((size.width - 20) * 0.33) * 0.5) + 40),
  397. child: Card(
  398. elevation: 15,
  399. child: Container(
  400. height: size.width * 0.35,
  401. width: size.width - 20,
  402. padding: EdgeInsets.all(15),
  403. decoration: BoxDecoration(
  404. color: Colors.white,
  405. borderRadius:
  406. BorderRadius.all(Radius.circular(10))),
  407. child: Column(
  408. mainAxisAlignment: MainAxisAlignment.end,
  409. crossAxisAlignment: CrossAxisAlignment.center,
  410. children: <Widget>[
  411. Text(name,
  412. maxLines: 2,
  413. overflow: TextOverflow.ellipsis,
  414. textAlign: TextAlign.center,
  415. style: GoogleFonts.inter(
  416. fontSize: 18,
  417. color: Colors.black,
  418. fontWeight: FontWeight.bold),
  419. ),
  420. Text(position,
  421. textAlign: TextAlign.center,
  422. style: GoogleFonts.inter(
  423. fontSize: 17, color: Colors.black),
  424. ),
  425. ],
  426. )),
  427. ),
  428. ),
  429. Align(
  430. alignment: Alignment.topCenter,
  431. child: Container(
  432. margin: EdgeInsets.only(left: 15, top: 40),
  433. alignment: Alignment.topLeft,
  434. height: (size.width - 20) * 0.33,
  435. width: (size.width - 20) * 0.33,
  436. decoration: BoxDecoration(
  437. color: Colors.black,
  438. image: DecorationImage(
  439. image: _imageToShow,
  440. fit: BoxFit.cover,
  441. ),
  442. shape: BoxShape.circle,
  443. ),
  444. ),
  445. ),
  446. ],
  447. ),
  448. ),
  449. GridView.count(
  450. shrinkWrap: true,
  451. physics: NeverScrollableScrollPhysics(),
  452. padding: EdgeInsets.only(top: 25, left: 5, right: 5),
  453. crossAxisSpacing: 15,
  454. mainAxisSpacing: 15,
  455. crossAxisCount: 2,
  456. children: <Widget>[
  457. InkWell(
  458. child: Container(
  459. decoration: BoxDecoration(
  460. color: Color(0xFFD0D0D0),
  461. borderRadius: BorderRadius.circular(5)),
  462. child: Column(
  463. crossAxisAlignment: CrossAxisAlignment.center,
  464. mainAxisAlignment: MainAxisAlignment.center,
  465. children: <Widget>[
  466. Container(
  467. width: 75,
  468. height: 75,
  469. child: Image.asset(
  470. "assets/icons/menu/ic_absensi.png",
  471. fit: BoxFit.fill,
  472. alignment: Alignment.center,
  473. ),
  474. ),
  475. Container(
  476. margin: EdgeInsets.only(top: 10),
  477. padding: EdgeInsets.all(5),
  478. child: Text(
  479. 'Attendance',
  480. textAlign: TextAlign.center,
  481. style: GoogleFonts.acme(
  482. fontSize: 18, color: Colors.black),
  483. ),
  484. ),
  485. ],
  486. ),
  487. ),
  488. onTap: () {
  489. Navigator.push(
  490. context,
  491. MaterialPageRoute(
  492. builder: (context) => AbsensiScreen()));
  493. }),
  494. InkWell(
  495. child: Container(
  496. decoration: BoxDecoration(
  497. color: Color(0xFFD0D0D0),
  498. borderRadius: BorderRadius.circular(5)),
  499. child: Column(
  500. crossAxisAlignment: CrossAxisAlignment.center,
  501. mainAxisAlignment: MainAxisAlignment.center,
  502. children: <Widget>[
  503. Container(
  504. width: 75,
  505. height: 75,
  506. child: Image.asset(
  507. "assets/icons/menu/ic_slipgaji_2.png",
  508. fit: BoxFit.fill,
  509. alignment: Alignment.center),
  510. ),
  511. Container(
  512. margin: EdgeInsets.only(top: 10),
  513. padding: EdgeInsets.all(5),
  514. child: Text(
  515. 'Pay Slip',
  516. textAlign: TextAlign.center,
  517. style: GoogleFonts.acme(
  518. fontSize: 18, color: Colors.black),
  519. ),
  520. ),
  521. ],
  522. ),
  523. ),
  524. onTap: () {
  525. Navigator.push(
  526. context,
  527. MaterialPageRoute(
  528. builder: (context) => SlipGajiScreen()));
  529. },
  530. ),
  531. InkWell(
  532. child: Container(
  533. decoration: BoxDecoration(
  534. color: Color(0xFFD0D0D0),
  535. borderRadius: BorderRadius.circular(5)),
  536. child: Column(
  537. crossAxisAlignment: CrossAxisAlignment.center,
  538. mainAxisAlignment: MainAxisAlignment.center,
  539. children: <Widget>[
  540. Container(
  541. width: 70,
  542. height: 70,
  543. child: Image.asset(
  544. "assets/icons/menu/ic_cuti_2.png",
  545. fit: BoxFit.fill,
  546. alignment: Alignment.center),
  547. ),
  548. Container(
  549. margin: EdgeInsets.only(top: 10),
  550. padding: EdgeInsets.all(5),
  551. child: Text(
  552. 'Leaves',
  553. textAlign: TextAlign.center,
  554. style: GoogleFonts.acme(
  555. fontSize: 18, color: Colors.black),
  556. ),
  557. ),
  558. ],
  559. ),
  560. ),
  561. onTap: () {
  562. Navigator.push(
  563. context,
  564. MaterialPageRoute(
  565. builder: (context) => AjukanCutiScreen()));
  566. },
  567. ),
  568. InkWell(
  569. child: Container(
  570. decoration: BoxDecoration(
  571. color: Color(0xFFD0D0D0),
  572. borderRadius: BorderRadius.circular(5)),
  573. child: Column(
  574. crossAxisAlignment: CrossAxisAlignment.center,
  575. mainAxisAlignment: MainAxisAlignment.center,
  576. children: <Widget>[
  577. Container(
  578. width: 70,
  579. height: 70,
  580. child: Image.asset(
  581. "assets/icons/menu/ic_surattugas_2.png",
  582. fit: BoxFit.fill,
  583. alignment: Alignment.center,
  584. ),
  585. ),
  586. Container(
  587. margin: EdgeInsets.only(top: 10),
  588. padding: EdgeInsets.all(5),
  589. child: Text(
  590. 'Assignment Letter',
  591. textAlign: TextAlign.center,
  592. style: GoogleFonts.acme(
  593. fontSize: 18, color: Colors.black),
  594. ),
  595. ),
  596. ],
  597. ),
  598. ),
  599. onTap: () {
  600. Navigator.push(
  601. context,
  602. MaterialPageRoute(
  603. builder: (context) => SuratTugas_Screen()));
  604. },
  605. ),
  606. InkWell(
  607. child: Container(
  608. decoration: BoxDecoration(
  609. color: Color(0xFFD0D0D0),
  610. borderRadius: BorderRadius.circular(5)),
  611. child: Column(
  612. crossAxisAlignment: CrossAxisAlignment.center,
  613. mainAxisAlignment: MainAxisAlignment.center,
  614. children: <Widget>[
  615. Container(
  616. width: 70,
  617. height: 70,
  618. child: Image.asset(
  619. "assets/icons/menu/ic_reimburse.png",
  620. fit: BoxFit.fill,
  621. alignment: Alignment.center),
  622. ),
  623. Container(
  624. margin: EdgeInsets.only(top: 10),
  625. padding: EdgeInsets.all(5),
  626. child: Text(
  627. 'Reimburse',
  628. textAlign: TextAlign.center,
  629. style: GoogleFonts.acme(
  630. fontSize: 18, color: Colors.black),
  631. ),
  632. ),
  633. ],
  634. ),
  635. ),
  636. onTap: () {
  637. Navigator.push(
  638. context,
  639. MaterialPageRoute(
  640. builder: (context) => ReimburseScreen()));
  641. },
  642. ),
  643. InkWell(
  644. child: Container(
  645. decoration: BoxDecoration(
  646. color: Color(0xFFD0D0D0),
  647. borderRadius: BorderRadius.circular(5)),
  648. child: Column(
  649. crossAxisAlignment: CrossAxisAlignment.center,
  650. mainAxisAlignment: MainAxisAlignment.center,
  651. children: <Widget>[
  652. Container(
  653. width: 70,
  654. height: 70,
  655. child: Image.asset(
  656. "assets/icons/menu/ic_about_3.png",
  657. fit: BoxFit.fill,
  658. alignment: Alignment.center),
  659. ),
  660. Container(
  661. margin: EdgeInsets.only(top: 10),
  662. padding: EdgeInsets.all(5),
  663. child: Text(
  664. 'About',
  665. textAlign: TextAlign.center,
  666. style: GoogleFonts.acme(
  667. fontSize: 18, color: Colors.black),
  668. ),
  669. ),
  670. ],
  671. ),
  672. ),
  673. onTap: () {
  674. Navigator.push(
  675. context,
  676. MaterialPageRoute(
  677. builder: (context) => AboutScreen()));
  678. },
  679. ),
  680. /*InkWell(
  681. child: Container(
  682. decoration: BoxDecoration(
  683. color: Color(0xFFD0D0D0),
  684. borderRadius: BorderRadius.circular(5)),
  685. child: Column(
  686. crossAxisAlignment: CrossAxisAlignment.center,
  687. mainAxisAlignment: MainAxisAlignment.center,
  688. children: <Widget>[
  689. Container(
  690. width: 70,
  691. height: 70,
  692. child: Image.asset(
  693. "assets/icons/menu/ic_reimburse.png",
  694. fit: BoxFit.fill,
  695. alignment: Alignment.center),
  696. ),
  697. Container(
  698. margin: EdgeInsets.only(top: 10),
  699. padding: EdgeInsets.all(5),
  700. child: Text(
  701. 'Reimburse',
  702. textAlign: TextAlign.center,
  703. style: GoogleFonts.acme(
  704. fontSize: 18, color: Colors.black),
  705. ),
  706. ),
  707. ],
  708. ),
  709. ),
  710. onTap: () {
  711. Navigator.push(
  712. context,
  713. MaterialPageRoute(
  714. builder: (context) => ReimburseScreen()));
  715. },
  716. ),
  717. InkWell(
  718. child: Container(
  719. decoration: BoxDecoration(
  720. color: Color(0xFFD0D0D0),
  721. borderRadius: BorderRadius.circular(5)),
  722. child: Column(
  723. crossAxisAlignment: CrossAxisAlignment.center,
  724. mainAxisAlignment: MainAxisAlignment.center,
  725. children: <Widget>[
  726. Container(
  727. width: 70,
  728. height: 70,
  729. child: Image.asset(
  730. "assets/icons/menu/ic_about_3.png",
  731. fit: BoxFit.fill,
  732. alignment: Alignment.center),
  733. ),
  734. Container(
  735. margin: EdgeInsets.only(top: 10),
  736. padding: EdgeInsets.all(5),
  737. child: Text(
  738. 'About',
  739. textAlign: TextAlign.center,
  740. style: GoogleFonts.acme(
  741. fontSize: 18, color: Colors.black),
  742. ),
  743. ),
  744. ],
  745. ),
  746. ),
  747. onTap: () {
  748. Navigator.push(
  749. context,
  750. MaterialPageRoute(
  751. builder: (context) => AboutScreen()));
  752. },
  753. ),*/
  754. ],
  755. )
  756. ],
  757. ),
  758. ),
  759. ),
  760. /*Center(
  761. child: _widgetOptions.elementAt(_selectedIndex),
  762. )*/
  763. ],
  764. ),
  765. )
  766. ),
  767. );
  768. }
  769. }