source/php/Event.php
/**
     * Set a event post meta fields
     * @param   integer $postId The post's id
     * @param   object  $data   The cbis data
     * @return  void
     */
Set a event post meta fields
@param   integer $postId The post's id
@param   object  $data   The cbis data
@return  void
Set a event post meta fields @param integer $postId The post ' s id @param object $data The cbis data @return void
private static function addPostMeta($postId, $data)
    {
        update_post_meta($postId, 'event-sync', true);
        update_post_meta($postId, 'event-uid', $data['id']);
        update_post_meta($postId, 'event-date-start', date('Y-m-d H:i', strtotime($data['date_start'])));
        update_post_meta($postId, 'event-date-end', date('Y-m-d H:i', strtotime($data['date_end'])));
        update_post_meta($postId, 'event-location', $data['location']);
        update_post_meta($postId, 'event-address', $data['address']);
        update_post_meta($postId, 'event-image_url', $data['image_url']);
        if (!self::isUrl($data['ticket_link'])) {
            $data['ticket_link'] = '';
        }
        update_post_meta($postId, 'event-ticket_url', $data['ticket_link']);
    }
private static function addPostMeta ( $ postId , $ data ) { update_post_meta ( $ postId , 'event-sync' , true ) ; update_post_meta ( $ postId , 'event-uid' , $ data [ 'id' ] ) ; update_post_meta ( $ postId , 'event-date-start' , date ( 'Y-m-d H:i' , strtotime ( $ data [ 'date_start' ] ) ) ) ; update_post_meta ( $ postId , 'event-date-end' , date ( 'Y-m-d H:i' , strtotime ( $ data [ 'date_end' ] ) ) ) ; update_post_meta ( $ postId , 'event-location' , $ data [ 'location' ] ) ; update_post_meta ( $ postId , 'event-address' , $ data [ 'address' ] ) ; update_post_meta ( $ postId , 'event-image_url' , $ data [ 'image_url' ] ) ; if ( ! self :: isUrl ( $ data [ 'ticket_link' ] ) ) { $ data [ 'ticket_link' ] = '' ; } update_post_meta ( $ postId , 'event-ticket_url' , $ data [ 'ticket_link' ] ) ; }
Set a event post meta fields
 @param   integer $postId The post's id
 @param   object  $data   The cbis data
 @return  void
Set a event post meta fields @param integer $postId The post ' s id @param object $data The cbis data @return void