added add siswa and dana sosial

This commit is contained in:
kicap committed 2023-05-18 18:58:21 +08:00
1 parent 949474b8ef
commit e0b5213a3b
14 files changed
+519 -161

No files matched your search

+2 -2
View File
@@ -7,8 +7,8 @@ class MyHttpServices {
final log = getLogger('MyHttpServices');
final _options = BaseOptions(
baseUrl: dotenv.env['api_url']!,
connectTimeout: const Duration(seconds: 60),
receiveTimeout: const Duration(seconds: 60),
connectTimeout: const Duration(seconds: 120),
receiveTimeout: const Duration(seconds: 120),
);
late Dio _dio;
+11
View File
@@ -0,0 +1,11 @@
class OtherFunction {
int umur(String tanggalLahir) {
// change tanggalLahir to DateTime
DateTime date = DateTime.parse(tanggalLahir);
// get current date
DateTime now = DateTime.now();
// get difference in year
int year = now.year - date.year;
return year;
}
}