From 102c4ec87449654dbc9fe93b199fb189e5bc38d8 Mon Sep 17 00:00:00 2001 From: qiyu-xie Date: Thu, 4 Mar 2021 17:10:39 +0800 Subject: [PATCH] * Modify install module. --- module/install/control.php | 18 ++++----- module/install/lang/de.php | 2 +- module/install/lang/en.php | 2 +- module/install/lang/fr.php | 4 +- module/install/lang/vi.php | 2 +- module/install/lang/zh-cn.php | 2 +- module/install/lang/zh-tw.php | 2 +- module/install/model.php | 74 +++++++++++++++++------------------ 8 files changed, 53 insertions(+), 53 deletions(-) diff --git a/module/install/control.php b/module/install/control.php index 42dbcb6116..896c8f245d 100644 --- a/module/install/control.php +++ b/module/install/control.php @@ -13,7 +13,7 @@ class install extends control { /** * Construct function. - * + * * @access public * @return void */ @@ -28,7 +28,7 @@ class install extends control /** * Index page of install module. - * + * * @access public * @return void */ @@ -41,8 +41,8 @@ class install extends control } /** - * Checking agree license. - * + * Checking agree license. + * * @access public * @return void */ @@ -55,7 +55,7 @@ class install extends control /** * Check the system. - * + * * @access public * @return void */ @@ -97,7 +97,7 @@ class install extends control /** * Set configs. - * + * * @access public * @return void */ @@ -109,7 +109,7 @@ class install extends control /** * Create the config file. - * + * * @access public * @return void */ @@ -168,7 +168,7 @@ class install extends control /** * Create company, admin. - * + * * @access public * @return void */ @@ -204,7 +204,7 @@ class install extends control /** * Join zentao community or login pms. - * + * * @access public * @return void */ diff --git a/module/install/lang/de.php b/module/install/lang/de.php index a0f48b8063..2edf559a0c 100644 --- a/module/install/lang/de.php +++ b/module/install/lang/de.php @@ -153,7 +153,7 @@ $lang->install->groupList['LIMITED']['name'] = 'Eingeschränkte Benutzer'; $lang->install->groupList['LIMITED']['desc'] = 'Können nur Inhalte bearbeiten, die sie selbst betreffen'; $lang->install->cronList[''] = 'Cron Anzeigen'; -$lang->install->cronList['moduleName=project&methodName=computeburn'] = 'Update Burndown Chart'; +$lang->install->cronList['moduleName=execution&methodName=computeBurn'] = 'Update Burndown Chart'; $lang->install->cronList['moduleName=report&methodName=remind'] = 'Täglicher Aufgaben reminder'; $lang->install->cronList['moduleName=svn&methodName=run'] = 'Synchronisiere SVN'; $lang->install->cronList['moduleName=git&methodName=run'] = 'Synchronisiere GIT'; diff --git a/module/install/lang/en.php b/module/install/lang/en.php index d9dc97fad5..2a1621b5a5 100644 --- a/module/install/lang/en.php +++ b/module/install/lang/en.php @@ -153,7 +153,7 @@ $lang->install->groupList['LIMITED']['name'] = 'Limited User'; $lang->install->groupList['LIMITED']['desc'] = 'Users can only edit contents related to themselves.'; $lang->install->cronList[''] = 'Monitor Cron'; -$lang->install->cronList['moduleName=project&methodName=computeburn'] = 'Update Burndown Chart'; +$lang->install->cronList['moduleName=execution&methodName=computeBurn'] = 'Update Burndown Chart'; $lang->install->cronList['moduleName=report&methodName=remind'] = 'Daily Task Reminder'; $lang->install->cronList['moduleName=svn&methodName=run'] = 'Synchronize SVN'; $lang->install->cronList['moduleName=git&methodName=run'] = 'Synchronize GIT'; diff --git a/module/install/lang/fr.php b/module/install/lang/fr.php index 9d9243e48e..fd790bb11b 100644 --- a/module/install/lang/fr.php +++ b/module/install/lang/fr.php @@ -33,7 +33,7 @@ $lang->install->links = <<Nature Easy Soft Co., LTD. Site Officiel : https://www.zentao.pm Support Technique: https://www.zentao.pm/forum/ -LinkedIn: Nature Easy Soft +LinkedIn: Nature Easy Soft Facebook: Nature Easy Soft Twitter: ZenTao ALM @@ -153,7 +153,7 @@ $lang->install->groupList['LIMITED']['name'] = 'Utilisateur restreint'; $lang->install->groupList['LIMITED']['desc'] = 'Les utilisateurs peuvent seulement éditer ce qui les concernent.'; $lang->install->cronList[''] = 'Moniteur Cron'; -$lang->install->cronList['moduleName=project&methodName=computeburn'] = 'Mise à jour Graphe Burndown'; +$lang->install->cronList['moduleName=execution&methodName=computeBurn'] = 'Mise à jour Graphe Burndown'; $lang->install->cronList['moduleName=report&methodName=remind'] = 'Rappel Tâches quotidiennes'; $lang->install->cronList['moduleName=svn&methodName=run'] = 'Synchroniser SVN'; $lang->install->cronList['moduleName=git&methodName=run'] = 'Synchroniser GIT'; diff --git a/module/install/lang/vi.php b/module/install/lang/vi.php index 687774a718..fac01d4bf8 100644 --- a/module/install/lang/vi.php +++ b/module/install/lang/vi.php @@ -153,7 +153,7 @@ $lang->install->groupList['LIMITED']['name'] = 'Người dùng hạn chế'; $lang->install->groupList['LIMITED']['desc'] = 'Người dùng chỉ có thể chỉnh sửa nội dung được liên kết tới của họ.'; $lang->install->cronList[''] = 'Monitor Cron'; -$lang->install->cronList['moduleName=project&methodName=computeburn'] = 'Cập nhật biểu đồ Burndown'; +$lang->install->cronList['moduleName=execution&methodName=computeBurn'] = 'Cập nhật biểu đồ Burndown'; $lang->install->cronList['moduleName=report&methodName=remind'] = 'Nhắc nhở nhiệm vụ hàng ngày'; $lang->install->cronList['moduleName=svn&methodName=run'] = 'Đồng bộ SVN'; $lang->install->cronList['moduleName=git&methodName=run'] = 'Đồng bộ GIT'; diff --git a/module/install/lang/zh-cn.php b/module/install/lang/zh-cn.php index 730765461b..109d7f100a 100644 --- a/module/install/lang/zh-cn.php +++ b/module/install/lang/zh-cn.php @@ -153,7 +153,7 @@ $lang->install->groupList['LIMITED']['name'] = '受限用户'; $lang->install->groupList['LIMITED']['desc'] = '受限用户分组(只能编辑与自己相关的内容)'; $lang->install->cronList[''] = '监控定时任务'; -$lang->install->cronList['moduleName=project&methodName=computeburn'] = '更新燃尽图'; +$lang->install->cronList['moduleName=execution&methodName=computeBurn'] = '更新燃尽图'; $lang->install->cronList['moduleName=report&methodName=remind'] = '每日任务提醒'; $lang->install->cronList['moduleName=svn&methodName=run'] = '同步SVN'; $lang->install->cronList['moduleName=git&methodName=run'] = '同步GIT'; diff --git a/module/install/lang/zh-tw.php b/module/install/lang/zh-tw.php index 4b3049bf65..53004437ec 100644 --- a/module/install/lang/zh-tw.php +++ b/module/install/lang/zh-tw.php @@ -153,7 +153,7 @@ $lang->install->groupList['LIMITED']['name'] = '受限用戶'; $lang->install->groupList['LIMITED']['desc'] = '受限用戶分組(只能編輯與自己相關的內容)'; $lang->install->cronList[''] = '監控定時任務'; -$lang->install->cronList['moduleName=project&methodName=computeburn'] = '更新燃盡圖'; +$lang->install->cronList['moduleName=execution&methodName=computeBurn'] = '更新燃盡圖'; $lang->install->cronList['moduleName=report&methodName=remind'] = '每日任務提醒'; $lang->install->cronList['moduleName=svn&methodName=run'] = '同步SVN'; $lang->install->cronList['moduleName=git&methodName=run'] = '同步GIT'; diff --git a/module/install/model.php b/module/install/model.php index 0d92cb0be2..71b05010fa 100644 --- a/module/install/model.php +++ b/module/install/model.php @@ -15,7 +15,7 @@ class installModel extends model { /** * Get license according the client lang. - * + * * @access public * @return string */ @@ -32,7 +32,7 @@ class installModel extends model /** * Check version of zentao. - * + * * @access public * @return void */ @@ -42,7 +42,7 @@ class installModel extends model /** * get php version. - * + * * @access public * @return string */ @@ -53,7 +53,7 @@ class installModel extends model /** * Get latest release. - * + * * @access public * @return string or bool */ @@ -71,7 +71,7 @@ class installModel extends model /** * Check php version. - * + * * @access public * @return string ok|fail */ @@ -82,7 +82,7 @@ class installModel extends model /** * Check PDO. - * + * * @access public * @return string ok|fail */ @@ -92,8 +92,8 @@ class installModel extends model } /** - * Check PDO::MySQL - * + * Check PDO::MySQL + * * @access public * @return string ok|fail */ @@ -181,7 +181,7 @@ class installModel extends model /** * Get tempRoot info. - * + * * @access public * @return array */ @@ -195,7 +195,7 @@ class installModel extends model /** * Check tmpRoot. - * + * * @access public * @return string ok|fail */ @@ -206,10 +206,10 @@ class installModel extends model } /** - * Get session save path. - * + * Get session save path. + * * @access public - * @return array + * @return array */ public function getSessionSavePath() { @@ -220,15 +220,15 @@ class installModel extends model } /** - * Check session save path. - * + * Check session save path. + * * @access public * @return string */ public function checkSessionSavePath() { $sessionSavePath = preg_replace("/\d;/", '', session_save_path()); - $result = (is_dir($sessionSavePath) and is_writable($sessionSavePath)) ? 'ok' : 'fail'; + $result = (is_dir($sessionSavePath) and is_writable($sessionSavePath)) ? 'ok' : 'fail'; if($result == 'fail') return $result; /* Test session path again. Fix bug #1527. */ @@ -243,8 +243,8 @@ class installModel extends model } /** - * Get data root - * + * Get data root + * * @access public * @return array */ @@ -257,8 +257,8 @@ class installModel extends model } /** - * Check the data root. - * + * Check the data root. + * * @access public * @return string ok|fail */ @@ -270,7 +270,7 @@ class installModel extends model /** * Get the php.ini info. - * + * * @access public * @return string */ @@ -287,7 +287,7 @@ class installModel extends model /** * Check config ok or not. - * + * * @access public * @return array */ @@ -345,7 +345,7 @@ class installModel extends model /** * Set database params. - * + * * @access public * @return void */ @@ -362,14 +362,14 @@ class installModel extends model /** * Connect to database. - * + * * @access public * @return object */ public function connectDB() { $dsn = "mysql:host={$this->config->db->host}; port={$this->config->db->port}"; - try + try { $dbh = new PDO($dsn, $this->config->db->user, $this->config->db->password); $dbh->setAttribute(PDO::ATTR_DEFAULT_FETCH_MODE, PDO::FETCH_OBJ); @@ -386,7 +386,7 @@ class installModel extends model /** * Check db exits or not. - * + * * @access public * @return bool */ @@ -398,7 +398,7 @@ class installModel extends model /** * Check table exits or not. - * + * * @access public * @return void */ @@ -411,7 +411,7 @@ class installModel extends model /** * Get mysql version. - * + * * @access public * @return string */ @@ -424,8 +424,8 @@ class installModel extends model /** * Create database. - * - * @param string $version + * + * @param string $version * @access public * @return bool */ @@ -438,8 +438,8 @@ class installModel extends model /** * Create tables. - * - * @param string $version + * + * @param string $version * @access public * @return bool */ @@ -489,7 +489,7 @@ class installModel extends model /** * Create a comapny, set admin. - * + * * @access public * @return void */ @@ -530,8 +530,8 @@ class installModel extends model } /** - * Import demo data. - * + * Import demo data. + * * @access public * @return void */ @@ -541,10 +541,10 @@ class installModel extends model $demoDataFile = $this->app->getAppRoot() . 'db' . DS . $demoDataFile; $insertTables = explode(";\n", file_get_contents($demoDataFile)); foreach($insertTables as $table) - { + { $table = trim($table); if(empty($table)) continue; - + $table = str_replace('`zt_', $this->config->db->name . '.`zt_', $table); $table = str_replace('zt_', $this->config->db->prefix, $table); if(!$this->dbh->query($table)) return false;