mirror of
https://code.equilibrium.co.ao/ITO/doneit-web.git
synced 2026-04-18 20:47:54 +00:00
Module Actions stable version.
This commit is contained in:
@@ -52,6 +52,7 @@ export class NewPublicationPage implements OnInit {
|
||||
private publications: PublicationsService,
|
||||
private camera: Camera,
|
||||
) {
|
||||
|
||||
this.publicationType = this.navParams.get('publicationType');
|
||||
this.folderId = this.navParams.get('folderId');
|
||||
this.publicationTitle = 'Nova Publicação';
|
||||
@@ -106,8 +107,11 @@ export class NewPublicationPage implements OnInit {
|
||||
|
||||
async save(){
|
||||
if(this.publicationType == '3'){
|
||||
console.log(this.navParams.get('publication'));
|
||||
|
||||
if(this.capturedImage != ''){
|
||||
this.publication = {
|
||||
DateIndex: this.publication.DateIndex,
|
||||
DocumentId:this.publication.DocumentId,
|
||||
ProcessId:this.publication.ProcessId,
|
||||
Title: this.pub.Title,
|
||||
@@ -115,7 +119,7 @@ export class NewPublicationPage implements OnInit {
|
||||
DatePublication: this.publication.DatePublication,
|
||||
OriginalFileName: this.capturedImageTitle,
|
||||
FileBase64: this.capturedImage,
|
||||
FileExtension: 'jpg',
|
||||
FileExtension: 'jpeg',
|
||||
}
|
||||
console.log('Edit change image');
|
||||
console.log(this.publication);
|
||||
@@ -124,14 +128,15 @@ export class NewPublicationPage implements OnInit {
|
||||
}
|
||||
else{
|
||||
this.publication = {
|
||||
DateIndex: this.publication.DateIndex,
|
||||
DocumentId:this.publication.DocumentId,
|
||||
ProcessId:this.publication.ProcessId,
|
||||
Title: this.pub.Title,
|
||||
Message: this.pub.Message,
|
||||
DatePublication: this.publication.DatePublication,
|
||||
OriginalFileName: '',
|
||||
OriginalFileName: this.publication.OriginalFileName,
|
||||
FileBase64: this.publication.FileBase64,
|
||||
FileExtension: 'jpg',
|
||||
FileExtension: 'jpeg',
|
||||
}
|
||||
console.log('Edit - keep image');
|
||||
console.log(this.publication);
|
||||
@@ -142,6 +147,7 @@ export class NewPublicationPage implements OnInit {
|
||||
else{
|
||||
|
||||
this.publication = {
|
||||
DateIndex: new Date(),
|
||||
DocumentId:null,
|
||||
ProcessId:this.folderId,
|
||||
Title: this.pub.Title,
|
||||
@@ -149,7 +155,7 @@ export class NewPublicationPage implements OnInit {
|
||||
DatePublication: new Date(),
|
||||
OriginalFileName: this.capturedImageTitle,
|
||||
FileBase64: this.capturedImage,
|
||||
FileExtension: 'jpg',
|
||||
FileExtension: 'jpeg',
|
||||
}
|
||||
|
||||
console.log('Create');
|
||||
|
||||
Reference in New Issue
Block a user