Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
students
rich-maker
Commits
93a47926
Commit
93a47926
authored
Aug 09, 2021
by
Soo Hyun Kim
Browse files
0809 메인 페이지
parent
7d50384d
Changes
2
Show whitespace changes
Inline
Side-by-side
MainScreen.js
View file @
93a47926
...
...
@@ -110,7 +110,6 @@ function MainScreen({ navigation }) {
const
getWeeklyData
=
async
(
start
,
end
)
=>
{
if
(
getDateStr
(
start
)
!==
getDateStr
(
startingDate
))
{
console
.
log
(
'
weekchanged~~~~~~~~~~~~
'
,
start
,
end
)
const
{
data
,
input
,
output
}
=
await
weekApi
.
getWeeklyData
(
start
,
end
)
setStartingDate
(
start
)
setWeekMoney
({
input
:
input
,
output
,
output
})
...
...
db/mainScreen.api.js
View file @
93a47926
...
...
@@ -44,7 +44,6 @@ const getWeeklyData = async (start, end) => {
}
}
})
console
.
log
(
'
실행실행실행
'
)
resolve
({
data
:
temp
,
input
:
input
,
output
:
output
})
})
}
...
...
@@ -53,7 +52,6 @@ const getData = async (findDate) => {
const
db
=
await
getDb
();
return
new
Promise
((
resolve
,
reject
)
=>
{
db
.
transaction
(
async
(
tx
)
=>
{
console
.
log
(
"
get single data
"
);
const
[
txn
,
results
]
=
await
tx
.
executeSql
(
`
SELECT money.type_id, category_name, assets_name, contents, price
FROM money
...
...
@@ -104,7 +102,6 @@ const getData = async (findDate) => {
const
getTotalData
=
async
()
=>
{
const
db
=
await
getDb
();
return
new
Promise
(
async
(
resolve
,
reject
)
=>
{
console
.
log
(
"
get total Money
"
);
let
total
=
0
;
const
temp
=
[];
await
db
.
transaction
(
async
(
tx
)
=>
{
...
...
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