示例#1
0
文件: install.php 项目: hisapi/his
 $install_failed = false;
 foreach ($table_exist as $table_to_be_created) {
     $found_table = false;
     foreach ($current_db_tables as $table_created) {
         if (strtolower($table_created) == strtolower($table_to_be_created)) {
             $found_table = true;
         }
     }
     if (!$found_table) {
         $install_failed = true;
         $tables_found[] = $table_to_be_created;
     }
 }
 // EITHER SUCCESS OR FAILURE - ALL TABLES CREATED OR NOT
 if (!$install_failed) {
     $sys_setting = new sys_setting();
     $sys_setting->create(array("category" => "system", "param" => "version", "val" => $software_version));
     $pw = sha1($settings['salt1']['@attributes']['value'] . $_POST['admin_password'] . $_POST['user_name'] . $settings['salt2']['@attributes']['value']);
     $id_user = sha1(time() . $_POST['user_name'] . $pw);
     $secret = sha1(time() . rand(1, 50) . $_POST['admin_password'] . $_POST['user_name'] . $settings['salt2']['@attributes']['value']);
     $props = array();
     $props['id_user'] = $id_user;
     $props['user_name'] = $_POST['user_name'];
     $props['email'] = $_POST['admin_email'];
     $props['pw'] = $pw;
     $props['secret'] = $secret;
     $props['lang'] = "undefined";
     foreach ($_POST as $PK => $PV) {
         if ($PK != "Submit" && $PK != "btnSubmit" && $PK != "submit") {
             $PAGE->body = $PAGE->body . "<input type='hidden' name='" . str_replace("'", "", $PK) . "' value='" . str_replace("'", "", $PV) . "'/>";
         }
示例#2
0
     if ($idx > 5) {
         //logger("RECEIVED NEW JOB SUBMISSION:\n\t".$INSTANCE_NAME."@".$new_job_news->id."\n\t"."BUT THERE IS NO JOB_ID_USER ENTRY FOR THAT JOB ID\n");
         //print_r($JOB);
         $failed_to_find_job = true;
         break;
     }
     $JOB->get_from_hashrange($new_job_news->id_user, $new_job_news->id);
     // change to drive off of ip address
     $idx = $idx + 1;
 }
 // END WHILE
 // SKIP THE REST IF UNABLE TO FIND A JOB BY THAT NAME
 if ($failed_to_find_job) {
     continue;
 }
 $assigner_setting = new sys_setting();
 $assigner_setting->get_from_hashrange("jobcluster-" . substr($id_user, 0, 10), "reassigner");
 if ($assigner_setting->val == $INSTANCE_NAME) {
     $user_server_reassigns = array();
     $user_server_reassign = new user_server();
     // LIST OF ALL JOB SERVERS
     $user_server_reassigns = $user_server_reassign->get_from_hashrange($id_user);
     // HOW MANY NON-BUSY JOB SERVERS
     $not_busy_servers = array();
     foreach ($user_server_reassigns as $user_server_reassign) {
         if (isset($user_server_reassign['is_busy'])) {
             if ($user_server_reassign['is_busy'] . "" != "1") {
                 $not_busy_servers[] = $user_server_reassign;
             }
         }
     }
示例#3
0
文件: update.php 项目: hisapi/his
     $PAGE->body = $PAGE->body . " ";
     $PAGE->body = $PAGE->body . $next_version;
     $PAGE->body = $PAGE->body . "</b>";
     $update_notes = $UPDATE->notes();
     if (strlen($update_notes) > 0) {
         $PAGE->body = $PAGE->body . "<ul>";
         $PAGE->body = $PAGE->body . "<br/>";
         $PAGE->body = $PAGE->body . $update_notes;
         $PAGE->body = $PAGE->body . "</ul>";
     }
 } elseif (isset($_GET['page']) && intval($_GET['page']) == 2 && isset($_POST['btnSubmit'])) {
     // CALL THE UPDATE COMMANDS
     $UPDATE->execute();
     $old_version = $current_version;
     // UPDATE THE DATABASE VERSION NUMBER
     $sys_setting = new sys_setting();
     $sys_setting->get_from_hashrange("system", "version");
     $sys_setting->update(array("val" => $next_version));
     $database_version = $sys_setting->val;
     $current_version = $next_version;
     $title_text = getTranslation("Update from version", $settings);
     $title_text = $title_text . " ";
     $title_text = $title_text . $old_version;
     $title_text = $title_text . " ";
     $title_text = $title_text . getTranslation("to version", $settings);
     $title_text = $title_text . " ";
     $title_text = $title_text . $current_version;
     $title_text = $title_text . " ";
     $title_text = $title_text . getTranslation("successful", $settings);
     $update_notes = $UPDATE->notes();
     if (strlen($update_notes) > 0) {
示例#4
0
文件: view.main.php 项目: hisapi/his
 echo "<b>";
 echo getTranslation("HIS System Information", $settings);
 //echo ": ";
 echo "</b>";
 echo "<ul>";
 echo "<b>";
 echo getTranslation("Software Version", $settings);
 echo ": ";
 echo "</b>";
 echo $software_version;
 echo "<br/>";
 echo "<b>";
 echo getTranslation("Database Version", $settings);
 echo ": ";
 echo "</b>";
 $sys_setting = new sys_setting();
 $sys_setting->get_from_hashrange("system", "version");
 echo $sys_setting->val;
 echo "<br/>";
 echo "<b>";
 echo getTranslation("HF XML File Format Version", $settings);
 echo ": ";
 echo "</b>";
 echo $software_version;
 echo "<br/>";
 echo "</ul>";
 echo "<br/>";
 echo "<b>";
 echo getTranslation("Available Software Versions", $settings);
 echo "</b>";
 echo "<ul>";