diff models/extractapp.php @ 62:3fb9e3884401 extractapp

New: insert selected wordlist into textarea at cursor position when editing regex
author Zoe Hong <zhong@mpiwg-berlin.mpg.de>
date Tue, 31 Mar 2015 14:55:58 +0200
parents c6fa7f83c5bf
children 3395385476d1
line wrap: on
line diff
--- a/models/extractapp.php	Tue Mar 31 12:34:57 2015 +0200
+++ b/models/extractapp.php	Tue Mar 31 14:55:58 2015 +0200
@@ -264,13 +264,6 @@
         $this->messages['info'] .= ", file id: ".$this->file_id;
         $this->messages['info'] .= "<br>";
 
-        /*
-        $this->messages .= "Info: ";
-        $this->messages .= "file_id=".$this->file_id.", section_id=".$this->section_id;
-        $this->messages .= ", user_id=".$this->user_id.", branch_id=".$this->branch_id.", topic_id=".$this->topic;
-        $this->messages .= ", book_id=".$this->book_id.", book_name=".$this->book_name.", section_name=".$this->section_name;
-        $this->messages .= ", current_fileId=".$this->current_fileId."<br>";
-        */
 
         $data['messages'] = $this->messages;
 
@@ -303,32 +296,6 @@
     }
 
     public function UpdateInfoByResponseFromLGService($response) {
-         
-        /*
-        $response_file = $response["file"];
-        $response_branch = $response["branch"];
-
-        
-        $status = (string)$response["status"];
-
-        if ((string)$response["status"] == "error") {
-            $response_currentFile = $response["currentFile"];
-    
-            $this->current_fileId = (string)$response_currentFile['id'];
-            $this->messages .= "saving does not success! ".(string)$response["message"];
-
-            
-        } else {
-           
-            $this->messages .= "saving success.";
-            var_dump((string)$response_file["id"]);
-
-            $this->file_id = (string)$response_file["id"]; 
-            $this->branch_id = (string)$response_branch["id"];
-
-        }
-        */
-
         
         $response_file = $response["file"];
         $response_branch = $response["branch"];
@@ -336,7 +303,6 @@
         $status = (string)$response["status"];
         if ($status == "ok") {
             $this->messages['info'] .= "[Info] Saving success. <br>";
-            //$this->messages .= "Saving success.";
             $this->file_id = (string)$response_file["id"]; 
             $this->branch_id = (string)$response_branch["id"];
 
@@ -345,12 +311,7 @@
             $this->messages['error'] .= "[Error] Saving Failed! ".(string)$response["message"]."<br>";
             $this->messages['warning'] .= "[Warning] Please check branch ".$this->branch_id." in LGService, and modify from the latest version. <br>";
 
-            /*
-            $this->messages .= "Saving Failed! ".(string)$response["message"]."<br>";
-            $this->messages .= "Please check branch ".$this->branch_id." in LGService, and modify from the latest version. <br>";
-            */
             $response_currentFile = $response["currentFile"];
-            //$this->current_fileId = $response["currentFileId"];
             $this->current_fileId = (string)$response_currentFile["id"];
 
         }