annotate interface/check_sections.php @ 8:da10158c6d0a

add toc_correction status in books table. On TOC correction list page, providing the status checking box for users.
author Zoe Hong <zhong@mpiwg-berlin.mpg.de>
date Mon, 09 Feb 2015 12:28:09 +0100
parents 0e9a7c69f22c
children 584b1623e9ef
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
0
b12c99b7c3f0 commit for previous development
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents:
diff changeset
1 <?php
b12c99b7c3f0 commit for previous development
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents:
diff changeset
2 include_once('Lib_mb_utf8.php');
b12c99b7c3f0 commit for previous development
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents:
diff changeset
3 include_once('config.php');
b12c99b7c3f0 commit for previous development
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents:
diff changeset
4 include_once('edit_section_db.php');
b12c99b7c3f0 commit for previous development
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents:
diff changeset
5 set_time_limit(0);
b12c99b7c3f0 commit for previous development
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents:
diff changeset
6 ini_set('memory_limit', '-1');
b12c99b7c3f0 commit for previous development
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents:
diff changeset
7
b12c99b7c3f0 commit for previous development
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents:
diff changeset
8 $link_mysql = mysql_connect($mysql_server, $mysql_user, $mysql_password);
b12c99b7c3f0 commit for previous development
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents:
diff changeset
9 mysql_query("SET NAMES utf8");
b12c99b7c3f0 commit for previous development
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents:
diff changeset
10
b12c99b7c3f0 commit for previous development
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents:
diff changeset
11 if (!$link_mysql) {
b12c99b7c3f0 commit for previous development
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents:
diff changeset
12 die('Could not connect: ' . mysql_error());
b12c99b7c3f0 commit for previous development
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents:
diff changeset
13 }
b12c99b7c3f0 commit for previous development
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents:
diff changeset
14
b12c99b7c3f0 commit for previous development
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents:
diff changeset
15 $db_selected = mysql_select_db($mysql_database, $link_mysql);
b12c99b7c3f0 commit for previous development
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents:
diff changeset
16 if (!$db_selected) {
b12c99b7c3f0 commit for previous development
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents:
diff changeset
17 die ('Can\'t use foo : ' . mysql_error());
b12c99b7c3f0 commit for previous development
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents:
diff changeset
18 }
b12c99b7c3f0 commit for previous development
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents:
diff changeset
19
8
da10158c6d0a add toc_correction status in books table. On TOC correction list page, providing the status checking box for users.
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents: 7
diff changeset
20 if (isset($_POST['func'])){
da10158c6d0a add toc_correction status in books table. On TOC correction list page, providing the status checking box for users.
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents: 7
diff changeset
21 switch ($_POST['func']) {
da10158c6d0a add toc_correction status in books table. On TOC correction list page, providing the status checking box for users.
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents: 7
diff changeset
22 case 'UpdateTOCstatus':
da10158c6d0a add toc_correction status in books table. On TOC correction list page, providing the status checking box for users.
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents: 7
diff changeset
23 UpdateTOCstatus($_POST['id'],$_POST['status']);
da10158c6d0a add toc_correction status in books table. On TOC correction list page, providing the status checking box for users.
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents: 7
diff changeset
24 break;
da10158c6d0a add toc_correction status in books table. On TOC correction list page, providing the status checking box for users.
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents: 7
diff changeset
25
da10158c6d0a add toc_correction status in books table. On TOC correction list page, providing the status checking box for users.
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents: 7
diff changeset
26 default:
da10158c6d0a add toc_correction status in books table. On TOC correction list page, providing the status checking box for users.
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents: 7
diff changeset
27 # code...
da10158c6d0a add toc_correction status in books table. On TOC correction list page, providing the status checking box for users.
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents: 7
diff changeset
28 break;
da10158c6d0a add toc_correction status in books table. On TOC correction list page, providing the status checking box for users.
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents: 7
diff changeset
29 }
da10158c6d0a add toc_correction status in books table. On TOC correction list page, providing the status checking box for users.
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents: 7
diff changeset
30 }
da10158c6d0a add toc_correction status in books table. On TOC correction list page, providing the status checking box for users.
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents: 7
diff changeset
31
da10158c6d0a add toc_correction status in books table. On TOC correction list page, providing the status checking box for users.
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents: 7
diff changeset
32 function UpdateTOCstatus($id, $status) {
da10158c6d0a add toc_correction status in books table. On TOC correction list page, providing the status checking box for users.
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents: 7
diff changeset
33
da10158c6d0a add toc_correction status in books table. On TOC correction list page, providing the status checking box for users.
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents: 7
diff changeset
34 $query = "UPDATE books SET toc_correction='".$status."' WHERE id='".$id."'";
da10158c6d0a add toc_correction status in books table. On TOC correction list page, providing the status checking box for users.
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents: 7
diff changeset
35
da10158c6d0a add toc_correction status in books table. On TOC correction list page, providing the status checking box for users.
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents: 7
diff changeset
36 $result = mysql_query($query);
da10158c6d0a add toc_correction status in books table. On TOC correction list page, providing the status checking box for users.
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents: 7
diff changeset
37 if (!$result){
da10158c6d0a add toc_correction status in books table. On TOC correction list page, providing the status checking box for users.
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents: 7
diff changeset
38 echo mysql_error();
da10158c6d0a add toc_correction status in books table. On TOC correction list page, providing the status checking box for users.
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents: 7
diff changeset
39 echo ("Failed during updating books table.");
da10158c6d0a add toc_correction status in books table. On TOC correction list page, providing the status checking box for users.
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents: 7
diff changeset
40 }
da10158c6d0a add toc_correction status in books table. On TOC correction list page, providing the status checking box for users.
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents: 7
diff changeset
41
da10158c6d0a add toc_correction status in books table. On TOC correction list page, providing the status checking box for users.
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents: 7
diff changeset
42 }
da10158c6d0a add toc_correction status in books table. On TOC correction list page, providing the status checking box for users.
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents: 7
diff changeset
43
0
b12c99b7c3f0 commit for previous development
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents:
diff changeset
44 function checkSections($count){
b12c99b7c3f0 commit for previous development
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents:
diff changeset
45
b12c99b7c3f0 commit for previous development
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents:
diff changeset
46 /* $query="SELECT books.name AS book_name, books.level1, books.level2, books.period, books.id, sections.name, start_page, end_page, COUNT( * ) AS count
b12c99b7c3f0 commit for previous development
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents:
diff changeset
47 FROM sections
b12c99b7c3f0 commit for previous development
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents:
diff changeset
48 JOIN books ON sections.books_id = books.id
b12c99b7c3f0 commit for previous development
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents:
diff changeset
49 WHERE NOT EXISTS
b12c99b7c3f0 commit for previous development
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents:
diff changeset
50 (SELECT 1 FROM sections_versions WHERE books_id=sections.books_id)
b12c99b7c3f0 commit for previous development
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents:
diff changeset
51 GROUP BY books_id, start_page, end_page
b12c99b7c3f0 commit for previous development
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents:
diff changeset
52 HAVING COUNT( * ) >=".$count."
b12c99b7c3f0 commit for previous development
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents:
diff changeset
53 ORDER BY COUNT( * ) DESC ";*/
b12c99b7c3f0 commit for previous development
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents:
diff changeset
54 $query="(SELECT books.name AS book_name, books.level1, books.level2, books.period, books.id, sections.name, start_page, end_page, COUNT( * ) AS count
b12c99b7c3f0 commit for previous development
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents:
diff changeset
55 FROM sections
b12c99b7c3f0 commit for previous development
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents:
diff changeset
56 JOIN books ON sections.books_id = books.id
b12c99b7c3f0 commit for previous development
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents:
diff changeset
57 WHERE NOT EXISTS
b12c99b7c3f0 commit for previous development
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents:
diff changeset
58 (SELECT 1 FROM sections_versions WHERE books_id=sections.books_id)
b12c99b7c3f0 commit for previous development
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents:
diff changeset
59 GROUP BY books_id, start_page, end_page
b12c99b7c3f0 commit for previous development
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents:
diff changeset
60 HAVING COUNT( * ) >=".$count.")
b12c99b7c3f0 commit for previous development
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents:
diff changeset
61 UNION
b12c99b7c3f0 commit for previous development
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents:
diff changeset
62 (SELECT books.name AS book_name, books.level1, books.level2, books.period, books.id, sections_revisions.name, start_page, end_page, COUNT( * ) AS count
b12c99b7c3f0 commit for previous development
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents:
diff changeset
63 FROM sections_revisions
b12c99b7c3f0 commit for previous development
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents:
diff changeset
64 JOIN books ON sections_revisions.books_id = books.id
b12c99b7c3f0 commit for previous development
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents:
diff changeset
65 JOIN (
b12c99b7c3f0 commit for previous development
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents:
diff changeset
66 SELECT sections_versions.id
b12c99b7c3f0 commit for previous development
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents:
diff changeset
67 FROM sections_versions WHERE sections_versions.version=(SELECT MAX(version) FROM sections_versions)
b12c99b7c3f0 commit for previous development
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents:
diff changeset
68 GROUP BY books_id
b12c99b7c3f0 commit for previous development
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents:
diff changeset
69 ) AS t ON t.id=sections_revisions.versions_id
b12c99b7c3f0 commit for previous development
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents:
diff changeset
70 WHERE deleted=0
b12c99b7c3f0 commit for previous development
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents:
diff changeset
71 GROUP BY books_id, versions_id,start_page, end_page
b12c99b7c3f0 commit for previous development
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents:
diff changeset
72 HAVING COUNT( * ) >=".$count.")
b12c99b7c3f0 commit for previous development
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents:
diff changeset
73 ORDER BY count DESC ";
b12c99b7c3f0 commit for previous development
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents:
diff changeset
74 $result = mysql_query($query);
b12c99b7c3f0 commit for previous development
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents:
diff changeset
75 echo mysql_num_rows($result)." result(s)<br><br>";
b12c99b7c3f0 commit for previous development
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents:
diff changeset
76 echo "<table>";
b12c99b7c3f0 commit for previous development
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents:
diff changeset
77 echo "<tr>";
b12c99b7c3f0 commit for previous development
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents:
diff changeset
78 echo "<td class='bookName'>book name<td class='level1'>level1<td class='level2'>level2<td class='period'>period<td class='sectionName'>section name<td class='sectionName'>page<td class='page'>count";
b12c99b7c3f0 commit for previous development
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents:
diff changeset
79 while ($row = mysql_fetch_assoc($result)) {
b12c99b7c3f0 commit for previous development
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents:
diff changeset
80 $str="<tr>";
b12c99b7c3f0 commit for previous development
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents:
diff changeset
81 $str.="<td>".$row['book_name'];
b12c99b7c3f0 commit for previous development
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents:
diff changeset
82 $str.="<td>".$row['level1'];
b12c99b7c3f0 commit for previous development
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents:
diff changeset
83 $str.="<td>".$row['level2'];
b12c99b7c3f0 commit for previous development
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents:
diff changeset
84 $str.="<td>".$row['period'];
b12c99b7c3f0 commit for previous development
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents:
diff changeset
85 $str.="<td><a href='tagging_text.php?id=".$row['id']."' target='_blank'>".$row['name']."</a>";
b12c99b7c3f0 commit for previous development
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents:
diff changeset
86 $str.="<td>p".$row['start_page']."-".$row['end_page'];
b12c99b7c3f0 commit for previous development
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents:
diff changeset
87 $str.="<td><a href='check_sections_details.php?book_id=".$row['id']."&count=".$count."' target='_blank'>".$row['count']."</a>";
b12c99b7c3f0 commit for previous development
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents:
diff changeset
88 echo $str;
b12c99b7c3f0 commit for previous development
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents:
diff changeset
89 }
b12c99b7c3f0 commit for previous development
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents:
diff changeset
90 echo "</table>";
b12c99b7c3f0 commit for previous development
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents:
diff changeset
91 }
b12c99b7c3f0 commit for previous development
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents:
diff changeset
92
1
ef6d0c6a13d7 (1)Add 'sort_by' time entry in main page. (check_sections.php)
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents: 0
diff changeset
93
ef6d0c6a13d7 (1)Add 'sort_by' time entry in main page. (check_sections.php)
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents: 0
diff changeset
94 // sorting by the $sort_by parameter
ef6d0c6a13d7 (1)Add 'sort_by' time entry in main page. (check_sections.php)
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents: 0
diff changeset
95 function checkSections_sort_by($sort_by){
ef6d0c6a13d7 (1)Add 'sort_by' time entry in main page. (check_sections.php)
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents: 0
diff changeset
96 switch ($sort_by) {
8
da10158c6d0a add toc_correction status in books table. On TOC correction list page, providing the status checking box for users.
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents: 7
diff changeset
97
da10158c6d0a add toc_correction status in books table. On TOC correction list page, providing the status checking box for users.
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents: 7
diff changeset
98
da10158c6d0a add toc_correction status in books table. On TOC correction list page, providing the status checking box for users.
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents: 7
diff changeset
99 case 'time':
da10158c6d0a add toc_correction status in books table. On TOC correction list page, providing the status checking box for users.
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents: 7
diff changeset
100 $query="(SELECT name AS book_name,level1,level2,period,dynasty,start_year,id, toc_correction from books ORDER BY start_year)";
1
ef6d0c6a13d7 (1)Add 'sort_by' time entry in main page. (check_sections.php)
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents: 0
diff changeset
101 $result = mysql_query($query);
7
0e9a7c69f22c add editing records/log into TOC correction list page, more editing records could be shown on the TOC page
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents: 4
diff changeset
102 if (!$result){
0e9a7c69f22c add editing records/log into TOC correction list page, more editing records could be shown on the TOC page
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents: 4
diff changeset
103 echo ("Failed during selecting books table.");
0e9a7c69f22c add editing records/log into TOC correction list page, more editing records could be shown on the TOC page
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents: 4
diff changeset
104 }
0e9a7c69f22c add editing records/log into TOC correction list page, more editing records could be shown on the TOC page
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents: 4
diff changeset
105
8
da10158c6d0a add toc_correction status in books table. On TOC correction list page, providing the status checking box for users.
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents: 7
diff changeset
106 echo mysql_num_rows($result)." result(s)<br><br>";
7
0e9a7c69f22c add editing records/log into TOC correction list page, more editing records could be shown on the TOC page
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents: 4
diff changeset
107
8
da10158c6d0a add toc_correction status in books table. On TOC correction list page, providing the status checking box for users.
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents: 7
diff changeset
108 echo "<form autocomplete='off'>";
7
0e9a7c69f22c add editing records/log into TOC correction list page, more editing records could be shown on the TOC page
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents: 4
diff changeset
109 echo "<table>";
0e9a7c69f22c add editing records/log into TOC correction list page, more editing records could be shown on the TOC page
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents: 4
diff changeset
110 echo "<tr>";
0e9a7c69f22c add editing records/log into TOC correction list page, more editing records could be shown on the TOC page
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents: 4
diff changeset
111 echo "<td class='bookName'>book name<td class='level1'>level1<td class='level2'>level2 <td class='period'>period<td class='dynasty'>dynasty<td class='start_year'>start_year<td class='last_editor'>last_editor<td class='edit_time'>edit_time";
0e9a7c69f22c add editing records/log into TOC correction list page, more editing records could be shown on the TOC page
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents: 4
diff changeset
112 while ($row = mysql_fetch_assoc($result)) {
0e9a7c69f22c add editing records/log into TOC correction list page, more editing records could be shown on the TOC page
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents: 4
diff changeset
113 $str="<tr>";
0e9a7c69f22c add editing records/log into TOC correction list page, more editing records could be shown on the TOC page
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents: 4
diff changeset
114 $str.="<td>".$row['book_name'];
0e9a7c69f22c add editing records/log into TOC correction list page, more editing records could be shown on the TOC page
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents: 4
diff changeset
115 $str.="<td>".$row['level1'];
0e9a7c69f22c add editing records/log into TOC correction list page, more editing records could be shown on the TOC page
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents: 4
diff changeset
116 $str.="<td>".$row['level2'];
0e9a7c69f22c add editing records/log into TOC correction list page, more editing records could be shown on the TOC page
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents: 4
diff changeset
117 $str.="<td>".$row['period'];
0e9a7c69f22c add editing records/log into TOC correction list page, more editing records could be shown on the TOC page
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents: 4
diff changeset
118 $str.="<td>".$row['dynasty'];
0e9a7c69f22c add editing records/log into TOC correction list page, more editing records could be shown on the TOC page
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents: 4
diff changeset
119 $str.="<td>".$row['start_year'];
8
da10158c6d0a add toc_correction status in books table. On TOC correction list page, providing the status checking box for users.
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents: 7
diff changeset
120 $id = $row['id'];
da10158c6d0a add toc_correction status in books table. On TOC correction list page, providing the status checking box for users.
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents: 7
diff changeset
121
7
0e9a7c69f22c add editing records/log into TOC correction list page, more editing records could be shown on the TOC page
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents: 4
diff changeset
122 // query last_editor and last_edit_time
0e9a7c69f22c add editing records/log into TOC correction list page, more editing records could be shown on the TOC page
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents: 4
diff changeset
123 $query_editor = "(SELECT editor, date from sections_versions WHERE books_id='".$row['id']."' ORDER BY version DESC)";
0e9a7c69f22c add editing records/log into TOC correction list page, more editing records could be shown on the TOC page
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents: 4
diff changeset
124 $row_sections_versions = mysql_fetch_assoc(mysql_query($query_editor)); // the first one
0e9a7c69f22c add editing records/log into TOC correction list page, more editing records could be shown on the TOC page
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents: 4
diff changeset
125 $last_editor = $row_sections_versions['editor'];
0e9a7c69f22c add editing records/log into TOC correction list page, more editing records could be shown on the TOC page
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents: 4
diff changeset
126 $last_edit_time = $row_sections_versions['date'];
0e9a7c69f22c add editing records/log into TOC correction list page, more editing records could be shown on the TOC page
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents: 4
diff changeset
127 $str.="<td>".$last_editor;
0e9a7c69f22c add editing records/log into TOC correction list page, more editing records could be shown on the TOC page
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents: 4
diff changeset
128 $str.="<td>".$last_edit_time;
0e9a7c69f22c add editing records/log into TOC correction list page, more editing records could be shown on the TOC page
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents: 4
diff changeset
129
0e9a7c69f22c add editing records/log into TOC correction list page, more editing records could be shown on the TOC page
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents: 4
diff changeset
130 $str.="<td><a href='check_sections_details.php?book_id=".$row['id']."&count=100"."' target='_blank'>"."click here"."</a>";
8
da10158c6d0a add toc_correction status in books table. On TOC correction list page, providing the status checking box for users.
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents: 7
diff changeset
131
da10158c6d0a add toc_correction status in books table. On TOC correction list page, providing the status checking box for users.
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents: 7
diff changeset
132 //$str.="<td> <input type='radio' name='books'".$row['id']." value='no'/> NotFinished";
da10158c6d0a add toc_correction status in books table. On TOC correction list page, providing the status checking box for users.
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents: 7
diff changeset
133 switch ($row['toc_correction']) {
da10158c6d0a add toc_correction status in books table. On TOC correction list page, providing the status checking box for users.
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents: 7
diff changeset
134 case '0':
da10158c6d0a add toc_correction status in books table. On TOC correction list page, providing the status checking box for users.
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents: 7
diff changeset
135 $str.="<td> <input type='radio' name='".$id."' value='0' onClick='toc_status(this)' checked/> Not Finished";
da10158c6d0a add toc_correction status in books table. On TOC correction list page, providing the status checking box for users.
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents: 7
diff changeset
136 $str.="<td> <input type='radio' name='".$id."' value='1' onClick='toc_status(this)'/> Works-in-progress";
da10158c6d0a add toc_correction status in books table. On TOC correction list page, providing the status checking box for users.
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents: 7
diff changeset
137 $str.="<td> <input type='radio' name='".$id."' value='2' onClick='toc_status(this)' /> Finished";
da10158c6d0a add toc_correction status in books table. On TOC correction list page, providing the status checking box for users.
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents: 7
diff changeset
138 break;
da10158c6d0a add toc_correction status in books table. On TOC correction list page, providing the status checking box for users.
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents: 7
diff changeset
139 case '1':
da10158c6d0a add toc_correction status in books table. On TOC correction list page, providing the status checking box for users.
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents: 7
diff changeset
140 $str.="<td> <input type='radio' name='".$id."' value='0' onClick='toc_status(this)'/> Not Finished";
da10158c6d0a add toc_correction status in books table. On TOC correction list page, providing the status checking box for users.
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents: 7
diff changeset
141 $str.="<td> <input type='radio' name='".$id."' value='1' onClick='toc_status(this)' checked/> Works-in-progress";
da10158c6d0a add toc_correction status in books table. On TOC correction list page, providing the status checking box for users.
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents: 7
diff changeset
142 $str.="<td> <input type='radio' name='".$id."' value='2' onClick='toc_status(this)'/> Finished";
da10158c6d0a add toc_correction status in books table. On TOC correction list page, providing the status checking box for users.
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents: 7
diff changeset
143 break;
da10158c6d0a add toc_correction status in books table. On TOC correction list page, providing the status checking box for users.
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents: 7
diff changeset
144 case '2':
da10158c6d0a add toc_correction status in books table. On TOC correction list page, providing the status checking box for users.
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents: 7
diff changeset
145 $str.="<td> <input type='radio' name='".$id."' value='0' onClick='toc_status(this)'/> Not Finished";
da10158c6d0a add toc_correction status in books table. On TOC correction list page, providing the status checking box for users.
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents: 7
diff changeset
146 $str.="<td> <input type='radio' name='".$id."' value='1' onClick='toc_status(this)'/> Works-in-progress";
da10158c6d0a add toc_correction status in books table. On TOC correction list page, providing the status checking box for users.
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents: 7
diff changeset
147 $str.="<td> <input type='radio' name='".$id."' value='2' onClick='toc_status(this)' checked/> Finished";
da10158c6d0a add toc_correction status in books table. On TOC correction list page, providing the status checking box for users.
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents: 7
diff changeset
148 break;
da10158c6d0a add toc_correction status in books table. On TOC correction list page, providing the status checking box for users.
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents: 7
diff changeset
149
da10158c6d0a add toc_correction status in books table. On TOC correction list page, providing the status checking box for users.
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents: 7
diff changeset
150 default:
da10158c6d0a add toc_correction status in books table. On TOC correction list page, providing the status checking box for users.
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents: 7
diff changeset
151 break;
da10158c6d0a add toc_correction status in books table. On TOC correction list page, providing the status checking box for users.
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents: 7
diff changeset
152 }
da10158c6d0a add toc_correction status in books table. On TOC correction list page, providing the status checking box for users.
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents: 7
diff changeset
153
7
0e9a7c69f22c add editing records/log into TOC correction list page, more editing records could be shown on the TOC page
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents: 4
diff changeset
154 echo $str;
0e9a7c69f22c add editing records/log into TOC correction list page, more editing records could be shown on the TOC page
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents: 4
diff changeset
155 }
0e9a7c69f22c add editing records/log into TOC correction list page, more editing records could be shown on the TOC page
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents: 4
diff changeset
156 echo "</table>";
8
da10158c6d0a add toc_correction status in books table. On TOC correction list page, providing the status checking box for users.
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents: 7
diff changeset
157 echo "</form>";
7
0e9a7c69f22c add editing records/log into TOC correction list page, more editing records could be shown on the TOC page
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents: 4
diff changeset
158 break;
0e9a7c69f22c add editing records/log into TOC correction list page, more editing records could be shown on the TOC page
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents: 4
diff changeset
159
1
ef6d0c6a13d7 (1)Add 'sort_by' time entry in main page. (check_sections.php)
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents: 0
diff changeset
160 default:
ef6d0c6a13d7 (1)Add 'sort_by' time entry in main page. (check_sections.php)
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents: 0
diff changeset
161 # code...
ef6d0c6a13d7 (1)Add 'sort_by' time entry in main page. (check_sections.php)
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents: 0
diff changeset
162 echo "no sorting parameter set";
ef6d0c6a13d7 (1)Add 'sort_by' time entry in main page. (check_sections.php)
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents: 0
diff changeset
163 break;
ef6d0c6a13d7 (1)Add 'sort_by' time entry in main page. (check_sections.php)
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents: 0
diff changeset
164 }
ef6d0c6a13d7 (1)Add 'sort_by' time entry in main page. (check_sections.php)
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents: 0
diff changeset
165 }
ef6d0c6a13d7 (1)Add 'sort_by' time entry in main page. (check_sections.php)
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents: 0
diff changeset
166
7
0e9a7c69f22c add editing records/log into TOC correction list page, more editing records could be shown on the TOC page
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents: 4
diff changeset
167
0
b12c99b7c3f0 commit for previous development
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents:
diff changeset
168 ?>
b12c99b7c3f0 commit for previous development
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents:
diff changeset
169
1
ef6d0c6a13d7 (1)Add 'sort_by' time entry in main page. (check_sections.php)
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents: 0
diff changeset
170
ef6d0c6a13d7 (1)Add 'sort_by' time entry in main page. (check_sections.php)
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents: 0
diff changeset
171
0
b12c99b7c3f0 commit for previous development
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents:
diff changeset
172 <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
b12c99b7c3f0 commit for previous development
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents:
diff changeset
173 <html>
b12c99b7c3f0 commit for previous development
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents:
diff changeset
174 <head>
b12c99b7c3f0 commit for previous development
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents:
diff changeset
175 <meta http-equiv="Content-Type" content="text/html; charset=utf-8"/>
b12c99b7c3f0 commit for previous development
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents:
diff changeset
176 <link href="css/search.css" type="text/css" rel="stylesheet"/>
4
883ad980a43b add dynasty column to table books
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents: 1
diff changeset
177 <script src="https://ajax.googleapis.com/ajax/libs/jquery/1.6.2/jquery.min.js" type="text/javascript"></script>
0
b12c99b7c3f0 commit for previous development
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents:
diff changeset
178 <!--<script src="js/check_sections.js" charset="utf-8"></script>!-->
b12c99b7c3f0 commit for previous development
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents:
diff changeset
179 </head>
b12c99b7c3f0 commit for previous development
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents:
diff changeset
180 <body>
b12c99b7c3f0 commit for previous development
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents:
diff changeset
181 <form action='check_sections.php' method='GET'>
b12c99b7c3f0 commit for previous development
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents:
diff changeset
182 find sections overlapping more than <input type="text" name="count"> other sections
b12c99b7c3f0 commit for previous development
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents:
diff changeset
183 <input type="submit" name="find" value="find">
b12c99b7c3f0 commit for previous development
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents:
diff changeset
184 </form>
b12c99b7c3f0 commit for previous development
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents:
diff changeset
185 <br>
b12c99b7c3f0 commit for previous development
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents:
diff changeset
186 <div id="search_result">
b12c99b7c3f0 commit for previous development
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents:
diff changeset
187 <?php
b12c99b7c3f0 commit for previous development
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents:
diff changeset
188 if(isset($_GET['find']) && $_GET['count']!='' && is_numeric($_GET['count'])){
b12c99b7c3f0 commit for previous development
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents:
diff changeset
189 checkSections($_GET['count']);
b12c99b7c3f0 commit for previous development
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents:
diff changeset
190 }
1
ef6d0c6a13d7 (1)Add 'sort_by' time entry in main page. (check_sections.php)
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents: 0
diff changeset
191 else if(isset($_GET['sort_by'])){
ef6d0c6a13d7 (1)Add 'sort_by' time entry in main page. (check_sections.php)
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents: 0
diff changeset
192 checkSections_sort_by($_GET['sort_by']);
ef6d0c6a13d7 (1)Add 'sort_by' time entry in main page. (check_sections.php)
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents: 0
diff changeset
193 }
0
b12c99b7c3f0 commit for previous development
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents:
diff changeset
194 ?>
b12c99b7c3f0 commit for previous development
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents:
diff changeset
195 </div>
b12c99b7c3f0 commit for previous development
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents:
diff changeset
196 </body>
8
da10158c6d0a add toc_correction status in books table. On TOC correction list page, providing the status checking box for users.
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents: 7
diff changeset
197
da10158c6d0a add toc_correction status in books table. On TOC correction list page, providing the status checking box for users.
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents: 7
diff changeset
198
da10158c6d0a add toc_correction status in books table. On TOC correction list page, providing the status checking box for users.
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents: 7
diff changeset
199 <script type="text/javascript">
da10158c6d0a add toc_correction status in books table. On TOC correction list page, providing the status checking box for users.
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents: 7
diff changeset
200
da10158c6d0a add toc_correction status in books table. On TOC correction list page, providing the status checking box for users.
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents: 7
diff changeset
201 function toc_status(t) {
da10158c6d0a add toc_correction status in books table. On TOC correction list page, providing the status checking box for users.
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents: 7
diff changeset
202 var id = t.name;
da10158c6d0a add toc_correction status in books table. On TOC correction list page, providing the status checking box for users.
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents: 7
diff changeset
203 var val = t.value;
da10158c6d0a add toc_correction status in books table. On TOC correction list page, providing the status checking box for users.
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents: 7
diff changeset
204 switch(val) {
da10158c6d0a add toc_correction status in books table. On TOC correction list page, providing the status checking box for users.
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents: 7
diff changeset
205 case '0':
da10158c6d0a add toc_correction status in books table. On TOC correction list page, providing the status checking box for users.
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents: 7
diff changeset
206 $.ajax({
da10158c6d0a add toc_correction status in books table. On TOC correction list page, providing the status checking box for users.
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents: 7
diff changeset
207 url : './check_sections.php',
da10158c6d0a add toc_correction status in books table. On TOC correction list page, providing the status checking box for users.
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents: 7
diff changeset
208 async : false,
da10158c6d0a add toc_correction status in books table. On TOC correction list page, providing the status checking box for users.
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents: 7
diff changeset
209 type : 'POST',
da10158c6d0a add toc_correction status in books table. On TOC correction list page, providing the status checking box for users.
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents: 7
diff changeset
210 data : 'func=UpdateTOCstatus'+'&id='+id+'&status='+val
da10158c6d0a add toc_correction status in books table. On TOC correction list page, providing the status checking box for users.
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents: 7
diff changeset
211 }).done(function(result) {
da10158c6d0a add toc_correction status in books table. On TOC correction list page, providing the status checking box for users.
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents: 7
diff changeset
212 alert('You update the status of book to "Not Finished"!');
da10158c6d0a add toc_correction status in books table. On TOC correction list page, providing the status checking box for users.
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents: 7
diff changeset
213 });
da10158c6d0a add toc_correction status in books table. On TOC correction list page, providing the status checking box for users.
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents: 7
diff changeset
214
da10158c6d0a add toc_correction status in books table. On TOC correction list page, providing the status checking box for users.
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents: 7
diff changeset
215 break;
da10158c6d0a add toc_correction status in books table. On TOC correction list page, providing the status checking box for users.
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents: 7
diff changeset
216 case '1':
da10158c6d0a add toc_correction status in books table. On TOC correction list page, providing the status checking box for users.
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents: 7
diff changeset
217 $.ajax({
da10158c6d0a add toc_correction status in books table. On TOC correction list page, providing the status checking box for users.
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents: 7
diff changeset
218 url : './check_sections.php',
da10158c6d0a add toc_correction status in books table. On TOC correction list page, providing the status checking box for users.
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents: 7
diff changeset
219 async : false,
da10158c6d0a add toc_correction status in books table. On TOC correction list page, providing the status checking box for users.
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents: 7
diff changeset
220 type : 'POST',
da10158c6d0a add toc_correction status in books table. On TOC correction list page, providing the status checking box for users.
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents: 7
diff changeset
221 data : 'func=UpdateTOCstatus'+'&id='+id+'&status='+val
da10158c6d0a add toc_correction status in books table. On TOC correction list page, providing the status checking box for users.
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents: 7
diff changeset
222 }).done(function(result) {
da10158c6d0a add toc_correction status in books table. On TOC correction list page, providing the status checking box for users.
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents: 7
diff changeset
223 alert('You update the status of book to "Works-in-progress"!');
da10158c6d0a add toc_correction status in books table. On TOC correction list page, providing the status checking box for users.
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents: 7
diff changeset
224 });
da10158c6d0a add toc_correction status in books table. On TOC correction list page, providing the status checking box for users.
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents: 7
diff changeset
225
da10158c6d0a add toc_correction status in books table. On TOC correction list page, providing the status checking box for users.
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents: 7
diff changeset
226 break;
da10158c6d0a add toc_correction status in books table. On TOC correction list page, providing the status checking box for users.
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents: 7
diff changeset
227 case '2':
da10158c6d0a add toc_correction status in books table. On TOC correction list page, providing the status checking box for users.
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents: 7
diff changeset
228 $.ajax({
da10158c6d0a add toc_correction status in books table. On TOC correction list page, providing the status checking box for users.
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents: 7
diff changeset
229 url : './check_sections.php',
da10158c6d0a add toc_correction status in books table. On TOC correction list page, providing the status checking box for users.
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents: 7
diff changeset
230 async : false,
da10158c6d0a add toc_correction status in books table. On TOC correction list page, providing the status checking box for users.
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents: 7
diff changeset
231 type : 'POST',
da10158c6d0a add toc_correction status in books table. On TOC correction list page, providing the status checking box for users.
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents: 7
diff changeset
232 data : 'func=UpdateTOCstatus'+'&id='+id+'&status='+val
da10158c6d0a add toc_correction status in books table. On TOC correction list page, providing the status checking box for users.
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents: 7
diff changeset
233 }).done(function(result) {
da10158c6d0a add toc_correction status in books table. On TOC correction list page, providing the status checking box for users.
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents: 7
diff changeset
234 alert('You update the status of book to "Finished"!');
da10158c6d0a add toc_correction status in books table. On TOC correction list page, providing the status checking box for users.
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents: 7
diff changeset
235 });
da10158c6d0a add toc_correction status in books table. On TOC correction list page, providing the status checking box for users.
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents: 7
diff changeset
236
da10158c6d0a add toc_correction status in books table. On TOC correction list page, providing the status checking box for users.
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents: 7
diff changeset
237 break;
da10158c6d0a add toc_correction status in books table. On TOC correction list page, providing the status checking box for users.
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents: 7
diff changeset
238 default:
da10158c6d0a add toc_correction status in books table. On TOC correction list page, providing the status checking box for users.
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents: 7
diff changeset
239 break;
da10158c6d0a add toc_correction status in books table. On TOC correction list page, providing the status checking box for users.
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents: 7
diff changeset
240 }
da10158c6d0a add toc_correction status in books table. On TOC correction list page, providing the status checking box for users.
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents: 7
diff changeset
241
da10158c6d0a add toc_correction status in books table. On TOC correction list page, providing the status checking box for users.
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents: 7
diff changeset
242 }
da10158c6d0a add toc_correction status in books table. On TOC correction list page, providing the status checking box for users.
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents: 7
diff changeset
243
da10158c6d0a add toc_correction status in books table. On TOC correction list page, providing the status checking box for users.
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents: 7
diff changeset
244 </script>
da10158c6d0a add toc_correction status in books table. On TOC correction list page, providing the status checking box for users.
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents: 7
diff changeset
245
da10158c6d0a add toc_correction status in books table. On TOC correction list page, providing the status checking box for users.
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents: 7
diff changeset
246
da10158c6d0a add toc_correction status in books table. On TOC correction list page, providing the status checking box for users.
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents: 7
diff changeset
247
0
b12c99b7c3f0 commit for previous development
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents:
diff changeset
248 </html>
b12c99b7c3f0 commit for previous development
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents:
diff changeset
249
8
da10158c6d0a add toc_correction status in books table. On TOC correction list page, providing the status checking box for users.
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents: 7
diff changeset
250
da10158c6d0a add toc_correction status in books table. On TOC correction list page, providing the status checking box for users.
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents: 7
diff changeset
251