Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
B
Breeze
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
3
Issues
3
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
DeStream-public
Breeze
Commits
fea31959
Commit
fea31959
authored
Apr 10, 2017
by
dev0tion
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Add status filter to create, recover, history, dashboard and receive components
parent
be60ace9
Hide whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
68 additions
and
17 deletions
+68
-17
login.component.ts
Breeze.UI/src/app/login/login.component.ts
+1
-1
create.component.ts
Breeze.UI/src/app/setup/create/create.component.ts
+15
-1
recover.component.ts
Breeze.UI/src/app/setup/recover/recover.component.ts
+17
-3
history.component.ts
Breeze.UI/src/app/wallet/history/history.component.ts
+11
-2
dashboard.component.ts
Breeze.UI/src/app/wallet/menu/dashboard.component.ts
+13
-8
receive.component.ts
Breeze.UI/src/app/wallet/receive/receive.component.ts
+11
-2
No files found.
Breeze.UI/src/app/login/login.component.ts
View file @
fea31959
...
...
@@ -34,7 +34,7 @@ export class LoginComponent implements OnInit {
},
error
=>
{
this
.
errorMessage
=
<
any
>
error
;
if
(
error
.
status
===
400
)
{
if
(
error
.
status
>
400
)
{
alert
(
this
.
errorMessage
);
console
.
log
(
this
.
errorMessage
);
}
...
...
Breeze.UI/src/app/setup/create/create.component.ts
View file @
fea31959
...
...
@@ -15,7 +15,9 @@ export class CreateComponent {
constructor
(
private
apiService
:
ApiService
)
{}
private
newWallet
:
WalletCreation
;
private
responseMessage
:
string
;
private
errorMessage
:
string
;
private
createWallet
(
password
:
string
,
network
:
string
,
folderPath
:
string
,
name
:
string
,
)
{
this
.
newWallet
=
new
WalletCreation
();
...
...
@@ -26,6 +28,18 @@ export class CreateComponent {
this
.
apiService
.
createWallet
(
this
.
newWallet
)
.
subscribe
((
response
:
string
)
=>
this
.
responseMessage
=
response
);
.
subscribe
(
response
=>
{
if
(
response
.
status
===
200
){
this
.
responseMessage
=
response
;
}
},
error
=>
{
if
(
error
.
status
>
400
){
this
.
errorMessage
=
error
;
console
.
log
(
this
.
errorMessage
);
}
}
);
}
}
Breeze.UI/src/app/setup/recover/recover.component.ts
View file @
fea31959
...
...
@@ -10,8 +10,11 @@ import { WalletRecovery } from '../../shared/wallet-recovery'
export
class
RecoverComponent
implements
OnInit
{
constructor
(
private
apiService
:
ApiService
)
{
}
private
walletRecovery
:
WalletRecovery
;
private
responseBody
:
string
;
private
responseMessage
:
string
;
private
errorMessage
:
string
;
ngOnInit
()
{
}
...
...
@@ -26,7 +29,18 @@ export class RecoverComponent implements OnInit {
this
.
apiService
.
recoverWallet
(
this
.
walletRecovery
)
.
subscribe
((
response
:
string
)
=>
this
.
responseBody
=
response
,
()
=>
console
.
log
(
"recoverWallet() completed"
));
.
subscribe
(
response
=>
{
if
(
response
.
status
===
200
)
{
this
.
responseMessage
=
response
;
}
},
error
=>
{
if
(
error
.
status
>
400
)
{
this
.
errorMessage
=
error
;
console
.
log
(
this
.
errorMessage
);
}
}
);
}
}
\ No newline at end of file
Breeze.UI/src/app/wallet/history/history.component.ts
View file @
fea31959
...
...
@@ -21,8 +21,17 @@ export class HistoryComponent {
private
getWalletHistory
()
{
this
.
apiService
.
getWalletHistory
()
.
subscribe
(
response
=>
this
.
transactions
=
response
.
history
,
error
=>
this
.
errorMessage
=
<
any
>
error
response
=>
{
if
(
response
.
status
===
200
)
{
this
.
transactions
=
response
.
history
;
}
},
error
=>
{
if
(
error
.
status
===
400
)
{
this
.
errorMessage
=
<
any
>
error
;
console
.
log
(
this
.
errorMessage
);
}
}
);
}
}
Breeze.UI/src/app/wallet/menu/dashboard.component.ts
View file @
fea31959
...
...
@@ -21,14 +21,19 @@ export class DashboardComponent {
private
getWalletBalance
()
{
this
.
apiService
.
getWalletBalance
()
.
subscribe
(
response
=>
this
.
balanceResponse
=
response
,
error
=>
this
.
errorMessage
=
<
any
>
error
,
()
=>
this
.
setBalance
()
response
=>
{
if
(
response
.
status
===
200
)
{
this
.
balanceResponse
=
response
this
.
confirmedBalance
=
this
.
balanceResponse
.
confirmed
;
this
.
unconfirmedBalance
=
this
.
balanceResponse
.
unconfirmed
;
}
},
error
=>
{
if
(
error
.
status
>
400
)
{
this
.
errorMessage
=
<
any
>
error
;
console
.
log
(
this
.
errorMessage
);
}
}
);
}
private
setBalance
()
{
this
.
confirmedBalance
=
this
.
balanceResponse
.
confirmed
;
this
.
unconfirmedBalance
=
this
.
balanceResponse
.
unconfirmed
;
}
}
Breeze.UI/src/app/wallet/receive/receive.component.ts
View file @
fea31959
...
...
@@ -21,8 +21,17 @@ export class ReceiveComponent {
private
getUnusedReceiveAddresses
()
{
this
.
apiService
.
getUnusedReceiveAddresses
()
.
subscribe
(
response
=>
this
.
addresses
=
response
.
addresses
,
error
=>
this
.
errorMessage
=
<
any
>
error
response
=>
{
if
(
response
.
status
===
200
)
{
this
.
addresses
=
response
.
addresses
;
}
},
error
=>
{
if
(
error
.
status
>
400
)
{
this
.
errorMessage
=
<
any
>
error
;
console
.
log
(
this
.
errorMessage
);
}
}
);
}
}
\ No newline at end of file
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