Commit 63f64fc5 authored by Laurent's avatar Laurent
Browse files

Display site info on account popup

parent 71b41167
......@@ -80,9 +80,12 @@ export class AccountsController extends Controller {
{
title: account.label,
cancelButtonText: L('cancel'),
actions: [L('delete'), L('account_parameters')]
actions: [L('about'), L('delete'), L('account_parameters')]
})
.then( (result) => {
if (result == L('about'))
return this.displayAccountInfo(account)
if (result == L('account_parameters'))
return this.editAccount(account)
......@@ -154,6 +157,11 @@ export class AccountsController extends Controller {
public displayAccountInfoAction(event) {
let account = event.object.bindingContext
this.displayAccountInfo(account)
}
public displayAccountInfo(account: Account) {
this.navigate( {
moduleName: "views/library/account_info",
bindingContext: (new LibraryController(account, this._manager)).showAccountInfo()
......
<GridLayout colums="auto" row="auto" xmlns:lv="nativescript-ui-listview">
<Label visibility="{{ holds.length || busy == 'on' ? 'collapsed' : 'visible' }}" style="text-align: center; height: 100dip" text="{{ L('no_holds') }}"/>
<lv:RadListView col="0" row="0"
items="{{ holds }}"
id="holds"
......@@ -39,4 +37,6 @@
</StackLayout>
</lv:RadListView.itemTemplate>
</lv:RadListView>
<Label visibility="{{ holds.length || busy == 'on' ? 'collapsed' : 'visible' }}" style="text-align: center; height: 100dip" text="{{ L('no_holds') }}"/>
</GridLayout>
<GridLayout colums="auto" row="auto" xmlns:lv="nativescript-ui-listview">
<Label visibility="{{ loans.length || busy == 'on' ? 'collapsed' : 'visible' }}" style="text-align: center; height: 100dip" text="{{ L('no_loans') }}"/>
<lv:RadListView col="0" row="0"
items="{{ loans }}"
......@@ -46,4 +46,6 @@
</StackLayout>
</lv:RadListView.itemTemplate>
</lv:RadListView>
<Label visibility="{{ loans.length || busy == 'on' ? 'collapsed' : 'visible' }}" style="text-align: center; height: 100dip" text="{{ L('no_loans') }}" col="0" row="0"/>
</GridLayout>
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment