diff --git a/REMEMBER.txt b/REMEMBER.txt
index 0eee62e..25632de 100644
--- a/REMEMBER.txt
+++ b/REMEMBER.txt
@@ -22,6 +22,8 @@ ionic generate page jobactive
ionic generate component taskactivities
ionic generate component suggestedlist
+ionic generate page addjob
+
ionic generate component historyCompletedJobs
diff --git a/src/app/app-routing.module.ts b/src/app/app-routing.module.ts
index ea27988..4954ced 100644
--- a/src/app/app-routing.module.ts
+++ b/src/app/app-routing.module.ts
@@ -274,6 +274,11 @@ const routes: Routes = [
path: 'addjob',
loadChildren: () => import('./pages/addjob/addjob.module').then(m => m.AddjobPageModule)
},
+ {
+ path: 'addfamilykid',
+ loadChildren: () => import('./pages/addfamilykid/addfamilykid.module').then(m => m.AddfamilykidPageModule)
+ },
+
diff --git a/src/app/components/familiy-dash/familiy-dash.component.html b/src/app/components/familiy-dash/familiy-dash.component.html
index 5f725dc..73d2c3d 100644
--- a/src/app/components/familiy-dash/familiy-dash.component.html
+++ b/src/app/components/familiy-dash/familiy-dash.component.html
@@ -1,7 +1,36 @@
0">
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+ {{item.short_title}}
+ {{item.short_description}}
+
+
+
diff --git a/src/app/components/familiy-dash/familiy-dash.component.scss b/src/app/components/familiy-dash/familiy-dash.component.scss
index e69de29..b0872b6 100644
--- a/src/app/components/familiy-dash/familiy-dash.component.scss
+++ b/src/app/components/familiy-dash/familiy-dash.component.scss
@@ -0,0 +1,162 @@
+.bg_white {
+ display: flex;
+ align-items: flex-start;
+ background-color: white;
+ padding: 5px;
+ box-shadow: 0px 0px 20px 1px rgba(0, 0, 0, 0.1);
+ border-radius: 10px;
+ margin-bottom: 20px;
+ &.OFFERS{
+ background-color: #186875;
+ .name{
+ color: white;
+ }
+ .bg_text{
+ --background-color: white;
+ }
+ }
+ &.INTEREST{
+ background-color: #6b6b08;
+ .name{
+ color: white;
+ }
+ }
+ &.PASTDUEJOB{
+ background-color: #e0b4b4;
+ }
+ &.REVIEWJOB{
+ background-color: #dbefda;
+ }
+ &.bg_alice{
+ background-color: aliceblue;
+ padding: 1px;
+ ion-row{
+ padding:1px;
+ }
+ .detail{
+ font-size: 14px;
+ font-weight: bolder;
+ margin-top: 15px;
+ }
+ }
+ .list {
+ display: flex;
+ align-items: center;
+ width: 100%;
+
+ .back_image {
+ height: 95px;
+ width: 95px;
+ border-radius: 10px;
+ }
+ .banner_image{
+ min-width: 90px;
+ }
+ .detail {
+ width: 100%;
+ margin-left: 10px;
+
+ .bg_text {
+ color: var(--ion-color-primary);
+ background-color: rgba(246, 246, 248, 0.9);
+ font-size: 12px;
+ padding: 2px 5px;
+ border-radius: 5px;
+ //width: 80px;
+ text-align: center;
+ height: 38px;
+ width: 100%;
+ overflow: hidden;
+ .ovf{
+ overflow: hidden;
+ }
+ }
+
+ .name {
+ font-family: 'bold';
+ margin-top: 5px;
+ padding: 5px;
+ }
+
+ .price {
+ margin-top: 3px;
+ color: var(--ion-color-primary);
+ font-family: 'semi-bold';
+ }
+
+ .row {
+ display: flex;
+ align-items: center;
+ margin-top: 3px;
+
+ ion-icon {
+ font-size: 18px;
+ }
+
+ .small {
+ margin-left: 8px;
+ color: grey;
+ font-size: 14px;
+ }
+ }
+ }
+
+ }
+ .blog_list {
+ //background-color: lightgrey !important;
+ display: flex;
+ align-items: center;
+
+ .back_image {
+ height: 95px;
+ width: 95px !important;
+ border-radius: 10px;
+ }
+ .banner_image{
+ min-width: 90px;
+ //float: right;
+ //display: flex;
+ //justify-content: flex-end
+ }
+ .detail {
+ margin-left: 10px;
+
+ .bg_text {
+ color: var(--ion-color-primary);
+ background-color: #dfe1f3;
+ font-size: 12px;
+ padding: 2px 5px;
+ border-radius: 5px;
+ //width: 80px;
+ text-align: center;
+ }
+
+ .name {
+ font-family: 'bold';
+ margin-top: 5px;
+ }
+
+ .price {
+ margin-top: 3px;
+ color: var(--ion-color-primary);
+ font-family: 'semi-bold';
+ }
+
+ .row {
+ display: flex;
+ align-items: center;
+ margin-top: 3px;
+
+ ion-icon {
+ font-size: 18px;
+ }
+
+ .small {
+ margin-left: 8px;
+ color: grey;
+ font-size: 14px;
+ }
+ }
+ }
+ }
+}
diff --git a/src/app/components/familiy-dash/familiy-dash.component.ts b/src/app/components/familiy-dash/familiy-dash.component.ts
index 5bd2063..ef0bc8f 100644
--- a/src/app/components/familiy-dash/familiy-dash.component.ts
+++ b/src/app/components/familiy-dash/familiy-dash.component.ts
@@ -1,8 +1,9 @@
-import { Component, OnInit } from '@angular/core';
+import {Component, Input, OnInit} from '@angular/core';
import {NavController} from "@ionic/angular";
import {Router} from "@angular/router";
import {SessionDataProviderService} from "../../store/session-data-provider.service";
import {WrenchService} from "../../services/wrench.service";
+import {BannersDataService} from "../../store/banners-data.service";
@Component({
selector: 'app-familiy-dash',
@@ -10,13 +11,17 @@ import {WrenchService} from "../../services/wrench.service";
styleUrls: ['./familiy-dash.component.scss'],
})
export class FamiliyDashComponent implements OnInit {
- family_dash_show:number = 0;
+ @Input('bannerData') bannerData:any;
+ homebannerCount:number=0;
+ family_action:string="";
+ family_dash_show:number =10;
pageItem:{
page_name: number
}
constructor(private navctr: NavController,
private router: Router,
+ public bannersDataService:BannersDataService,
public sessionDataProviderService: SessionDataProviderService,
private wrenchService: WrenchService) {
@@ -25,7 +30,7 @@ export class FamiliyDashComponent implements OnInit {
});
addEventListener('app_familiy_nokids_action', () => {
- this.router.navigate(['family'],{state: this.pageItem});
+ this.router.navigate(['addfamilykid'],{state: this.pageItem});
});
addEventListener('app_familiy_notask_action', () => {
@@ -40,6 +45,61 @@ export class FamiliyDashComponent implements OnInit {
this.router.navigate(['family'],{state: this.pageItem});
});
+ var interval = setInterval( ()=> {
+ this.bannerData = this.bannersDataService.bannerData;
+ this.homebannerCount = this.bannersDataService.homebannerCount;
+ console.log("IM THE FAM HOME DASH ****** ");
+ }, 5000);
+
+ this.family_action = this.sessionDataProviderService.family_action;
+ }
+
+ onDetails(item) {
+ // var pageToNavigate = 'detail';
+ var pageToNavigate = '';
+ // alert(item.link_path);
+ switch (item.link_path){
+ case 'referral':
+ pageToNavigate = 'invite';
+ break;
+ case 'mytask': // offers waiting to start
+ pageToNavigate = 'joboffers';
+ break;
+
+ case 'my-coupon':
+ pageToNavigate = 'mycoupons';
+ break;
+ case 'blog-page':
+ // this.blogDetails(this.getOneBlog(item));
+ // this.getOneBlog(item);
+ break;
+
+ case 'my-review-jobs':
+ pageToNavigate = 'jobmanager';
+ break
+
+ case 'my-pastdue-jobs':
+ pageToNavigate = 'jobmanager';
+ break
+
+ case 'pend-interest':
+ pageToNavigate ='pendinterest';
+ break;
+
+
+
+ case 'offer-interest':
+ pageToNavigate = 'jobinterest';
+ break
+
+ case 'acc-family':
+ pageToNavigate = 'family';
+ break;
+
+ }
+ if(pageToNavigate !=''){
+ this.router.navigate([pageToNavigate],{state: item});
+ }
}
ngOnInit() {}
diff --git a/src/app/components/familycards/familiy-nokids/familiy-nokids.component.html b/src/app/components/familycards/familiy-nokids/familiy-nokids.component.html
index 41d67ec..1bf326b 100644
--- a/src/app/components/familycards/familiy-nokids/familiy-nokids.component.html
+++ b/src/app/components/familycards/familiy-nokids/familiy-nokids.component.html
@@ -1,19 +1,36 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
- Add Kids
-
-
+ Add Kids
+
-
-
- .
-
-
+
+
+ Add kids, invite relatives or groups, and plan and send rewards in one place.
+
+
+
+
\ No newline at end of file
diff --git a/src/app/components/familycards/familiy-nokids/familiy-nokids.component.scss b/src/app/components/familycards/familiy-nokids/familiy-nokids.component.scss
index 445731a..e64b340 100644
--- a/src/app/components/familycards/familiy-nokids/familiy-nokids.component.scss
+++ b/src/app/components/familycards/familiy-nokids/familiy-nokids.component.scss
@@ -1,6 +1,15 @@
-ion-card{
+ion-card {
+ margin: 20px 0px 0px 0px;
+ background-color: #186875;
+ color: white;
+ ion-card-title{
+ color: white;
+ }
+}
+
+ion-card_2{
margin:20px 0px 0px 0px;
- height: 130px;
+ height: 230px;
padding: 0px;
background-image: url("https://www.wrenchboard.com/assets/images/apps/dash-family-card-nokid.png");
background-size: cover;
diff --git a/src/app/pages/addfamilykid/addfamilykid-routing.module.ts b/src/app/pages/addfamilykid/addfamilykid-routing.module.ts
new file mode 100644
index 0000000..26f0c9a
--- /dev/null
+++ b/src/app/pages/addfamilykid/addfamilykid-routing.module.ts
@@ -0,0 +1,17 @@
+import { NgModule } from '@angular/core';
+import { Routes, RouterModule } from '@angular/router';
+
+import { AddfamilykidPage } from './addfamilykid.page';
+
+const routes: Routes = [
+ {
+ path: '',
+ component: AddfamilykidPage
+ }
+];
+
+@NgModule({
+ imports: [RouterModule.forChild(routes)],
+ exports: [RouterModule],
+})
+export class AddfamilykidPageRoutingModule {}
diff --git a/src/app/pages/addfamilykid/addfamilykid.module.ts b/src/app/pages/addfamilykid/addfamilykid.module.ts
new file mode 100644
index 0000000..28de7f9
--- /dev/null
+++ b/src/app/pages/addfamilykid/addfamilykid.module.ts
@@ -0,0 +1,20 @@
+import { NgModule } from '@angular/core';
+import { CommonModule } from '@angular/common';
+import { FormsModule } from '@angular/forms';
+
+import { IonicModule } from '@ionic/angular';
+
+import { AddfamilykidPageRoutingModule } from './addfamilykid-routing.module';
+
+import { AddfamilykidPage } from './addfamilykid.page';
+
+@NgModule({
+ imports: [
+ CommonModule,
+ FormsModule,
+ IonicModule,
+ AddfamilykidPageRoutingModule
+ ],
+ declarations: [AddfamilykidPage]
+})
+export class AddfamilykidPageModule {}
diff --git a/src/app/pages/addfamilykid/addfamilykid.page.html b/src/app/pages/addfamilykid/addfamilykid.page.html
new file mode 100644
index 0000000..cfc2a89
--- /dev/null
+++ b/src/app/pages/addfamilykid/addfamilykid.page.html
@@ -0,0 +1,144 @@
+
+
+
+
+
+
+
+ Add Kid
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ Birthday(Year/Month)
+
+
+
+
+
+
+
+
Year
+
+
+
+ {{item1}}
+
+
+
+
+
+
+
+
+
+
Month
+
+
+
+ {{item[1]}}
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ {{addFamilyResult}}
+ Add
+
+
+
+
+
+
+
diff --git a/src/app/pages/addfamilykid/addfamilykid.page.scss b/src/app/pages/addfamilykid/addfamilykid.page.scss
new file mode 100644
index 0000000..e69de29
diff --git a/src/app/pages/addfamilykid/addfamilykid.page.spec.ts b/src/app/pages/addfamilykid/addfamilykid.page.spec.ts
new file mode 100644
index 0000000..65e754c
--- /dev/null
+++ b/src/app/pages/addfamilykid/addfamilykid.page.spec.ts
@@ -0,0 +1,24 @@
+import { ComponentFixture, TestBed, waitForAsync } from '@angular/core/testing';
+import { IonicModule } from '@ionic/angular';
+
+import { AddfamilykidPage } from './addfamilykid.page';
+
+describe('AddfamilykidPage', () => {
+ let component: AddfamilykidPage;
+ let fixture: ComponentFixture;
+
+ beforeEach(waitForAsync(() => {
+ TestBed.configureTestingModule({
+ declarations: [ AddfamilykidPage ],
+ imports: [IonicModule.forRoot()]
+ }).compileComponents();
+
+ fixture = TestBed.createComponent(AddfamilykidPage);
+ component = fixture.componentInstance;
+ fixture.detectChanges();
+ }));
+
+ it('should create', () => {
+ expect(component).toBeTruthy();
+ });
+});
diff --git a/src/app/pages/addfamilykid/addfamilykid.page.ts b/src/app/pages/addfamilykid/addfamilykid.page.ts
new file mode 100644
index 0000000..8ca6c36
--- /dev/null
+++ b/src/app/pages/addfamilykid/addfamilykid.page.ts
@@ -0,0 +1,111 @@
+import {Component, OnInit, ViewChild} from '@angular/core';
+import {SessionDataProviderService} from "../../store/session-data-provider.service";
+import {WrenchService} from "../../services/wrench.service";
+import {LoadingController, NavController} from "@ionic/angular";
+
+@Component({
+ selector: 'app-addfamilykid',
+ templateUrl: './addfamilykid.page.html',
+ styleUrls: ['./addfamilykid.page.scss'],
+})
+export class AddfamilykidPage implements OnInit {
+
+ @ViewChild('firstname') firstname;
+ @ViewChild('lastname') lastname;
+ @ViewChild('month') month;
+ @ViewChild('year') year;
+ addFamilyResult:string='';
+
+
+ constructor(
+ private navctr: NavController,
+ public sessionDataProviderService: SessionDataProviderService,
+ private wrenchService: WrenchService,
+ private loadingCtrl: LoadingController
+ ) { }
+
+ regMonth:any;
+ regYear:any;
+ ngOnInit() {
+ this.regMonth=this.sessionDataProviderService.getMonths();
+ this.regYear = this.sessionDataProviderService.getChildAddYears();
+ //debugger;
+ }
+
+ onBack() {
+ this.navctr.back();
+ }
+
+
+ isDisabled:boolean= true;
+ verifyEntry(){
+ this.isDisabled= true;
+ if ( this.firstname.length> 1 && this.lastname.length> 1 && this.month> 0 && this.year> 0 ){
+ this.isDisabled= false;
+ }
+ }
+ /*
+ 'member_id' => int 1
+ 'sessionid' => string '9C780E24425EBE70E1AE3D385193E6FF0DF839A5CA62CD6A6DCE9A5065530968' (length=64)
+ 'uid' => string '3119b744-42ad-4834-bb83-b737588754ca' (length=36)
+ 'firstname' => string 'First406' (length=8)
+ 'lastname' => string 'Last151' (length=7)
+ 'year' => int 2002
+ 'month' => int 8
+ 'action' => int 22015
+ */
+ reqData: {
+ action:number,
+ member_id: number,
+ uid: string,
+ sessionid: string,
+ firstname:string,
+ lastname: string,
+ month: number,
+ year: number
+ };
+
+ createFamilyResult:any;
+
+ async addFamilyMember(){
+ const loading = await this.loadingCtrl.create({
+ message: 'Creating Family Member...',
+ duration: 5000,
+ });
+
+ this.reqData={
+ action:22015,
+ member_id: this.sessionDataProviderService.member_id,
+ uid: this.sessionDataProviderService.member_uid,
+ sessionid: this.sessionDataProviderService.session ,
+ firstname: this.firstname,
+ lastname: this.lastname,
+ month: this.month,
+ year: this.year
+ }
+ loading.present();
+
+ this.wrenchService.familyAdd(this.reqData).subscribe(
+ createFamilyResult => {
+ loading.dismiss();
+ this.createFamilyResult = createFamilyResult;
+ console.log("this.wrenchService.createFamilyResult RETURN DATA->", this.createFamilyResult);
+ if (this.createFamilyResult.internal_return> 0){
+ this.firstname='';
+ this.lastname='';
+
+ this.createFamilyResult = "Family Added";
+ setTimeout(()=>{
+ this.createFamilyResult="";
+ this.onBack();
+ },3000);
+ }
+ }
+ );
+ }
+
+
+
+
+
+}
diff --git a/src/app/pages/home/home.page.html b/src/app/pages/home/home.page.html
index 5b45b7c..082b5a0 100644
--- a/src/app/pages/home/home.page.html
+++ b/src/app/pages/home/home.page.html
@@ -75,9 +75,7 @@
-
-
0">
@@ -90,52 +88,51 @@
+
+
+
+
+
+
+ {{item.short_title}}
+ {{item.short_description}}
+
+
+
+
+
+
-
-
-
-
-
- {{item.short_title}}
- {{item.short_description}}
-
-
-
-
-
-
-
-
-
-
-
Recent Blog
See all
diff --git a/src/app/pages/home/home.page.ts b/src/app/pages/home/home.page.ts
index dd1cbea..1d4fcdb 100644
--- a/src/app/pages/home/home.page.ts
+++ b/src/app/pages/home/home.page.ts
@@ -59,7 +59,8 @@ export class HomePage implements OnInit {
addEventListener('dash_tool_mywallet', () => {
this.myWallet();
});
-
+ this.home_dash_type = this.sessionDataProviderService.home_dash_type;
+ //this.home_dash_type = 'FAMILY_PARENT_DASH';
}
allInitFunctions(){
diff --git a/src/app/services/wrench.service.ts b/src/app/services/wrench.service.ts
index d258a23..a55156d 100644
--- a/src/app/services/wrench.service.ts
+++ b/src/app/services/wrench.service.ts
@@ -1,4 +1,4 @@
-import { HttpClient } from '@angular/common/http';
+import {HttpClient, HttpHeaders} from '@angular/common/http';
import { Injectable } from '@angular/core';
import { Observable } from 'rxjs';
//import 'rxjs/add/operator/map';
@@ -21,6 +21,12 @@ export class WrenchService {
this.url = 'https://apigate.lotus.g1.wrenchboard.com/en/wrench/api/v1';
}
getPostData(reqPath:string, reqData): Observable
{
+ let headers = new HttpHeaders({
+ 'Content-Type': 'application/json',
+ /* 'Authorization': this.basic */});
+ let options = { headers: headers };
+
+ headers.append('Content-Type','application/json');
if (reqPath != 'userlogin' && reqPath != 'createuser'
&& reqPath !='stepresetpass' && reqPath !='startresetpasword' && reqPath!='qrlogin' && reqPath!= 'signupcountry'){
@@ -31,7 +37,7 @@ export class WrenchService {
}
}
const apiReturn = this.http.post(
- `${environment.baseUrl}/${reqPath}`,reqData
+ `${environment.baseUrl}/${reqPath}`,reqData, { headers: headers}
);
/*
We have to check if this sessio
diff --git a/src/app/store/session-data-provider.service.ts b/src/app/store/session-data-provider.service.ts
index 1669c3e..7d11e4d 100644
--- a/src/app/store/session-data-provider.service.ts
+++ b/src/app/store/session-data-provider.service.ts
@@ -82,6 +82,9 @@ export class SessionDataProviderService {
family_uid:string='';
family_types:any=[];
history_types:any=[];
+ home_dash_type:string="DEFAULT_HOME_DASH";
+ family_action:string="";
+
session_contructed:boolean = false;
@@ -162,6 +165,9 @@ export class SessionDataProviderService {
this.family_types= loginResult.family_types;
this.history_types =loginResult.history_types;
+ this.home_dash_type =loginResult.home_dash_type;
+ this.family_action =loginResult.family_action;
+
//this.pushNotificationProvider.tagUser(this.session);
this.session_contructed = true;