
<ion-header class="theme_background">
    <button ion-button class="nav_btn floatLeft" menuToggle>
        <ion-icon name="menu"></ion-icon>
    </button>
    <div class="nav_header_title floatLeft">
        <h5>{{'common.Home' | translate}}</h5>
    </div>
    <div class="clear"></div>
    <div class=" widthFull">
        <ion-searchbar [(ngModel)]="myInput" [showCancelButton]="shouldShowCancel" (ionInput)="onInput($event.target.value)" (ionCancel)="onCancel($event)">
        </ion-searchbar>
    </div>

    
</ion-header>
<ion-content>
  <div class="search_local">
  <ion-item>
      <ion-icon name="pin" item-start></ion-icon>
      <h2 *ngIf="selected_location">{{selected_location}}</h2>
      <ion-icon name="ios-create" item-end (click)="edit_place()"></ion-icon>
    </ion-item>
  </div>
  <div *ngIf="selected_location">
   <ion-card-content class="p0" >
    <div *ngIf="!place_choose">
    <div class="">
       <input id="address_signup" (click)="initialize($event)"  class="s_signup_location" placeholder="{{'common.enter_your_address' | translate}}">
       <button ion-button icon-only (click)="get_current()" full class="m0">
          <ion-icon name="locate"></ion-icon> {{'common.Current_Location' | translate}}
        </button>
    </div>
  </div>
  </ion-card-content>
</div>
    <div class="grid-basic-page" *ngIf="result">
        <ion-card *ngFor="let shops of result.shops" (click)="view_shop(shops.id)">
            <div class="shop_banner">
                <img src="{{shops.image}}" onError="this.src='assets/imgs/spa.jpg';">
                <div class="shop_banner_detail">
                    <ion-row>
                        <ion-col col-6 class="p0">
                            <h2>{{shops.shop_name}}</h2>
                            <h4>{{round2Fixed(shops.distance)}} km</h4>
                        </ion-col>
                        <ion-col col-6 class="p0 ratting">
                            <ionic3-star-rating activeIcon="ios-heart" defaultIcon="ios-heart-outline" activeColor="#eb4354" defaultColor="#f4f4f4" readonly="false" [rating]="shops.total_rating">
                            </ionic3-star-rating>

                        </ion-col>
                    </ion-row>
                </div>
                <div class="shop_ratting">
                    {{shops.total_rating}}.0
                </div>
            </div>
        </ion-card>
        <ion-card *ngIf="result.shops.length==0">
          <ion-card-content class="no_shop">
             {{'common.Current_Location' | translate}}
          </ion-card-content>
        </ion-card>
        <ion-infinite-scroll (ionInfinite)="doInfinite($event)">
            <ion-infinite-scroll-content></ion-infinite-scroll-content>
        </ion-infinite-scroll>
        
    </div>
    

    <ion-fab right bottom>
        <button ion-fab (click)="filter()"><ion-icon name="funnel"></ion-icon></button>
    </ion-fab>
</ion-content>

<!--
  Generated template for the HomePage page.

  See http://ionicframework.com/docs/components/#navigation for more info on
  Ionic pages and navigation.
-->
<!-- <ion-header>

  <ion-navbar>
    <ion-title>home</ion-title>
    <span item-end><ion-icon ios="ios-options" (click)="filter()"></ion-icon></span>
  </ion-navbar>

</ion-header>



<ion-content class="grid-basic-page" *ngIf="result">
  <ion-card *ngFor="let shops of result.shops" (click)="view_shop(shops.id)">

    <ion-item>
    <span><h2>{{shops.shop_name}} <ion-icon ios="ios-heart" float-right *ngIf="shops.fav_status==1"></ion-icon> <ion-icon ios="ios-heart-outline" float-right *ngIf="shops.fav_status==0"></ion-icon><h4>{{round2Fixed(shops.distance)}} mi</h4></h2></span>
  </ion-item>

  <img src="{{shops.image}}" onError="this.src='assets/imgs/advance-card-tmntr.jpg';">

  <ion-card-content>
    <p>{{get_elipse(shops.description)}}</p>
  </ion-card-content>

  <ion-row>
    <ion-col>
      <button ion-button icon-start clear small>
        <ion-icon name="thumbs-up"></ion-icon>
        <div>{{shops.fav_count}} Like(s)</div>
      </button>
    </ion-col>
    <ion-col>
      <button ion-button icon-start clear small>
        <ion-icon name="text"></ion-icon>
        <div>{{shops.review_count}} Comment(s)</div>
      </button>
    </ion-col>
    <ion-col>
      <button ion-button icon-start clear small>
        <ion-icon name="star"></ion-icon>
        <div>{{shops.total_rating}} Rate</div>
      </button>
    </ion-col>
  </ion-row>

</ion-card>

<ion-infinite-scroll (ionInfinite)="doInfinite($event)">
   <ion-infinite-scroll-content></ion-infinite-scroll-content>
</ion-infinite-scroll>
  
</ion-content>

>>>>>>> ce70b671b5ce54e2b1f11849c1fe8398e7b85e0f -->
