mirror of
https://code.equilibrium.co.ao/ITO/doneit-web.git
synced 2026-04-18 20:47:54 +00:00
Improve publication back sequence
This commit is contained in:
@@ -76,6 +76,7 @@
|
||||
class="height-100 d-flex flex-column overflow-hidden flex-grow-1"
|
||||
(addNewPublication)="addNewPublication($event)"
|
||||
(openPublicationDetails)="openPublicationDetails($event)"
|
||||
(goBacktoPublicationDetails)="goBacktoPublicationDetails($event)"
|
||||
(goBackToViewPublications)="goBackToViewPublications($event)"
|
||||
(closeDesktopComponent)="closeDesktopComponent($event)"
|
||||
>
|
||||
|
||||
@@ -179,18 +179,24 @@ export class PublicationsPage implements OnInit {
|
||||
}
|
||||
|
||||
}
|
||||
// called from view publications
|
||||
|
||||
// called from publications details
|
||||
// Emittter
|
||||
goBackToViewPublications(){
|
||||
|
||||
this.closeDesktopComponent();
|
||||
this.desktopComponent.showViewPublication = true;
|
||||
}
|
||||
|
||||
// called from publications details
|
||||
// Emitters
|
||||
goBackToPubications(){
|
||||
this.closeDesktopComponent();
|
||||
this.desktopComponent.showViewPublication = true;
|
||||
}
|
||||
|
||||
// called from edit publication (Emitters only)
|
||||
// Emitters
|
||||
async goBacktoPublicationDetails(){
|
||||
this.closeDesktopComponent();
|
||||
this.desktopComponent.showPublicationDetail = true;
|
||||
|
||||
@@ -1,8 +1,8 @@
|
||||
<ion-header class="ion-no-border background-white px-20 pt-25">
|
||||
<div class="title-content d-flex">
|
||||
<div class="back-icon">
|
||||
<!-- <div class="back-icon">
|
||||
<ion-icon class="font-35" (click)="goBack()" slot="end" src='assets/images/icons-arrow-arrow-left.svg'></ion-icon>
|
||||
</div>
|
||||
</div> -->
|
||||
<div class="div-title">
|
||||
<ion-label class="title">{{publicationTitle}}</ion-label>
|
||||
</div>
|
||||
|
||||
@@ -39,8 +39,9 @@ export class NewPublicationPage implements OnInit {
|
||||
@Input() publicationType: string;
|
||||
@Input() folderId: string;
|
||||
@Output() closeDesktopComponent = new EventEmitter<any>();
|
||||
@Output() goBacktoPublicationDetails = new EventEmitter();
|
||||
|
||||
@Output() openPublicationDetails = new EventEmitter<any>();
|
||||
@Output() goBackToViewPublications = new EventEmitter<any>();
|
||||
@Output() goBacktoPublicationDetails = new EventEmitter<any>();
|
||||
|
||||
guestPicture:any;
|
||||
|
||||
@@ -121,7 +122,7 @@ export class NewPublicationPage implements OnInit {
|
||||
console.log('Edit change image');
|
||||
console.log(this.publication);
|
||||
this.publications.UpdatePublication(this.publication.ProcessId, this.publication);
|
||||
this.closeDesktopComponent.emit();
|
||||
this.goBack();
|
||||
}
|
||||
else{
|
||||
this.publication = {
|
||||
@@ -138,7 +139,7 @@ export class NewPublicationPage implements OnInit {
|
||||
console.log('Edit - keep image');
|
||||
console.log(this.publication);
|
||||
this.publications.UpdatePublication(this.publication.ProcessId, this.publication);
|
||||
this.closeDesktopComponent.emit();
|
||||
this.goBack();
|
||||
}
|
||||
}
|
||||
else{
|
||||
@@ -164,7 +165,7 @@ export class NewPublicationPage implements OnInit {
|
||||
|
||||
|
||||
close(){
|
||||
this.closeDesktopComponent.emit('!???____!!');
|
||||
this.goBack();
|
||||
}
|
||||
clear(){
|
||||
this.capturedImage = '';
|
||||
@@ -183,8 +184,13 @@ export class NewPublicationPage implements OnInit {
|
||||
}
|
||||
|
||||
async goBack(){
|
||||
|
||||
this.goBacktoPublicationDetails.emit();
|
||||
|
||||
if(this.publicationType == '2'){
|
||||
this.goBackToViewPublications.emit();
|
||||
} else {
|
||||
this.goBacktoPublicationDetails.emit();
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
/* async openGallery() {
|
||||
|
||||
-2
@@ -74,7 +74,6 @@
|
||||
}
|
||||
.post-img{
|
||||
width: 100%;
|
||||
height: 400px;
|
||||
margin: 0 auto;
|
||||
border-radius: 0px!important;
|
||||
overflow: hidden;
|
||||
@@ -85,7 +84,6 @@
|
||||
object-fit: cover;
|
||||
}
|
||||
.post-description{
|
||||
width: 360px;
|
||||
margin: 0 auto;
|
||||
margin-bottom: 35px;
|
||||
}
|
||||
@@ -3,9 +3,9 @@
|
||||
<ion-header class="ion-no-border">
|
||||
<div class="main-header">
|
||||
<div class="title-content">
|
||||
<div class="back-icon" (click)="goBack()">
|
||||
<!-- <div class="back-icon" (click)="goBack()">
|
||||
<ion-icon slot="end" src='assets/images/icons-arrow-arrow-left.svg'></ion-icon>
|
||||
</div>
|
||||
</div> -->
|
||||
<div class="div-title">
|
||||
<ion-label class="title">{{item.Description}}</ion-label>
|
||||
<p class="item-content-detail">{{item.Detail}}</p>
|
||||
|
||||
@@ -149,9 +149,5 @@ export class ViewPublicationsPage implements OnInit {
|
||||
|
||||
}
|
||||
|
||||
async goBack(){
|
||||
console.log('!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!')
|
||||
this.goBacktoPublicationDetails.emit();
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user