当前位置: 首页>>代码示例>>PHP>>正文


PHP BFCHelper::getJsonEncodeString方法代码示例

本文整理汇总了PHP中BFCHelper::getJsonEncodeString方法的典型用法代码示例。如果您正苦于以下问题:PHP BFCHelper::getJsonEncodeString方法的具体用法?PHP BFCHelper::getJsonEncodeString怎么用?PHP BFCHelper::getJsonEncodeString使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在BFCHelper的用法示例。


在下文中一共展示了BFCHelper::getJsonEncodeString方法的5个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。

示例1: setOrder

 public function setOrder($customerData = NULL, $suggestedStay = NULL, $creditCardData = NULL, $otherNoteData = NULL, $merchantId = 0, $orderType = NULL, $userNotes = NULL, $label = NULL, $cultureCode = NULL, $processOrder = NULL, $priceType = NULL)
 {
     $userId = '';
     $user = JFactory::getUser();
     if ($user->id != 0) {
         $userId = $user->id . "|" . $user->username . "|" . $_SERVER["SERVER_NAME"];
     }
     if (!isset($creditCardData) || empty($creditCardData)) {
         $creditCardData = "";
         //		}else{
         //			$creditCardData =  BFCHelper::getJsonEncodeString($creditCardData);
     }
     if (!isset($otherNoteData) || empty($otherNoteData)) {
         $otherNoteData = "";
     }
     if (!isset($userNotes) || empty($userNotes)) {
         $userNotes = "";
     }
     //$suggestedStay = null;
     $options = array('path' => $this->urlCreateOrder, 'data' => array('customerData' => BFCHelper::getQuotedString(BFCHelper::getJsonEncodeString($customerData)), 'suggestedStay' => BFCHelper::getQuotedString(BFCHelper::getJsonEncodeString($suggestedStay)), 'creditCardData' => $creditCardData, 'otherNoteData' => BFCHelper::getQuotedString($otherNoteData), 'merchantId' => $merchantId, 'orderType' => BFCHelper::getQuotedString($orderType), 'userNotes' => BFCHelper::getQuotedString($userNotes), 'label' => BFCHelper::getQuotedString($label), 'cultureCode' => BFCHelper::getQuotedString($cultureCode), 'processOrder' => $processOrder, 'priceType' => BFCHelper::getQuotedString($priceType), 'addedBy' => BFCHelper::getQuotedString($userId), '$format' => 'json'));
     $url = $this->helper->getQuery($options);
     $order = null;
     //$r = $this->helper->executeQuery($url);
     $r = $this->helper->executeQuery($url, "POST");
     if (isset($r)) {
         $res = json_decode($r);
         //			$order = $res->d->results ?: $res->d;
         if (!empty($res->d->results)) {
             $order = $res->d->results;
         } elseif (!empty($res->d)) {
             $order = $res->d;
         }
     }
     return $order;
 }
开发者ID:Bookingfor,项目名称:joomla-extension,代码行数:35,代码来源:orders.php

示例2: setAlertOnSell

 public function setAlertOnSell($customerData = NULL, $searchData = NULL, $merchantId = NULL, $type = NULL, $label = NULL, $cultureCode = NULL, $processRequest = NULL, $enabled = NULL)
 {
     $options = array('path' => $this->urlCreateUserAlert, 'data' => array('customerData' => BFCHelper::getQuotedString(BFCHelper::getJsonEncodeString($customerData)), 'searchData' => BFCHelper::getQuotedString(BFCHelper::getJsonEncodeString($searchData)), 'merchantId' => $merchantId, 'type' => BFCHelper::getQuotedString($type), 'label' => BFCHelper::getQuotedString($label), 'cultureCode' => BFCHelper::getQuotedString($cultureCode), 'processUserAlert' => $processRequest, 'enabled' => $enabled, '$format' => 'json'));
     $url = $this->helper->getQuery($options);
     $alert = null;
     //$r = $this->helper->executeQuery($url);
     $r = $this->helper->executeQuery($url, "POST");
     if (isset($r)) {
         $res = json_decode($r);
         $alert = (int) $res->d->CreateUserAlert;
         //$alert = $res->d->results ?: $res->d;
     }
     return $alert;
 }
开发者ID:Bookingfor,项目名称:joomla-extension,代码行数:14,代码来源:searchonsell.php

示例3: setMerchantAndUser

 public function setMerchantAndUser($customerData = NULL, $password = NULL, $merchantType = 0, $merchantCategory = 0, $company = NULL, $userPhone = NULL, $webSite = NULL)
 {
     $options = array('path' => $this->urlCreateMerchantAndUser, 'data' => array('customerData' => BFCHelper::getQuotedString(BFCHelper::getJsonEncodeString($customerData)), 'password' => BFCHelper::getQuotedString($password), 'company' => BFCHelper::getQuotedString($company), 'userPhone' => BFCHelper::getQuotedString($userPhone), 'webSite' => BFCHelper::getQuotedString($webSite), 'merchantType' => $merchantType, 'merchantCategory' => $merchantCategory, '$format' => 'json'));
     $url = $this->helper->getQuery($options);
     $userId = -1;
     //$r = $this->helper->executeQuery($url);
     $r = $this->helper->executeQuery($url, "POST");
     if (isset($r)) {
         $res = json_decode($r);
         $tmpuserId = $res->d->results ?: $res->d;
         $userId = $tmpuserId->CreateMerchantAndUser;
     }
     return $userId;
 }
开发者ID:Bookingfor,项目名称:joomla-extension,代码行数:14,代码来源:merchants.php

示例4: setInfoRequest

 public function setInfoRequest($customerData = NULL, $suggestedStay = NULL, $creditCardData = NULL, $otherNoteData = NULL, $merchantId = 0, $type = NULL, $userNotes = NULL, $label = NULL, $cultureCode = NULL, $processInfoRequest = NULL, $mailFrom = NULL)
 {
     $options = array('path' => $this->urlCreateInfoRequest, 'data' => array('customerData' => BFCHelper::getQuotedString(BFCHelper::getJsonEncodeString($customerData)), 'suggestedStay' => BFCHelper::getQuotedString(BFCHelper::getJsonEncodeString($suggestedStay)), 'otherNoteData' => BFCHelper::getQuotedString($otherNoteData), 'infoRequestType' => BFCHelper::getQuotedString($type), 'userNotes' => BFCHelper::getQuotedString($userNotes), 'label' => BFCHelper::getQuotedString($label), 'cultureCode' => BFCHelper::getQuotedString($cultureCode), 'processInfoRequest' => $processInfoRequest, 'mailFrom' => $mailFrom, '$format' => 'json'));
     if (!empty($merchantId) && intval($merchantId) > 0) {
         $options['data']['merchantId'] = $merchantId;
     }
     $url = $this->helper->getQuery($options);
     $order = null;
     //$r = $this->helper->executeQuery($url);
     $r = $this->helper->executeQuery($url, "POST");
     if (isset($r)) {
         $res = json_decode($r);
         $order = $res->d->results ?: $res->d;
     }
     return $order;
 }
开发者ID:Bookingfor,项目名称:joomla-extension-v-2,代码行数:16,代码来源:inforequest.php

示例5: setCrew

 public function setCrew($customerData = NULL, $merchantId = NULL, $orderId = NULL)
 {
     $params = $this->getState('params');
     if ($customerData == null) {
         $customerData = $params['customerData'];
     }
     if (COM_BOOKINGFORCONNECTOR_USEEXTERNALUPDATEORDER) {
         $this->urlCreateCrew = '/CreateCrewFrom' . COM_BOOKINGFORCONNECTOR_USEEXTERNALUPDATEORDERSYSTEM;
     }
     $options = array('path' => $this->urlCreateCrew, 'data' => array('crewData' => BFCHelper::getQuotedString(BFCHelper::getJsonEncodeString($customerData)), 'merchantId' => $merchantId, 'orderId' => $orderId, '$format' => 'json', '$expand' => 'ChildCrews'));
     $url = $this->helper->getQuery($options);
     $crew = null;
     //$r = $this->helper->executeQuery($url);
     $r = $this->helper->executeQuery($url, "POST");
     if (isset($r)) {
         $res = json_decode($r);
         $crew = $res->d->results ?: $res->d;
     }
     return $crew[0];
 }
开发者ID:Bookingfor,项目名称:joomla-extension-v-2,代码行数:20,代码来源:crew.php


注:本文中的BFCHelper::getJsonEncodeString方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。