当前位置: 首页>>代码示例>>PHP>>正文


PHP Rule::cleanForItemCriteria方法代码示例

本文整理汇总了PHP中Rule::cleanForItemCriteria方法的典型用法代码示例。如果您正苦于以下问题:PHP Rule::cleanForItemCriteria方法的具体用法?PHP Rule::cleanForItemCriteria怎么用?PHP Rule::cleanForItemCriteria使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在Rule的用法示例。


在下文中一共展示了Rule::cleanForItemCriteria方法的10个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。

示例1: cleanDBonPurge

 function cleanDBonPurge()
 {
     global $DB;
     $gu = new Group_User();
     $gu->cleanDBonItemDelete($this->getType(), $this->fields['id']);
     $gt = new Group_Ticket();
     $gt->cleanDBonItemDelete($this->getType(), $this->fields['id']);
     $gp = new Group_Problem();
     $gp->cleanDBonItemDelete($this->getType(), $this->fields['id']);
     $gki = new Group_KnowbaseItem();
     $gki->cleanDBonItemDelete($this->getType(), $this->fields['id']);
     $gr = new Group_Reminder();
     $gr->cleanDBonItemDelete($this->getType(), $this->fields['id']);
     // Ticket rules use various _groups_id_*
     Rule::cleanForItemAction($this, '_groups_id%');
     Rule::cleanForItemCriteria($this, '_groups_id%');
     // GROUPS for RuleMailcollector
     Rule::cleanForItemCriteria($this, 'GROUPS');
     // Set no group to consumables
     $query = "UPDATE `glpi_consumables`\n                SET `items_id` = '0'\n                WHERE `items_id` = '" . $this->fields['id'] . "'\n                      AND `itemtype` = 'Group'";
     $DB->query($query);
 }
开发者ID:geldarr,项目名称:hack-space,代码行数:22,代码来源:group.class.php

示例2: cleanDBonPurge

 function cleanDBonPurge()
 {
     global $DB;
     $query = "DELETE\n                FROM `glpi_profiles_users`\n                WHERE `users_id` = '" . $this->fields['id'] . "'";
     $DB->query($query);
     if ($this->fields['id'] > 0) {
         // Security
         $query = "DELETE\n                   FROM `glpi_displaypreferences`\n                   WHERE `users_id` = '" . $this->fields['id'] . "'";
         $DB->query($query);
         $query = "DELETE\n                   FROM `glpi_bookmarks_users`\n                   WHERE `users_id` = '" . $this->fields['id'] . "'";
         $DB->query($query);
     }
     // Delete own reminders
     $query = "DELETE\n                FROM `glpi_reminders`\n                WHERE `users_id` = '" . $this->fields['id'] . "'";
     $DB->query($query);
     // Delete private bookmark
     $query = "DELETE\n                FROM `glpi_bookmarks`\n                WHERE `users_id` = '" . $this->fields['id'] . "'\n                      AND `is_private` = '1'";
     $DB->query($query);
     // Set no user to public bookmark
     $query = "UPDATE `glpi_bookmarks`\n                SET `users_id` = '0'\n                WHERE `users_id` = '" . $this->fields['id'] . "'";
     $DB->query($query);
     // Set no user to consumables
     $query = "UPDATE `glpi_consumables`\n                SET `items_id` = '0'\n                WHERE `items_id` = '" . $this->fields['id'] . "'\n                      AND `itemtype` = 'User'";
     $DB->query($query);
     $gu = new Group_User();
     $gu->cleanDBonItemDelete($this->getType(), $this->fields['id']);
     $tu = new Ticket_User();
     $tu->cleanDBonItemDelete($this->getType(), $this->fields['id']);
     $pu = new Problem_User();
     $pu->cleanDBonItemDelete($this->getType(), $this->fields['id']);
     $kiu = new KnowbaseItem_User();
     $kiu->cleanDBonItemDelete($this->getType(), $this->fields['id']);
     $ru = new Reminder_User();
     $ru->cleanDBonItemDelete($this->getType(), $this->fields['id']);
     $ue = new UserEmail();
     $ue->deleteByCriteria(array('users_id' => $this->fields['id']));
     // Ticket rules use various _users_id_*
     Rule::cleanForItemAction($this, '_users_id%');
     Rule::cleanForItemCriteria($this, '_users_id%');
 }
开发者ID:geldarr,项目名称:hack-space,代码行数:40,代码来源:user.class.php

示例3: cleanDBonPurge

 function cleanDBonPurge()
 {
     global $DB;
     $gpr = new ProfileRight();
     $gpr->cleanDBonItemDelete($this->getType(), $this->fields['id']);
     $gpu = new Profile_User();
     $gpu->cleanDBonItemDelete($this->getType(), $this->fields['id']);
     Rule::cleanForItemAction($this);
     // PROFILES and UNIQUE_PROFILE in RuleMailcollector
     Rule::cleanForItemCriteria($this, 'PROFILES');
     Rule::cleanForItemCriteria($this, 'UNIQUE_PROFILE');
     $gki = new KnowbaseItem_Profile();
     $gki->cleanDBonItemDelete($this->getType(), $this->fields['id']);
     $gr = new Profile_Reminder();
     $gr->cleanDBonItemDelete($this->getType(), $this->fields['id']);
 }
开发者ID:glpi-project,项目名称:glpi,代码行数:16,代码来源:profile.class.php

示例4: cleanDBonPurge

 function cleanDBonPurge()
 {
     Rule::cleanForItemCriteria($this);
 }
开发者ID:JULIO8,项目名称:respaldo_glpi,代码行数:4,代码来源:itilcategory.class.php

示例5: cleanDBonPurge

 function cleanDBonPurge()
 {
     // mailcollector for RuleMailCollector, _mailgate for RuleTicket
     Rule::cleanForItemCriteria($this, 'mailcollector');
     Rule::cleanForItemCriteria($this, '_mailgate');
 }
开发者ID:remicollet,项目名称:glpi,代码行数:6,代码来源:mailcollector.class.php

示例6: cleanDBonPurge

 function cleanDBonPurge()
 {
     Rule::cleanForItemCriteria($this, 'LDAP_SERVER');
 }
开发者ID:euqip,项目名称:glpi-smartcities,代码行数:4,代码来源:authldap.class.php

示例7: cleanDBonPurge

 function cleanDBonPurge()
 {
     global $DB;
     // most use entities_id, RuleDictionnarySoftwareCollection use new_entities_id
     Rule::cleanForItemAction($this, '%entities_id');
     Rule::cleanForItemCriteria($this);
     $gki = new Entity_KnowbaseItem();
     $gki->cleanDBonItemDelete($this->getType(), $this->fields['id']);
     $gr = new Entity_Reminder();
     $gr->cleanDBonItemDelete($this->getType(), $this->fields['id']);
 }
开发者ID:korial29,项目名称:glpi,代码行数:11,代码来源:entity.class.php

示例8: cleanDBonPurge

 function cleanDBonPurge()
 {
     $link = new PluginOcsinventoryngOcslink();
     $link->deleteByCriteria(array('plugin_ocsinventoryng_ocsservers_id' => $this->fields['id']));
     $admin = new PluginOcsinventoryngOcsAdminInfosLink();
     $admin->deleteByCriteria(array('plugin_ocsinventoryng_ocsservers_id' => $this->fields['id']));
     $server = new PluginOcsinventoryngServer();
     $server->deleteByCriteria(array('plugin_ocsinventoryng_ocsservers_id' => $this->fields['id']));
     unset($_SESSION["plugin_ocsinventoryng_ocsservers_id"]);
     // ocsservers_id for RuleImportComputer, OCS_SERVER for RuleImportEntity
     Rule::cleanForItemCriteria($this);
     Rule::cleanForItemCriteria($this, 'OCS_SERVER');
 }
开发者ID:geldarr,项目名称:hack-space,代码行数:13,代码来源:ocsserver.class.php

示例9: cleanDBonPurge

 function cleanDBonPurge()
 {
     Rule::cleanForItemAction($this);
     Rule::cleanForItemCriteria($this, 'users_locations');
 }
开发者ID:stweil,项目名称:glpi,代码行数:5,代码来源:location.class.php

示例10: cleanDBonPurge

 function cleanDBonPurge()
 {
     global $DB;
     $query = "DELETE\n                FROM `glpi_profiles_users`\n                WHERE `profiles_id` = '" . $this->fields['id'] . "'";
     $DB->query($query);
     Rule::cleanForItemAction($this);
     // PROFILES and UNIQUE_PROFILE in RuleMailcollector
     Rule::cleanForItemCriteria($this, 'PROFILES');
     Rule::cleanForItemCriteria($this, 'UNIQUE_PROFILE');
     $gki = new KnowbaseItem_Profile();
     $gki->cleanDBonItemDelete($this->getType(), $this->fields['id']);
     $gr = new Profile_Reminder();
     $gr->cleanDBonItemDelete($this->getType(), $this->fields['id']);
 }
开发者ID:gaforeror,项目名称:glpi,代码行数:14,代码来源:profile.class.php


注:本文中的Rule::cleanForItemCriteria方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。