Commit f6b936e8 by muhsin

fixed search bar issue, initial userdata issue

parent 0e941d48
...@@ -3,17 +3,14 @@ ...@@ -3,17 +3,14 @@
<ion-menu> <ion-menu>
<ion-content> <ion-content>
<div class="side_menu_wrapper"> <div class="side_menu_wrapper">
<<<<<<< HEAD
<ion-menu-toggle>
<div class="top_banner" (click)="goToPage('profile')">
=======
<ion-menu-toggle *ngIf="userData"> <ion-menu-toggle *ngIf="userData">
<div class="top_banner"> <div class="top_banner">
>>>>>>> b35f226916e6e5b4feacc30b355445f087230416 <div class="top_image">
<div class="top_image"></div> <img [src]="userData.profilePhoto" />
</div>
<div class="top_detail"> <div class="top_detail">
<h4>{{userData.name}}</h4> <h4>{{ userData.name }}</h4>
<p>{{userData.emailId}}</p> <p>{{ userData.emailId }}</p>
</div> </div>
<div class="clear"></div> <div class="clear"></div>
</div> </div>
...@@ -62,7 +59,7 @@ ...@@ -62,7 +59,7 @@
</ion-split-pane> </ion-split-pane>
</ion-app> </ion-app>
<div class="common_tab" [hidden]="fetchCase() === true"> <div class="common_tab" [hidden]="fetchCase() === true" *ngIf="!isSearchOpen">
<ul> <ul>
<li (click)="goToPage('home')"> <li (click)="goToPage('home')">
<div <div
...@@ -100,7 +97,8 @@ ...@@ -100,7 +97,8 @@
class="icon_sec m6_icon" class="icon_sec m6_icon"
[class.m6_icon_act]="sec_active6" [class.m6_icon_act]="sec_active6"
(click)="setActive6()" (click)="setActive6()"
menuClose></div> menuClose
></div>
</li> </li>
</ul> </ul>
</div> </div>
...@@ -23,6 +23,8 @@ import { SearchmodalPage } from './searchmodal/searchmodal.page'; ...@@ -23,6 +23,8 @@ import { SearchmodalPage } from './searchmodal/searchmodal.page';
styleUrls: ['app.component.scss'] styleUrls: ['app.component.scss']
}) })
export class AppComponent { export class AppComponent {
isSearchOpen = false;
sec_active1 = true; sec_active1 = true;
sec_active2 = false; sec_active2 = false;
sec_active3 = false; sec_active3 = false;
...@@ -56,7 +58,7 @@ export class AppComponent { ...@@ -56,7 +58,7 @@ export class AppComponent {
this.state = loginData; this.state = loginData;
}); });
this.service.get('userData').then(userData => { this.subjectService.getUserData().subscribe(userData => {
if (userData) { if (userData) {
this.userData = JSON.parse(userData); this.userData = JSON.parse(userData);
console.log(userData); console.log(userData);
...@@ -109,7 +111,7 @@ export class AppComponent { ...@@ -109,7 +111,7 @@ export class AppComponent {
} }
setActive1() { setActive1() {
this.sec_active1 = !this.sec_active1; this.sec_active1 = true;
this.sec_active2 = false; this.sec_active2 = false;
this.sec_active3 = false; this.sec_active3 = false;
this.sec_active4 = false; this.sec_active4 = false;
...@@ -117,7 +119,7 @@ export class AppComponent { ...@@ -117,7 +119,7 @@ export class AppComponent {
this.sec_active6 = false; this.sec_active6 = false;
} }
setActive2() { setActive2() {
this.sec_active2 = !this.sec_active2; this.sec_active2 = true;
this.sec_active1 = false; this.sec_active1 = false;
this.sec_active3 = false; this.sec_active3 = false;
this.sec_active4 = false; this.sec_active4 = false;
...@@ -125,7 +127,7 @@ export class AppComponent { ...@@ -125,7 +127,7 @@ export class AppComponent {
this.sec_active6 = false; this.sec_active6 = false;
} }
setActive3() { setActive3() {
this.sec_active3 = !this.sec_active3; this.sec_active3 = true;
this.sec_active1 = false; this.sec_active1 = false;
this.sec_active2 = false; this.sec_active2 = false;
this.sec_active4 = false; this.sec_active4 = false;
...@@ -133,7 +135,7 @@ export class AppComponent { ...@@ -133,7 +135,7 @@ export class AppComponent {
this.sec_active6 = false; this.sec_active6 = false;
} }
setActive4() { setActive4() {
this.sec_active4 = !this.sec_active4; this.sec_active4 = true;
this.sec_active1 = false; this.sec_active1 = false;
this.sec_active2 = false; this.sec_active2 = false;
this.sec_active3 = false; this.sec_active3 = false;
...@@ -141,7 +143,7 @@ export class AppComponent { ...@@ -141,7 +143,7 @@ export class AppComponent {
this.sec_active6 = false; this.sec_active6 = false;
} }
setActive5() { setActive5() {
this.sec_active5 = !this.sec_active5; this.sec_active5 = true;
this.sec_active1 = false; this.sec_active1 = false;
this.sec_active2 = false; this.sec_active2 = false;
this.sec_active3 = false; this.sec_active3 = false;
...@@ -149,7 +151,7 @@ export class AppComponent { ...@@ -149,7 +151,7 @@ export class AppComponent {
this.sec_active6 = false; this.sec_active6 = false;
} }
setActive6() { setActive6() {
this.sec_active6 = !this.sec_active6; this.sec_active6 = true;
this.sec_active1 = false; this.sec_active1 = false;
this.sec_active2 = false; this.sec_active2 = false;
this.sec_active3 = false; this.sec_active3 = false;
...@@ -199,10 +201,19 @@ export class AppComponent { ...@@ -199,10 +201,19 @@ export class AppComponent {
} }
async searchModal() { async searchModal() {
// Hides Bottom navbar items
this.isSearchOpen = true;
const modal = await this.modalController.create({ const modal = await this.modalController.create({
component: SearchmodalPage component: SearchmodalPage
}); });
modal.onDidDismiss().then(dataReturned => {}); // modal.onDidDismiss().then(dataReturned => {
//
// });
// Shows bottom navbar items on component unmount
modal.onWillDismiss().then(() => {
this.isSearchOpen = false;
});
return await modal.present(); return await modal.present();
} }
} }
...@@ -58,13 +58,13 @@ export class ChangedetailsPage implements OnInit { ...@@ -58,13 +58,13 @@ export class ChangedetailsPage implements OnInit {
form.value.password && form.value.password &&
form.value.password != form.value.confirmPassword form.value.password != form.value.confirmPassword
) { ) {
this.register.updatePassword(form.value.password); // this.register.updatePassword(form.value.password);
} else { } else {
alert('Password should match'); alert('Password should match');
} }
// Calls update user data fn // Calls update user data fn
this.register.updateData(form.value, this.userData.uid); // this.register.updateData(form.value, this.userData.uid);
console.log('valid form values', form.value); console.log('valid form values', form.value);
} }
} }
......
<div class="nav_header"> <div class="nav_header">
<ion-menu-toggle> <ion-menu-toggle>
<button class="nav_btn nav_menu floatLeft"> <button class="nav_btn nav_menu floatLeft"></button>
</button>
</ion-menu-toggle> </ion-menu-toggle>
<div class="nav_title floatLeft relative"> <div class="nav_title floatLeft relative">
<!-- <input class="search_bar" placeholder="Search here.. eg:shirts, retailers etc..." (click)="clickSearch()" (input)="searchFun($event.target.value)" #searchText> --> <!-- <input class="search_bar" placeholder="Search here.. eg:shirts, retailers etc..." (click)="clickSearch()" (input)="searchFun($event.target.value)" #searchText> -->
<input class="search_bar" placeholder="Search here.. eg:shirts, retailers etc..." (click)="searchModal()"> <input
class="search_bar"
</div> placeholder="Search here.. eg:shirts, retailers etc..."
<button class="nav_btn nav_search floatRight" *ngIf="!searchShow"> (click)="searchModal()"
</button> />
<button class="nav_btn nav_close floatRight" *ngIf="searchShow" (click)="searchClose()"> </div>
</button> <button
class="nav_btn nav_search floatRight"
*ngIf="!searchShow"
(click)="searchModal()"
></button>
<button
class="nav_btn nav_close floatRight"
*ngIf="searchShow"
(click)="searchClose()"
></button>
<div class="clear"></div> <div class="clear"></div>
</div> </div>
<ion-content> <ion-content>
<div class="home_wrapper"> <div class="home_wrapper">
<div class="home_banner"> <div class="home_banner">
<div class="home_banner_title"> <div class="home_banner_title">
<ion-row> <ion-row>
<ion-col class="textLeft"> <ion-col class="textLeft">
<img src="../assets/Group 11_2.png"> <img src="../assets/Group 11_2.png" />
</ion-col> </ion-col>
<ion-col class="textRight"> <ion-col class="textRight">
<p class="floatRight" (click)="istoggle()">{{address}}</p> <p class="floatRight" (click)="istoggle()">{{address}}</p>
</ion-col> </ion-col>
</ion-row> </ion-row>
</div> </div>
<ion-slides pager="true" *ngIf="centerService.centers && centerService.centers.length > 0"> <ion-slides
pager="true"
*ngIf="centerService.centers && centerService.centers.length > 0"
>
<ion-slide *ngFor="let center of centerService.centers"> <ion-slide *ngFor="let center of centerService.centers">
<div class="banner_slide" (click)="goToPage('storelist', center)"> <div class="banner_slide" (click)="goToPage('storelist', center)">
<h5>{{center.centerName}}</h5> <h5>{{center.centerName}}</h5>
<p>{{center.description}}</p> <p>{{center.description}}</p>
</div> </div>
<img [src]="center.centerImg" onerror="this.src='./../../assets/getmi_malls/mall_banner/mall_4.png'"> <img
[src]="center.centerImg"
onerror="this.src='./../../assets/getmi_malls/mall_banner/mall_4.png'"
/>
</ion-slide> </ion-slide>
</ion-slides> </ion-slides>
</div> </div>
...@@ -44,10 +57,20 @@ ...@@ -44,10 +57,20 @@
Featured Stores Featured Stores
</div> </div>
<div class="featured_slider"> <div class="featured_slider">
<ion-slides pager="false" [options]="slideOpts" *ngIf="shopperService.activeshoppers && shopperService.activeshoppers.length > 0"> <ion-slides
pager="false"
[options]="slideOpts"
*ngIf="shopperService.activeshoppers && shopperService.activeshoppers.length > 0"
>
<ion-slide *ngFor="let shopper of shopperService.activeshoppers"> <ion-slide *ngFor="let shopper of shopperService.activeshoppers">
<div class="feature_product" (click)="goToPage('productlist', shopper)"> <div
<img [src]="shopper.featuredImage" onerror="this.src='./../../assets/getmi_malls/featured/featured1.png'"> class="feature_product"
(click)="goToPage('productlist', shopper)"
>
<img
[src]="shopper.featuredImage"
onerror="this.src='./../../assets/getmi_malls/featured/featured1.png'"
/>
<div class="feature_overlay"> <div class="feature_overlay">
<h5>{{shopper.name}}</h5> <h5>{{shopper.name}}</h5>
<p>{{shopper.caption}}</p> <p>{{shopper.caption}}</p>
...@@ -68,23 +91,30 @@ ...@@ -68,23 +91,30 @@
<div class="home_sub_header"> <div class="home_sub_header">
<span class="floatLeft">Nearby Shopping Centers</span> <span class="floatLeft">Nearby Shopping Centers</span>
<span class="floatRight"> <span class="floatRight">
<div class="nearby_icon" (click)="goToPage('nearby')"> <div class="nearby_icon" (click)="goToPage('nearby')"></div>
</div>
</span> </span>
<div class="clear"></div> <div class="clear"></div>
</div> </div>
<div class="nearby_shop_list"> <div class="nearby_shop_list">
<ul *ngIf="centerService.nearcenters && centerService.nearcenters.length > 0"> <ul
<li *ngFor="let center of centerService.nearcenters" (click)="goToPage('storelist', center)"> *ngIf="centerService.nearcenters && centerService.nearcenters.length > 0"
>
<li
*ngFor="let center of centerService.nearcenters"
(click)="goToPage('storelist', center)"
>
<div class="nearby_image"> <div class="nearby_image">
<img [src]="center.centerImg" onerror="this.src='./../../assets/getmi_malls/mall_298/mall2.png'"> <img
[src]="center.centerImg"
onerror="this.src='./../../assets/getmi_malls/mall_298/mall2.png'"
/>
</div> </div>
<div class="nearby_detail"> <div class="nearby_detail">
<h5> <h5>
<span class="floatLeft">{{center.centerName}}</span> <span class="floatLeft">{{center.centerName}}</span>
<span class="floatRight">0 <span class="floatRight"
<img src="../assets/Path61_2.png"> >0
<img src="../assets/Path61_2.png" />
</span> </span>
<div class="clear"></div> <div class="clear"></div>
</h5> </h5>
...@@ -98,9 +128,17 @@ ...@@ -98,9 +128,17 @@
Featured Catagories Featured Catagories
</div> </div>
<div class="featured_catagory_list"> <div class="featured_catagory_list">
<ul *ngIf="categoriesService.activecategories && categoriesService.activecategories.length > 0"> <ul
<li *ngFor="let categories of categoriesService.activecategories" (click)="goToPage('catstorelist', categories)"> *ngIf="categoriesService.activecategories && categoriesService.activecategories.length > 0"
<img [src]="categories.catImage" onerror="this.src='../assets/handsome-man-outdoors-drinking-coffee-with-sunglasses-guy-with-beard-instagram-effect_1212-818@3x.png'"> >
<li
*ngFor="let categories of categoriesService.activecategories"
(click)="goToPage('catstorelist', categories)"
>
<img
[src]="categories.catImage"
onerror="this.src='../assets/handsome-man-outdoors-drinking-coffee-with-sunglasses-guy-with-beard-instagram-effect_1212-818@3x.png'"
/>
<div class="featured_overlay"> <div class="featured_overlay">
<h4>{{categories.catName}}</h4> <h4>{{categories.catName}}</h4>
</div> </div>
...@@ -112,7 +150,7 @@ ...@@ -112,7 +150,7 @@
<div *ngIf="isShow" [@slideInOut]> <div *ngIf="isShow" [@slideInOut]>
<div class="nav_header"> <div class="nav_header">
<button class="nav_btn nav_back floatLeft" (click)="istoggle()"> <button class="nav_btn nav_back floatLeft" (click)="istoggle()">
<img src="../assets/Group17_2.png"> <img src="../assets/Group17_2.png" />
</button> </button>
<div class="nav_title floatLeft"> <div class="nav_title floatLeft">
<h4>CHANGE LOCATION</h4> <h4>CHANGE LOCATION</h4>
...@@ -120,22 +158,41 @@ ...@@ -120,22 +158,41 @@
<div class="clear"></div> <div class="clear"></div>
</div> </div>
<ion-content class="sort_wrappper"> <ion-content class="sort_wrappper">
<agm-map [zoom]="20" [latitude]="lat" [longitude]="lng" [disableDefaultUI]="false" [zoomControl]="false" [backgroundColor]="'rgba(29, 27, 130,0.2)'"> <agm-map
[zoom]="20"
[latitude]="lat"
[longitude]="lng"
[disableDefaultUI]="false"
[zoomControl]="false"
[backgroundColor]="'rgba(29, 27, 130,0.2)'"
>
<agm-marker [latitude]="lat" [longitude]="lng"></agm-marker> <agm-marker [latitude]="lat" [longitude]="lng"></agm-marker>
</agm-map> </agm-map>
<div class="add_address_wrapper"> <div class="add_address_wrapper">
<h5> <h5>
<span class="floatLeft">NEW ADDRESS</span> <span class="floatLeft">NEW ADDRESS</span>
<span class="floatRight" (click)="istoggle(); goToPage('nearby')">ADD NEW</span> <span class="floatRight" (click)="istoggle(); goToPage('nearby')"
>ADD NEW</span
>
<div class="clear"></div> <div class="clear"></div>
</h5> </h5>
<ul *ngIf="addressService.addressList && addressService.addressList.length > 0"> <ul
*ngIf="addressService.addressList && addressService.addressList.length > 0"
>
<li *ngFor="let address of addressService.addressList; let i = index"> <li *ngFor="let address of addressService.addressList; let i = index">
<div class="floatLeft">{{address.default}} <div class="floatLeft">
<input class="styled-checkbox" name="addressId" id="styled-checkbox-{{i}}" type="radio" (click)="setDefault(address.addressId)" [value]="address.addressId" #addressType [checked]="address.defaultVal == 1"> {{address.default}}
<label for="styled-checkbox-{{i}}"> {{address.addressType}} <input
</label> class="styled-checkbox"
name="addressId"
id="styled-checkbox-{{i}}"
type="radio"
(click)="setDefault(address.addressId)"
[value]="address.addressId"
#addressType
[checked]="address.defaultVal == 1"
/>
<label for="styled-checkbox-{{i}}"> {{address.addressType}} </label>
</div> </div>
<div class="floatLeft"> <div class="floatLeft">
<p> <p>
...@@ -146,14 +203,16 @@ ...@@ -146,14 +203,16 @@
</li> </li>
</ul> </ul>
</div> </div>
</ion-content> </ion-content>
</div> </div>
<div class="search_item_list" *ngIf="searchShow" [@slideInOut]> <div class="search_item_list" *ngIf="searchShow" [@slideInOut]>
<ul *ngIf="searchService.searchList"> <ul *ngIf="searchService.searchList">
<li *ngFor="let search of searchService.searchList" (click)="viewPage(search)">{{search.text}}</li> <li
*ngFor="let search of searchService.searchList"
(click)="viewPage(search)"
>
{{search.text}}
</li>
</ul> </ul>
</div> </div>
<div class="nav_header"> <div class="nav_header">
<button class="nav_btn nav_back floatLeft" (click)="goBack()"> <button class="nav_btn nav_back floatLeft" (click)="goBack()">
<img src="../assets/Group17_2.png"> <img src="../assets/Group17_2.png" />
</button> </button>
<div class="nav_title floatLeft"> <div class="nav_title floatLeft">
<input class="search_bar" placeholder="Search here.. eg:shirts, retailers etc..." (click)="clickSearch()"> <input
class="search_bar"
placeholder="Search here.. eg:shirts, retailers etc..."
(click)="clickSearch()"
/>
</div> </div>
<button class="nav_btn nav_search floatRight" *ngIf="!searchShow"> <button
</button> class="nav_btn nav_search floatRight"
<button class="nav_btn nav_close floatRight" *ngIf="searchShow" (click)="searchClose()"> *ngIf="!searchShow"
</button> (click)="clickSearch()"
></button>
<button
class="nav_btn nav_close floatRight"
*ngIf="searchShow"
(click)="searchClose()"
></button>
<div class="clear"></div> <div class="clear"></div>
</div> </div>
<ion-content> <ion-content>
<div class="product_list"> <div class="product_list">
<div class="product_taskbar"> <div class="product_taskbar">
<div class="filter floatLeft" (click)="istoggle()"> <div class="filter floatLeft" (click)="istoggle()"></div>
</div>
<div class="viewset floatRight"> <div class="viewset floatRight">
<div class="grid_view grid_act floatRight" (click)="gridToggle()" [class.line_view]="onGrid"> <div
</div> class="grid_view grid_act floatRight"
(click)="gridToggle()"
[class.line_view]="onGrid"
></div>
<div class="clear"></div> <div class="clear"></div>
</div> </div>
<div class="clear"></div> <div class="clear"></div>
...@@ -28,16 +38,29 @@ ...@@ -28,16 +38,29 @@
<div class="product_title" *ngIf="data"> <div class="product_title" *ngIf="data">
{{data.shopName}} {{data.shopName}}
</div> </div>
<ul [class.grid_view]="onGrid" *ngIf="prodService.product && prodService.product.length > 0"> <ul
[class.grid_view]="onGrid"
*ngIf="prodService.product && prodService.product.length > 0"
>
<li *ngFor="let product of prodService.product; let i = index"> <li *ngFor="let product of prodService.product; let i = index">
<div class="product_image"> <div class="product_image">
<img [src]="product.image" onerror="this.src='../assets/[email protected]'" (click)="prodDetails(i)"> <img
<div [ngClass]="checkFavStatus(product.prodId)" (click)="changeFav(product.prodId)"> [src]="product.image"
</div> onerror="this.src='../assets/[email protected]'"
(click)="prodDetails(i)"
/>
<div
[ngClass]="checkFavStatus(product.prodId)"
(click)="changeFav(product.prodId)"
></div>
<div class="featured_badge" *ngIf="product.featured">Featured</div> <div class="featured_badge" *ngIf="product.featured">Featured</div>
</div> </div>
<h5 class="ellipse" (click)="prodDetails(i)">{{product.prodName}}</h5> <h5 class="ellipse" (click)="prodDetails(i)">{{product.prodName}}</h5>
<p (click)="prodDetails(i)">A$ {{product.price}}<span class="offer" *ngIf="product.discount > 0">-{{product.discount}}%</span></p> <p (click)="prodDetails(i)">
A$ {{product.price}}<span class="offer" *ngIf="product.discount > 0"
>-{{product.discount}}%</span
>
</p>
</li> </li>
</ul> </ul>
</div> </div>
...@@ -54,11 +77,25 @@ ...@@ -54,11 +77,25 @@
<label for="styled-checkbox-2">Relevence</label> <label for="styled-checkbox-2">Relevence</label>
</li> --> </li> -->
<li> <li>
<input class="styled-checkbox" id="styled-checkbox-3" type="radio" value="low" name="sort" (click)="setValue($event.target.value)"> <input
class="styled-checkbox"
id="styled-checkbox-3"
type="radio"
value="low"
name="sort"
(click)="setValue($event.target.value)"
/>
<label for="styled-checkbox-3">Price Low - High</label> <label for="styled-checkbox-3">Price Low - High</label>
</li> </li>
<li> <li>
<input class="styled-checkbox" id="styled-checkbox-4" type="radio" value="high" name="sort" (click)="setValue($event.target.value)"> <input
class="styled-checkbox"
id="styled-checkbox-4"
type="radio"
value="high"
name="sort"
(click)="setValue($event.target.value)"
/>
<label for="styled-checkbox-4">Price High - Low</label> <label for="styled-checkbox-4">Price High - Low</label>
</li> </li>
<!-- <li> <!-- <li>
...@@ -68,15 +105,21 @@ ...@@ -68,15 +105,21 @@
</ul> </ul>
<div class="sort_footer"> <div class="sort_footer">
<button class="cancel floatLeft" (click)="istoggle()">CANCEL</button> <button class="cancel floatLeft" (click)="istoggle()">CANCEL</button>
<button class="submit floatRight" (click)="istoggle(); submit()">SUBMIT</button> <button class="submit floatRight" (click)="istoggle(); submit()">
SUBMIT
</button>
<div class="clear"></div> <div class="clear"></div>
</div> </div>
</div> </div>
</div> </div>
</ion-content> </ion-content>
<div class="search_item_list" *ngIf="searchShow" [@slideInOut]> <div class="search_item_list" *ngIf="searchShow" [@slideInOut]>
<ul *ngIf="searchService.searchList"> <ul *ngIf="searchService.searchList">
<li *ngFor="let search of searchService.searchList" (click)="viewPage(search)">{{search.text}}</li> <li
*ngFor="let search of searchService.searchList"
(click)="viewPage(search)"
>
{{search.text}}
</li>
</ul> </ul>
</div> </div>
\ No newline at end of file
<div class="nav_header"> <div class="nav_header">
<button class="nav_btn nav_back floatLeft" (click)="closeModal()"> <button class="nav_btn nav_back floatLeft" (click)="closeModal()"></button>
</button>
<div class="nav_title floatLeft relative"> <div class="nav_title floatLeft relative">
<input class="search_bar" placeholder="Search here.. eg:shirts, retailers etc..." (click)="clickSearch()" (input)="searchFun($event.target.value)" #searchText> <input
class="search_bar"
placeholder="Search here.. eg:shirts, retailers etc..."
(click)="clickSearch()"
(input)="searchFun($event.target.value)"
#searchText
/>
</div> </div>
<button class="nav_btn nav_close floatRight" (click)="closeModal()"> <button class="nav_btn nav_close floatRight" (click)="closeModal()"></button>
</button>
<div class="clear"></div> <div class="clear"></div>
</div> </div>
<div class="search_item_list"> <div class="search_item_list">
<ul *ngIf="searchService.searchList"> <ul *ngIf="searchService.searchList">
<li *ngFor="let search of searchService.searchList" (click)="viewPage(search)">{{search.text}} </li> <li
*ngFor="let search of searchService.searchList"
(click)="viewPage(search)"
>
{{search.text}}
</li>
</ul> </ul>
</div> </div>
<div class="nav_header"> <div class="nav_header">
<button class="nav_btn nav_back floatLeft" (click)="goBack()"> <button class="nav_btn nav_back floatLeft" (click)="goBack()"></button>
</button>
<div class="nav_title floatLeft"> <div class="nav_title floatLeft">
<input class="search_bar" placeholder="Search here.. eg:shirts, retailers etc..." (click)="clickSearch()"> <input
class="search_bar"
placeholder="Search here.. eg:shirts, retailers etc..."
(click)="clickSearch()"
/>
</div> </div>
<button class="nav_btn nav_search floatRight" *ngIf="!searchShow"> <button
</button> class="nav_btn nav_search floatRight"
<button class="nav_btn nav_close floatRight" *ngIf="searchShow" (click)="searchClose()"> *ngIf="!searchShow"
</button> (click)="clickSearch()"
></button>
<button
class="nav_btn nav_close floatRight"
*ngIf="searchShow"
(click)="searchClose()"
></button>
<div class="clear"></div> <div class="clear"></div>
</div> </div>
<ion-content> <ion-content>
...@@ -16,10 +25,20 @@ ...@@ -16,10 +25,20 @@
Featured Stores Featured Stores
</div> </div>
<div class="featured_slider"> <div class="featured_slider">
<ion-slides pager="false" [options]="slideOpts" *ngIf="shopperService.activeshoppers && shopperService.activeshoppers.length > 0"> <ion-slides
pager="false"
[options]="slideOpts"
*ngIf="shopperService.activeshoppers && shopperService.activeshoppers.length > 0"
>
<ion-slide *ngFor="let shopper of shopperService.activeshoppers"> <ion-slide *ngFor="let shopper of shopperService.activeshoppers">
<div class="feature_product" (click)="goToPage('productlist', shopper)"> <div
<img [src]="shopper.featuredImage" onerror="this.src='./../../assets/getmi_malls/featured/featured1.png'"> class="feature_product"
(click)="goToPage('productlist', shopper)"
>
<img
[src]="shopper.featuredImage"
onerror="this.src='./../../assets/getmi_malls/featured/featured1.png'"
/>
<div class="feature_overlay"> <div class="feature_overlay">
<h5>{{shopper.name}}</h5> <h5>{{shopper.name}}</h5>
<p>{{shopper.caption}}</p> <p>{{shopper.caption}}</p>
...@@ -33,15 +52,22 @@ ...@@ -33,15 +52,22 @@
</div> </div>
<div class="nearby_shop_list"> <div class="nearby_shop_list">
<ul *ngIf="shopperService.shoppers && shopperService.shoppers.length > 0"> <ul *ngIf="shopperService.shoppers && shopperService.shoppers.length > 0">
<li *ngFor="let shopper of shopperService.shoppers" (click)="goToPage('productlist', shopper)"> <li
*ngFor="let shopper of shopperService.shoppers"
(click)="goToPage('productlist', shopper)"
>
<div class="nearby_image"> <div class="nearby_image">
<img [src]="shopper.profilePic" onerror="this.src='./../../assets/getmi_malls/store298/stores1.png'"> <img
[src]="shopper.profilePic"
onerror="this.src='./../../assets/getmi_malls/store298/stores1.png'"
/>
</div> </div>
<div class="nearby_detail"> <div class="nearby_detail">
<h5> <h5>
<span class="floatLeft">{{shopper.name}}</span> <span class="floatLeft">{{shopper.name}}</span>
<span class="floatRight">0 <span class="floatRight"
<img src="../assets/Path61_2.png"> >0
<img src="../assets/Path61_2.png" />
</span> </span>
<div class="clear"></div> <div class="clear"></div>
</h5> </h5>
...@@ -52,7 +78,6 @@ ...@@ -52,7 +78,6 @@
</ul> </ul>
</div> </div>
</div> </div>
</ion-content> </ion-content>
<div class="search_item_list" *ngIf="searchShow" [@slideInOut]> <div class="search_item_list" *ngIf="searchShow" [@slideInOut]>
......
...@@ -150,6 +150,7 @@ export class AuthService { ...@@ -150,6 +150,7 @@ export class AuthService {
}; };
this.loggedUser = userData; this.loggedUser = userData;
this.service.set('userData', JSON.stringify(this.loggedUser)); this.service.set('userData', JSON.stringify(this.loggedUser));
this.subjectService.sendUserData(JSON.stringify(this.loggedUser));
console.log(this.loggedUser); console.log(this.loggedUser);
}); });
} }
......
...@@ -7,6 +7,7 @@ import { BehaviorSubject } from 'rxjs/BehaviorSubject'; ...@@ -7,6 +7,7 @@ import { BehaviorSubject } from 'rxjs/BehaviorSubject';
}) })
export class SubjectService { export class SubjectService {
private loginState = new BehaviorSubject<any>(null); private loginState = new BehaviorSubject<any>(null);
private DataState = new BehaviorSubject<any>(null);
sendLoginData(state: any) { sendLoginData(state: any) {
this.loginState.next(state); this.loginState.next(state);
...@@ -15,4 +16,12 @@ export class SubjectService { ...@@ -15,4 +16,12 @@ export class SubjectService {
getLoginData(): Observable<any> { getLoginData(): Observable<any> {
return this.loginState.asObservable(); return this.loginState.asObservable();
} }
sendUserData(state: any) {
this.DataState.next(state);
}
getUserData(): Observable<any> {
return this.DataState.asObservable();
}
} }
...@@ -9,25 +9,24 @@ ...@@ -9,25 +9,24 @@
* https://ionicframework.com/docs/layout/global-stylesheets * https://ionicframework.com/docs/layout/global-stylesheets
*/ */
/* Core CSS required for Ionic components to work properly */ /* Core CSS required for Ionic components to work properly */
@import "~@ionic/angular/css/core.css"; @import '~@ionic/angular/css/core.css';
/* Basic CSS for apps built with Ionic */ /* Basic CSS for apps built with Ionic */
@import "~@ionic/angular/css/normalize.css"; @import '~@ionic/angular/css/normalize.css';
@import "~@ionic/angular/css/structure.css"; @import '~@ionic/angular/css/structure.css';
@import "~@ionic/angular/css/typography.css"; @import '~@ionic/angular/css/typography.css';
@import '~@ionic/angular/css/display.css'; @import '~@ionic/angular/css/display.css';
/* Optional CSS utils that can be commented out */ /* Optional CSS utils that can be commented out */
@import "~@ionic/angular/css/padding.css"; @import '~@ionic/angular/css/padding.css';
@import "~@ionic/angular/css/float-elements.css"; @import '~@ionic/angular/css/float-elements.css';
@import "~@ionic/angular/css/text-alignment.css"; @import '~@ionic/angular/css/text-alignment.css';
@import "~@ionic/angular/css/text-transformation.css"; @import '~@ionic/angular/css/text-transformation.css';
@import "~@ionic/angular/css/flex-utils.css"; @import '~@ionic/angular/css/flex-utils.css';
/* /*
Site Name: GETME Site Name: GETME
...@@ -54,7 +53,6 @@ ...@@ -54,7 +53,6 @@
*/ */
/*------------------------------- /*-------------------------------
01. FONTS-N-SIZES 01. FONTS-N-SIZES
...@@ -84,8 +82,8 @@ button { ...@@ -84,8 +82,8 @@ button {
outline: none; outline: none;
} }
input[type=number]::-webkit-inner-spin-button, input[type='number']::-webkit-inner-spin-button,
input[type=number]::-webkit-outer-spin-button { input[type='number']::-webkit-outer-spin-button {
-webkit-appearance: none !important; -webkit-appearance: none !important;
margin: 0; margin: 0;
} }
...@@ -165,7 +163,6 @@ button { ...@@ -165,7 +163,6 @@ button {
} }
} }
/*------------------------------- /*-------------------------------
02. FONTS-SETTINGS 02. FONTS-SETTINGS
...@@ -216,7 +213,6 @@ button { ...@@ -216,7 +213,6 @@ button {
font-weight: 600 !important; font-weight: 600 !important;
} }
/*------------------------------- /*-------------------------------
03. THEMES-N-BACKGROUNDS 03. THEMES-N-BACKGROUNDS
...@@ -248,7 +244,6 @@ button { ...@@ -248,7 +244,6 @@ button {
background-color: rgba(243, 243, 243, 0.6) !important; background-color: rgba(243, 243, 243, 0.6) !important;
} }
/*------------------------------- /*-------------------------------
04. SPACING-N-POSITIONS 04. SPACING-N-POSITIONS
...@@ -367,7 +362,6 @@ button { ...@@ -367,7 +362,6 @@ button {
border: none !important; border: none !important;
} }
/*------------------------------- /*-------------------------------
05. ALIGMENTS 05. ALIGMENTS
...@@ -497,7 +491,7 @@ app-deliverypop { ...@@ -497,7 +491,7 @@ app-deliverypop {
.nav_back { .nav_back {
background-color: #fff !important; background-color: #fff !important;
background-image: url("./assets/Group17_2.png"); background-image: url('./assets/Group17_2.png');
img { img {
width: 25px; width: 25px;
display: none; display: none;
...@@ -506,7 +500,7 @@ app-deliverypop { ...@@ -506,7 +500,7 @@ app-deliverypop {
.nav_back_white { .nav_back_white {
background-color: transparent; background-color: transparent;
background-image: url("./assets/arrow_white.png"); background-image: url('./assets/arrow_white.png');
img { img {
width: 25px !important; width: 25px !important;
display: none; display: none;
...@@ -514,7 +508,7 @@ app-deliverypop { ...@@ -514,7 +508,7 @@ app-deliverypop {
} }
.nav_menu { .nav_menu {
background-image: url("./assets/Group22_2.png"); background-image: url('./assets/Group22_2.png');
img { img {
width: 25px; width: 25px;
display: none; display: none;
...@@ -522,7 +516,7 @@ app-deliverypop { ...@@ -522,7 +516,7 @@ app-deliverypop {
} }
.nav_search { .nav_search {
background-image: url("./assets/search_2.png"); background-image: url('./assets/search_2.png');
img { img {
width: 25px; width: 25px;
display: none; display: none;
...@@ -530,7 +524,7 @@ app-deliverypop { ...@@ -530,7 +524,7 @@ app-deliverypop {
} }
.nav_exit { .nav_exit {
background-image: url("./assets/Group17_2.png"); background-image: url('./assets/Group17_2.png');
img { img {
width: 25px; width: 25px;
display: none; display: none;
...@@ -538,7 +532,7 @@ app-deliverypop { ...@@ -538,7 +532,7 @@ app-deliverypop {
} }
.nav_close { .nav_close {
background-image: url("./assets/close.png"); background-image: url('./assets/close.png');
img { img {
width: 25px; width: 25px;
display: none; display: none;
...@@ -546,7 +540,7 @@ app-deliverypop { ...@@ -546,7 +540,7 @@ app-deliverypop {
} }
.nav_cart { .nav_cart {
background-image: url("./assets/cart_icon.png"); background-image: url('./assets/cart_icon.png');
img { img {
width: 25px; width: 25px;
display: none; display: none;
......
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