Trying

Trying

С нами с 05 марта 2016; Место в рейтинге пользователей: #806
Trying
16 декабря 2021, 17:28
0
Понял.
Еще раз спасибо!
Trying
16 декабря 2021, 13:29
0
Спасибо!

Я просто поменял:
&filters=`msoption|name:number`
в
&filters=`msoption|name:decimal`

И все заработало нормально. Не знаю корректно ли это — в документации не нашел.
Trying
29 сентября 2019, 13:06
0
Присоединяюсь к вопросу. Сортировка как задано в значениях msoption была бы самой логичной, так как даже простой checkbox Да/Нет на английском отображаетса как No/Yes, уже не говорю про более сложные значения, которые клиент хочет расбросать так, как ему кажется логично.

Конечно можно и так.

Указать значения с цифрами:

1 zgrhetyjr
2 afenmjfhjm
3 shtrym

И эти цифры потом скрыть:

$('form#mse2_filters label span').html(function() {
  	var text= $(this).text().trim().split(' ');
  	var first = text.shift();
  	return (text.length > 0 ? '<span style="display:none">'+ first + '</span> ' : first) + text.join(' ');
  	});

Но это костиля.
Trying
25 сентября 2019, 13:46
0
docs.modx.pro/komponentyi/msearch2/snippetyi/mfilter2#Скрипты-и-стили

&filterOptions=`{
"selected_tpl": "<a href='#' data-id='_id_' class='mse2_selected_link'><em>_title_</em><sup>x</sup></a>",
"selected_wrapper_tpl": "<strong>_title_:</strong> ",
"selected_filters_delimeter": "; ",
"selected_values_delimeter": ", "
}`
Trying
18 июня 2019, 12:29
0
Добрый день,

А как в этом pdoMenu коде подключить и вывести также и msProductOptions, то есть те опции которые мы можем создавать сами?

А также c msProductData работает только [[+thumb]] и [[+image]], в msProducts работало и {$file['medium']} в Media Sources оформлены так:
{
«small»:{«w»:200,«h»:130,«q»:100,«zc»:«1»,«bg»:«ffffff»},
«medium»:{«w»:400,«h»:260,«q»:100,«zc»:«1»,«bg»:«ffffff»},
«big»:{«w»:600,«h»:390,«q»:100,«zc»:«1»,«bg»:«ffffff»}
}

Тут возможно подключить?

Спасибо!
Trying
09 марта 2016, 13:39
0
And this also works:
return $this->pdoTools->getChunk($tpl, $row, $this->pdoTools->config['fastMode']) . "\n";
Trying
09 марта 2016, 12:42
0
Ok, so looking at how it was implemented in Wayfinder, I have just changed this line in pdomenu.class:

return $this->pdoTools->getChunk($tpl, $row, $this->pdoTools->config['fastMode']);
to this bit of code:
$tploutput = $this->pdoTools->getChunk($tpl, $row, $this->pdoTools->config['fastMode']);
$newline = "\n";
return $tploutput . $newline;
Ant it works. Probably it is possible to make it more elegant and simple, but since I know nothing in these things so can only mimic what is done elsewhere.

Trying
08 марта 2016, 12:12
0
No, it doesn't work. Does nothing. Also can't find setting outputSeparator being referenced in other class.php files
Trying
07 марта 2016, 21:03
0
Yes, I did. It displays \n in html. For whatever reason, when all
<li></li><li></li>
are in one line sometimes occur slight distortions of css styling. In Wayfinder every rowtpl is in new line, I found in wayfinder.class.php this line:
/* return the row */
        $separator = $this->modx->getOption('nl',$this->_config,"\n");
        return $output . $separator;
Probably it is possible to add somewhere \n in pdomenu.class.php?