-
Notifications
You must be signed in to change notification settings - Fork 2
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
WZ-4212: Added more details in Wizzy section on Product Details Page … #145
Conversation
da27dfe
to
3308aa4
Compare
Block/Adminhtml/Sync/Status.php
Outdated
foreach ($entitiesSyncStatus as $entitySyncStatus) { | ||
$entitiesSyncStatus_[] = [ | ||
"id" => $entitySyncStatus['id'], | ||
"entity_id" => $entitySyncStatus['entity_id'], |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Remove non required details
Block/Adminhtml/Sync/Status.php
Outdated
"updated_at" => $entitySyncStatus['updated_at'], | ||
"skipped_data" => ($skippedEntitiesData && !empty($skippedEntitiesData['entity_data'])) | ||
? $skippedEntitiesData['entity_data'] | ||
: "", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Keep it null if not found.
@@ -57,4 +61,21 @@ public function deleteSkippedEntities($entityIds, $storeId, $entityType = self:: | |||
|
|||
return $entities; | |||
} | |||
public function getSkippedEntities($storeId, $entityId, $entityType = null) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
getSkippedEntityById
$collection->addFieldToFilter('entity_type', $entityType); | ||
} | ||
|
||
$entityDataArray = []; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
$skippedEntities
|
||
$entityDataArray = []; | ||
foreach ($collection->getItems() as $item) { | ||
$entityDataArray['entity_data'] = $item->getData('entity_data'); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Remove entity_data
A entity can be skipped for multiple store. Check what happens for the case.
<b><?= $block->escapeHtml('In sync'); ?></b> | ||
<?php | ||
} elseif ($sync['status'] == -1) { ?> | ||
<b><?= $block->escapeHtml('No entities to be synced!'); ?></b> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Product is not added in sync yet.
<b><?= $block->escapeHtml('No entities to be synced!'); ?></b> | ||
<?php | ||
} elseif ($sync['skipped_data']) { ?> | ||
<b><?= $block->escapeHtml('Product Skipped!'); ?></b> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Product Skipped during Sync
444a6bf
to
9663651
Compare
Helpers/API/WizzyAPIEndPoints.php
Outdated
@@ -4,7 +4,7 @@ | |||
|
|||
class WizzyAPIEndPoints | |||
{ | |||
const BASE_END_POINT = "https://api.wizsearch.in/v1"; | |||
const BASE_END_POINT = "https://testing.api.wizzy.ai/v1"; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Remove this change
Block/Adminhtml/Sync/Status.php
Outdated
|
||
return $syncResults; | ||
} | ||
return [$entitiesSyncStatus_]; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You're sending array of array.Won't this break functionalities on frontend ?
…- When a Product is Skipped
…- When a Product is Skipped