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
c8fc92fb
Commit
c8fc92fb
authored
May 11, 2017
by
dev0tion
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Reorganise layout
parent
26ed04e4
Show whitespace changes
Inline
Side-by-side
Showing
10 changed files
with
107 additions
and
60 deletions
+107
-60
dashboard.component.css
Breeze.UI/src/app/wallet/dashboard/dashboard.component.css
+0
-0
dashboard.component.html
Breeze.UI/src/app/wallet/dashboard/dashboard.component.html
+36
-0
dashboard.component.spec.ts
...e.UI/src/app/wallet/dashboard/dashboard.component.spec.ts
+0
-0
dashboard.component.ts
Breeze.UI/src/app/wallet/dashboard/dashboard.component.ts
+65
-0
dashboard.component.html
Breeze.UI/src/app/wallet/menu/dashboard.component.html
+0
-2
dashboard.component.ts
Breeze.UI/src/app/wallet/menu/dashboard.component.ts
+0
-42
wallet-routing.module.ts
Breeze.UI/src/app/wallet/wallet-routing.module.ts
+3
-1
wallet.component.css
Breeze.UI/src/app/wallet/wallet.component.css
+0
-12
wallet.component.html
Breeze.UI/src/app/wallet/wallet.component.html
+2
-2
wallet.module.ts
Breeze.UI/src/app/wallet/wallet.module.ts
+1
-1
No files found.
Breeze.UI/src/app/wallet/
menu
/dashboard.component.css
→
Breeze.UI/src/app/wallet/
dashboard
/dashboard.component.css
View file @
c8fc92fb
File moved
Breeze.UI/src/app/wallet/dashboard/dashboard.component.html
0 → 100644
View file @
c8fc92fb
<div
class=
"container"
>
<div
class=
"row"
>
<div
class=
"col"
>
<div>
Active Balance
</div>
<div>
Balance: {{confirmedBalance | coinNotation | coinAbbreviation}}
</div>
</div>
<div
class=
"col"
>
<div>
Current Value
</div>
<div>
Over 9000
</div>
</div>
</div>
<div
class=
"row"
>
<div
class=
"col"
>
<div>
Transactions
</div>
<table
*
ngIf=
"transactions; else noTransactions"
>
<thead>
<th>
Timestamp
</th>
<th>
Amount
</th>
<th>
Confirmed
</th>
<th>
Transaction ID
</th>
</thead>
<tr
*
ngFor=
"let transaction of transactions; let i=index"
>
<div
*
ngIf=
"i<5"
>
<!--<td *ngIf="{{ transaction.amount }} < 0; else received">SENT</td>
<td #received>RECEIVED</td>-->
<td>
{{ transaction.timestamp }}
</td>
<td>
{{ transaction.amount }}
</td>
<td>
{{ transaction.confirmed }}
</td>
<td>
{{ transaction.txId }}
</td>
</div>
</tr>
</table>
<ng-template
#
noTransactions
>
Looks like you haven't had any transactions yet
</ng-template>
</div>
</div>
</div>
Breeze.UI/src/app/wallet/
menu
/dashboard.component.spec.ts
→
Breeze.UI/src/app/wallet/
dashboard
/dashboard.component.spec.ts
View file @
c8fc92fb
File moved
Breeze.UI/src/app/wallet/dashboard/dashboard.component.ts
0 → 100644
View file @
c8fc92fb
import
{
Component
,
OnInit
}
from
'@angular/core'
;
import
{
ApiService
}
from
'../../shared/services/api.service'
;
import
{
GlobalService
}
from
'../../shared/services/global.service'
;
import
{
WalletInfo
}
from
'../../shared/classes/wallet-info'
;
@
Component
({
selector
:
'dashboard-component'
,
templateUrl
:
'./dashboard.component.html'
,
styleUrls
:
[
'./dashboard.component.css'
],
})
export
class
DashboardComponent
{
constructor
(
private
apiService
:
ApiService
,
private
globalService
:
GlobalService
)
{}
private
balanceResponse
:
any
;
private
confirmedBalance
:
number
;
private
unconfirmedBalance
:
number
;
private
transactions
:
any
;
private
errorMessage
:
string
;
ngOnInit
()
{
this
.
getWalletBalance
();
this
.
getHistory
();
};
private
getWalletBalance
()
{
let
walletInfo
=
new
WalletInfo
(
this
.
globalService
.
getWalletName
(),
this
.
globalService
.
getCoinType
())
this
.
apiService
.
getWalletBalance
(
walletInfo
)
.
subscribe
(
response
=>
{
if
(
response
.
status
>=
200
&&
response
.
status
<
400
)
{
this
.
balanceResponse
=
response
.
json
();
this
.
confirmedBalance
=
this
.
balanceResponse
.
balances
[
0
].
amountConfirmed
;
this
.
unconfirmedBalance
=
this
.
balanceResponse
.
balances
[
0
].
amountUnconfirmed
;
}
},
error
=>
{
if
(
error
.
status
>=
400
)
{
this
.
errorMessage
=
<
any
>
error
;
console
.
log
(
this
.
errorMessage
);
}
}
);
};
private
getHistory
()
{
let
walletInfo
=
new
WalletInfo
(
this
.
globalService
.
getWalletName
(),
this
.
globalService
.
getCoinType
())
this
.
apiService
.
getWalletHistory
(
walletInfo
)
.
subscribe
(
response
=>
{
if
(
response
.
status
>=
200
&&
response
.
status
<
400
)
{
if
(
response
.
json
().
transactions
.
length
>
0
)
{
this
.
transactions
=
response
.
json
().
transactions
;
}
}
},
error
=>
{
if
(
error
.
status
>=
400
)
{
this
.
errorMessage
=
<
any
>
error
;
console
.
log
(
this
.
errorMessage
);
}
}
);
};
}
Breeze.UI/src/app/wallet/menu/dashboard.component.html
deleted
100644 → 0
View file @
26ed04e4
<p>
Balance: {{confirmedBalance | coinNotation | coinAbbreviation}}
</p>
<p>
Unconfirmed: {{unconfirmedBalance | coinNotation | coinAbbreviation}}
<p>
Breeze.UI/src/app/wallet/menu/dashboard.component.ts
deleted
100644 → 0
View file @
26ed04e4
import
{
Component
,
OnInit
}
from
'@angular/core'
;
import
{
ApiService
}
from
'../../shared/services/api.service'
;
import
{
GlobalService
}
from
'../../shared/services/global.service'
;
import
{
WalletInfo
}
from
'../../shared/classes/wallet-info'
;
@
Component
({
selector
:
'dashboard-component'
,
templateUrl
:
'./dashboard.component.html'
,
styleUrls
:
[
'./dashboard.component.css'
],
})
export
class
DashboardComponent
{
constructor
(
private
apiService
:
ApiService
,
private
globalService
:
GlobalService
)
{}
private
balanceResponse
:
any
;
private
confirmedBalance
:
number
;
private
unconfirmedBalance
:
number
;
private
errorMessage
:
string
;
ngOnInit
()
{
this
.
getWalletBalance
();
}
private
getWalletBalance
()
{
let
walletInfo
=
new
WalletInfo
(
this
.
globalService
.
getWalletName
(),
this
.
globalService
.
getCoinType
())
this
.
apiService
.
getWalletBalance
(
walletInfo
)
.
subscribe
(
response
=>
{
if
(
response
.
status
>=
200
&&
response
.
status
<
400
)
{
this
.
balanceResponse
=
response
.
json
();
this
.
confirmedBalance
=
this
.
balanceResponse
.
balances
[
0
].
amountConfirmed
;
this
.
unconfirmedBalance
=
this
.
balanceResponse
.
balances
[
0
].
amountUnconfirmed
;
}
},
error
=>
{
if
(
error
.
status
>=
400
)
{
this
.
errorMessage
=
<
any
>
error
;
console
.
log
(
this
.
errorMessage
);
}
}
);
}
}
Breeze.UI/src/app/wallet/wallet-routing.module.ts
View file @
c8fc92fb
...
...
@@ -5,12 +5,14 @@ import { WalletComponent } from './wallet.component';
import
{
SendComponent
}
from
'./send/send.component'
;
import
{
ReceiveComponent
}
from
'./receive/receive.component'
;
import
{
HistoryComponent
}
from
'./history/history.component'
;
import
{
DashboardComponent
}
from
'./dashboard/dashboard.component'
;
const
routes
:
Routes
=
[
{
path
:
''
,
redirectTo
:
'wallet'
,
pathMatch
:
'full'
},
{
path
:
'wallet'
,
component
:
WalletComponent
,
children
:
[
{
path
:
''
,
redirectTo
:
'history'
,
pathMatch
:
'full'
},
{
path
:
''
,
redirectTo
:
'dashboard'
,
pathMatch
:
'full'
},
{
path
:
'dashboard'
,
component
:
DashboardComponent
},
{
path
:
'send'
,
component
:
SendComponent
},
{
path
:
'receive'
,
component
:
ReceiveComponent
},
{
path
:
'history'
,
component
:
HistoryComponent
}
...
...
Breeze.UI/src/app/wallet/wallet.component.css
View file @
c8fc92fb
#sidepanel
{
margin
:
0
;
padding
:
0
;
height
:
100%
;
width
:
200px
;
position
:
fixed
;
overflow
:
auto
;
}
#content
{
margin-left
:
200px
;
}
\ No newline at end of file
Breeze.UI/src/app/wallet/wallet.component.html
View file @
c8fc92fb
<div
id=
"container"
>
<div
id=
"
sidepanel
"
>
<div
id=
"
navigation
"
>
<app-menu></app-menu>
</div>
<div
id=
"content"
>
...
...
Breeze.UI/src/app/wallet/wallet.module.ts
View file @
c8fc92fb
...
...
@@ -4,7 +4,7 @@ import { FormsModule, ReactiveFormsModule } from '@angular/forms';
import
{
WalletComponent
}
from
'./wallet.component'
;
import
{
MenuComponent
}
from
'./menu/menu.component'
;
import
{
DashboardComponent
}
from
'./
menu
/dashboard.component'
;
import
{
DashboardComponent
}
from
'./
dashboard
/dashboard.component'
;
import
{
SendComponent
}
from
'./send/send.component'
;
import
{
ReceiveComponent
}
from
'./receive/receive.component'
;
import
{
HistoryComponent
}
from
'./history/history.component'
;
...
...
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