File

src/modules/firetask/components/ft-friends-list/ft-friends-list.ts

Description

Generated class for the FtFriendsListComponent component.

See https://angular.io/api/core/Component for more info on Angular Components.

Metadata

selector ft-friends-list
templateUrl ft-friends-list.html

Index

Properties
Methods

Constructor

constructor(app: App, friends: FtFriendsProvider, session: FtSessionProvider, navCtrl: NavController, events: Events, loader: LoadingController, alert: AlertController)
Parameters :
Name Type Optional Description
app App
friends FtFriendsProvider
session FtSessionProvider
navCtrl NavController
events Events
loader LoadingController
alert AlertController

Methods

Public addFriend
addFriend()

Call the screen to add a new friend

Returns : void
Private bootstrap
bootstrap(shouldShowLoading: boolean)

Friends list initialization

Parameters :
Name Type Optional Description
shouldShowLoading boolean
Returns : void
Public chat
chat(data: any, slidingItem: ItemSliding)

Open the chat screen

Parameters :
Name Type Optional Description
data any
slidingItem ItemSliding
Returns : void
Public delete
delete(entry: any, slidingItem: ItemSliding)

Delete a friend relationship

Parameters :
Name Type Optional Description
entry any
slidingItem ItemSliding
Returns : void
ngOnDestroy
ngOnDestroy()

Turn off subscribers

Returns : void

Properties

Public alert
alert: AlertController
Type : AlertController
Public app
app: App
Type : App
Public events
events: Events
Type : Events
Public friends
friends: FtFriendsProvider
Type : FtFriendsProvider
Public loader
loader: LoadingController
Type : LoadingController
Public navCtrl
navCtrl: NavController
Type : NavController
Public session
session: FtSessionProvider
Type : FtSessionProvider
subscribers
subscribers: any[]
Type : any[]
<div class="not-found" text-center *ngIf="!friends.list.length && !session.loading">
  <ion-icon ios="ios-people" md="md-people"></ion-icon>
  <p padding>You have no friends. <a (tap)="addFriend()">Add a new one over here</a>. They must to also has a Firetask account.</p>
</div>

<br /><br /><br />
<ion-list>
  <ion-item-sliding *ngFor="let user of friends.list" #slidingItem>
    <ion-item (tap)="chat(user, slidingItem)">
      <ion-avatar item-left >
        <img [src]="user.photoURL||'assets/images/user-blank.svg'">
      </ion-avatar>
      <h2>{{user.displayName}}</h2>
      <p>{{user.email}}</p>
      <i class="fa fa-bars fa-lg drag" aria-hidden="true" ></i>
    </ion-item>
    <ion-item-options side="right">
      <button ion-button (tap)="chat(user, slidingItem)" color="secondary">
               <ion-icon name="ios-chatbubbles-outline" style="font-size: 18px;    margin: 7px 0 0 2px;"></ion-icon>
              </button>
      <button ion-button (tap)="delete(user, slidingItem)" color="secondary">
               <ion-icon name="ios-remove-circle-outline" style="font-size: 18px;    margin: 7px 0 0 2px;"></ion-icon>
              </button>
    </ion-item-options>
  </ion-item-sliding>
</ion-list>
Legend
Html element
Component
Html element with directive

results matching ""

    No results matching ""