Index: branches/liquidthreads/maintenance/postgres/compare_schemas.pl |
— | — | @@ -155,7 +155,7 @@ |
156 | 156 | ); |
157 | 157 | $dtype = qr{($dtype)}; |
158 | 158 | my %new; |
159 | | -my ($infunction,$inview,$inrule) = (0,0,0); |
| 159 | +my ($infunction,$inview,$inrule,$lastcomma) = (0,0,0,0); |
160 | 160 | seek $newfh, 0, 0; |
161 | 161 | while (<$newfh>) { |
162 | 162 | next if /^\s*\-\-/ or /^\s*$/; |
— | — | @@ -190,11 +190,19 @@ |
191 | 191 | if (/^CREATE TABLE "?(\w+)"? \($/) { |
192 | 192 | $table = $1; |
193 | 193 | $new{$table}{name}=$table; |
| 194 | + $lastcomma = 1; |
194 | 195 | } |
195 | 196 | elsif (/^\);$/) { |
| 197 | + if ($lastcomma) { |
| 198 | + warn "Stray comma before line $.\n"; |
| 199 | + } |
196 | 200 | } |
197 | | - elsif (/^ (\w+) +$dtype/) { |
| 201 | + elsif (/^ (\w+) +$dtype.*?(,?)(?: --.*)?$/) { |
198 | 202 | $new{$table}{column}{$1} = $2; |
| 203 | + if (!$lastcomma) { |
| 204 | + print "Missing comma before line $. of $new\n"; |
| 205 | + } |
| 206 | + $lastcomma = $3 ? 1 : 0; |
199 | 207 | } |
200 | 208 | else { |
201 | 209 | die "Cannot parse line $. of $new:\n$_\n"; |
Index: branches/liquidthreads/maintenance/language/messages.inc |
— | — | @@ -1021,6 +1021,7 @@ |
1022 | 1022 | 'specialloguserlabel', |
1023 | 1023 | 'speciallogtitlelabel', |
1024 | 1024 | 'log', |
| 1025 | + 'all-logs-page', |
1025 | 1026 | 'log-search-legend', |
1026 | 1027 | 'log-search-submit', |
1027 | 1028 | 'alllogstext', |
Index: branches/liquidthreads/includes/api/ApiQueryLinks.php |
— | — | @@ -73,6 +73,8 @@ |
74 | 74 | if ($this->getPageSet()->getGoodTitleCount() == 0) |
75 | 75 | return; // nothing to do |
76 | 76 | |
| 77 | + $params = $this->extractRequestParams(); |
| 78 | + |
77 | 79 | $this->addFields(array ( |
78 | 80 | $this->prefix . '_from pl_from', |
79 | 81 | $this->prefix . '_namespace pl_namespace', |
— | — | @@ -81,6 +83,7 @@ |
82 | 84 | |
83 | 85 | $this->addTables($this->table); |
84 | 86 | $this->addWhereFld($this->prefix . '_from', array_keys($this->getPageSet()->getGoodTitles())); |
| 87 | + $this->addWhereFld($this->prefix . '_namespace', $params['namespace']); |
85 | 88 | $this->addOption('ORDER BY', str_replace('pl_', $this->prefix . '_', 'pl_from, pl_namespace, pl_title')); |
86 | 89 | |
87 | 90 | $db = $this->getDB(); |
— | — | @@ -131,6 +134,23 @@ |
132 | 135 | $data); |
133 | 136 | } |
134 | 137 | |
| 138 | + protected function getAllowedParams() |
| 139 | + { |
| 140 | + return array( |
| 141 | + 'namespace' => array( |
| 142 | + ApiBase :: PARAM_TYPE => 'namespace', |
| 143 | + ApiBase :: PARAM_ISMULTI => true |
| 144 | + ) |
| 145 | + ); |
| 146 | + } |
| 147 | + |
| 148 | + protected function getParamDescription() |
| 149 | + { |
| 150 | + return array( |
| 151 | + 'namespace' => "Show {$this->description}s in this namespace(s) only" |
| 152 | + ); |
| 153 | + } |
| 154 | + |
135 | 155 | protected function getDescription() { |
136 | 156 | return "Returns all {$this->description}s from the given page(s)"; |
137 | 157 | } |
— | — | @@ -140,7 +160,9 @@ |
141 | 161 | "Get {$this->description}s from the [[Main Page]]:", |
142 | 162 | " api.php?action=query&prop={$this->getModuleName()}&titles=Main%20Page", |
143 | 163 | "Get information about the {$this->description} pages in the [[Main Page]]:", |
144 | | - " api.php?action=query&generator={$this->getModuleName()}&titles=Main%20Page&prop=info" |
| 164 | + " api.php?action=query&generator={$this->getModuleName()}&titles=Main%20Page&prop=info", |
| 165 | + "Get {$this->description}s from the Main Page in the User and Template namespaces:", |
| 166 | + " api.php?action=query&prop={$this->getModuleName()}&titles=Main%20Page&{$this->prefix}namespace=2|10" |
145 | 167 | ); |
146 | 168 | } |
147 | 169 | |
Index: branches/liquidthreads/includes/api/ApiQueryWatchlist.php |
— | — | @@ -62,9 +62,7 @@ |
63 | 63 | $allrev = $start = $end = $namespace = $dir = $limit = $prop = null; |
64 | 64 | extract($this->extractRequestParams()); |
65 | 65 | |
66 | | - if (!is_null($prop)) { |
67 | | - if (!is_null($resultPageSet)) |
68 | | - $this->dieUsage($this->encodeParamName('prop') . ' parameter may not be used in a generator', 'params'); |
| 66 | + if (!is_null($prop) && is_null($resultPageSet)) { |
69 | 67 | |
70 | 68 | $prop = array_flip($prop); |
71 | 69 | |
Index: branches/liquidthreads/languages/messages/MessagesHe.php |
— | — | @@ -1242,6 +1242,7 @@ |
1243 | 1243 | 'specialloguserlabel' => 'משתמש:', |
1244 | 1244 | 'speciallogtitlelabel' => 'כותרת:', |
1245 | 1245 | 'log' => 'יומנים', |
| 1246 | +'all-logs-page' => 'כל היומנים', |
1246 | 1247 | 'log-search-legend' => 'חיפוש יומנים', |
1247 | 1248 | 'log-search-submit' => 'עבור', |
1248 | 1249 | 'alllogstext' => 'תצוגה משולבת של כל סוגי היומנים הזמינים ב{{grammar:תחילית|{{SITENAME}}}}. |
Index: branches/liquidthreads/languages/messages/MessagesDa.php |
— | — | @@ -701,7 +701,7 @@ |
702 | 702 | |
703 | 703 | # History pages |
704 | 704 | 'revhistory' => 'Versionshistorik', |
705 | | -'viewpagelogs' => 'Vis logs for denne side', |
| 705 | +'viewpagelogs' => 'Vis loglister for denne side', |
706 | 706 | 'nohistory' => 'Der er ingen versionshistorik for denne side.', |
707 | 707 | 'revnotfound' => 'Versionen er ikke fundet', |
708 | 708 | 'revnotfoundtext' => 'Den gamle version af den side du spurgte efter kan |
— | — | @@ -1224,7 +1224,8 @@ |
1225 | 1225 | # Special:Log |
1226 | 1226 | 'specialloguserlabel' => 'Bruger:', |
1227 | 1227 | 'speciallogtitlelabel' => 'Titel:', |
1228 | | -'log' => 'Logs', |
| 1228 | +'log' => 'Loglister', |
| 1229 | +'all-logs-page' => 'Alle loglister', |
1229 | 1230 | 'log-search-legend' => 'Gennemsøg logs', |
1230 | 1231 | 'log-search-submit' => 'Søg', |
1231 | 1232 | 'alllogstext' => 'Samlet visning af oplægningslog, sletningslog, blokeringslog, bureaukratlog og listen over beskyttede sider. Du kan sortere i visningen ved at vælge type, brugernavn og/eller en udvalgt side.', |
Property changes on: branches/liquidthreads |
___________________________________________________________________ |
Modified: svnmerge-integrated |
1232 | 1233 | - /trunk/phase3:1-23037 |
1233 | 1234 | + /trunk/phase3:1-23049 |