public function safeUp()
{
$this->execute("UPDATE `da_object_parameters` SET `caption`='Обязательное', `not_null`=0 WHERE `da_object_parameters`.`id_object`=21 AND `da_object_parameters`.`id_parameter`=84");
$this->execute("UPDATE `da_object_parameters` SET `not_null`=0 WHERE `da_object_parameters`.`id_object`=21 AND `da_object_parameters`.`id_parameter`=156");
$path = dirname(__FILE__) . "/../../assets/";
HFile::removeDirectoryRecursive($path, false, false, false);
}
public function safeUp()
{
$this->execute("UPDATE `da_object_view` SET `icon_class`='glyphicon glyphicon-list-alt' WHERE `da_object_view`.`id_object_view`='ygin-menu-view-main'");
$this->execute("UPDATE `da_object_view` SET `icon_class`='glyphicon glyphicon-bullhorn' WHERE `da_object_view`.`id_object_view`='2002'");
$this->execute("UPDATE `da_object_view` SET `icon_class`='glyphicon glyphicon-picture' WHERE `da_object_view`.`id_object_view`='2000'");
$this->execute("UPDATE `da_object_view` SET `icon_class`='glyphicon glyphicon-share-alt' WHERE `da_object_view`.`id_object_view`='2016'");
$this->execute("UPDATE `da_object_view` SET `icon_class`='glyphicon glyphicon-retweet' WHERE `da_object_view`.`id_object_view`='2011'");
$this->execute("UPDATE `da_object_view` SET `icon_class`='glyphicon glyphicon-comment' WHERE `da_object_view`.`id_object_view`='67'");
$this->execute("UPDATE `da_object_view` SET `icon_class`='glyphicon glyphicon-fullscreen' WHERE `da_object_view`.`id_object_view`='2018'");
$this->execute("UPDATE `da_object_view` SET `icon_class`='glyphicon glyphicon-book' WHERE `da_object_view`.`id_object_view`='2025'");
$this->execute("UPDATE `da_object_view` SET `icon_class`='glyphicon glyphicon-tags' WHERE `da_object_view`.`id_object_view`='100'");
$this->execute("UPDATE `da_object_view` SET `icon_class`='glyphicon glyphicon-import' WHERE `da_object_view`.`id_object_view`='100'");
$this->execute("UPDATE `da_object_view` SET `icon_class`='glyphicon glyphicon-tags' WHERE `da_object_view`.`id_object_view`='55'");
$this->execute("UPDATE `da_object_view` SET `icon_class`='glyphicon glyphicon-tag' WHERE `da_object_view`.`id_object_view`='57'");
$this->execute("UPDATE `da_object_view` SET `icon_class`='glyphicon glyphicon-gift' WHERE `da_object_view`.`id_object_view`='2008'");
$this->execute("UPDATE `da_object_view` SET `icon_class`='glyphicon glyphicon-shopping-cart' WHERE `da_object_view`.`id_object_view`='2017'");
$this->execute("UPDATE `da_object_view` SET `icon_class`='glyphicon glyphicon-bookmark' WHERE `da_object_view`.`id_object_view`='2023'");
$this->execute("UPDATE `da_object_view` SET `icon_class`='glyphicon glyphicon-th-large' WHERE `da_object_view`.`id_object_view`='2'");
$this->execute("UPDATE `da_object_view` SET `icon_class`='glyphicon glyphicon-dashboard' WHERE `da_object_view`.`id_object_view`='33'");
$this->execute("UPDATE `da_object_view` SET `icon_class`='glyphicon glyphicon-user' WHERE `da_object_view`.`id_object_view`='6'");
$this->execute("UPDATE `da_object_view` SET `icon_class`='glyphicon glyphicon-pushpin' WHERE `da_object_view`.`id_object_view`='13'");
$this->execute("UPDATE `da_object_view` SET `icon_class`='glyphicon glyphicon-wrench' WHERE `da_object_view`.`id_object_view`='12'");
$this->execute("UPDATE `da_object_view` SET `icon_class`='glyphicon glyphicon-calendar' WHERE `da_object_view`.`id_object_view`='33'");
$this->execute("UPDATE `da_object_view` SET `icon_class`='glyphicon glyphicon-book' WHERE `da_object_view`.`id_object_view`='9'");
$this->execute("UPDATE `da_object_view` SET `icon_class`='glyphicon glyphicon-inbox' WHERE `da_object_view`.`id_object_view`='32'");
$this->execute("UPDATE `da_object_view` SET `icon_class`='glyphicon glyphicon-cog' WHERE `da_object_view`.`id_object_view`='12'");
$this->execute("UPDATE `da_object_view` SET `icon_class`='glyphicon glyphicon-envelope' WHERE `da_object_view`.`id_object_view`='16'");
$path = dirname(__FILE__) . "/../../assets/";
@HFile::removeDirectoryRecursive($path, false, false, false, array(".gitignore"));
}
public function safeUp()
{
$this->execute("UPDATE `da_object_parameters` SET `id_object`='20', `id_parameter`='63', `id_parameter_type`=11, `sequence`=1, `widget`=NULL, `caption`='id', `field_name`='id_object', `add_parameter`='1', `default_value`=NULL, `not_null`=1, `sql_parameter`=NULL, `is_unique`=0, `group_type`=0, `need_locale`=0, `search`=0, `is_additional`=0, `hint`='Уникальный ИД объекта в виде строки. Например для новостей ИД будет равен ygin-news Вместо ygin можно использовать название проекта или компании.' WHERE `da_object_parameters`.`id_object`='20' AND `da_object_parameters`.`id_parameter`='63'");
$this->execute("UPDATE `da_users` SET `id_user`=1, `name`='admin', `user_password`='91a399ceafc4f3ecb187932030b020e78d94952e', `mail`='[email protected]', `full_name`='Разработчик', `rid`=NULL, `create_date`=1178788080, `count_post`=1, `active`=1, `requires_new_password`=0, `salt`='73561e3259556005dd91739f0c54744829a245d7', `password_strategy`='sha1' WHERE `da_users`.`id_user`=1");
$this->execute("UPDATE `da_object_parameters` SET `id_object`='21', `id_parameter`='74', `id_parameter_type`=11, `sequence`=6, `widget`=NULL, `caption`='id', `field_name`='id_parameter', `add_parameter`='1', `default_value`=NULL, `not_null`=1, `sql_parameter`=NULL, `is_unique`=0, `group_type`=0, `need_locale`=0, `search`=0, `is_additional`=0, `hint`='Уникальный ИД свойства объекта в виде строки. Например для заголовка новостей ИД будет равен ygin-news-title Вместо ygin можно использовать название проекта или компании.' WHERE `da_object_parameters`.`id_object`='21' AND `da_object_parameters`.`id_parameter`='74'");
$this->execute("UPDATE `da_object_parameters` SET `id_object`='27', `id_parameter`='109', `id_parameter_type`=11, `sequence`=8, `widget`=NULL, `caption`='id', `field_name`='id_reference', `add_parameter`='1', `default_value`=NULL, `not_null`=1, `sql_parameter`=NULL, `is_unique`=0, `group_type`=0, `need_locale`=0, `search`=0, `is_additional`=0, `hint`='Уникальный ИД справочника. Например ygin-shop-reference-order_status Вместо ygin можно использовать название проекта или компании.' WHERE `da_object_parameters`.`id_object`='27' AND `da_object_parameters`.`id_parameter`='109'");
$this->execute("UPDATE `da_object_parameters` SET `id_object`='28', `id_parameter`='111', `id_parameter_type`=11, `sequence`=1, `widget`=NULL, `caption`='id', `field_name`='id_reference_element_instance', `add_parameter`='1', `default_value`=NULL, `not_null`=1, `sql_parameter`=NULL, `is_unique`=0, `group_type`=0, `need_locale`=0, `search`=0, `is_additional`=0, `hint`='Уникальный ИД элемента справочника. Например ygin-shop-reference-order_status-new Вместо ygin можно использовать название проекта или компании.' WHERE `da_object_parameters`.`id_object`='28' AND `da_object_parameters`.`id_parameter`='111'");
$this->execute("UPDATE `da_object_parameters` SET `id_object`='30', `id_parameter`='116', `id_parameter_type`=11, `sequence`=8, `widget`=NULL, `caption`='id', `field_name`='id_system_parameter', `add_parameter`='1', `default_value`=NULL, `not_null`=1, `sql_parameter`=NULL, `is_unique`=0, `group_type`=0, `need_locale`=0, `search`=0, `is_additional`=0, `hint`='Уникальный ИД системного параметра. Например ygin-parameter-phone Вместо ygin можно использовать название проекта или компании.' WHERE `da_object_parameters`.`id_object`='30' AND `da_object_parameters`.`id_parameter`='116'");
$this->execute("UPDATE `da_object_parameters` SET `id_object`='51', `id_parameter`='267', `id_parameter_type`=11, `sequence`=1, `widget`=NULL, `caption`='id', `field_name`='id_job', `add_parameter`='1', `default_value`=NULL, `not_null`=1, `sql_parameter`=NULL, `is_unique`=0, `group_type`=0, `need_locale`=0, `search`=0, `is_additional`=0, `hint`='Уникальный ИД задачи планировщика. Например для отправки уведомлений это будет ygin-send_mail Вместо ygin можно использовать название проекта или компании.' WHERE `da_object_parameters`.`id_object`='51' AND `da_object_parameters`.`id_parameter`='267'");
$this->execute("UPDATE `da_object_parameters` SET `id_object`='51', `id_parameter`='267', `id_parameter_type`=11, `sequence`=1, `widget`=NULL, `caption`='id', `field_name`='id_job', `add_parameter`='1', `default_value`=NULL, `not_null`=1, `sql_parameter`=NULL, `is_unique`=0, `group_type`=0, `need_locale`=0, `search`=0, `is_additional`=0, `hint`='Уникальный ИД задачи планировщика. Например для отправки уведомлений это будет ygin-sendMail Вместо ygin можно использовать название проекта или компании.' WHERE `da_object_parameters`.`id_object`='51' AND `da_object_parameters`.`id_parameter`='267'");
$this->execute("UPDATE `da_object_parameters` SET `id_object`='28', `id_parameter`='111', `id_parameter_type`=11, `sequence`=1, `widget`=NULL, `caption`='id', `field_name`='id_reference_element_instance', `add_parameter`='1', `default_value`=NULL, `not_null`=1, `sql_parameter`=NULL, `is_unique`=0, `group_type`=0, `need_locale`=0, `search`=0, `is_additional`=0, `hint`='Уникальный ИД элемента справочника. Например ygin-shop-reference-orderStatus-new Вместо ygin можно использовать название проекта или компании.' WHERE `da_object_parameters`.`id_object`='28' AND `da_object_parameters`.`id_parameter`='111'");
$this->execute("UPDATE `da_object_parameters` SET `id_object`='27', `id_parameter`='109', `id_parameter_type`=11, `sequence`=8, `widget`=NULL, `caption`='id', `field_name`='id_reference', `add_parameter`='1', `default_value`=NULL, `not_null`=1, `sql_parameter`=NULL, `is_unique`=0, `group_type`=0, `need_locale`=0, `search`=0, `is_additional`=0, `hint`='Уникальный ИД справочника. Например ygin-shop-reference-orderStatus Вместо ygin можно использовать название проекта или компании.' WHERE `da_object_parameters`.`id_object`='27' AND `da_object_parameters`.`id_parameter`='109'");
$this->execute("UPDATE `da_object_parameters` SET `id_object`='63', `id_parameter`='400', `id_parameter_type`=11, `sequence`=1, `widget`=NULL, `caption`='id', `field_name`='id_object_view', `add_parameter`='1', `default_value`=NULL, `not_null`=1, `sql_parameter`=NULL, `is_unique`=0, `group_type`=0, `need_locale`=0, `search`=0, `is_additional`=0, `hint`='Уникальный ИД представления объекта в виде строки. Обычно имеет имя ygin-news-view-main Вместо ygin можно использовать название проекта или компании' WHERE `da_object_parameters`.`id_object`='63' AND `da_object_parameters`.`id_parameter`='400'");
$this->execute("UPDATE `da_object_parameters` SET `id_object`='66', `id_parameter`='415', `id_parameter_type`=11, `sequence`=1, `widget`=NULL, `caption`='id', `field_name`='id_object_view_column', `add_parameter`='1', `default_value`=NULL, `not_null`=1, `sql_parameter`=NULL, `is_unique`=0, `group_type`=0, `need_locale`=0, `search`=0, `is_additional`=0, `hint`='Уникальный ИД колонки представления. Например для заголовка новости ИД будет равен ygin-news-view-main-title Вместо ygin можно использовать название проекта или компании.' WHERE `da_object_parameters`.`id_object`='66' AND `da_object_parameters`.`id_parameter`='415'");
$this->execute("UPDATE `da_object_parameters` SET `id_object`='80', `id_parameter`='338', `id_parameter_type`=11, `sequence`=1, `widget`=NULL, `caption`='id', `field_name`='id_php_script_type', `add_parameter`='1', `default_value`=NULL, `not_null`=1, `sql_parameter`=NULL, `is_unique`=0, `group_type`=0, `need_locale`=0, `search`=0, `is_additional`=0, `hint`='Уникальный ИД пхп обработчика. Например для модуля новостей это будет ygin-news-module-last Вместо ygin можно использовать название проекта или компании.' WHERE `da_object_parameters`.`id_object`='80' AND `da_object_parameters`.`id_parameter`='338'");
$this->execute("UPDATE da_object_parameters SET id_object=replace(id_object, '.', '-')");
$this->execute("UPDATE da_object_parameters SET add_parameter=replace(add_parameter, '.', '-') WHERE id_parameter_type=7");
$this->execute("UPDATE da_object_view SET id_object=replace(id_object, '.', '-')");
$this->execute("UPDATE da_object_view_column SET id_object=replace(id_object, '.', '-')");
$this->execute("UPDATE da_object_view SET id_object_view=replace(id_object_view, '.', '-')");
$this->execute("UPDATE da_object_view_column SET id_object_view=replace(id_object_view, '.', '-')");
$this->execute("UPDATE da_object_view_column SET id_object_view_column=replace(id_object_view_column, '.', '-')");
$this->execute("UPDATE da_object_parameters SET id_parameter=replace(id_parameter, '.', '-')");
$this->execute("UPDATE da_files SET id_parameter=replace(id_parameter, '.', '-')");
$this->execute("UPDATE da_object_view_column SET id_object_parameter=replace(id_object_parameter, '.', '-')");
$path = dirname(__FILE__) . "/../../assets/";
@HFile::removeDirectoryRecursive($path, false, false, false, array(".gitignore"));
}
public function safeUp()
{
$this->execute("DELETE FROM da_search_data WHERE id_object=21 AND id_instance='39'");
$this->execute("DELETE FROM `da_object_parameters` WHERE `da_object_parameters`.`id_object`=34 AND `da_object_parameters`.`id_parameter`=39");
$path = dirname(__FILE__) . "/../../assets/";
HFile::removeDirectoryRecursive($path, false, false, false, array(".gitignore"));
}
请发表评论