コード例 #1
0
 public function __construct($logger, $message)
 {
     parent::__construct($logger);
     $this->_logger->log(__CLASS__ . ' ' . __METHOD__);
     $this->message = $message;
     $this->run();
 }
コード例 #2
0
 public function __construct($logger)
 {
     parent::__construct($logger);
     $this->synchronization = new Synchronization();
     $this->slave_ip = $this->synchronization->getRemoteIpToSentMessages();
     $this->slave_port = $this->synchronization->getRemotePortToSentMessages();
     $this->loadSlaveClient();
 }
コード例 #3
0
 /**
  * Ctor.
  * 
  * @param ILogger $logger
  * @param string $source Source string with connection info
  * @param string $by User who runs listener
  */
 public function __construct($logger, $source, $communication_type, $by)
 {
     parent::__construct($logger);
     $this->_logger->log(__METHOD__);
     $this->source = $source;
     $this->communication_type = $communication_type;
     $this->by = $by;
     $this->init();
 }
コード例 #4
0
 /**
  * Ctor.
  * 
  * @param ILogger $logger
  * @param string $source Source string with connection info
  * @param string $by User who runs listener
  */
 public function __construct($logger, $source, $by, $listener)
 {
     parent::__construct($logger);
     $this->_logger->log(__METHOD__);
     $this->source = $source;
     $this->listener = $listener;
     $this->by = $by;
     if (!$this->init()) {
         return false;
     }
     $this->run();
 }
コード例 #5
0
 /**
  * Ctor.
  * 
  * @param ILogger $logger
  * @param string $source Source string with connection info
  * @param string $by User who runs listener
  */
 public function __construct($logger, $source, $by, $listener, $callerClass, $connector)
 {
     if ($callerClass !== 'ProcessListenCom') {
         return false;
     }
     parent::__construct($logger);
     $this->_logger->log(__METHOD__);
     $this->_connector = $connector;
     $this->source = $source;
     $this->listener = $listener;
     $this->by = $by;
     if (!$this->init()) {
         return false;
     }
     $this->run();
 }
コード例 #6
0
ファイル: ProcessMessage.php プロジェクト: anton-itscript/WM
 public function __construct($logger, $message_obj_temp)
 {
     parent::__construct($logger);
     // тут надо производить замену модели  $message_obj с ListenerLogtemp на ListenrLog
     $message_obj = new ListenerLog();
     $message_obj->listener_id = $message_obj_temp->listener_id;
     $message_obj->message = $message_obj_temp->message;
     $message_obj->rewrite_prev_values = $message_obj_temp->rewrite_prev_values;
     $message_obj->is_processed = $message_obj_temp->is_processed;
     $message_obj->is_processing = $message_obj_temp->is_processing;
     $message_obj->source = $message_obj_temp->source;
     $message_obj->source_info = $message_obj_temp->source_info;
     $message_obj->station_id = 0;
     $message_obj->save();
     $this->_logger->log(__METHOD__);
     $this->message_obj = $message_obj;
 }
コード例 #7
0
 public function __construct($logger)
 {
     parent::__construct($logger);
     $this->loadForwardingClients();
 }
コード例 #8
0
ファイル: catalog.tpl.php プロジェクト: AlexanderWhi/tplshop2
        include 'catalog_view_' . $this->getView() . '.tpl.php';
    }
    ?>



<?php 
} elseif (!$action) {
    ?>
<div>Список пуст</div><?php 
}
?>
</form>
</div>
<?php 
if ($text = BaseComponent::getText("/catalog/{$id}")) {
    ?>
<div class="blk2">
<?php 
    echo $text;
    ?>
</div>
<?php 
} else {
    echo $this->getText("/catalog/{$id}");
}
/*form  class="common search" action="/catalog/?act=searchGoods" method="POST">

<input name="search" class="field" value="<?=isset($_GET['search'])?htmlspecialchars(trim(urldecode($_GET['search']))):''?>">
<button type="submit" class="button">Найти</button>
</form*/
コード例 #9
0
ファイル: Item.php プロジェクト: silentworks/raktiv
 public function __construct(array $options = [])
 {
     parent::__construct($options);
 }
コード例 #10
0
ファイル: Ymap.class.php プロジェクト: AlexanderWhi/tplshop2
 function actGetDescrByZone()
 {
     global $get;
     echo BaseComponent::getText('delivery_zone_' . $get->get('id'));
 }
コード例 #11
0
 /**
  * 
  * 
  * @param ILogger $logger
  * @param Listener $listener
  * @param PhpSerial $serial
  * @param array $serialPortParams
  * @param int $serialPort
  * @param string $phoneNumber
  * @param string $messageText
  */
 public function __construct($logger, $listener, $serial, $serialPortParams, $serialPort, $phoneNumber, $messageText)
 {
     parent::__construct($logger);
     $this->_logger->log(__METHOD__);
     $this->_listener = $listener;
     $this->_serial = $serial;
     $this->_serialPortParams = $serialPortParams;
     $this->_serialPort = $serialPort;
     $this->_phoneNumber = $phoneNumber;
     $this->_messageText = $messageText;
 }
コード例 #12
0
    if (empty($is_order)) {
        ?>
<!--	<a class="refresh" href="/catalog/">Продолжить покупки</a>-->
<!--	<a class="refresh" href="javascript:shop.refresh()">Пересчитать</a>-->
<a class="clear" href="javascript:shop.clear()" ><span>Очистить корзину</span></a>
<?php 
    }
    ?>
&nbsp;</td>
	<td>Итого:</td>
	<td colspan="2"><strong class="total_price"><span id="basket_total_summ"><?php 
    echo price($price);
    ?>
</strong>
	<?php 
    echo BaseComponent::getText('total_info');
    ?>
	</td>
	<td></td><?php 
    if (empty($is_order)) {
        ?>
<td></td><?php 
    }
    ?>
</tr>

</tfoot>
</table>

<?php 
} else {
コード例 #13
0
 function actSubscribe()
 {
     global $ST, $post;
     if ($post->isMail('mail')) {
         $type = array("news");
         if ($t = $post->get('type')) {
             $type = preg_split('/[,\\s]/', $t);
         }
         //Добавим в подписку
         $rs = $ST->select("SELECT * FROM sc_subscribe WHERE mail='" . SQL::slashes($post->get('mail')) . "'");
         if (!$rs->next()) {
             $ST->insert('sc_subscribe', array('mail' => $post->get('mail'), 'type' => implode(' ', $type)));
         } else {
             $t = array();
             if (trim($rs->get('type'))) {
                 $t = explode(' ', trim($rs->get('type')));
             }
             if ($t == array_unique(array_merge($t, $type))) {
                 echo printJSON(array('msg' => 'Уже подписаны'));
                 exit;
             }
             $t = array_unique(array_merge($t, $type));
             $ST->update('sc_subscribe', array('type' => implode(' ', $t)), "mail='" . SQL::slashes($post->get('mail')) . "'");
         }
         echo printJSON(array('msg' => BaseComponent::getText('subscribe_confirm')));
         exit;
     } else {
         echo printJSON(array('err' => 'Введите адрес корректно!'));
         exit;
     }
 }
コード例 #14
0
 /**
  * @param Logger $logger
  * @param array  $server
  * @param array  $client
  */
 public function __construct($logger, $server, $client)
 {
     parent::__construct($logger);
     $this->server_param = $server;
     $this->client_param = $client;
 }
コード例 #15
0
 function renderExplorer($delimitter = ' - ')
 {
     //		global $ST;
     //		$this->explorer[]=array('name'=>$this->mod_name,'url'=>$this->mod_alias);
     //		$parent=$this->mod_parent_id;
     //		while ($parent) {
     //			$rs=$ST->select("SELECT * FROM sc_module WHERE mod_id=".$parent);
     //			if($rs->next()){
     //				$parent=$rs->getInt('mod_parent_id');
     //				$this->explorer[]=array('name'=>$rs->get('mod_name'),'url'=>$rs->get('mod_alias'));
     //			}else{
     //				break;
     //			}
     //		}
     //		if($this->mod_alias!='/'){
     //			$this->explorer[]=array('name'=>'Главная','url'=>'/');
     //		}
     return parent::renderExplorer($delimitter);
 }
コード例 #16
0
 /**
  *   Constructor. Calls BaseComponent constructor.
  */
 function __construct()
 {
     parent::__construct();
 }
コード例 #17
0
 function method()
 {
     $this->needAuth();
     parent::method();
 }
コード例 #18
0
ファイル: Schedule.php プロジェクト: anton-itscript/WM-Web
 public function __construct($logger, $args)
 {
     parent::__construct($logger);
     $this->run($args);
 }
コード例 #19
0
 function checkDelivery($args)
 {
     $error = array();
     if (!Cfg::get('SHOP_DELIVERY_ENABLED')) {
         return $error;
     }
     if ($args->exists('date')) {
         //Если передаём дату доставки
         if (!trim($args->get('date'))) {
             $error['time'] = 'Введите дату';
         } elseif (!preg_match('|\\d{2}\\.\\d{2}\\.\\d{4}|', $args->get('date'))) {
             $error['time'] = 'Введите дату корректно [dd.mm.yyyy]';
         }
     }
     if ($this->cfg('SHOP_CHECK_DELIVERY_TIME') && time() > strtotime($args->get('date') . ' ' . $args->get('time') . ':00:00')) {
         $error['time'] = BaseComponent::getText('delivery_time_error_notice');
         $error['time'] .= '<small style="color:#aaa">Текущее время ' . date('H:i:s') . '</small>';
     }
     if (!trim($args->get('address'))) {
         $error['address'] = 'Введите адрес доставки';
     }
     return $error;
 }