11< div class ="border-b border-gray-200 dark:border-gray-700 mb-2 ">
22 < ul class ="flex flex-wrap -mb-px text-sm font-medium text-center text-gray-500 dark:text-gray-400 ">
33 < li class ="me-2 ">
4- < a (click) ="onRoleChange('Customer') "
4+ < a data-cy =" asCustomerTab " (click) ="onRoleChange('Customer') "
55 [ngClass] ="role !== 'Customer' ? 'text-gray-400 group-hover:text-gray-500 dark:text-gray-500 dark:group-hover:text-gray-300' : 'text-primary-100 border-primary-100 active dark:text-primary-50 dark:border-primary-50' "
66 class ="inline-flex cursor-pointer items-center justify-center p-4 border-b-2 border-transparent rounded-t-lg group " aria-current ="page ">
77 < svg [ngClass] ="role !== 'Customer' ? 'text-gray-400 group-hover:text-gray-500 dark:text-gray-500 dark:group-hover:text-gray-300' : 'text-primary-100 dark:text-primary-50' "
1313 </ li >
1414 @if(isSeller){
1515 < li class ="me-2 ">
16- < a (click) ="onRoleChange('Seller') "
16+ < a data-cy =" asProviderTab " (click) ="onRoleChange('Seller') "
1717 [ngClass] ="{'text-primary-100 border-primary-100 active dark:text-primary-50 dark:border-primary-50 group': role == 'Seller'} "
1818 class ="inline-flex cursor-pointer items-center justify-center p-4 border-b-2 border-transparent rounded-t-lg hover:text-gray-600 hover:border-gray-300 dark:hover:text-gray-300 group ">
1919 < svg
@@ -193,7 +193,7 @@ <h6 class="mb-3 text-sm font-bold text-gray-900 dark:text-white">
193193 {{order?.orderDate | date:'EEEE, dd/MM/yy, HH:mm'}}
194194 </ td >
195195 < td class ="px-6 py-4 text-center align-middle ">
196- < button (click) ="toggleShowDetails(order);$event.stopPropagation(); " type ="button " class ="text-white bg-primary-100 hover:bg-blue-800 focus:ring-4 focus:outline-none focus:ring-blue-300 font-medium rounded-full text-sm p-2.5 text-center inline-flex items-center me-2 ">
196+ < button data-cy =" viewOrderDetails " (click) ="toggleShowDetails(order);$event.stopPropagation(); " type ="button " class ="text-white bg-primary-100 hover:bg-blue-800 focus:ring-4 focus:outline-none focus:ring-blue-300 font-medium rounded-full text-sm p-2.5 text-center inline-flex items-center me-2 ">
197197 < svg class ="w-[18px] h-[18px] text-white " aria-hidden ="true " xmlns ="http://www.w3.org/2000/svg " fill ="none " viewBox ="0 0 20 14 ">
198198 < g stroke ="currentColor " stroke-linecap ="round " stroke-linejoin ="round " stroke-width ="2 ">
199199 < path d ="M10 10a3 3 0 1 0 0-6 3 3 0 0 0 0 6Z "/>
@@ -413,7 +413,7 @@ <h3 class="text-base dark:text-gray-200">
413413 < td class ="px-6 py-4 text-center align-middle flex justify-center ">
414414 @if (!hasProcurementAutomaticTerm(item)) {
415415 @if (!item.productOrderItem.state && role == 'Seller') {
416- < button type ="button " title ="Acknowledge the order item "
416+ < button data-cy =" acknowledgeOrder " type ="button " title ="Acknowledge the order item "
417417 class ="text-white bg-primary-100 hover:bg-blue-800 focus:ring-4 focus:outline-none focus:ring-blue-300 font-medium rounded-full text-sm p-2.5 text-center inline-flex items-center me-2 "
418418 (click) ="openModal('acknowledged', item) ">
419419 <!--!Font Awesome Pro 6.7.2 by @fontawesome - https://fontawesome.com License - https://fontawesome.com/license (Commercial License) Copyright 2025 Fonticons, Inc.-->
@@ -423,7 +423,7 @@ <h3 class="text-base dark:text-gray-200">
423423 </ svg >
424424 </ button >
425425
426- < button type ="button " title ="Reject the order item "
426+ < button data-cy =" rejectOrder " type ="button " title ="Reject the order item "
427427 class ="text-red-950 bg-red-500 hover:bg-red-600 focus:ring-4 focus:outline-none focus:ring-red-300 font-medium rounded-full text-sm p-2.5 text-center inline-flex items-center me-2 "
428428 (click) ="openModal('cancelled', item) ">
429429 < svg class ="w-[18px] h-[18px] text-white stroke-white fill-white stroke-2 " stroke ="currentColor "
@@ -434,14 +434,14 @@ <h3 class="text-base dark:text-gray-200">
434434 } @else {
435435 @if(role == 'Seller'){
436436 @if (item.productOrderItem.state === 'acknowledged') {
437- < button type ="button " title ="Start Order Treatment "
437+ < button data-cy =" startOrderTreatment " type ="button " title ="Start Order Treatment "
438438 class ="text-green-950 bg-green-500 hover:bg-green-600 focus:ring-4 focus:outline-none focus:ring-green-300 font-medium rounded-full text-sm p-2.5 text-center inline-flex items-center me-2 "
439439 (click) ="openModal('inProgress', item) ">
440440 < svg class ="w-[18px] h-[18px] text-white stroke-white fill-white stroke-2 " xmlns ="http://www.w3.org/2000/svg " viewBox ="0 0 384 512 ">
441441 < path class ="fa-secondary " opacity =".4 " d ="M32 80l0 352c0 5.8 3.1 11.1 8.2 14s11.2 2.7 16.2-.3l288-176c4.8-2.9 7.7-8.1 7.7-13.7s-2.9-10.7-7.7-13.7l-288-176c-4.9-3-11.1-3.1-16.2-.3s-8.2 8.2-8.2 14z "/> < path class ="fa-primary " d ="M56.3 66.3c-4.9-3-11.1-3.1-16.2-.3s-8.2 8.2-8.2 14l0 352c0 5.8 3.1 11.1 8.2 14s11.2 2.7 16.2-.3l288-176c4.8-2.9 7.7-8.1 7.7-13.7s-2.9-10.7-7.7-13.7l-288-176zM24.5 38.1C39.7 29.6 58.2 30 73 39L361 215c14.3 8.7 23 24.2 23 41s-8.7 32.2-23 41L73 473c-14.8 9.1-33.4 9.4-48.5 .9S0 449.4 0 432L0 80C0 62.6 9.4 46.6 24.5 38.1z "/> </ svg >
442442 </ button >
443443 } @else if (item.productOrderItem.state === 'inProgress') {
444- < button type ="button " title ="Order Completely Treated "
444+ < button data-cy =" completeOrder " type ="button " title ="Order Completely Treated "
445445 class ="text-green-950 bg-green-500 hover:bg-green-600 focus:ring-4 focus:outline-none focus:ring-green-300 font-medium rounded-full text-sm p-2.5 text-center inline-flex items-center me-2 "
446446 (click) ="openModal('completed', item) ">
447447 < svg class ="w-[18px] h-[18px] text-white stroke-white fill-white stroke-2 " xmlns ="http://www.w3.org/2000/svg " viewBox ="0 0 512 512 ">
@@ -501,12 +501,12 @@ <h3 class="text-xl font-semibold text-secondary-50 dark:text-white">
501501 </ div >
502502 <!-- Botones de acción -->
503503 < div class ="flex items-center p-6 space-x-4 border-t border-gray-200 rounded-b dark:border-gray-600 ">
504- < button type ="button " (click) ="confirmAction() "
504+ < button data-cy =" confirmActionBtn " type ="button " (click) ="confirmAction() "
505505 class ="text-white bg-blue-600 hover:bg-blue-800 focus:ring-4 focus:ring-blue-300 font-medium
506506 rounded-lg text-sm px-5 py-2.5 text-center dark:bg-blue-500 dark:hover:bg-blue-700 dark:focus:ring-blue-800 ">
507507 Yes, Confirm
508508 </ button >
509- < button type ="button " (click) ="closeModal() "
509+ < button data-cy =" cancelActionBtn " type ="button " (click) ="closeModal() "
510510 class ="text-gray-500 bg-white border border-gray-300 focus:outline-none hover:bg-gray-100
511511 focus:ring-4 focus:ring-gray-200 font-medium rounded-lg text-sm px-5 py-2.5 dark:bg-gray-700
512512 dark:text-gray-300 dark:border-gray-500 dark:hover:bg-gray-600 dark:focus:ring-gray-600 ">
0 commit comments