Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Contribute to GitLab
Sign in / Register
Toggle navigation
Y
Your Cashier
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
Ahmad Abi Mulya
Your Cashier
Commits
1d80eafc
Commit
1d80eafc
authored
Aug 31, 2020
by
Trio Saputra
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
new updated
parent
b0bf33e1
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
3 additions
and
2 deletions
+3
-2
ProductAdapter.java
.../com/example/yourcashiertest/adapters/ProductAdapter.java
+2
-1
colors.xml
app/src/main/res/values/colors.xml
+1
-1
No files found.
app/src/main/java/com/example/yourcashiertest/adapters/ProductAdapter.java
View file @
1d80eafc
...
...
@@ -90,10 +90,11 @@ public class ProductAdapter extends RecyclerView.Adapter<ProductAdapter.ViewHold
binding
.
setPrice
(
rupiah
.
format
(
product
.
getPrice
()));
if
(
product
.
getQuantity
()
>
0
)
{
binding
.
setStock
(
"Available"
);
binding
.
tvStock
.
setTextColor
(
Color
.
parseColor
(
"#
40e0d0
"
));
binding
.
tvStock
.
setTextColor
(
Color
.
parseColor
(
"#
009688
"
));
}
else
{
binding
.
setStock
(
"Sold Out"
);
binding
.
tvStock
.
setTextColor
(
Color
.
parseColor
(
"#BD0303"
));
binding
.
vAdd
.
setEnabled
(
false
);
}
...
...
app/src/main/res/values/colors.xml
View file @
1d80eafc
...
...
@@ -23,7 +23,7 @@
<color
name=
"dot_light_screen2"
>
#A9A9A9
</color>
<color
name=
"dot_light_screen3"
>
#A9A9A9
</color>
<color
name=
"dot_light_screen4"
>
#A9A9A9
</color>
<array
name=
"array_dot_active"
>
<item>
@color/dot_light_screen1
</item>
<item>
@color/dot_light_screen2
</item>
...
...
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