|  |  |  | @ -8860,7 +8860,7 @@ exports.updateHardwareList = async (req, reply) => { | 
			
		
	
		
			
				
					|  |  |  |  | 
 | 
			
		
	
		
			
				
					|  |  |  |  | exports.assignCategorizeIssue = async (request, reply) => { | 
			
		
	
		
			
				
					|  |  |  |  |   const { supportId } = request.params; | 
			
		
	
		
			
				
					|  |  |  |  |   const { support_teamMemberId, startDate, endDate, category, masterHardwareId } = request.body; | 
			
		
	
		
			
				
					|  |  |  |  |   const { support_teamMemberId, category, masterHardwareId } = request.body; | 
			
		
	
		
			
				
					|  |  |  |  | 
 | 
			
		
	
		
			
				
					|  |  |  |  |   if (!support_teamMemberId || !startDate || !endDate || !category || !masterHardwareId) { | 
			
		
	
		
			
				
					|  |  |  |  |     return reply.code(400).send({ error: 'support_teamMemberId, startDate, endDate, category, and masterHardwareId are required' }); | 
			
		
	
	
		
			
				
					|  |  |  | @ -8879,15 +8879,15 @@ exports.assignCategorizeIssue = async (request, reply) => { | 
			
		
	
		
			
				
					|  |  |  |  |   } | 
			
		
	
		
			
				
					|  |  |  |  | 
 | 
			
		
	
		
			
				
					|  |  |  |  |   // ✅ Parse using moment with expected format
 | 
			
		
	
		
			
				
					|  |  |  |  |   const start = moment(startDate, "DD-MM-YYYY HH:mm", true); | 
			
		
	
		
			
				
					|  |  |  |  |   const end = moment(endDate, "DD-MM-YYYY HH:mm", true); | 
			
		
	
		
			
				
					|  |  |  |  |   // const start = moment(startDate, "DD-MM-YYYY HH:mm", true);
 | 
			
		
	
		
			
				
					|  |  |  |  |   // const end = moment(endDate, "DD-MM-YYYY HH:mm", true);
 | 
			
		
	
		
			
				
					|  |  |  |  | 
 | 
			
		
	
		
			
				
					|  |  |  |  |   if (!start.isValid() || !end.isValid()) { | 
			
		
	
		
			
				
					|  |  |  |  |     return reply.code(400).send({ error: 'Invalid startDate or endDate format. Use DD-MM-YYYY HH:mm' }); | 
			
		
	
		
			
				
					|  |  |  |  |   } | 
			
		
	
		
			
				
					|  |  |  |  |   // if (!start.isValid() || !end.isValid()) {
 | 
			
		
	
		
			
				
					|  |  |  |  |   //   return reply.code(400).send({ error: 'Invalid startDate or endDate format. Use DD-MM-YYYY HH:mm' });
 | 
			
		
	
		
			
				
					|  |  |  |  |   // }
 | 
			
		
	
		
			
				
					|  |  |  |  | 
 | 
			
		
	
		
			
				
					|  |  |  |  |   const formattedStart = start.format("DD-MM-YYYY HH:mm:ss"); | 
			
		
	
		
			
				
					|  |  |  |  |   const formattedEnd = end.format("DD-MM-YYYY HH:mm:ss"); | 
			
		
	
		
			
				
					|  |  |  |  |   // const formattedStart = start.format("DD-MM-YYYY HH:mm:ss");
 | 
			
		
	
		
			
				
					|  |  |  |  |   // const formattedEnd = end.format("DD-MM-YYYY HH:mm:ss");
 | 
			
		
	
		
			
				
					|  |  |  |  | 
 | 
			
		
	
		
			
				
					|  |  |  |  |   let assignedCount = 0; | 
			
		
	
		
			
				
					|  |  |  |  | 
 | 
			
		
	
	
		
			
				
					|  |  |  | @ -8901,8 +8901,8 @@ exports.assignCategorizeIssue = async (request, reply) => { | 
			
		
	
		
			
				
					|  |  |  |  |         support_teamMemberId: teamMember.support_teamMemberId, | 
			
		
	
		
			
				
					|  |  |  |  |         phone: teamMember.phone, | 
			
		
	
		
			
				
					|  |  |  |  |         email: teamMember.email, | 
			
		
	
		
			
				
					|  |  |  |  |         startDate: formattedStart, | 
			
		
	
		
			
				
					|  |  |  |  |         endDate: formattedEnd | 
			
		
	
		
			
				
					|  |  |  |  |         // startDate: formattedStart,
 | 
			
		
	
		
			
				
					|  |  |  |  |         // endDate: formattedEnd
 | 
			
		
	
		
			
				
					|  |  |  |  |       }; | 
			
		
	
		
			
				
					|  |  |  |  |       assignedCount++; | 
			
		
	
		
			
				
					|  |  |  |  |     } | 
			
		
	
	
		
			
				
					|  |  |  | 
 |