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


PHP ZurmoDatabaseCompatibilityUtil::dropStoredFunctionsAndProcedures方法代码示例

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


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

示例1: setUpBeforeClass

 public static function setUpBeforeClass()
 {
     parent::setUpBeforeClass();
     ZurmoDatabaseCompatibilityUtil::dropStoredFunctionsAndProcedures();
     Yii::app()->user->userModel = SecurityTestHelper::createSuperAdmin();
     SecurityTestHelper::createUsers();
 }
开发者ID:youprofit,项目名称:Zurmo,代码行数:7,代码来源:FormLayoutSecurityUtilTest.php

示例2: setUpBeforeClass

 public static function setUpBeforeClass()
 {
     parent::setUpBeforeClass();
     ZurmoDatabaseCompatibilityUtil::dropStoredFunctionsAndProcedures();
     SecurityTestHelper::createSuperAdmin();
     SecurityTestHelper::createUsers();
     SecurityTestHelper::createGroups();
     SecurityTestHelper::createRoles();
     RedBeanModel::forgetAll();
     //do the rebuild to ensure the tables get created properly.
     ReadPermissionsOptimizationUtil::rebuild();
     //Manually build the test model munge tables.
     ReadPermissionsOptimizationUtil::recreateTable(ReadPermissionsOptimizationUtil::getMungeTableName('OwnedSecurableTestItem'));
     ReadPermissionsOptimizationUtil::recreateTable(ReadPermissionsOptimizationUtil::getMungeTableName('OwnedSecurableTestItem2'));
     $benny = User::getByUsername('benny');
     $model = new OwnedSecurableTestItem();
     $model->member = 'test';
     assert($model->save());
     // Not Coding Standard
     $model = new OwnedSecurableTestItem();
     $model->member = 'test2';
     assert($model->save());
     // Not Coding Standard
     $model = new OwnedSecurableTestItem();
     $model->member = 'test3';
     $model->owner = $benny;
     assert($model->save());
     // Not Coding Standard
     assert(OwnedSecurableTestItem::getCount() == 3);
     // Not Coding Standard
     $model = new OwnedSecurableTestItem2();
     $model->member = 'test5';
     assert($model->save());
     // Not Coding Standard
 }
开发者ID:maruthisivaprasad,项目名称:zurmo,代码行数:35,代码来源:OwnedSecurableItemReadPermissionOptimizationTest.php

示例3: setUpBeforeClass

 public static function setUpBeforeClass()
 {
     parent::setUpBeforeClass();
     ZurmoDatabaseCompatibilityUtil::dropStoredFunctionsAndProcedures();
     $super = SecurityTestHelper::createSuperAdmin();
     Yii::app()->user->userModel = User::getByUsername('super');
     $headquarters = AccountTestHelper::createAccountByNameForOwner('Headquarters', $super);
     $division1 = AccountTestHelper::createAccountByNameForOwner('Division1', $super);
     $division2 = AccountTestHelper::createAccountByNameForOwner('Division2', $super);
     $ceo = ContactTestHelper::createContactWithAccountByNameForOwner('ceo', $super, $headquarters);
     $div1President = ContactTestHelper::createContactWithAccountByNameForOwner('div1 President', $super, $division1);
     $div2President = ContactTestHelper::createContactWithAccountByNameForOwner('div2 President', $super, $division2);
     $opportunity = OpportunityTestHelper::createOpportunityWithAccountByNameForOwner('big opp', $super, $headquarters);
     $opportunityDiv1 = OpportunityTestHelper::createOpportunityWithAccountByNameForOwner('div1 small opp', $super, $division1);
     $opportunityDiv2 = OpportunityTestHelper::createOpportunityWithAccountByNameForOwner('div2 small opp', $super, $division2);
     //attach divisions to headquarters
     $headquarters->accounts->add($division1);
     $headquarters->accounts->add($division2);
     assert($headquarters->save());
     // Not Coding Standard
     //attach opportunities to contacts
     $opportunity->contacts->add($ceo);
     assert($opportunity->save());
     // Not Coding Standard
     //Forget models to ensure relations are known on the next retrieval
     $headquarters->forget();
     $division1->forget();
     $division2->forget();
     $ceo->forget();
 }
开发者ID:RamaKavanan,项目名称:InitialVersion,代码行数:30,代码来源:ModelsRollUpTest.php

示例4: setUpBeforeClass

 public static function setUpBeforeClass()
 {
     parent::setUpBeforeClass();
     ZurmoDatabaseCompatibilityUtil::dropStoredFunctionsAndProcedures();
     SecurityTestHelper::createSuperAdmin();
     UserTestHelper::createBasicUser('billy');
     UserTestHelper::createBasicUser('sally');
 }
开发者ID:youprofit,项目名称:Zurmo,代码行数:8,代码来源:ZurmoLanguageHelperTest.php

示例5: setUpBeforeClass

 public static function setUpBeforeClass()
 {
     parent::setUpBeforeClass();
     ZurmoDatabaseCompatibilityUtil::dropStoredFunctionsAndProcedures();
     SecurityTestHelper::createSuperAdmin();
     Yii::app()->user->userModel = User::getByUsername('super');
     $billy = UserTestHelper::createBasicUser('billy');
 }
开发者ID:maruthisivaprasad,项目名称:zurmo,代码行数:8,代码来源:LatestActivitiesUtilTest.php

示例6: setUpBeforeClass

 public static function setUpBeforeClass()
 {
     parent::setUpBeforeClass();
     ZurmoDatabaseCompatibilityUtil::dropStoredFunctionsAndProcedures();
     SecurityTestHelper::createSuperAdmin();
     Yii::app()->user->userModel = User::getByUsername('super');
     $loaded = ContactsModule::loadStartingData();
     assert('$loaded');
     // Not Coding Standard
 }
开发者ID:sandeep1027,项目名称:zurmo_,代码行数:10,代码来源:ModelAutoCompleteUtilTest.php

示例7: setUpBeforeClass

 public static function setUpBeforeClass()
 {
     parent::setUpBeforeClass();
     ZurmoDatabaseCompatibilityUtil::dropStoredFunctionsAndProcedures();
     SecurityTestHelper::createSuperAdmin();
     //do the rebuild to ensure the tables get created properly.
     AllPermissionsOptimizationUtil::rebuild();
     //Manually build the test model munge tables.
     ReadPermissionsOptimizationUtil::recreateTable(ReadPermissionsOptimizationUtil::getMungeTableName('OwnedSecurableTestItem'));
 }
开发者ID:maruthisivaprasad,项目名称:zurmo,代码行数:10,代码来源:OwnedSecurableTestItemTest.php

示例8: setUpBeforeClass

 public static function setUpBeforeClass()
 {
     parent::setUpBeforeClass();
     ZurmoDatabaseCompatibilityUtil::dropStoredFunctionsAndProcedures();
     SecurityTestHelper::createSuperAdmin();
     Yii::app()->user->userModel = User::getByUsername('super');
     SecurityTestHelper::createUsers();
     SecurityTestHelper::createGroups();
     SecurityTestHelper::createAccounts();
     AllPermissionsOptimizationUtil::rebuild();
 }
开发者ID:RamaKavanan,项目名称:InitialVersion,代码行数:11,代码来源:ControllerSecurityUtilTest.php

示例9: setUpBeforeClass

 public static function setUpBeforeClass()
 {
     parent::setUpBeforeClass();
     ZurmoDatabaseCompatibilityUtil::dropStoredFunctionsAndProcedures();
     SecurityTestHelper::createSuperAdmin();
     SecurityTestHelper::createUsers();
     SecurityTestHelper::createGroups();
     SecurityTestHelper::createRoles();
     //Forget the cache, otherwise user/role/group information is not properly reflected in the cache.
     RedBeanModel::forgetAll();
 }
开发者ID:RamaKavanan,项目名称:InitialVersion,代码行数:11,代码来源:RightTest.php

示例10: setUpBeforeClass

 public static function setUpBeforeClass()
 {
     parent::setUpBeforeClass();
     ZurmoDatabaseCompatibilityUtil::dropStoredFunctionsAndProcedures();
     SecurityTestHelper::createSuperAdmin();
     $billy = UserTestHelper::createBasicUser('billy');
     $group = Group::getByName('Super Administrators');
     $group->users->add($billy);
     $saved = $group->save();
     assert($saved);
     // Not Coding Standard
     UserTestHelper::createBasicUser('sally');
 }
开发者ID:youprofit,项目名称:Zurmo,代码行数:13,代码来源:ZurmoConfigurationFormAdapterTest.php

示例11: setUpBeforeClass

 public static function setUpBeforeClass()
 {
     parent::setUpBeforeClass();
     ZurmoDatabaseCompatibilityUtil::createActualPermissionsCacheTable();
     ZurmoDatabaseCompatibilityUtil::dropStoredFunctionsAndProcedures();
     SecurityTestHelper::createSuperAdmin();
     $super = User::getByUsername('super');
     Yii::app()->user->userModel = $super;
     StarredUtil::createStarredTables();
     $account = new Account();
     $account->owner = $super;
     $account->name = 'Test Account0';
     $account->officePhone = '1234567890';
     $account->save();
     StarredUtil::markModelAsStarred($account);
     $account = new Account();
     $account->owner = $super;
     $account->name = 'Test Account1';
     $account->officePhone = '1234567891';
     $account->save();
 }
开发者ID:youprofit,项目名称:Zurmo,代码行数:21,代码来源:StarredModelDataProviderTest.php

示例12: setUpBeforeClass

 public static function setUpBeforeClass()
 {
     parent::setUpBeforeClass();
     ZurmoDatabaseCompatibilityUtil::createActualPermissionsCacheTable();
     ZurmoDatabaseCompatibilityUtil::createNamedSecurableActualPermissionsCacheTable();
     ZurmoDatabaseCompatibilityUtil::createActualRightsCacheTable();
     ZurmoDatabaseCompatibilityUtil::dropStoredFunctionsAndProcedures();
     PermissionsCache::forgetAll();
     AllPermissionsOptimizationCache::forgetAll();
     RightsCache::forgetAll();
     PoliciesCache::forgetAll();
     Currency::resetCaches();
     //php only cache
     Permission::resetCaches();
     //php only cache
     self::$activitiesObserver = new ActivitiesObserver();
     self::$activitiesObserver->init();
     //runs init();
     self::$conversationsObserver = new ConversationsObserver();
     self::$conversationsObserver->init();
     //runs init();
     self::$emailMessagesObserver = new EmailMessagesObserver();
     self::$emailMessagesObserver->init();
     //runs init();
     self::$contactLatestActivityDateTimeObserver = new ContactLatestActivityDateTimeObserver();
     self::$contactLatestActivityDateTimeObserver->init();
     //runs init();
     self::$accountLatestActivityDateTimeObserver = new AccountLatestActivityDateTimeObserver();
     self::$accountLatestActivityDateTimeObserver->init();
     //runs init();
     self::$accountContactAffiliationObserver = new AccountContactAffiliationObserver();
     self::$accountContactAffiliationObserver->init();
     //runs init();
     Yii::app()->gameHelper;
     Yii::app()->gamificationObserver;
     //runs init();
     Yii::app()->gameHelper->resetDeferredPointTypesAndValuesByUserIdToAdd();
     Yii::app()->emailHelper->sendEmailThroughTransport = false;
     Yii::app()->jobQueue->deleteAll();
 }
开发者ID:RamaKavanan,项目名称:InitialVersion,代码行数:40,代码来源:ZurmoBaseTest.php

示例13: setUpBeforeClass

 public static function setUpBeforeClass()
 {
     parent::setUpBeforeClass();
     ZurmoDatabaseCompatibilityUtil::createActualPermissionsCacheTable();
     ZurmoDatabaseCompatibilityUtil::dropStoredFunctionsAndProcedures();
     PermissionsCache::forgetAll();
     RightsCache::forgetAll();
     PoliciesCache::forgetAll();
     Currency::resetCaches();
     //php only cache
     $activitiesObserver = new ActivitiesObserver();
     $activitiesObserver->init();
     //runs init();
     $conversationsObserver = new ConversationsObserver();
     $conversationsObserver->init();
     //runs init();
     Yii::app()->gameHelper;
     Yii::app()->gamificationObserver;
     //runs init();
     Yii::app()->gameHelper->resetDeferredPointTypesAndValuesByUserIdToAdd();
     Yii::app()->emailHelper->sendEmailThroughTransport = false;
 }
开发者ID:youprofit,项目名称:Zurmo,代码行数:22,代码来源:ZurmoBaseTest.php

示例14: testGroupsContainingGroupsAndContains

 /**
  * @depends testSaveAndLoadGroup
  */
 public function testGroupsContainingGroupsAndContains()
 {
     ZurmoDatabaseCompatibilityUtil::dropStoredFunctionsAndProcedures();
     $u = array();
     for ($i = 0; $i < 5; $i++) {
         $u[$i] = User::getByUsername("uuuuu{$i}");
     }
     $a = Group::getByName('AAA');
     $b = Group::getByName('BBB');
     $c = new Group();
     $c->name = 'CCC';
     $this->assertTrue($c->save());
     $this->assertEquals(0, $c->users->count());
     $this->assertEquals(0, $c->groups->count());
     $d = new Group();
     $d->name = 'DDD';
     $this->assertTrue($d->save());
     $this->assertEquals(0, $d->users->count());
     $this->assertEquals(0, $d->groups->count());
     $b->users->add($u[1]);
     $b->users->add($u[2]);
     $b->groups->add($c);
     $b->groups->add($d);
     $this->assertTrue($b->save());
     $c->users->add($u[3]);
     $this->assertTrue($c->save());
     $d->users->add($u[4]);
     $this->assertTrue($d->save());
     unset($a);
     unset($b);
     unset($c);
     unset($d);
     RedBeanModel::forgetAll();
     $a = Group::getByName('AAA');
     $b = Group::getByName('BBB');
     $c = Group::getByName('CCC');
     $d = Group::getByName('DDD');
     $this->assertEquals(1, $a->users->count());
     $this->assertEquals(2, $b->users->count());
     $this->assertEquals(1, $c->users->count());
     $this->assertEquals(1, $d->users->count());
     $this->assertEquals(1, $a->groups->count());
     $this->assertEquals(2, $b->groups->count());
     $this->assertEquals(0, $c->groups->count());
     $this->assertEquals(0, $d->groups->count());
     $this->assertTrue($a->contains($u[0]));
     $this->assertTrue($a->contains($u[1]));
     $this->assertTrue($a->contains($u[2]));
     $this->assertTrue($a->contains($u[3]));
     $this->assertTrue($a->contains($u[4]));
     $this->assertTrue($a->contains($b));
     $this->assertTrue($a->contains($c));
     $this->assertTrue($a->contains($d));
     $this->assertTrue(self::fastContainsUserByGroupName('AAA', $u[0]->id));
     $this->assertTrue(self::fastContainsUserByGroupName('AAA', $u[1]->id));
     $this->assertTrue(self::fastContainsUserByGroupName('AAA', $u[2]->id));
     $this->assertTrue(self::fastContainsUserByGroupName('AAA', $u[3]->id));
     $this->assertTrue(self::fastContainsUserByGroupName('AAA', $u[4]->id));
     $this->assertTrue($b->contains($u[1]));
     $this->assertTrue($b->contains($u[2]));
     $this->assertTrue($b->contains($u[3]));
     $this->assertTrue($b->contains($u[4]));
     $this->assertTrue($b->contains($c));
     $this->assertTrue($b->contains($d));
     $this->assertTrue(self::fastContainsUserByGroupName('BBB', $u[1]->id));
     $this->assertTrue(self::fastContainsUserByGroupName('BBB', $u[2]->id));
     $this->assertTrue(self::fastContainsUserByGroupName('BBB', $u[3]->id));
     $this->assertTrue(self::fastContainsUserByGroupName('BBB', $u[4]->id));
     $this->assertTrue($c->contains($u[3]));
     $this->assertTrue($d->contains($u[4]));
     $this->assertTrue(self::fastContainsUserByGroupName('CCC', $u[3]->id));
     $this->assertTrue(self::fastContainsUserByGroupName('DDD', $u[4]->id));
     $this->assertFalse($b->contains($u[0]));
     $this->assertFalse(self::fastContainsUserByGroupName('BBB', $u[0]->id));
     $this->assertFalse($c->contains($u[0]));
     $this->assertFalse($c->contains($u[1]));
     $this->assertFalse($c->contains($u[2]));
     $this->assertFalse($c->contains($u[4]));
     $this->assertFalse(self::fastContainsUserByGroupName('CCC', $u[0]->id));
     $this->assertFalse(self::fastContainsUserByGroupName('CCC', $u[1]->id));
     $this->assertFalse(self::fastContainsUserByGroupName('CCC', $u[2]->id));
     $this->assertFalse(self::fastContainsUserByGroupName('CCC', $u[4]->id));
     $this->assertFalse($d->contains($u[0]));
     $this->assertFalse($d->contains($u[1]));
     $this->assertFalse($d->contains($u[2]));
     $this->assertFalse($d->contains($u[3]));
     $this->assertFalse(self::fastContainsUserByGroupName('DDD', $u[0]->id));
     $this->assertFalse(self::fastContainsUserByGroupName('DDD', $u[1]->id));
     $this->assertFalse(self::fastContainsUserByGroupName('DDD', $u[2]->id));
     $this->assertFalse(self::fastContainsUserByGroupName('DDD', $u[3]->id));
     $this->assertFalse($b->contains($a));
     $this->assertFalse($c->contains($a));
     $this->assertFalse($d->contains($a));
     $this->assertFalse($c->contains($a));
     $this->assertFalse($c->contains($b));
     $this->assertFalse($d->contains($a));
     $this->assertFalse($d->contains($b));
//.........这里部分代码省略.........
开发者ID:RamaKavanan,项目名称:InitialVersion,代码行数:101,代码来源:GroupBenchmarkTest.php


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