active tasks
This commit is contained in:
@@ -1,7 +1,17 @@
|
||||
<ion-header mode="ios" class="ion-no-border">
|
||||
<ion-toolbar>
|
||||
<ion-buttons slot="start" (click)="onBack()">
|
||||
<ion-button>
|
||||
<ion-icon name="arrow-back-outline"></ion-icon>
|
||||
</ion-button>
|
||||
</ion-buttons>
|
||||
<ion-title>{{jobData.title}}</ion-title>
|
||||
</ion-toolbar>
|
||||
</ion-header>
|
||||
|
||||
<ion-content>
|
||||
<div class="boxed_contents">
|
||||
<div class="bg_image back_image" [style.backgroundImage]="'url(https://www.wrenchboard.com/assets/images/apps/jobs/default.jpg)'">
|
||||
<div class="bg_image back_image" [style.backgroundImage]="'url('+session_image_server+'/'+curr_session+'/job/'+jobData.job_uid+')'">
|
||||
<div class="ion-padding">
|
||||
<ion-icon slot="start" name="arrow-back" class="back" (click)="onBack()"></ion-icon>
|
||||
</div>
|
||||
@@ -33,14 +43,14 @@
|
||||
<!-- </div>-->
|
||||
</div>
|
||||
|
||||
<div *ngIf="status_description == 'ACTIVE'" >
|
||||
<ion-segment [(ngModel)]="tabs">
|
||||
<div *ngIf="status_description == 'ACTIVE'" >
|
||||
<ion-segment class="common_segment" [(ngModel)]="tabs">
|
||||
<ion-segment-button value="activities">
|
||||
<ion-label>Send Updates</ion-label>
|
||||
</ion-segment-button>
|
||||
<ion-segment-button value="about">
|
||||
<ion-label>Details</ion-label>
|
||||
</ion-segment-button>
|
||||
<ion-segment-button value="lesson">
|
||||
<ion-label>Send Updates</ion-label>
|
||||
</ion-segment-button>
|
||||
<ion-segment-button value="review">
|
||||
<ion-label>Actions</ion-label>
|
||||
</ion-segment-button>
|
||||
@@ -72,45 +82,37 @@
|
||||
|
||||
</div>
|
||||
|
||||
<div *ngIf="tabs =='lesson'" class="lesson">
|
||||
<!-- <div class="flex">-->
|
||||
<!-- <ion-label class="bold">Most Popular Courses</ion-label>-->
|
||||
<!-- <ion-label class="color">See all</ion-label>-->
|
||||
<!-- </div>-->
|
||||
<div *ngIf="tabs =='activities'" class="lesson">
|
||||
|
||||
<!-- <div class="sec">-->
|
||||
<!-- <ion-label class="grey">Due Date:{{jobData.delivery_date}}</ion-label>-->
|
||||
<!-- <ion-label class="color">{{jobData.contract}}</ion-label>-->
|
||||
<!-- </div>-->
|
||||
|
||||
<ion-card>
|
||||
<!-- <ion-card-header>-->
|
||||
<!-- <ion-card-subtitle>Send Updates</ion-card-subtitle>-->
|
||||
<!-- </ion-card-header>-->
|
||||
|
||||
<ion-card-content>
|
||||
<ion-textarea label="Your Message to Job Owner" placeholder="Type message here" [(ngModel)]='yourmessage' ></ion-textarea>
|
||||
<ion-card-content style="padding: 1px;">
|
||||
<ion-textarea
|
||||
style="background-color: aliceblue; margin: 0px; min-height: 120px"
|
||||
label="Your Message to Job Owner"
|
||||
placeholder="Enter your updates message here"
|
||||
[(ngModel)]='yourmessage' ></ion-textarea>
|
||||
</ion-card-content>
|
||||
<ion-grid>
|
||||
<ion-row>
|
||||
<ion-col style="text-align: left;">
|
||||
<ion-button color="secondary">
|
||||
<ion-icon slot="icon-only" name="camera-reverse-outline"></ion-icon>
|
||||
</ion-button>
|
||||
<ion-button style="margin-left: 10px;">
|
||||
<ion-icon slot="icon-only" name="folder-outline"></ion-icon>
|
||||
</ion-button>
|
||||
</ion-col>
|
||||
<ion-col>
|
||||
<ion-button color="secondary" expand="block" (click)="sendActiveJobMessage()">Send Updates</ion-button>
|
||||
</ion-col>
|
||||
</ion-row>
|
||||
</ion-grid>
|
||||
|
||||
<ion-button color="secondary" expand="block" (click)="sendActiveJobMessage()">Send Updates</ion-button>
|
||||
<ion-label class="description">{{interest_msg_status}}
|
||||
</ion-label>
|
||||
</ion-card>
|
||||
|
||||
<!-- <div class="video {{item.who}}" *ngFor="let item of msgListData">-->
|
||||
<!-- <div class="left">-->
|
||||
<!-- <div class="bg_image men_image" [style.backgroundImage]="'url(https://www.wrenchboard.com/assets/images/apps/msg/TEXT.svg)'"></div>-->
|
||||
|
||||
<!-- <div class="text">-->
|
||||
<!-- <ion-label class="bold_text">{{item.msg_firstname}}-{{item.msg_date}}</ion-label>-->
|
||||
<!-- <ion-label class="grey_text">{{item.message}}</ion-label>-->
|
||||
<!-- </div>-->
|
||||
<!-- </div>-->
|
||||
<!-- <!– <div class="right">–>-->
|
||||
<!-- <!–<!– <ion-icon name="lock-closed-outline"></ion-icon>–>–>-->
|
||||
<!-- <!– </div>–>-->
|
||||
<!-- </div>-->
|
||||
|
||||
</div>
|
||||
|
||||
<div *ngIf="tabs =='review'" class="review_tab">
|
||||
@@ -168,7 +170,6 @@
|
||||
</ion-card-content>
|
||||
</ion-card>
|
||||
</div>
|
||||
|
||||
<div *ngIf="status_description == 'REVIEW'" >
|
||||
<ion-card color="success">
|
||||
<ion-card-header>
|
||||
@@ -178,8 +179,6 @@
|
||||
<ion-card-content> THis task is in review , the owner will give feedback soon. </ion-card-content>
|
||||
</ion-card>
|
||||
</div>
|
||||
|
||||
|
||||
<app-taskactivities [jobData]="jobData"></app-taskactivities>
|
||||
|
||||
|
||||
@@ -187,11 +186,11 @@
|
||||
</div>
|
||||
</ion-content>
|
||||
|
||||
<ion-footer>
|
||||
<ion-toolbar>
|
||||
<div class="button" (click)="onBack()">
|
||||
<ion-label class="text">Return</ion-label>
|
||||
</div>
|
||||
</ion-toolbar>
|
||||
</ion-footer>
|
||||
<!--<ion-footer>-->
|
||||
<!-- <ion-toolbar>-->
|
||||
<!-- <div class="button" (click)="onBack()">-->
|
||||
<!-- <ion-label class="text">Return</ion-label>-->
|
||||
<!-- </div>-->
|
||||
<!-- </ion-toolbar>-->
|
||||
<!--</ion-footer>-->
|
||||
|
||||
|
||||
@@ -12,9 +12,10 @@ import { WrenchService } from 'src/app/services/wrench.service';
|
||||
})
|
||||
export class ActivetaskPage implements OnInit {
|
||||
@ViewChild('yourmessage') yourmessage;
|
||||
tabs = 'about';
|
||||
tabs = 'activities';
|
||||
status_description:string='';
|
||||
|
||||
session_image_server:string='';
|
||||
curr_session:string='';
|
||||
|
||||
jobData: any;
|
||||
constructor(
|
||||
@@ -25,16 +26,18 @@ export class ActivetaskPage implements OnInit {
|
||||
private wrenchService: WrenchService,
|
||||
public blogDataService: BlogDataService
|
||||
) {
|
||||
|
||||
this.yourmessage='';
|
||||
this.jobData = this.router.getCurrentNavigation().extras.state;
|
||||
console.log("XXXXX 1", this.router.getCurrentNavigation().extras);
|
||||
console.log("XXXXX 2", this.router.getCurrentNavigation().extras.state);
|
||||
//console.log("XXXXX 3", this.router.getCurrentNavigation().extras.state.ID);
|
||||
this.status_description = this.jobData.status_description;
|
||||
this.status_description = this.jobData?.status_description;
|
||||
}
|
||||
|
||||
ngOnInit() {
|
||||
this.activeJobMsgList();
|
||||
this.curr_session = this.sessionDataProviderService.session;
|
||||
this.session_image_server = this.sessionDataProviderService.session_image_server;
|
||||
//this.activeJobMsgList();
|
||||
}
|
||||
|
||||
onBack() {
|
||||
@@ -60,37 +63,37 @@ export class ActivetaskPage implements OnInit {
|
||||
*/
|
||||
|
||||
|
||||
contrData: {
|
||||
action:number,
|
||||
member_id: number,
|
||||
uid: string,
|
||||
sessionid: string,
|
||||
limit:20,
|
||||
contract:string,
|
||||
offset: 0
|
||||
};
|
||||
msgListTotalData:any;
|
||||
msgListData: [];
|
||||
activeJobMsgList(){
|
||||
this.contrData = {
|
||||
action:14011,
|
||||
member_id: this.sessionDataProviderService.member_id,
|
||||
uid: this.sessionDataProviderService.member_uid,
|
||||
sessionid: this.sessionDataProviderService.session ,
|
||||
limit:20,
|
||||
contract: this.jobData.contract,
|
||||
offset: 0}
|
||||
|
||||
this.wrenchService.activeJobMsgList(this.contrData).subscribe(
|
||||
msgListTotalData => {
|
||||
this.msgListTotalData = msgListTotalData;
|
||||
// console.log("REFER RETURN->", this.referTotalData);
|
||||
this.msgListData = this.msgListTotalData.result_list;
|
||||
console.log("REFER RETURN DATA->", this.msgListData);
|
||||
}
|
||||
);
|
||||
|
||||
}
|
||||
// contrData: {
|
||||
// action:number,
|
||||
// member_id: number,
|
||||
// uid: string,
|
||||
// sessionid: string,
|
||||
// limit:20,
|
||||
// contract:string,
|
||||
// offset: 0
|
||||
// };
|
||||
// msgListTotalData:any;
|
||||
// msgListData: [];
|
||||
// activeJobMsgList(){
|
||||
// this.contrData = {
|
||||
// action:14011,
|
||||
// member_id: this.sessionDataProviderService.member_id,
|
||||
// uid: this.sessionDataProviderService.member_uid,
|
||||
// sessionid: this.sessionDataProviderService.session ,
|
||||
// limit:20,
|
||||
// contract: this.jobData.contract,
|
||||
// offset: 0}
|
||||
//
|
||||
// this.wrenchService.activeJobMsgList(this.contrData).subscribe(
|
||||
// msgListTotalData => {
|
||||
// this.msgListTotalData = msgListTotalData;
|
||||
// // console.log("REFER RETURN->", this.referTotalData);
|
||||
// this.msgListData = this.msgListTotalData.result_list;
|
||||
// console.log("REFER RETURN DATA->", this.msgListData);
|
||||
// }
|
||||
// );
|
||||
//
|
||||
// }
|
||||
|
||||
/*
|
||||
'member_id' => int 1
|
||||
@@ -113,7 +116,7 @@ export class ActivetaskPage implements OnInit {
|
||||
|
||||
msgReqResult:any;
|
||||
sendActiveJobMessage(){
|
||||
if (this.yourmessage.length < 5){
|
||||
if (this.yourmessage == undefined || this.yourmessage?.length < 5){
|
||||
alert("Enter Message to send");
|
||||
return;
|
||||
}
|
||||
@@ -132,7 +135,11 @@ export class ActivetaskPage implements OnInit {
|
||||
this.msgReqResult = reqResult;
|
||||
console.log("msgReqResult RETURN->", this.msgReqResult);
|
||||
this.interest_msg_status = this.msgReqResult?.status;
|
||||
this.activeJobMsgList();
|
||||
//this.activeJobMsgList();
|
||||
const event = new Event("app-taskactivities-refresh");
|
||||
// Dispatch the event.
|
||||
dispatchEvent(event);
|
||||
|
||||
}
|
||||
);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user