Github user moeamla commented on the issue:
https://github.com/apache/incubator-predictionio/issues/282
@dszeto, thank you for the quick response and I subscribed to the email
list! Your help is appreciated.
I understand it depends on the Engine template. Can edit the template to
fit my needs?
Regarding the EntityType, the PHP SDK has hard coded EntityType of 'item'.
Do I need to add my own function to add 'location' entityType? or should we
make changes on the PHP SDK to take entityType as a param?
public function setItem($iid, array $properties=array(), $eventTime=null) {
$eventTime = $this->getEventTime($eventTime);
if (empty($properties)) $properties = (object)$properties;
$json = json_encode([
'event' => '$set',
**'entityType' => 'item',**
'entityId' => $iid,
'properties' => $properties,
'eventTime' => $eventTime,
]);
return $this->sendRequest('POST', $this->eventUrl, $json);
}
Sorry for the many questions :)
---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at [email protected] or file a JIRA ticket
with INFRA.
---