but1head

but1head

Был в сети 04 ноября 2021, 20:02
Заказы принимаю
Если свяжете с mfilter2 — будет очень круто) правда я не нашел калбэков от фильтрации, и
точки почему-то не скрываются через visible: false

вот кстати генератор точек по примеру яндекса

<?php
$json = array( 'type' => 'FeatureCollection', 'features' => array());
$points = $modx->getIterator('modDocument',array('parent' => 3, 'class_key' => 'Ticket', 'published' => 1));
foreach ($points as $point) {
	array_push($json['features'],array(
	  "type" => "Feature", "id" => $point->get('id'),
	  "geometry" => array("type" => "Point", "coordinates" => explode(",",$point->getTVValue('coords'))),
	  "properties" => array("dataid" => $point->get('id'), "balloonContent" => $point->get('pagetitle'))
	));
}

return $modx->toJSON($json);
вернулся к этому вопросу, почему не работает сортировка?
в базе 2 комента с id, 50 и 51. Выводит 50й
$pdoFetch->getObject('Ticket', $row['id'], array(
			'leftJoin' => array(
				'LastComment' => array('class' => 'TicketComment', 'on' => '`LastComment`.`thread` = '.$row['thread']),
			),
			'select' => array(
				'LastComment' => '`LastComment`.`raw` as `last_comment`',
			),
			'sortby' => array(
				'LastComment' => '`LastComment`.`id`',
			),
			'sortdir' => array(
				'LastComment' => 'ASC',
			),
			'groupby' => $class.'.id'
		));
Скачайте FormSave
[[!AjaxForm?
			&snippet=`FormIt`
			&form=`tpl.form.lowprice`
			&hooks=`email,FormSave`
			&fsFormTopic=`Нашел дешевле`
			&emailSubject=`Нашел дешевле`
			&emailTo=`тут мыло`
			&emailTpl=`форма`
			&validate=`product:required,name:required,phone:required`
			&validationErrorMessage=`Заполните все поля!`
			&successMessage=`Ваш заказ отправлен!`
			
		]]