new task on home
This commit is contained in:
@@ -1,110 +1,45 @@
|
||||
<div class="ion-padding">
|
||||
<!-- <div class="flex hdt">-->
|
||||
<!-- <ion-label class="bold_text">You have {{total_offers}} Offer(s)</ion-label>-->
|
||||
<!-- </div>-->
|
||||
|
||||
<div *ngIf="total_offers>3;">
|
||||
<ion-accordion-group>
|
||||
<ion-accordion *ngFor="let item of myOffersData" value="{{item.offer_uid}}">
|
||||
<ion-item slot="header" color="light">
|
||||
<ion-label>{{item.title}}</ion-label>
|
||||
</ion-item>
|
||||
<div class="ion-padding" slot="content">
|
||||
<div class="offers_div">
|
||||
|
||||
<ion-grid>
|
||||
<ion-row>
|
||||
<ion-col>
|
||||
<img class="offer_banner" alt="{{item.title}}" src="{{session_image_server+'/'+curr_session+'/job/'+item.job_uid}}" />
|
||||
</ion-col>
|
||||
<ion-col>
|
||||
<div>
|
||||
<div class="offer_title">{{item.title}}</div>
|
||||
<div class="expire">Expiration : {{item.expire | date}}</div>
|
||||
<div class="price">Price : {{item.price*0.01| number : '1.2-2'}} {{item.currency}}</div>
|
||||
</div>
|
||||
|
||||
<div class="detail_txt">
|
||||
{{(item.job_description.length<95)? item.job_description :item.job_description.substring(0,95)+'...' }}
|
||||
</div>
|
||||
|
||||
|
||||
</ion-col>
|
||||
</ion-row>
|
||||
<ion-row>
|
||||
<ion-col>
|
||||
<ion-grid class="action_area">
|
||||
<ion-row>
|
||||
<ion-col>
|
||||
<ion-button size="small" (click)="requestReject(item)" color="danger" fill="solid" shape="round">Reject</ion-button>
|
||||
</ion-col>
|
||||
<ion-col>
|
||||
|
||||
</ion-col>
|
||||
<ion-col>
|
||||
<ion-button size="small" (click)="requestStart(item)" color="success" fill="solid" shape="round">Start Now</ion-button>
|
||||
</ion-col>
|
||||
</ion-row>
|
||||
</ion-grid>
|
||||
|
||||
</ion-col>
|
||||
</ion-row>
|
||||
</ion-grid>
|
||||
|
||||
<div *ngFor="let item of myOffersData">
|
||||
<div class="offers_div">
|
||||
|
||||
<ion-grid>
|
||||
<ion-row>
|
||||
<ion-col>
|
||||
<img class="offer_banner" alt="{{item.title}}" src="{{session_image_server+'/'+curr_session+'/job/'+item.job_uid}}" />
|
||||
</ion-col>
|
||||
<ion-col>
|
||||
<div>
|
||||
<div class="offer_title">{{item.title}}</div>
|
||||
<div class="expire">Expiration : {{item.expire | date}}</div>
|
||||
<div class="price">Price : {{item.price*0.01| number : '1.2-2'}} {{item.currency}}</div>
|
||||
</div>
|
||||
</div>
|
||||
</ion-accordion>
|
||||
</ion-accordion-group>
|
||||
|
||||
<div class="detail_txt">
|
||||
{{(item.job_description.length<95)? item.job_description :item.job_description.substring(0,95)+'...' }}
|
||||
</div>
|
||||
|
||||
|
||||
</ion-col>
|
||||
</ion-row>
|
||||
<ion-row>
|
||||
<ion-col>
|
||||
<ion-grid class="action_area">
|
||||
<ion-row>
|
||||
<ion-col>
|
||||
<ion-button size="small" (click)="requestReject(item)" color="danger" fill="solid" shape="round">Reject</ion-button>
|
||||
</ion-col>
|
||||
<ion-col>
|
||||
|
||||
</ion-col>
|
||||
<ion-col>
|
||||
<ion-button size="small" (click)="requestStart(item)" color="success" fill="solid" shape="round">Start Now</ion-button>
|
||||
</ion-col>
|
||||
</ion-row>
|
||||
</ion-grid>
|
||||
|
||||
</ion-col>
|
||||
</ion-row>
|
||||
</ion-grid>
|
||||
|
||||
|
||||
</div>
|
||||
|
||||
<div *ngIf="total_offers>0 && total_offers<4;">
|
||||
<div *ngFor="let item of myOffersData">
|
||||
<div class="offers_div">
|
||||
|
||||
<ion-grid>
|
||||
<ion-row>
|
||||
<ion-col>
|
||||
<img class="offer_banner" alt="{{item.title}}" src="{{session_image_server+'/'+curr_session+'/job/'+item.job_uid}}" />
|
||||
</ion-col>
|
||||
<ion-col>
|
||||
<div>
|
||||
<div class="offer_title">{{item.title}}</div>
|
||||
<div class="expire">Expiration : {{item.expire | date}}</div>
|
||||
<div class="price">Price : {{item.price*0.01| number : '1.2-2'}} {{item.currency}}</div>
|
||||
</div>
|
||||
|
||||
<div class="detail_txt">
|
||||
{{(item.job_description.length<95)? item.job_description :item.job_description.substring(0,95)+'...' }}
|
||||
</div>
|
||||
|
||||
|
||||
</ion-col>
|
||||
</ion-row>
|
||||
<ion-row>
|
||||
<ion-col>
|
||||
<ion-grid class="action_area">
|
||||
<ion-row>
|
||||
<ion-col>
|
||||
<ion-button size="small" (click)="requestReject(item)" color="danger" fill="solid" shape="round">Reject</ion-button>
|
||||
</ion-col>
|
||||
<ion-col>
|
||||
|
||||
</ion-col>
|
||||
<ion-col>
|
||||
<ion-button size="small" (click)="requestStart(item)" color="success" fill="solid" shape="round">Start Now</ion-button>
|
||||
</ion-col>
|
||||
</ion-row>
|
||||
</ion-grid>
|
||||
|
||||
</ion-col>
|
||||
</ion-row>
|
||||
</ion-grid>
|
||||
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
</div>
|
||||
|
||||
@@ -1,46 +1,47 @@
|
||||
.offers_div{
|
||||
background-color: aliceblue;
|
||||
border-radius: 10px;
|
||||
border-color: #383a3e;
|
||||
margin: 10px 0 10px 0;
|
||||
.offer_title{
|
||||
font-size: 18px;
|
||||
font-weight: bolder;
|
||||
}
|
||||
.action_area{
|
||||
background-color:whitesmoke;
|
||||
}
|
||||
.offer_banner{
|
||||
border-radius: 100%;
|
||||
background-color: white;
|
||||
width: 100%;
|
||||
height: auto;
|
||||
}
|
||||
.price{
|
||||
margin-top: 5px;
|
||||
margin-bottom: 5px;
|
||||
color:green;
|
||||
font-size: 14px;
|
||||
}
|
||||
.expire{
|
||||
font-weight: bold;
|
||||
color: red;
|
||||
font-size: 10px;
|
||||
}
|
||||
.detail_txt{
|
||||
font-size: 14px;
|
||||
margin: 5px;
|
||||
font-weight: bold;
|
||||
background-color: white;
|
||||
border-radius: 10px;
|
||||
min-height: 120px;
|
||||
padding: 3px;
|
||||
overflow: hidden;
|
||||
text-overflow:ellipsis;
|
||||
}
|
||||
}
|
||||
|
||||
ion-content {
|
||||
.offers_div{
|
||||
background-color: aliceblue;
|
||||
border-radius: 10px;
|
||||
border-color: #383a3e;
|
||||
margin: 10px 0 10px 0;
|
||||
.offer_title{
|
||||
font-size: 18px;
|
||||
font-weight: bolder;
|
||||
}
|
||||
.action_area{
|
||||
background-color:whitesmoke;
|
||||
}
|
||||
.offer_banner{
|
||||
border-radius: 100%;
|
||||
background-color: white;
|
||||
width: 100%;
|
||||
height: auto;
|
||||
}
|
||||
.price{
|
||||
margin-top: 5px;
|
||||
margin-bottom: 5px;
|
||||
color:green;
|
||||
font-size: 14px;
|
||||
}
|
||||
.expire{
|
||||
font-weight: bold;
|
||||
color: red;
|
||||
font-size: 10px;
|
||||
}
|
||||
.detail_txt{
|
||||
font-size: 14px;
|
||||
margin: 5px;
|
||||
font-weight: bold;
|
||||
background-color: white;
|
||||
border-radius: 10px;
|
||||
min-height: 120px;
|
||||
padding: 3px;
|
||||
overflow: hidden;
|
||||
text-overflow:ellipsis;
|
||||
}
|
||||
}
|
||||
|
||||
.hdt{
|
||||
padding-bottom: 10px;
|
||||
}
|
||||
|
||||
@@ -18,10 +18,12 @@ export class OffersReceivedComponent implements OnInit {
|
||||
private alertController:AlertController,
|
||||
private wrenchService: WrenchService,
|
||||
private loadingCtrl: LoadingController
|
||||
) { }
|
||||
) {
|
||||
this.getMyOffersData();
|
||||
}
|
||||
|
||||
ngOnInit() {
|
||||
this.getMyOffersData();
|
||||
|
||||
}
|
||||
|
||||
session_image_server:string='';
|
||||
@@ -36,7 +38,7 @@ export class OffersReceivedComponent implements OnInit {
|
||||
total_offers:number = 0;
|
||||
myOffersTotalData:any;
|
||||
myOffersData: [];
|
||||
async getMyOffersData(){
|
||||
getMyOffersData(){
|
||||
this.usrData = {action:15010,
|
||||
member_id: this.sessionDataProviderService.member_id,
|
||||
uid: this.sessionDataProviderService.member_uid,
|
||||
|
||||
@@ -25,7 +25,7 @@ import {WorkersDashComponent} from "../../components/workers-dash/workers-dash.c
|
||||
import {FamilyhomeComponent} from "../../components/familyhome/familyhome.component";
|
||||
import {FamilyConnectComponent} from "../../components/family-connect/family-connect.component";
|
||||
import {GenerativeActivityComponent} from "../../components/generative-activity/generative-activity.component";
|
||||
import { MyjobOffersComponent } from "../../components/myjob-offers/myjob-offers.component";
|
||||
//import { MyjobOffersComponent } from "../../components/myjob-offers/myjob-offers.component";
|
||||
import { OffersReceivedComponent } from "../../components/offers-received/offers-received.component";
|
||||
// @NgModule({
|
||||
// schemas: [CUSTOM_ELEMENTS_SCHEMA]
|
||||
@@ -56,8 +56,8 @@ import { OffersReceivedComponent } from "../../components/offers-received/offers
|
||||
FamilyhomeComponent,
|
||||
FamilyConnectComponent,
|
||||
GenerativeActivityComponent,
|
||||
MyjobOffersComponent,
|
||||
OffersReceivedComponent
|
||||
|
||||
],
|
||||
schemas: [CUSTOM_ELEMENTS_SCHEMA]
|
||||
})
|
||||
|
||||
@@ -45,6 +45,8 @@ export class HomePage implements OnInit {
|
||||
public helpDataService: HelpDataService,
|
||||
public familyDataService: FamilyDataService
|
||||
) {
|
||||
//debugger;
|
||||
|
||||
this.accountType = sessionDataProviderService.account_type;
|
||||
this.firstname = this.sessionDataProviderService.firstname;
|
||||
this.blogData = this.blogDataService.blogData;
|
||||
@@ -89,6 +91,7 @@ export class HomePage implements OnInit {
|
||||
allInitFunctions() {
|
||||
if (this.sessionDataProviderService.member_uid != "") {
|
||||
//this.onesignalService.Init(this.sessionDataProviderService.member_uid);
|
||||
// debugger;
|
||||
this.locTrcService.startTracking();
|
||||
if (this.accountType == "FULL") {
|
||||
this.getBlogData([]);
|
||||
@@ -145,6 +148,8 @@ export class HomePage implements OnInit {
|
||||
blogResult: any;
|
||||
bannerResult: any;
|
||||
bannerData: [];
|
||||
offerData: [];
|
||||
|
||||
getBlogData(blogReq = []) {
|
||||
this.wrenchService.getBlogData(blogReq).subscribe((blogResult) => {
|
||||
this.blogResult = blogResult;
|
||||
@@ -156,8 +161,10 @@ export class HomePage implements OnInit {
|
||||
}
|
||||
|
||||
async refreshBannersData() {
|
||||
// debugger;
|
||||
this.bannerData = this.bannersDataService.bannerData;
|
||||
this.homebannerCount = this.bannersDataService.homebannerCount;
|
||||
this.offerData = this.bannersDataService.offerData;
|
||||
}
|
||||
|
||||
usrData: {
|
||||
|
||||
@@ -10,6 +10,7 @@ export class BannersDataService {
|
||||
homebannerCount: number = 0;
|
||||
bannerResult: any;
|
||||
bannerData: [];
|
||||
offerData:[];
|
||||
|
||||
constructor(
|
||||
public sessionDataProviderService: SessionDataProviderService,
|
||||
@@ -64,6 +65,7 @@ export class BannersDataService {
|
||||
|
||||
console.log("BANNERS RETURN->", this.bannerResult);
|
||||
this.bannerData = this.bannerResult.result_list;
|
||||
this.offerData = this.bannerResult.offers_list;
|
||||
if (this.bannerResult?.home_dash_type != "") {
|
||||
// debugger;
|
||||
this.sessionDataProviderService.home_dash_type =
|
||||
|
||||
Reference in New Issue
Block a user