Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Contribute to GitLab
Sign in
Toggle navigation
T
Tour Travel Agency AGR
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Dio Maulana
Tour Travel Agency AGR
Commits
aa43c417
Commit
aa43c417
authored
May 25, 2023
by
Dio Maulana
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
edit profile and upgrade flutter
parent
6665291f
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
231 additions
and
128 deletions
+231
-128
build.gradle
android/build.gradle
+31
-31
edit_profile.dart
lib/page/profile/edit_profile/edit_profile.dart
+99
-58
pubspec.lock
pubspec.lock
+101
-39
No files found.
android/build.gradle
View file @
aa43c417
buildscript
{
ext
.
kotlin_version
=
'1.6.10'
repositories
{
google
()
mavenCentral
()
}
dependencies
{
classpath
'com.android.tools.build:gradle:7.1.2'
classpath
"org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version"
}
}
allprojects
{
repositories
{
google
()
mavenCentral
()
}
}
rootProject
.
buildDir
=
'../build'
subprojects
{
project
.
buildDir
=
"${rootProject.buildDir}/${project.name}"
}
subprojects
{
project
.
evaluationDependsOn
(
':app'
)
}
task
clean
(
type:
Delete
)
{
delete
rootProject
.
buildDir
}
buildscript
{
ext
.
kotlin_version
=
'1.6.10'
repositories
{
google
()
mavenCentral
()
}
dependencies
{
classpath
'com.android.tools.build:gradle:7.1.2'
classpath
"org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version"
}
}
allprojects
{
repositories
{
google
()
mavenCentral
()
}
}
rootProject
.
buildDir
=
'../build'
subprojects
{
project
.
buildDir
=
"${rootProject.buildDir}/${project.name}"
}
subprojects
{
project
.
evaluationDependsOn
(
':app'
)
}
task
s
.
register
(
"clean"
,
Delete
)
{
delete
rootProject
.
buildDir
}
lib/page/profile/edit_profile/edit_profile.dart
View file @
aa43c417
import
'package:file_picker/file_picker.dart'
;
import
'package:flutter/foundation.dart'
;
import
'package:flutter/material.dart'
;
import
'package:tour_travel_agr/helper/components_widget/custom_appbar.dart'
;
import
'package:tour_travel_agr/helper/components_widget/widget_button.dart'
;
import
'package:tour_travel_agr/helper/components_widget/widget_text_field.dart'
;
import
'package:tour_travel_agr/helper/widget_responsive.dart'
;
import
'package:tour_travel_agr/resource/assets.dart'
;
import
'package:tour_travel_agr/resource/colors.dart'
;
import
'package:tour_travel_agr/resource/size.dart'
;
...
...
@@ -18,26 +21,56 @@ class _EditProfileViewState extends State<EditProfileView> {
final
TextEditingController
nikController
=
TextEditingController
();
final
TextEditingController
hpController
=
TextEditingController
();
Uint8List
?
byteImage
;
@override
Widget
build
(
BuildContext
context
)
{
return
Scaffold
(
backgroundColor:
ColorManager
.
backgroundColor
,
body:
Container
(
padding:
EdgeInsets
.
only
(
top:
AppPadding
.
safeAreaTop
(
context
),
left:
AppPadding
.
p20
,
right:
AppPadding
.
p20
,
bottom:
AppPadding
.
safeAreaBot
(
context
),
),
child:
Column
(
children:
[
const
CustomAppBar
(
text:
"Edit Profile"
),
Expanded
(
child:
SingleChildScrollView
(
child:
Column
(
crossAxisAlignment:
CrossAxisAlignment
.
center
,
children:
[
Container
(
body:
ScreenResponsive
(
widget:
bodyWidget
(
context
),
widthScreen:
MediaQuery
.
of
(
context
).
size
.
width
,
),
);
}
Container
bodyWidget
(
BuildContext
context
)
{
return
Container
(
padding:
EdgeInsets
.
only
(
top:
AppPadding
.
safeAreaTop
(
context
),
left:
AppPadding
.
p20
,
right:
AppPadding
.
p20
,
bottom:
AppPadding
.
safeAreaBot
(
context
),
),
child:
Column
(
children:
[
const
CustomAppBar
(
text:
"Edit Profile"
),
Expanded
(
child:
SingleChildScrollView
(
child:
Column
(
crossAxisAlignment:
CrossAxisAlignment
.
center
,
children:
[
GestureDetector
(
onTap:
()
async
{
FilePickerResult
?
result
=
await
FilePicker
.
platform
.
pickFiles
();
if
(
result
!=
null
)
{
PlatformFile
file
=
result
.
files
.
first
;
// print(file.name);
// print(file.bytes);
// print(file.size);
// print(file.extension);
// print(file);
setState
(()
{
byteImage
=
file
.
bytes
;
});
// print(file.path);
}
else
{
// User canceled the picker
}
},
child:
Container
(
margin:
EdgeInsets
.
only
(
top:
AppMargin
.
m12
,
),
...
...
@@ -47,51 +80,59 @@ class _EditProfileViewState extends State<EditProfileView> {
borderRadius:
BorderRadius
.
circular
(
100
),
color:
const
Color
.
fromARGB
(
255
,
235
,
232
,
232
),
),
child:
Image
(
width:
52
,
height
:
52
,
image:
AssetImage
(
Assets
.
editProfileSample
,
)
,
),
),
InputTextField
(
controller:
nameController
,
labelText:
"Nama Lengkap"
,
labelColor:
ColorManager
.
primary
,
borderSideActive:
true
,
hintText:
"Nama Lengkap"
,
marginTop:
18
,
child:
(
byteImage
==
null
)
?
Image
(
width
:
52
,
height:
52
,
image:
AssetImage
(
Assets
.
editProfileSample
,
),
)
:
ClipRRect
(
borderRadius:
BorderRadius
.
circular
(
100
)
,
child:
Image
.
memory
(
byteImage
!
,
fit:
BoxFit
.
fill
,
)
,
)
,
),
InputTextField
(
controller:
nikController
,
labelText:
"NIK"
,
labelColor:
ColorManager
.
primary
,
borderSideActive:
true
,
hintText:
"Nomor Induk Kependudukan"
,
marginTop:
12
,
),
InputTextField
(
controller:
nameController
,
labelText:
"Nama Lengkap"
,
labelColor:
ColorManager
.
primary
,
borderSideActive:
true
,
hintText:
"Nama Lengkap"
,
marginTop:
18
,
),
InputTextField
(
controller:
nikController
,
labelText:
"NIK"
,
labelColor:
ColorManager
.
primary
,
borderSideActive:
true
,
hintText:
"Nomor Induk Kependudukan"
,
marginTop:
12
,
),
InputTextField
(
controller:
hpController
,
labelText:
"Nomor Handphone"
,
labelColor:
ColorManager
.
primary
,
borderSideActive:
true
,
hintText:
"628...."
,
marginTop:
12
,
inputType:
TextInputType
.
number
,
),
Container
(
margin:
const
EdgeInsets
.
only
(
top:
30
),
child:
const
CustomButton
(
text:
"Update"
,
),
InputTextField
(
controller:
hpController
,
labelText:
"Nomor Handphone"
,
labelColor:
ColorManager
.
primary
,
borderSideActive:
true
,
hintText:
"628...."
,
marginTop:
12
,
inputType:
TextInputType
.
number
,
),
Container
(
margin:
const
EdgeInsets
.
only
(
top:
30
),
child:
const
CustomButton
(
text:
"Update"
,
),
)
],
),
)
],
),
)
],
)
,
)
,
)
]
,
),
);
}
...
...
pubspec.lock
View file @
aa43c417
...
...
@@ -5,51 +5,74 @@ packages:
dependency: transitive
description:
name: async
url: "https://pub.dartlang.org"
sha256: "947bfcf187f74dbc5e146c9eb9c0f10c9f8b30743e341481c1e2ed3ecc18c20c"
url: "https://pub.dev"
source: hosted
version: "2.
9
.0"
version: "2.
11
.0"
boolean_selector:
dependency: transitive
description:
name: boolean_selector
url: "https://pub.dartlang.org"
sha256: "6cfb5af12253eaf2b368f07bacc5a80d1301a071c73360d746b7f2e32d762c66"
url: "https://pub.dev"
source: hosted
version: "2.1.
0
"
version: "2.1.
1
"
characters:
dependency: transitive
description:
name: characters
url: "https://pub.dartlang.org"
sha256: "04a925763edad70e8443c99234dc3328f442e811f1d8fd1a72f1c8ad0f69a605"
url: "https://pub.dev"
source: hosted
version: "1.
2.1
"
version: "1.
3.0
"
clock:
dependency: transitive
description:
name: clock
url: "https://pub.dartlang.org"
sha256: cb6d7f03e1de671e34607e909a7213e31d7752be4fb66a86d29fe1eb14bfb5cf
url: "https://pub.dev"
source: hosted
version: "1.1.1"
collection:
dependency: transitive
description:
name: collection
url: "https://pub.dartlang.org"
sha256: "4a07be6cb69c84d677a6c3096fcf960cc3285a8330b4603e0d463d15d9bd934c"
url: "https://pub.dev"
source: hosted
version: "1.1
6.0
"
version: "1.1
7.1
"
cupertino_icons:
dependency: "direct main"
description:
name: cupertino_icons
url: "https://pub.dartlang.org"
sha256: e35129dc44c9118cee2a5603506d823bab99c68393879edb440e0090d07586be
url: "https://pub.dev"
source: hosted
version: "1.0.5"
fake_async:
dependency: transitive
description:
name: fake_async
url: "https://pub.dartlang.org"
sha256: "511392330127add0b769b75a987850d136345d9227c6b94c96a04cf4a391bf78"
url: "https://pub.dev"
source: hosted
version: "1.3.1"
ffi:
dependency: transitive
description:
name: ffi
sha256: ed5337a5660c506388a9f012be0288fb38b49020ce2b45fe1f8b8323fe429f99
url: "https://pub.dev"
source: hosted
version: "2.0.2"
file_picker:
dependency: "direct main"
description:
name: file_picker
sha256: b1729fc96627dd44012d0a901558177418818d6bd428df59dcfeb594e5f66432
url: "https://pub.dev"
source: hosted
version: "5.3.2"
flutter:
dependency: "direct main"
description: flutter
...
...
@@ -59,9 +82,18 @@ packages:
dependency: "direct dev"
description:
name: flutter_lints
url: "https://pub.dartlang.org"
sha256: aeb0b80a8b3709709c9cc496cdc027c5b3216796bc0af0ce1007eaf24464fd4c
url: "https://pub.dev"
source: hosted
version: "2.0.1"
flutter_plugin_android_lifecycle:
dependency: transitive
description:
name: flutter_plugin_android_lifecycle
sha256: "950e77c2bbe1692bc0874fc7fb491b96a4dc340457f4ea1641443d0a6c1ea360"
url: "https://pub.dev"
source: hosted
version: "2.0.15"
flutter_test:
dependency: "direct dev"
description: flutter
...
...
@@ -76,44 +108,58 @@ packages:
dependency: transitive
description:
name: js
url: "https://pub.dartlang.org"
sha256: f2c445dce49627136094980615a031419f7f3eb393237e4ecd97ac15dea343f3
url: "https://pub.dev"
source: hosted
version: "0.6.
4
"
version: "0.6.
7
"
lints:
dependency: transitive
description:
name: lints
url: "https://pub.dartlang.org"
sha256: "5e4a9cd06d447758280a8ac2405101e0e2094d2a1dbdd3756aec3fe7775ba593"
url: "https://pub.dev"
source: hosted
version: "2.0.1"
matcher:
dependency: transitive
description:
name: matcher
url: "https://pub.dartlang.org"
sha256: "6501fbd55da300384b768785b83e5ce66991266cec21af89ab9ae7f5ce1c4cbb"
url: "https://pub.dev"
source: hosted
version: "0.12.1
2
"
version: "0.12.1
5
"
material_color_utilities:
dependency: transitive
description:
name: material_color_utilities
url: "https://pub.dartlang.org"
sha256: d92141dc6fe1dad30722f9aa826c7fbc896d021d792f80678280601aff8cf724
url: "https://pub.dev"
source: hosted
version: "0.
1.5
"
version: "0.
2.0
"
meta:
dependency: transitive
description:
name: meta
url: "https://pub.dartlang.org"
sha256: "3c74dbf8763d36539f114c799d8a2d87343b5067e9d796ca22b5eb8437090ee3"
url: "https://pub.dev"
source: hosted
version: "1.
8.0
"
version: "1.
9.1
"
path:
dependency: transitive
description:
name: path
url: "https://pub.dartlang.org"
sha256: "8829d8a55c13fc0e37127c29fedf290c102f4e40ae94ada574091fe0ff96c917"
url: "https://pub.dev"
source: hosted
version: "1.8.3"
plugin_platform_interface:
dependency: transitive
description:
name: plugin_platform_interface
sha256: "6a2128648c854906c53fa8e33986fc0247a1116122f9534dd20e3ab9e16a32bc"
url: "https://pub.dev"
source: hosted
version: "
1.8.2
"
version: "
2.1.4
"
sky_engine:
dependency: transitive
description: flutter
...
...
@@ -123,58 +169,74 @@ packages:
dependency: transitive
description:
name: source_span
url: "https://pub.dartlang.org"
sha256: dd904f795d4b4f3b870833847c461801f6750a9fa8e61ea5ac53f9422b31f250
url: "https://pub.dev"
source: hosted
version: "1.9.
0
"
version: "1.9.
1
"
stack_trace:
dependency: transitive
description:
name: stack_trace
url: "https://pub.dartlang.org"
sha256: c3c7d8edb15bee7f0f74debd4b9c5f3c2ea86766fe4178eb2a18eb30a0bdaed5
url: "https://pub.dev"
source: hosted
version: "1.1
0
.0"
version: "1.1
1
.0"
stream_channel:
dependency: transitive
description:
name: stream_channel
url: "https://pub.dartlang.org"
sha256: "83615bee9045c1d322bbbd1ba209b7a749c2cbcdcb3fdd1df8eb488b3279c1c8"
url: "https://pub.dev"
source: hosted
version: "2.1.
0
"
version: "2.1.
1
"
string_scanner:
dependency: transitive
description:
name: string_scanner
url: "https://pub.dartlang.org"
sha256: "556692adab6cfa87322a115640c11f13cb77b3f076ddcc5d6ae3c20242bedcde"
url: "https://pub.dev"
source: hosted
version: "1.
1.1
"
version: "1.
2.0
"
term_glyph:
dependency: transitive
description:
name: term_glyph
url: "https://pub.dartlang.org"
sha256: a29248a84fbb7c79282b40b8c72a1209db169a2e0542bce341da992fe1bc7e84
url: "https://pub.dev"
source: hosted
version: "1.2.1"
test_api:
dependency: transitive
description:
name: test_api
url: "https://pub.dartlang.org"
sha256: eb6ac1540b26de412b3403a163d919ba86f6a973fe6cc50ae3541b80092fdcfb
url: "https://pub.dev"
source: hosted
version: "0.
4.12
"
version: "0.
5.1
"
url_strategy:
dependency: "direct main"
description:
name: url_strategy
url: "https://pub.dartlang.org"
sha256: "42b68b42a9864c4d710401add17ad06e28f1c1d5500c93b98c431f6b0ea4ab87"
url: "https://pub.dev"
source: hosted
version: "0.2.0"
vector_math:
dependency: transitive
description:
name: vector_math
url: "https://pub.dartlang.org"
sha256: "80b3257d1492ce4d091729e3a67a60407d227c27241d6927be0130c98e741803"
url: "https://pub.dev"
source: hosted
version: "2.1.4"
win32:
dependency: transitive
description:
name: win32
sha256: "6ca3aaab1790eeb1f5cad232e33d9c53ba66e884dd3e7686c4e730bffc45f1a3"
url: "https://pub.dev"
source: hosted
version: "
2.1
.2"
version: "
5.0
.2"
sdks:
dart: ">=
2.18.2 <3
.0.0"
flutter: ">=
1.20
.0"
dart: ">=
3.0.0 <4
.0.0"
flutter: ">=
3.3
.0"
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment