Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
S
Summative_Sam_Markey
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Boards
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
sam.markey
Summative_Sam_Markey
Commits
53eb1a01
Commit
53eb1a01
authored
May 05, 2021
by
Sam
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fixed crash errors
parent
47b056b8
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
6 additions
and
2 deletions
+6
-2
cafe_activity.java
...java/com/example/museumworld/cafe_shop/cafe_activity.java
+4
-1
shop_activity.java
...java/com/example/museumworld/cafe_shop/shop_activity.java
+1
-1
checkout.java
.../main/java/com/example/museumworld/checkout/checkout.java
+1
-0
No files found.
app/src/main/java/com/example/museumworld/cafe_shop/cafe_activity.java
View file @
53eb1a01
...
...
@@ -178,7 +178,10 @@ public class cafe_activity extends AppCompatActivity implements View.OnClickList
String
cafeQuantity
=
cafeItemList
.
get
(
i
).
getQuantity
();
String
cafeName
=
cafeItemList
.
get
(
i
).
getItem
();
String
cafePrice
=
cafeItemList
.
get
(
i
).
getPrice
();
if
(!
cafeQuantity
.
equals
(
"0"
))
{
if
(!
cafeQuantity
.
equals
(
"0"
)
&&
!
cafeQuantity
.
equals
(
""
))
{
Log
.
d
(
"cafeQuantity"
,
"The q is: "
+
cafeQuantity
);
itemQuantityCafe
.
add
(
cafeQuantity
);
itemNameCafe
.
add
(
cafeName
);
itemPriceCafe
.
add
(
cafePrice
);
...
...
app/src/main/java/com/example/museumworld/cafe_shop/shop_activity.java
View file @
53eb1a01
...
...
@@ -182,7 +182,7 @@ public class shop_activity extends AppCompatActivity implements View.OnClickList
String
shopQuantity
=
shopItemList
.
get
(
i
).
getQuantity
();
String
shopItem
=
shopItemList
.
get
(
i
).
getItem
();
String
shopPriceName
=
shopItemList
.
get
(
i
).
getPrice
();
if
(!
shopQuantity
.
equals
(
"0"
))
{
if
(!
shopQuantity
.
equals
(
"0"
)
&&
!
shopQuantity
.
equals
(
""
)
)
{
itemQuantityShop
.
add
(
shopQuantity
);
itemNameShop
.
add
(
shopItem
);
itemPriceShop
.
add
(
shopPriceName
);
...
...
app/src/main/java/com/example/museumworld/checkout/checkout.java
View file @
53eb1a01
...
...
@@ -131,6 +131,7 @@ public class checkout extends AppCompatActivity implements View.OnClickListener
int
totalCafeItems
=
0
;
int
totalShop
=
0
;
for
(
int
i
=
0
;
i
<
quantity
.
size
();
i
++)
{
int
currentQuantity
=
Integer
.
valueOf
(
quantity
.
get
(
i
));
int
currentPrice
=
Integer
.
valueOf
(
prices
.
get
(
i
));
...
...
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