mirror of
https://code.equilibrium.co.ao/ITO/doneit-web.git
synced 2026-04-18 12:37:53 +00:00
Fix editing publication
This commit is contained in:
@@ -1,12 +1,12 @@
|
||||
/* import { Image } from './image'; */
|
||||
|
||||
export class Publication{
|
||||
DateIndex: Date;
|
||||
DateIndex: Date | string;
|
||||
DocumentId:string;
|
||||
ProcessId:string;
|
||||
Title: string;
|
||||
Message: string;
|
||||
DatePublication: Date;
|
||||
DatePublication: Date | string;
|
||||
OriginalFileName?: string;
|
||||
FileBase64?:string;
|
||||
FileExtension?: string;
|
||||
|
||||
@@ -215,6 +215,8 @@ export class NewPublicationPage implements OnInit {
|
||||
}
|
||||
}
|
||||
else {
|
||||
|
||||
alert('create !!! 312')
|
||||
this.publication = {
|
||||
DateIndex: new Date(),
|
||||
DocumentId:null,
|
||||
|
||||
@@ -188,8 +188,8 @@ export class NewPublicationPage implements OnInit {
|
||||
}
|
||||
|
||||
}
|
||||
else{
|
||||
|
||||
else if (!this.publication.OriginalFileName) {
|
||||
|
||||
this.publication = {
|
||||
DateIndex: this.publication.DateIndex,
|
||||
DocumentId:this.publication.DocumentId,
|
||||
@@ -197,9 +197,9 @@ export class NewPublicationPage implements OnInit {
|
||||
Title: this.pub.Title,
|
||||
Message: this.pub.Message,
|
||||
DatePublication: this.publication.DatePublication,
|
||||
OriginalFileName: this.publication.OriginalFileName,
|
||||
FileBase64: this.publication.FileBase64,
|
||||
FileExtension: 'jpeg',
|
||||
// OriginalFileName: this.publication.OriginalFileName,
|
||||
// FileBase64: this.publication.FileBase64,
|
||||
// FileExtension: 'jpeg',
|
||||
}
|
||||
const loader = this.toastService.loading()
|
||||
|
||||
@@ -218,14 +218,18 @@ export class NewPublicationPage implements OnInit {
|
||||
}
|
||||
}
|
||||
else {
|
||||
|
||||
|
||||
alert('create !!! 123')
|
||||
|
||||
let time = new Date()
|
||||
alert(time)
|
||||
this.publication = {
|
||||
DateIndex: new Date(),
|
||||
DateIndex: time,
|
||||
DocumentId:null,
|
||||
ProcessId:this.folderId,
|
||||
Title: this.pub.Title,
|
||||
Message: this.pub.Message,
|
||||
DatePublication: new Date(),
|
||||
DatePublication: time,
|
||||
OriginalFileName: this.capturedImageTitle,
|
||||
FileBase64: this.capturedImage,
|
||||
FileExtension: 'jpeg',
|
||||
|
||||
Reference in New Issue
Block a user