Wassi Wassinen

Wassi Wassinen

С нами с 25 января 2013; Место в рейтинге пользователей: #37
Wassi Wassinen
10 января 2017, 01:53
+1
Это классно! Если рейтинг или сумма заказов уменьшилась (расторжения, отказы), то пользователь переходит на предыдущий уровень возможностей\скидок. Удобно.
Wassi Wassinen
08 января 2017, 22:24
0
Он не умеет автоматически. Нужно вручную размечать текст специальными тегами.
Wassi Wassinen
08 января 2017, 22:23
0
Благодарю за ответ! Надеюсь, получится что-то интересное. В этом компоненте, действительно, нет понимания его масштабируемости и базового функционала.
Wassi Wassinen
08 января 2017, 20:52
0
Огромное спасибо! Скажите, а можно как-то повесить этот код плагином, чтобы все работало без исправления исходников?
Wassi Wassinen
08 января 2017, 20:32
0
Интересно, можно как-то понимать какие ресурсы или плагины в логе вызывают ошибки?
Wassi Wassinen
08 января 2017, 13:00
0
Может быть все же внедрить функционал перевода из группы в группу плагинами на определенные количественно-качественные показатели, как я предлагал раньше? Объясню, почему я это предлагаю. Вы бы могли сделать основу условно-бесплатной (Интерфейс групп и плагинов, которые к ним привязаны с одним плагином для ознакомления), а дополняющие плагины продавать по 100-200 рублей и закрывать максимально обширную аудиторию. Одним нужно переводить из группы в группу исходя из кол-ва комментариев и постов, а другим — в зависимости от рейтинга в определенном разделе и т.д. А так вы создали узконаправленный компонент, но он практически никому не нужен.

Заранее благодарен за ответ!
Wassi Wassinen
08 января 2017, 12:01
0
Спасибо, Алексей. Куда скинуть деньги?
Wassi Wassinen
07 января 2017, 22:46
1
+1
Это уже работает. Создавайте поле в чанке ms2form и в него добавляйте дату вида yyyy-mm-dd. Самое простое — прикрутить скрипт datepicker. И сохраняйте значение в поле publishedon и т.д.
Wassi Wassinen
07 января 2017, 00:22
0
У вас в итоге получилось построить запрос?
Wassi Wassinen
06 января 2017, 16:45
0
Это из документации:

&having Используется, чтобы ограничить выборку сгруппированных строк с помощью условия, относящегося ко всей группе, заданной в &groupby

Так как не нашел примера, я не понял как использовать. Это не про количественное ограничение в каждой группировке?
Wassi Wassinen
06 января 2017, 16:42
0
Василий, ты главное, знай, что у меня нет задачи как-то тебя задеть или вывести из себя. Я просто хочу понять, в чем ошибка. И всегда готов общаться.
Wassi Wassinen
06 января 2017, 16:07
0
Вот копия &showLog

0.0002460: Query parameters are prepared.
0.0000370: xPDO query object created
0.0002151: leftJoined TicketsSection as Section
0.0001669: leftJoined modUser as User
0.0001462: leftJoined modUserProfile as Profile
0.0007679: leftJoined TicketTotal as Total
0.0000021: Grouped by parent
0.0001140: Added selection of TicketsSection: SQL_CALC_FOUND_ROWS `id` AS `section.id`, `type` AS `section.type`, `contentType` AS `section.contentType`, `pagetitle` AS `section.pagetitle`, `longtitle` AS `section.longtitle`, `description` AS `section.description`, `alias` AS `section.alias`, `link_attributes` AS `section.link_attributes`, `published` AS `section.published`, `pub_date` AS `section.pub_date`, `unpub_date` AS `section.unpub_date`, `parent` AS `section.parent`, `isfolder` AS `section.isfolder`, `introtext` AS `section.introtext`, `richtext` AS `section.richtext`, `template` AS `section.template`, `menuindex` AS `section.menuindex`, `searchable` AS `section.searchable`, `cacheable` AS `section.cacheable`, `createdby` AS `section.createdby`, `createdon` AS `section.createdon`, `editedby` AS `section.editedby`, `editedon` AS `section.editedon`, `deleted` AS `section.deleted`, `deletedon` AS `section.deletedon`, `deletedby` AS `section.deletedby`, `publishedon` AS `section.publishedon`, `publishedby` AS `section.publishedby`, `menutitle` AS `section.menutitle`, `donthit` AS `section.donthit`, `privateweb` AS `section.privateweb`, `privatemgr` AS `section.privatemgr`, `content_dispo` AS `section.content_dispo`, `hidemenu` AS `section.hidemenu`, `class_key` AS `section.class_key`, `context_key` AS `section.context_key`, `content_type` AS `section.content_type`, `uri` AS `section.uri`, `uri_override` AS `section.uri_override`, `hide_children_in_tree` AS `section.hide_children_in_tree`, `show_in_tree` AS `section.show_in_tree`, `properties` AS `section.properties`
0.0000150: Added selection of modUser: `username`
0.0000291: Added selection of modUserProfile: `internalKey`, `fullname`, `email`, `phone`, `mobilephone`, `blocked`, `blockeduntil`, `blockedafter`, `logincount`, `lastlogin`, `thislogin`, `failedlogincount`, `sessionid`, `dob`, `gender`, `address`, `country`, `city`, `state`, `zip`, `fax`, `photo`, `comment`, `website`, `extended`
0.0000401: Added selection of Ticket: `id`, `type`, `contentType`, `pagetitle`, `longtitle`, `description`, `alias`, `link_attributes`, `published`, `pub_date`, `unpub_date`, `parent`, `isfolder`, `introtext`, `richtext`, `template`, `menuindex`, `searchable`, `cacheable`, `createdby`, `createdon`, `editedby`, `editedon`, `deleted`, `deletedon`, `deletedby`, `publishedon`, `publishedby`, `menutitle`, `donthit`, `privateweb`, `privatemgr`, `content_dispo`, `hidemenu`, `class_key`, `context_key`, `content_type`, `uri`, `uri_override`, `hide_children_in_tree`, `show_in_tree`, `properties`
0.0001049: Added selection of TicketTotal: `comments`, `views`, `stars`, `rating`, `rating_plus`, `rating_minus`
0.0000300: Processed additional conditions
0.0002840: Added where condition: class_key=Ticket, Ticket.published=1, Ticket.deleted=0, Ticket.context_key=proza
0.0005121: Added having condition: 
0.0000710: Sorted by Ticket.id, ASC
0.0005348: SQL prepared "SELECT SQL_CALC_FOUND_ROWS `Section`.`id` AS `section.id`, `Section`.`type` AS `section.type`, `Section`.`contentType` AS `section.contentType`, `Section`.`pagetitle` AS `section.pagetitle`, `Section`.`longtitle` AS `section.longtitle`, `Section`.`description` AS `section.description`, `Section`.`alias` AS `section.alias`, `Section`.`link_attributes` AS `section.link_attributes`, `Section`.`published` AS `section.published`, `Section`.`pub_date` AS `section.pub_date`, `Section`.`unpub_date` AS `section.unpub_date`, `Section`.`parent` AS `section.parent`, `Section`.`isfolder` AS `section.isfolder`, `Section`.`introtext` AS `section.introtext`, `Section`.`richtext` AS `section.richtext`, `Section`.`template` AS `section.template`, `Section`.`menuindex` AS `section.menuindex`, `Section`.`searchable` AS `section.searchable`, `Section`.`cacheable` AS `section.cacheable`, `Section`.`createdby` AS `section.createdby`, `Section`.`createdon` AS `section.createdon`, `Section`.`editedby` AS `section.editedby`, `Section`.`editedon` AS `section.editedon`, `Section`.`deleted` AS `section.deleted`, `Section`.`deletedon` AS `section.deletedon`, `Section`.`deletedby` AS `section.deletedby`, `Section`.`publishedon` AS `section.publishedon`, `Section`.`publishedby` AS `section.publishedby`, `Section`.`menutitle` AS `section.menutitle`, `Section`.`donthit` AS `section.donthit`, `Section`.`privateweb` AS `section.privateweb`, `Section`.`privatemgr` AS `section.privatemgr`, `Section`.`content_dispo` AS `section.content_dispo`, `Section`.`hidemenu` AS `section.hidemenu`, `Section`.`class_key` AS `section.class_key`, `Section`.`context_key` AS `section.context_key`, `Section`.`content_type` AS `section.content_type`, `Section`.`uri` AS `section.uri`, `Section`.`uri_override` AS `section.uri_override`, `Section`.`hide_children_in_tree` AS `section.hide_children_in_tree`, `Section`.`show_in_tree` AS `section.show_in_tree`, `Section`.`properties` AS `section.properties`, `User`.`username`, `Profile`.`internalKey`, `Profile`.`fullname`, `Profile`.`email`, `Profile`.`phone`, `Profile`.`mobilephone`, `Profile`.`blocked`, `Profile`.`blockeduntil`, `Profile`.`blockedafter`, `Profile`.`logincount`, `Profile`.`lastlogin`, `Profile`.`thislogin`, `Profile`.`failedlogincount`, `Profile`.`sessionid`, `Profile`.`dob`, `Profile`.`gender`, `Profile`.`address`, `Profile`.`country`, `Profile`.`city`, `Profile`.`state`, `Profile`.`zip`, `Profile`.`fax`, `Profile`.`photo`, `Profile`.`comment`, `Profile`.`website`, `Profile`.`extended`, `Ticket`.`id`, `Ticket`.`type`, `Ticket`.`contentType`, `Ticket`.`pagetitle`, `Ticket`.`longtitle`, `Ticket`.`description`, `Ticket`.`alias`, `Ticket`.`link_attributes`, `Ticket`.`published`, `Ticket`.`pub_date`, `Ticket`.`unpub_date`, `Ticket`.`parent`, `Ticket`.`isfolder`, `Ticket`.`introtext`, `Ticket`.`richtext`, `Ticket`.`template`, `Ticket`.`menuindex`, `Ticket`.`searchable`, `Ticket`.`cacheable`, `Ticket`.`createdby`, `Ticket`.`createdon`, `Ticket`.`editedby`, `Ticket`.`editedon`, `Ticket`.`deleted`, `Ticket`.`deletedon`, `Ticket`.`deletedby`, `Ticket`.`publishedon`, `Ticket`.`publishedby`, `Ticket`.`menutitle`, `Ticket`.`donthit`, `Ticket`.`privateweb`, `Ticket`.`privatemgr`, `Ticket`.`content_dispo`, `Ticket`.`hidemenu`, `Ticket`.`class_key`, `Ticket`.`context_key`, `Ticket`.`content_type`, `Ticket`.`uri`, `Ticket`.`uri_override`, `Ticket`.`hide_children_in_tree`, `Ticket`.`show_in_tree`, `Ticket`.`properties`, `Total`.`comments`, `Total`.`views`, `Total`.`stars`, `Total`.`rating`, `Total`.`rating_plus`, `Total`.`rating_minus` FROM `modx_site_content` AS `Ticket` LEFT JOIN `modx_site_content` `Section` ON `Section`.`id` = `Ticket`.`parent` LEFT JOIN `modx_users` `User` ON `User`.`id` = `Ticket`.`createdby` LEFT JOIN `modx_user_attributes` `Profile` ON `Profile`.`internalKey` = `User`.`id` LEFT JOIN `modx_tickets_totals` `Total` ON `Ticket`.`id` =  `Total`.`id` WHERE  ( `Ticket`.`class_key` = 'Ticket' AND `Ticket`.`published` = 1 AND `Ticket`.`deleted` = 0 AND `Ticket`.`context_key` = 'proza' )  GROUP BY parent HAVING  ORDER BY Ticket.id ASC "
0.0004361: Could not process query, error #1064: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'ORDER BY Ticket.id ASC' at line 1
0.0000110: Returning processed chunks
0.0059268: Total time
6 815 744: Memory usage
Wassi Wassinen
06 января 2017, 15:48
0
Ошибки генерит этот вызов:

[[!pdoPage?
            &nestedChunkPrefix=`tickets_`
            &element=`getTickets`
            &groupby=`parent`
            &having=`5`
            &tpl=`tpl.Tickets.list.proza.main.row`
            &showHidden=`1`
            &parents=`0`
            &sortby=``
            &sortdir=`ASC`
            &context=`proza`
            &limit=`0`
            &showLog=`1`
        ]]
        [[!+page.nav]]

Все остальные отключил. Может быть никто не пробует группировать по ID родителя? Поэтому не видит ошибок?

[2017-01-06 15:47:37] (ERROR @ /var/www/pishi.pro/www/core/components/pdotools/model/pdotools/pdofetch.class.php : 945) Recoverable error: Argument 1 passed to pdoFetch::replaceTVCondition() must be of the type array, string given, called in /var/www/pishi.pro/www/core/components/pdotools/model/pdotools/pdofetch.class.php on line 233 and defined
[2017-01-06 15:47:37] (ERROR @ /var/www/pishi.pro/www/core/xpdo/om/xpdoquery.class.php : 688) Error parsing condition with key 0: 5
[2017-01-06 15:47:37] (ERROR @ /var/www/pishi.pro/www/core/components/pdotools/model/pdotools/pdofetch.class.php : 237) PHP warning: Invalid argument supplied for foreach()
[2017-01-06 15:47:37] (ERROR @ /var/www/pishi.pro/www/core/components/pdotools/model/pdotools/pdofetch.class.php : 171) [pdoTools] Error 42000: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'ORDER BY Ticket.id ASC' at line 1
Wassi Wassinen
06 января 2017, 15:04
0
И вот эта:
/***/core/components/pdotools/model/pdotools/pdofetch.class.php : 945) Recoverable error: Argument 1 passed to pdoFetch::replaceTVCondition() must be of the type array, string given, called in /***/core/components/pdotools/model/pdotools/pdofetch.class.php on line 233 and defined
Wassi Wassinen
06 января 2017, 15:02
0
Спасибо. А ошибки про мускул с чем связаны?
Wassi Wassinen
28 декабря 2016, 11:15
0
Спасибо за помощь!