export let versionData = { "shortSHA": "eb77736a6", "SHA": "eb77736a60ce338807e2160729fd08121755516e", "branch": "developer-prod", "lastCommitAuthor": "'Peter Maquiran'", "lastCommitTime": "'Wed Aug 16 08:38:09 2023 +0100'", "lastCommitMessage": "fix", "lastCommitNumber": "5171", "change": "diff --git a/src/app/models/beast-orm.ts b/src/app/models/beast-orm.ts\nindex ce46ac39b..6d1062fe3 100644\n--- a/src/app/models/beast-orm.ts\n+++ b/src/app/models/beast-orm.ts\n@@ -23,6 +23,7 @@ export class MessageModel extends models.Model {\n \tlocalReference = models.CharField({blank:true, unique: true})\n \tattachments = ArrayField({blank:true})\n \tfile = JsonField({blank:true})\n+\tUploadAttachmentsTemp = models.IntegerField()\n \n \tasync getAttachments() {\n \t\tconsole.log('this[id]', this['id'])\ndiff --git a/src/app/models/chatMethod.ts b/src/app/models/chatMethod.ts\nindex 8a3363d2d..e1ac3a2ba 100644\n--- a/src/app/models/chatMethod.ts\n+++ b/src/app/models/chatMethod.ts\n@@ -94,6 +94,7 @@ export interface Message {\n \t\tfileBase64: string\n \t}\n \thasFile: boolean\n+\tUploadAttachmentsTemp: number\n }\n \n \ndiff --git a/src/app/pages/chat/group-messages/group-contacts/group-contacts.page.html b/src/app/pages/chat/group-messages/group-contacts/group-contacts.page.html\nindex d0f7f1af9..ee75fc6ca 100644\n--- a/src/app/pages/chat/group-messages/group-contacts/group-contacts.page.html\n+++ b/src/app/pages/chat/group-messages/group-contacts/group-contacts.page.html\n@@ -47,19 +47,19 @@\n \n \n \n- \n+ \n+
\n \n-
\n- {{header}}\n+
\n+ {{ userContainer.key }}\n
\n \n-
\n- \n-

{{user.name}}

\n- \n+
\n+ \n+ {{user.name}}\n+
\n
\n-\n- \n+
\n \n
\n \ndiff --git a/src/app/pages/chat/group-messages/group-contacts/group-contacts.page.ts b/src/app/pages/chat/group-messages/group-contacts/group-contacts.page.ts\nindex 90eab93a4..0d7e58e22 100644\n--- a/src/app/pages/chat/group-messages/group-contacts/group-contacts.page.ts\n+++ b/src/app/pages/chat/group-messages/group-contacts/group-contacts.page.ts\n@@ -32,6 +32,10 @@ export class GroupContactsPage implements OnInit {\n groupName:string;\n selectedUserList:any;\n sessionStore = SessionStore\n+\n+\n+ objectUserSingleStone = []\n+ userContainer = {}\n \n constructor(\n private modalController: ModalController,\n@@ -81,6 +85,30 @@ export class GroupContactsPage implements OnInit {\n }\n return 0;\n });\n+\n+\n+\n+\n+ for( const user of this.users) {\n+\n+ const foundUser = this.objectUserSingleStone.find( e => e.name == user.name)\n+\n+ if(!foundUser) {\n+ this.objectUserSingleStone.push(user)\n+ }\n+ \n+ }\n+ \n+ for(const user of this.objectUserSingleStone) {\n+ const firstLetter = user.name.charAt(0)\n+\n+ if(!this.userContainer[firstLetter]) {\n+ this.userContainer[firstLetter] = [user]\n+ } else {\n+ this.userContainer[firstLetter].push(user)\n+ }\n+ \n+ }\n \n \n this.showLoader = false;\n@@ -178,6 +206,26 @@ export class GroupContactsPage implements OnInit {\n })\n \n this.users = users\n+\n+\n+\n+\n+ let a = this.objectUserSingleStone.filter( e => e.name.toLowerCase().includes(this.textSearch.toLowerCase()))\n+ \n+ let b = {}\n+ for(const user of a) {\n+ const firstLetter = user.name.charAt(0)\n+\n+ if(!b[firstLetter]) {\n+ b[firstLetter] = [user]\n+ } else {\n+ b[firstLetter].push(user)\n+ }\n+ \n+ }\n+\n+\n+ this.userContainer = b\n \n \n }\n@@ -185,9 +233,11 @@ export class GroupContactsPage implements OnInit {\n \n \n }\n- selectedContact(user:any){\n- /* this.groupName = this.room.name; */\n- user.isChecked = !user.isChecked;\n+ selectedContact(user:any) {\n+ /* this.groupName = this.room.name; */\n+ user.isChecked = user.isChecked != false ? true : false \n+ const userIndex = this.objectUserSingleStone.findIndex((e) => e._id == user._id)\n+ this.objectUserSingleStone[userIndex].isChecked = user.isChecked\n \n \n }\ndiff --git a/src/app/pages/chat/messages/contacts/contacts.page.html b/src/app/pages/chat/messages/contacts/contacts.page.html\nindex 21cce9129..9f6f6a645 100644\n--- a/src/app/pages/chat/messages/contacts/contacts.page.html\n+++ b/src/app/pages/chat/messages/contacts/contacts.page.html\n@@ -32,7 +32,7 @@\n \n
\n \n- \n+ \n \n
\n {{header}}\ndiff --git a/src/app/pages/gabinete-digital/expediente/expediente-detail/expediente-detail.page.html b/src/app/pages/gabinete-digital/expediente/expediente-detail/expediente-detail.page.html\nindex 231a8e6d6..51bd68ef9 100644\n--- a/src/app/pages/gabinete-digital/expediente/expediente-detail/expediente-detail.page.html\n+++ b/src/app/pages/gabinete-digital/expediente/expediente-detail/expediente-detail.page.html\n@@ -7,7 +7,7 @@\n
\n
\n
\n-
\n+
\n \n \n \ndiff --git a/src/app/pipes/filter.pipe.ts b/src/app/pipes/filter.pipe.ts\nindex 97100f9eb..9992c805d 100644\n--- a/src/app/pipes/filter.pipe.ts\n+++ b/src/app/pipes/filter.pipe.ts\n@@ -7,13 +7,15 @@ export class FilterPipe implements PipeTransform {\n \n transform(array: any[], text:string, column:string): any {\n \n+ console.log(array, text, column);\n+ \n if(text === ''){\n return array;\n }\n \n text = text.toLowerCase();\n \n- if(Array.isArray(array)) {\n+ if(!Array.isArray(array)) {\n array = []\n }\n \ndiff --git a/src/app/services/chat/chat-system.service.ts b/src/app/services/chat/chat-system.service.ts\nindex 6c5c85cc7..0e2766c77 100644\n--- a/src/app/services/chat/chat-system.service.ts\n+++ b/src/app/services/chat/chat-system.service.ts\n@@ -65,6 +65,23 @@ export class ChatSystemService {\n private notificationService: NotificationsService\n ) {\n \n+\n+ const user = this.users\n+\n+ const alfa = {}\n+\n+ const sortedUserList = user.sort((a, b) => {\n+ if(a.name < b.name) {\n+ return -1;\n+ }\n+ if(a.name > b.name) {\n+ return 1;\n+ }\n+ return 0;\n+ })\n+\n+ console.log({sortedUserList})\n+\n this.RochetChatConnectorService.registerCallback({\n type: 'reConnect',\n funx: async () => {\ndiff --git a/src/app/services/chat/message.service.ts b/src/app/services/chat/message.service.ts\nindex 599700e12..a1b6ab1e4 100644\n--- a/src/app/services/chat/message.service.ts\n+++ b/src/app/services/chat/message.service.ts\n@@ -79,7 +79,7 @@ export class MessageService {\n private notificationService: NotificationsService) {\n }\n \n- setData({customFields = {}, channels, mentions, msg ,rid ,ts, u, t, _id, id, _updatedAt, file, attachments, temporaryData, localReference = 'out-'+uuidv4() , viewed = [], received = [], delate = false, delateRequest =false, from, sendAttempt = 0, origin, attachmentsModelData, hasFile = false }:Message) {\n+ setData({customFields = {}, channels, mentions, msg ,rid ,ts, u, t, _id, id, _updatedAt, file, attachments, temporaryData, localReference = 'out-'+uuidv4() , viewed = [], received = [], delate = false, delateRequest =false, from, sendAttempt = 0, origin, attachmentsModelData, hasFile = false, UploadAttachmentsTemp = 0 }:Message) {\n \n this.channels = channels || []\n this.mentions = mentions || []\n@@ -99,6 +99,7 @@ export class MessageService {\n this.sendAttempt = 0\n this.origin = origin\n this.attachmentsModelData = attachmentsModelData\n+ this.UploadAttachmentsTemp = UploadAttachmentsTemp\n \n if(this.attachments?.length >= 1 && attachments?.length >= 1) {\n this.attachments[0] = Object.assign(this.attachments[0], attachments[0])\n@@ -268,15 +269,20 @@ export class MessageService {\n uploadSuccessfully = await this.NfService.beforeSendAttachment(this)\n this.UploadAttachmentsTemp++\n this.uploadingFile = false\n- \n+\n this.manualRetry = false\n this.errorUploadingAttachment = false\n this.hasSendAttachment = true\n+\n+ this.saveChanges()\n } catch (error) {\n this.uploadingFile = false\n+ \n \n this.errorUploadingAttachment = true\n this.UploadAttachmentsTemp++\n+\n+ this.saveChanges()\n }\n \n }\n@@ -513,7 +519,8 @@ export class MessageService {\n localReference: this.localReference,\n attachments: this.attachments,\n file: this.file,\n- delate: this.delate\n+ delate: this.delate,\n+ UploadAttachmentsTemp: this.UploadAttachmentsTemp\n }\n }\n \ndiff --git a/src/app/shared/chat/group-messages/group-contacts/group-contacts.page.html b/src/app/shared/chat/group-messages/group-contacts/group-contacts.page.html\nindex 6e820fa0b..a6e3d6584 100644\n--- a/src/app/shared/chat/group-messages/group-contacts/group-contacts.page.html\n+++ b/src/app/shared/chat/group-messages/group-contacts/group-contacts.page.html\n@@ -40,7 +40,7 @@\n \n
\n \n-

{{user.name}}

\n+

{{user.name}}

\n \n
\n \n- \n \n-
\n- {{header}}\n+
\n+\n+
\n+ {{ userContainer.key }}\n
\n \n-
\n- \n- {{user.name}}\n+
\n+ {{ user.isChecked }}\n+ \n+ {{user.name}}\n
\n
\n-\n- \n+
\n \n
\n \ndiff --git a/src/app/shared/chat/group-messages/group-contacts/group-contacts.page.ts b/src/app/shared/chat/group-messages/group-contacts/group-contacts.page.ts\nindex 7dd8027bb..eacccb208 100644\n--- a/src/app/shared/chat/group-messages/group-contacts/group-contacts.page.ts\n+++ b/src/app/shared/chat/group-messages/group-contacts/group-contacts.page.ts\n@@ -36,6 +36,10 @@ export class GroupContactsPage implements OnInit {\n @Input() roomId:string;\n @Output() openGroupMessage:EventEmitter = new EventEmitter();\n \n+\n+ objectUserSingleStone = []\n+ userContainer = {}\n+\n constructor(\n private modalController: ModalController,\n private chatService: ChatService,\n@@ -168,7 +172,7 @@ export class GroupContactsPage implements OnInit {\n });\n }\n \n- loadUsers(){\n+ loadUsers() {\n \n this.chatService.getAllUsers().subscribe((res:any)=>{\n \n@@ -192,22 +196,29 @@ export class GroupContactsPage implements OnInit {\n });\n \n \n- this.showLoader = false;\n- });\n- }\n+ for( const user of this.users) {\n \n- separateLetter(record, recordIndex, records){\n- if(recordIndex == 0){\n- return record.name[0];\n- }\n+ const foundUser = this.objectUserSingleStone.find( e => e.name == user.name)\n \n- let first_prev = records[recordIndex - 1].name[0];\n- let first_current = record.name[0];\n+ if(!foundUser) {\n+ this.objectUserSingleStone.push(user)\n+ }\n+ \n+ }\n+ \n+ for(const user of this.objectUserSingleStone) {\n+ const firstLetter = user.name.charAt(0)\n \n- if(first_prev != first_current){\n- return first_current;\n- }\n- return null;\n+ if(!this.userContainer[firstLetter]) {\n+ this.userContainer[firstLetter] = [user]\n+ } else {\n+ this.userContainer[firstLetter].push(user)\n+ }\n+ \n+ }\n+\n+ this.showLoader = false;\n+ });\n }\n \n doRefresh(ev){\n@@ -267,6 +278,24 @@ export class GroupContactsPage implements OnInit {\n \n this.users = users\n \n+\n+ let a = this.objectUserSingleStone.filter( e => e.name.toLowerCase().includes(this.textSearch.toLowerCase()))\n+ \n+ let b = {}\n+ for(const user of a) {\n+ const firstLetter = user.name.charAt(0)\n+\n+ if(!b[firstLetter]) {\n+ b[firstLetter] = [user]\n+ } else {\n+ b[firstLetter].push(user)\n+ }\n+ \n+ }\n+\n+\n+ this.userContainer = b\n+\n // console.log('this.users', this.users)\n }\n \n@@ -274,18 +303,24 @@ export class GroupContactsPage implements OnInit {\n \n }\n \n- selectedContact(user:any){\n- /* this.groupName = this.room.name; */\n- user.isChecked = !user.isChecked;\n-\n- const userIndex = this.users.findIndex((e) => e._id == user._id)\n- this.users[userIndex] = user \n+ selectedContact(user:any) {\n+ /* this.groupName = this.room.name; */\n+ if(user.isChecked != false ) {\n+ user.isChecked = true\n+ alert('tro')\n+ } else {\n+ alert('false')\n+ user.isChecked = false\n+ }\n+ \n+ const userIndex = this.objectUserSingleStone.findIndex((e) => e._id == user._id)\n+ this.objectUserSingleStone[userIndex].isChecked = user.isChecked\n \n }\n \n- addContacts(roomId:any){\n+ addContacts(roomId:any) {\n \n- this.selectedUserList = this.users.filter(function(contact) {\n+ this.selectedUserList = this.objectUserSingleStone.filter(function(contact) {\n return contact.isChecked == true;\n });\n \ndiff --git a/src/app/shared/chat/messages/messages.page.html b/src/app/shared/chat/messages/messages.page.html\nindex 5ae210611..165bd22d4 100644\n--- a/src/app/shared/chat/messages/messages.page.html\n+++ b/src/app/shared/chat/messages/messages.page.html\n@@ -39,7 +39,6 @@\n \n
\n- \n
\n
\n \ndiff --git a/src/app/shared/popover/opts-expediente/opts-expediente.page.html b/src/app/shared/popover/opts-expediente/opts-expediente.page.html\nindex 59f5fd715..86a2711b7 100644\n--- a/src/app/shared/popover/opts-expediente/opts-expediente.page.html\n+++ b/src/app/shared/popover/opts-expediente/opts-expediente.page.html\n@@ -7,7 +7,7 @@\n
\n
\n
\n-
\n+
\n \n \n \n@@ -22,23 +22,9 @@\n \n \n \n+ \n
\n
\n- \n \n-
\n- \n
\n \ndiff --git a/src/app/shared/popover/opts-expediente/opts-expediente.page.scss b/src/app/shared/popover/opts-expediente/opts-expediente.page.scss\nindex 121c5db26..677be7d4a 100644\n--- a/src/app/shared/popover/opts-expediente/opts-expediente.page.scss\n+++ b/src/app/shared/popover/opts-expediente/opts-expediente.page.scss\n@@ -35,7 +35,7 @@\n }\n @media only screen and (max-width: 800px) {\n .btn-ok, .btn-cancel, .btn-delete{\n- width: 100% !important;\n+ width: 47% !important;\n }\n }\n @media only screen and (min-width: 1024px) {\n@@ -45,11 +45,11 @@\n }\n .btn-cancel{\n display: none;\n- width: 100% !important;\n+ width: 47% !important;\n margin-bottom: 10px !important;\n }\n .btn-delete, .btn-ok{\n- width: 100% !important;\n+ width: 47% !important;\n margin-bottom: 10px !important;\n margin-top: 10px !important;\n }", "changeStatus": "On branch developer-prod\nChanges to be committed:\n (use \"git restore --staged ...\" to unstage)\n\tmodified: src/app/pages/publications/new-publication/new-publication.page.ts\n\tmodified: src/app/pages/publications/view-publications/publication-detail/publication-detail.page.ts\n\tmodified: src/app/pages/publications/view-publications/view-publications.page.html\n\tmodified: src/app/pages/publications/view-publications/view-publications.page.ts\n\tmodified: src/app/services/task.service.ts\n\tmodified: src/app/shared/publication/new-publication/new-publication.page.ts\n\tmodified: src/app/shared/publication/view-publications/publication-detail/publication-detail.page.html\n\tmodified: src/app/shared/publication/view-publications/publication-detail/publication-detail.page.ts\n\tmodified: src/app/shared/publication/view-publications/view-publications.page.html\n\tmodified: src/app/store/publication-folder.service.ts\n\tmodified: src/theme/variables.scss\n\nChanges not staged for commit:\n (use \"git add ...\" to update what will be committed)\n (use \"git restore ...\" to discard changes in working directory)\n\tmodified: src/app/models/beast-orm.ts\n\tmodified: src/app/models/chatMethod.ts\n\tmodified: src/app/pages/chat/group-messages/group-contacts/group-contacts.page.html\n\tmodified: src/app/pages/chat/group-messages/group-contacts/group-contacts.page.ts\n\tmodified: src/app/pages/chat/messages/contacts/contacts.page.html\n\tmodified: src/app/pages/gabinete-digital/expediente/expediente-detail/expediente-detail.page.html\n\tmodified: src/app/pipes/filter.pipe.ts\n\tmodified: src/app/services/chat/chat-system.service.ts\n\tmodified: src/app/services/chat/message.service.ts\n\tmodified: src/app/shared/chat/group-messages/group-contacts/group-contacts.page.html\n\tmodified: src/app/shared/chat/group-messages/group-contacts/group-contacts.page.ts\n\tmodified: src/app/shared/chat/messages/messages.page.html\n\tmodified: src/app/shared/popover/opts-expediente/opts-expediente.page.html\n\tmodified: src/app/shared/popover/opts-expediente/opts-expediente.page.scss", "changeAuthor": "peter.maquiran" }