Changes for v22.0.0.OS
This commit is contained in:
@@ -1,5 +1,8 @@
|
||||
<?php
|
||||
$migrationList = [];
|
||||
$migrationList[] = 'v20180417_210501_update_menu_names';
|
||||
$migrationList[] = 'v20180325_210101_delete_leave_group_employee';
|
||||
$migrationList[] = 'v20180317_210200_leave_rule_experience';
|
||||
$migrationList[] = 'v20180305_210100_drop_si_hi_languages';
|
||||
$migrationList[] = 'v20171126_200303_swift_mail';
|
||||
$migrationList[] = 'v20171003_200302_payroll_meta_export';
|
||||
|
||||
26
migrations/v20180317_210200_leave_rule_experience.php
Normal file
26
migrations/v20180317_210200_leave_rule_experience.php
Normal file
@@ -0,0 +1,26 @@
|
||||
<?php
|
||||
|
||||
namespace Classes\Migration;
|
||||
|
||||
class v20180317_210200_leave_rule_experience extends AbstractMigration {
|
||||
|
||||
public function up(){
|
||||
|
||||
$sql = <<<'SQL'
|
||||
alter table LeaveRules add column `exp_days` int(11) NULL;
|
||||
SQL;
|
||||
return $this->executeQuery($sql);
|
||||
}
|
||||
|
||||
public function down(){
|
||||
$sql = <<<'SQL'
|
||||
alter table LeaveRules drop column `exp_days`;
|
||||
SQL;
|
||||
|
||||
return $this->executeQuery($sql);
|
||||
}
|
||||
|
||||
}
|
||||
{
|
||||
|
||||
}
|
||||
31
migrations/v20180325_210101_delete_leave_group_employee.php
Normal file
31
migrations/v20180325_210101_delete_leave_group_employee.php
Normal file
@@ -0,0 +1,31 @@
|
||||
<?php
|
||||
namespace Classes\Migration;
|
||||
|
||||
class v20180325_210101_delete_leave_group_employee extends AbstractMigration{
|
||||
|
||||
public function up(){
|
||||
|
||||
$sql = <<<'SQL'
|
||||
alter table LeaveGroupEmployees drop FOREIGN KEY `Fk_LeaveGroupEmployees_Employee`;
|
||||
SQL;
|
||||
$this->executeQuery($sql);
|
||||
|
||||
$sql = <<<'SQL'
|
||||
alter table LeaveGroupEmployees drop index `LeaveGroupEmployees_employee`;
|
||||
SQL;
|
||||
$this->executeQuery($sql);
|
||||
|
||||
$sql = <<<'SQL'
|
||||
alter table LeaveGroupEmployees add CONSTRAINT `Fk_LeaveGroupEmployees_Employee` FOREIGN KEY (`employee`) REFERENCES `Employees` (`id`) ON DELETE CASCADE ON UPDATE CASCADE;
|
||||
SQL;
|
||||
return $this->executeQuery($sql);
|
||||
}
|
||||
|
||||
public function down(){
|
||||
$sql = <<<'SQL'
|
||||
alter table LeaveGroupEmployees add UNIQUE KEY `LeaveGroupEmployees_employee` (`employee`);
|
||||
SQL;
|
||||
return $this->executeQuery($sql);
|
||||
}
|
||||
|
||||
}
|
||||
19
migrations/v20180417_210501_update_menu_names.php
Normal file
19
migrations/v20180417_210501_update_menu_names.php
Normal file
@@ -0,0 +1,19 @@
|
||||
<?php
|
||||
namespace Classes\Migration;
|
||||
|
||||
class v20180417_210501_update_menu_names extends AbstractMigration{
|
||||
|
||||
public function up(){
|
||||
|
||||
$sql = <<<'SQL'
|
||||
Update Settings set value = '1' where name = 'System: Reset Module Names';
|
||||
SQL;
|
||||
return $this->executeQuery($sql);
|
||||
}
|
||||
|
||||
public function down(){
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
}
|
||||
Reference in New Issue
Block a user