Commit c6db58740bb05f5ba937859d1891496406c984d6
Merge branch 'edge' of git@github.com:ktgit/knowledgetree into edge
Showing
9 changed files
with
133 additions
and
58 deletions
dmsctl.vbs
| @@ -159,20 +159,20 @@ Else | @@ -159,20 +159,20 @@ Else | ||
| 159 | If (NOT isServiceStarted(svcName)) Then | 159 | If (NOT isServiceStarted(svcName)) Then |
| 160 | If (NOT startService(svcName)) Then | 160 | If (NOT startService(svcName)) Then |
| 161 | isSuccess = FALSE | 161 | isSuccess = FALSE |
| 162 | - writeLog "The " & KTOFFICE & " KnowledgeTree service could not be started. Result Code: " & lastErrorCode | 162 | + writeLog "The " & KTOFFICE & " KnowledgeTree service could not be started. Result Code: " & getServiceErrorMessage(lastErrorCode) |
| 163 | Else | 163 | Else |
| 164 | writeLog "The " & KTOFFICE & " KnowledgeTree service was successfully started" | 164 | writeLog "The " & KTOFFICE & " KnowledgeTree service was successfully started" |
| 165 | End If | 165 | End If |
| 166 | 166 | ||
| 167 | writeLog "Successfully started " & KTOFFICE | 167 | writeLog "Successfully started " & KTOFFICE |
| 168 | Else | 168 | Else |
| 169 | - writeLog KTOFFICE & " already started. Result Code: " & lastErrorCode | 169 | + writeLog KTOFFICE & " already started. Result Code: " & getServiceErrorMessage(lastErrorCode) |
| 170 | End If | 170 | End If |
| 171 | 171 | ||
| 172 | If (isSuccess) Then | 172 | If (isSuccess) Then |
| 173 | Wscript.Echo "The " & KTOFFICE & " KnowledgeTree service was successfully started" | 173 | Wscript.Echo "The " & KTOFFICE & " KnowledgeTree service was successfully started" |
| 174 | Else | 174 | Else |
| 175 | - Wscript.Echo "The " & KTOFFICE & " KnowledgeTree service could not be started. Result Code: " & lastErrorCode | 175 | + Wscript.Echo "The " & KTOFFICE & " KnowledgeTree service could not be started. Result Code: " & getServiceErrorMessage(lastErrorCode) |
| 176 | End If | 176 | End If |
| 177 | 177 | ||
| 178 | Case "scheduler" | 178 | Case "scheduler" |
| @@ -181,20 +181,20 @@ Else | @@ -181,20 +181,20 @@ Else | ||
| 181 | If (NOT isServiceStarted(svcName)) Then | 181 | If (NOT isServiceStarted(svcName)) Then |
| 182 | If (NOT startService(svcName)) Then | 182 | If (NOT startService(svcName)) Then |
| 183 | isSuccess = FALSE | 183 | isSuccess = FALSE |
| 184 | - writeLog "The " & KTSCHEDULER & " KnowledgeTree service could not be started. Result Code: " & lastErrorCode | 184 | + writeLog "The " & KTSCHEDULER & " KnowledgeTree service could not be started. Result Code: " & getServiceErrorMessage(lastErrorCode) |
| 185 | Else | 185 | Else |
| 186 | writeLog "The " & KTSCHEDULER & " KnowledgeTree service was successfully started" | 186 | writeLog "The " & KTSCHEDULER & " KnowledgeTree service was successfully started" |
| 187 | End If | 187 | End If |
| 188 | 188 | ||
| 189 | writeLog "Successfully started " & KTSCHEDULER | 189 | writeLog "Successfully started " & KTSCHEDULER |
| 190 | Else | 190 | Else |
| 191 | - writeLog KTSCHEDULER & " already started. Result Code: " & lastErrorCode | 191 | + writeLog KTSCHEDULER & " already started. Result Code: " & getServiceErrorMessage(lastErrorCode) |
| 192 | End If | 192 | End If |
| 193 | 193 | ||
| 194 | If (isSuccess) Then | 194 | If (isSuccess) Then |
| 195 | Wscript.Echo "The " & KTSCHEDULER & " KnowledgeTree service was successfully started" | 195 | Wscript.Echo "The " & KTSCHEDULER & " KnowledgeTree service was successfully started" |
| 196 | Else | 196 | Else |
| 197 | - Wscript.Echo "The " & KTSCHEDULER & " KnowledgeTree service could not be started. Result Code: " & lastErrorCode | 197 | + Wscript.Echo "The " & KTSCHEDULER & " KnowledgeTree service could not be started. Result Code: " & getServiceErrorMessage(lastErrorCode) |
| 198 | End If | 198 | End If |
| 199 | 199 | ||
| 200 | Case "lucene" | 200 | Case "lucene" |
| @@ -203,20 +203,20 @@ Else | @@ -203,20 +203,20 @@ Else | ||
| 203 | If (NOT isServiceStarted(svcName)) Then | 203 | If (NOT isServiceStarted(svcName)) Then |
| 204 | If (NOT startService(svcName)) Then | 204 | If (NOT startService(svcName)) Then |
| 205 | isSuccess = false | 205 | isSuccess = false |
| 206 | - writeLog "The " & KTLUCENE & " KnowledgeTree service could not be started. Result Code: " & lastErrorCode | 206 | + writeLog "The " & KTLUCENE & " KnowledgeTree service could not be started. Result Code: " & getServiceErrorMessage(lastErrorCode) |
| 207 | Else | 207 | Else |
| 208 | writeLog "The " & KTLUCENE & " KnowledgeTree service was successfully started" | 208 | writeLog "The " & KTLUCENE & " KnowledgeTree service was successfully started" |
| 209 | End If | 209 | End If |
| 210 | 210 | ||
| 211 | writeLog "Successfully started " & KTLUCENE | 211 | writeLog "Successfully started " & KTLUCENE |
| 212 | Else | 212 | Else |
| 213 | - writeLog KTLUCENE & " already started. Result Code: " & lastErrorCode | 213 | + writeLog KTLUCENE & " already started. Result Code: " & getServiceErrorMessage(lastErrorCode) |
| 214 | End If | 214 | End If |
| 215 | 215 | ||
| 216 | If (isSuccess) Then | 216 | If (isSuccess) Then |
| 217 | Wscript.Echo "The " & KTLUCENE & " KnowledgeTree service was successfully started" | 217 | Wscript.Echo "The " & KTLUCENE & " KnowledgeTree service was successfully started" |
| 218 | Else | 218 | Else |
| 219 | - Wscript.Echo "The " & KTLUCENE & " KnowledgeTree service could not be started. Result Code: " & lastErrorCode | 219 | + Wscript.Echo "The " & KTLUCENE & " KnowledgeTree service could not be started. Result Code: " & getServiceErrorMessage(lastErrorCode) |
| 220 | End If | 220 | End If |
| 221 | End Select | 221 | End Select |
| 222 | Else | 222 | Else |
| @@ -226,30 +226,36 @@ Else | @@ -226,30 +226,36 @@ Else | ||
| 226 | If (NOT isServiceStarted(svcName)) Then | 226 | If (NOT isServiceStarted(svcName)) Then |
| 227 | If (NOT startService(svcName)) Then | 227 | If (NOT startService(svcName)) Then |
| 228 | isSuccess = false | 228 | isSuccess = false |
| 229 | - End If | ||
| 230 | - writeLog "Successfully started " & KTOFFICE | 229 | + writeLog "Couldn't start. " & KTOFFICE & " Result Code: " & getServiceErrorMessage(lastErrorCode) |
| 231 | Else | 230 | Else |
| 232 | - writeLog KTOFFICE & " already started. Result Code: " & lastErrorCode | 231 | + writeLog "Successfully started " & KTOFFICE |
| 232 | + End If | ||
| 233 | + Else | ||
| 234 | + writeLog KTOFFICE & " already started. Result Code: " & getServiceErrorMessage(lastErrorCode) | ||
| 233 | End If | 235 | End If |
| 234 | 236 | ||
| 235 | svcName = KTSCHEDULER | 237 | svcName = KTSCHEDULER |
| 236 | If (NOT isServiceStarted(svcName)) Then | 238 | If (NOT isServiceStarted(svcName)) Then |
| 237 | If (NOT startService(svcName)) Then | 239 | If (NOT startService(svcName)) Then |
| 238 | isSuccess = false | 240 | isSuccess = false |
| 239 | - End If | ||
| 240 | - writeLog "Successfully started " & KTSCHEDULER | 241 | + writeLog "Couldn't start " & KTSCHEDULER & " Result Code: " & getServiceErrorMessage(lastErrorCode) |
| 241 | Else | 242 | Else |
| 242 | - writeLog KTSCHEDULER & " already started. Result Code: " & lastErrorCode | 243 | + writeLog "Successfully started " & KTSCHEDULER |
| 244 | + End If | ||
| 245 | + Else | ||
| 246 | + writeLog KTSCHEDULER & " already started. Result Code: " & getServiceErrorMessage(lastErrorCode) | ||
| 243 | End If | 247 | End If |
| 244 | 248 | ||
| 245 | svcName = KTLUCENE | 249 | svcName = KTLUCENE |
| 246 | If (NOT isServiceStarted(svcName)) Then | 250 | If (NOT isServiceStarted(svcName)) Then |
| 247 | If (NOT startService(svcName)) Then | 251 | If (NOT startService(svcName)) Then |
| 248 | isSuccess = false | 252 | isSuccess = false |
| 249 | - End If | ||
| 250 | - writeLog "Successfully started " & KTLUCENE | 253 | + writeLog "Couldn't start " & KTLUCENE & " Result Code: " & getServiceErrorMessage(lastErrorCode) |
| 251 | Else | 254 | Else |
| 252 | - writeLog KTLUCENE & " already started. Result Code: " & lastErrorCode | 255 | + writeLog "Successfully started " & KTLUCENE |
| 256 | + End If | ||
| 257 | + Else | ||
| 258 | + writeLog KTLUCENE & " already started. Result Code: " & getServiceErrorMessage(lastErrorCode) | ||
| 253 | End If | 259 | End If |
| 254 | 260 | ||
| 255 | If (isSuccess) Then | 261 | If (isSuccess) Then |
| @@ -267,20 +273,20 @@ Else | @@ -267,20 +273,20 @@ Else | ||
| 267 | If (isServiceStarted(svcName)) Then | 273 | If (isServiceStarted(svcName)) Then |
| 268 | If (NOT stopService(svcName)) Then | 274 | If (NOT stopService(svcName)) Then |
| 269 | isSuccess = false | 275 | isSuccess = false |
| 270 | - writeLog "The " & KTOFFICE & " KnowledgeTree service could not be stopped. Result Code: " & lastErrorCode | 276 | + writeLog "The " & KTOFFICE & " KnowledgeTree service could not be stopped. Result Code: " & getServiceErrorMessage(lastErrorCode) |
| 271 | Else | 277 | Else |
| 272 | writeLog "The " & KTOFFICE & " KnowledgeTree service was successfully stopped" | 278 | writeLog "The " & KTOFFICE & " KnowledgeTree service was successfully stopped" |
| 273 | End If | 279 | End If |
| 274 | 280 | ||
| 275 | writeLog "Successfully stopped " & KTOFFICE | 281 | writeLog "Successfully stopped " & KTOFFICE |
| 276 | Else | 282 | Else |
| 277 | - writeLog KTOFFICE & " already stopped. Result Code: " & lastErrorCode | 283 | + writeLog KTOFFICE & " already stopped. Result Code: " & getServiceErrorMessage(lastErrorCode) |
| 278 | End If | 284 | End If |
| 279 | 285 | ||
| 280 | If (isSuccess) Then | 286 | If (isSuccess) Then |
| 281 | Wscript.Echo "The " & KTOFFICE & " KnowledgeTree service was successfully stopped" | 287 | Wscript.Echo "The " & KTOFFICE & " KnowledgeTree service was successfully stopped" |
| 282 | Else | 288 | Else |
| 283 | - Wscript.Echo "The " & KTOFFICE & " KnowledgeTree service could not be stopped. Result Code: " & lastErrorCode | 289 | + Wscript.Echo "The " & KTOFFICE & " KnowledgeTree service could not be stopped. Result Code: " & getServiceErrorMessage(lastErrorCode) |
| 284 | End If | 290 | End If |
| 285 | 291 | ||
| 286 | Case "scheduler" | 292 | Case "scheduler" |
| @@ -289,20 +295,20 @@ Else | @@ -289,20 +295,20 @@ Else | ||
| 289 | If (isServiceStarted(svcName)) Then | 295 | If (isServiceStarted(svcName)) Then |
| 290 | If (NOT stopService(svcName)) Then | 296 | If (NOT stopService(svcName)) Then |
| 291 | isSuccess = false | 297 | isSuccess = false |
| 292 | - writeLog "The " & KTSCHEDULER & " KnowledgeTree service could not be stopped. Result Code: " & lastErrorCode | 298 | + writeLog "The " & KTSCHEDULER & " KnowledgeTree service could not be stopped. Result Code: " & getServiceErrorMessage(lastErrorCode) |
| 293 | Else | 299 | Else |
| 294 | writeLog "The " & KTSCHEDULER & " KnowledgeTree service was successfully stopped" | 300 | writeLog "The " & KTSCHEDULER & " KnowledgeTree service was successfully stopped" |
| 295 | End If | 301 | End If |
| 296 | 302 | ||
| 297 | writeLog "Successfully stopped " & KTSCHEDULER | 303 | writeLog "Successfully stopped " & KTSCHEDULER |
| 298 | Else | 304 | Else |
| 299 | - writeLog KTSCHEDULER & " already stopped. Result Code: " & lastErrorCode | 305 | + writeLog KTSCHEDULER & " already stopped. Result Code: " & getServiceErrorMessage(lastErrorCode) |
| 300 | End If | 306 | End If |
| 301 | 307 | ||
| 302 | If (isSuccess) Then | 308 | If (isSuccess) Then |
| 303 | Wscript.Echo "The " & KTSCHEDULER & " KnowledgeTree service was successfully stopped" | 309 | Wscript.Echo "The " & KTSCHEDULER & " KnowledgeTree service was successfully stopped" |
| 304 | Else | 310 | Else |
| 305 | - Wscript.Echo "The " & KTSCHEDULER & " KnowledgeTree service could not be stopped. Result Code: " & lastErrorCode | 311 | + Wscript.Echo "The " & KTSCHEDULER & " KnowledgeTree service could not be stopped. Result Code: " & getServiceErrorMessage(lastErrorCode) |
| 306 | End If | 312 | End If |
| 307 | 313 | ||
| 308 | Case "lucene" | 314 | Case "lucene" |
| @@ -311,20 +317,20 @@ Else | @@ -311,20 +317,20 @@ Else | ||
| 311 | If (isServiceStarted(svcName)) Then | 317 | If (isServiceStarted(svcName)) Then |
| 312 | If (NOT stopService(svcName)) Then | 318 | If (NOT stopService(svcName)) Then |
| 313 | isSuccess = false | 319 | isSuccess = false |
| 314 | - writeLog "The " & KTLUCENE & " KnowledgeTree service could not be stopped. Result Code: " & lastErrorCode | 320 | + writeLog "The " & KTLUCENE & " KnowledgeTree service could not be stopped. Result Code: " & getServiceErrorMessage(lastErrorCode) |
| 315 | Else | 321 | Else |
| 316 | writeLog "The " & KTLUCENE & " KnowledgeTree service was successfully stopped" | 322 | writeLog "The " & KTLUCENE & " KnowledgeTree service was successfully stopped" |
| 317 | End If | 323 | End If |
| 318 | 324 | ||
| 319 | writeLog "Successfully stopped " & KTLUCENE | 325 | writeLog "Successfully stopped " & KTLUCENE |
| 320 | Else | 326 | Else |
| 321 | - writeLog KTLUCENE & " already stopped. Result Code: " & lastErrorCode | 327 | + writeLog KTLUCENE & " already stopped. Result Code: " & getServiceErrorMessage(lastErrorCode) |
| 322 | End If | 328 | End If |
| 323 | 329 | ||
| 324 | If (isSuccess) Then | 330 | If (isSuccess) Then |
| 325 | Wscript.Echo "The " & KTLUCENE & " KnowledgeTree service was successfully stopped" | 331 | Wscript.Echo "The " & KTLUCENE & " KnowledgeTree service was successfully stopped" |
| 326 | Else | 332 | Else |
| 327 | - Wscript.Echo "The " & KTLUCENE & " KnowledgeTree service could not be stopped. Result Code: " & lastErrorCode | 333 | + Wscript.Echo "The " & KTLUCENE & " KnowledgeTree service could not be stopped. Result Code: " & getServiceErrorMessage(lastErrorCode) |
| 328 | End If | 334 | End If |
| 329 | End Select | 335 | End Select |
| 330 | Else | 336 | Else |
| @@ -335,30 +341,36 @@ Else | @@ -335,30 +341,36 @@ Else | ||
| 335 | If (isServiceStarted(svcName)) Then | 341 | If (isServiceStarted(svcName)) Then |
| 336 | If (NOT stopService(svcName)) Then | 342 | If (NOT stopService(svcName)) Then |
| 337 | isSuccess = false | 343 | isSuccess = false |
| 338 | - End If | ||
| 339 | - writeLog "Successfully stopped " & KTOFFICE | 344 | + writeLog "Couldn't stop." & KTOFFICE & " Result Code: " & getServiceErrorMessage(lastErrorCode) |
| 340 | Else | 345 | Else |
| 341 | - writeLog KTOFFICE & " already stopped. Result Code: " & lastErrorCode | 346 | + writeLog "Successfully stopped " & KTOFFICE |
| 347 | + End If | ||
| 348 | + Else | ||
| 349 | + writeLog KTOFFICE & " already stopped. Result Code: " & getServiceErrorMessage(lastErrorCode) | ||
| 342 | End If | 350 | End If |
| 343 | 351 | ||
| 344 | svcName = KTSCHEDULER | 352 | svcName = KTSCHEDULER |
| 345 | If (isServiceStarted(svcName)) Then | 353 | If (isServiceStarted(svcName)) Then |
| 346 | If (NOT stopService(svcName)) Then | 354 | If (NOT stopService(svcName)) Then |
| 347 | isSuccess = false | 355 | isSuccess = false |
| 348 | - End If | ||
| 349 | - writeLog "Successfully stopped " & KTSCHEDULER | 356 | + writeLog "Couldn't stop." & KTSCHEDULER & " Result Code: " & getServiceErrorMessage(lastErrorCode) |
| 350 | Else | 357 | Else |
| 351 | - writeLog KTSCHEDULER & " already stopped. Result Code: " & lastErrorCode | 358 | + writeLog "Successfully stopped " & KTSCHEDULER |
| 359 | + End If | ||
| 360 | + Else | ||
| 361 | + writeLog KTSCHEDULER & " already stopped. Result Code: " & getServiceErrorMessage(lastErrorCode) | ||
| 352 | End If | 362 | End If |
| 353 | 363 | ||
| 354 | svcName = KTLUCENE | 364 | svcName = KTLUCENE |
| 355 | If (isServiceStarted(svcName)) Then | 365 | If (isServiceStarted(svcName)) Then |
| 356 | If (NOT stopService(svcName)) Then | 366 | If (NOT stopService(svcName)) Then |
| 357 | isSuccess = false | 367 | isSuccess = false |
| 358 | - End If | ||
| 359 | - writeLog "Successfully stopped " & KTLUCENE | 368 | + writeLog "Couldn't stop." & KTLUCENE & " Result Code: " & getServiceErrorMessage(lastErrorCode) |
| 360 | Else | 369 | Else |
| 361 | - writeLog KTLUCENE & " already stopped. Result Code: " & lastErrorCode | 370 | + writeLog "Successfully stopped " & KTLUCENE |
| 371 | + End If | ||
| 372 | + Else | ||
| 373 | + writeLog KTLUCENE & " already stopped. Result Code: " & getServiceErrorMessage(lastErrorCode) | ||
| 362 | End If | 374 | End If |
| 363 | 375 | ||
| 364 | If (isSuccess) Then | 376 | If (isSuccess) Then |
| @@ -669,3 +681,59 @@ Public Sub writeLog(ByVal strMessage) | @@ -669,3 +681,59 @@ Public Sub writeLog(ByVal strMessage) | ||
| 669 | objTextFile.Close | 681 | objTextFile.Close |
| 670 | End Sub | 682 | End Sub |
| 671 | 683 | ||
| 684 | +Public Function getServiceErrorMessage(ByVal errCode) | ||
| 685 | + Select Case errCode | ||
| 686 | + Case SVC_SUCCESS | ||
| 687 | + getServiceErrorMessage = "Success" | ||
| 688 | + Case SVC_NOT_SUPPORTED | ||
| 689 | + getServiceErrorMessage = "Not Supported" | ||
| 690 | + Case SVC_ACCESS_DENIED | ||
| 691 | + getServiceErrorMessage = "Access Denied" | ||
| 692 | + Case SVC_DEPENDENT_SERVICES_RUNNING | ||
| 693 | + getServiceErrorMessage = "Dependent Services Running" | ||
| 694 | + Case SVC_INVALID_SERVICE_CONTROL | ||
| 695 | + getServiceErrorMessage = "Invalid Service Control" | ||
| 696 | + Case SVC_SERVICE_CANNOT_ACCEPT_CONTROL | ||
| 697 | + getServiceErrorMessage = "Service Cannot Accept Control" | ||
| 698 | + Case SVC_SERVICE_NOT_ACTIVE | ||
| 699 | + getServiceErrorMessage = "Service Not Active" | ||
| 700 | + Case SVC_SERVICE_REQUEST_TIMEOUT | ||
| 701 | + getServiceErrorMessage = "Service Request Timeout" | ||
| 702 | + Case SVC_UNKNOWN_FAILURE | ||
| 703 | + getServiceErrorMessage = "Unknown Failure" | ||
| 704 | + Case SVC_PATH_NOT_FOUND | ||
| 705 | + getServiceErrorMessage = "Path Not Found" | ||
| 706 | + Case SVC_SERVICE_ALREADY_RUNNING | ||
| 707 | + getServiceErrorMessage = "Service Already Running" | ||
| 708 | + Case SVC_SERVICE_DATABASE_LOCKED | ||
| 709 | + getServiceErrorMessage = "Service Database Locked" | ||
| 710 | + Case SVC_SERVICE_DEPENDENCY_DELETED | ||
| 711 | + getServiceErrorMessage = "Service Dependency Deleted" | ||
| 712 | + Case SVC_SERVICE_DEPENDENCY_FAILURE | ||
| 713 | + getServiceErrorMessage = "Service Dependency Failure" | ||
| 714 | + Case SVC_SERVICE_DISABLED | ||
| 715 | + getServiceErrorMessage = "Service Disabled" | ||
| 716 | + Case SVC_SERVICE_LOGON_FAILURE | ||
| 717 | + getServiceErrorMessage = "Service Logon Failure" | ||
| 718 | + Case SVC_SERVICE_MARKED_FOR_DELETION | ||
| 719 | + getServiceErrorMessage = "Service Marked For Deletion" | ||
| 720 | + Case SVC_SERVICES_NO_THREAD | ||
| 721 | + getServiceErrorMessage = "Service No Thread" | ||
| 722 | + Case SVC_STATUS_CIRCULAR_DEPENDENCY | ||
| 723 | + getServiceErrorMessage = "Status Circular Dependency" | ||
| 724 | + Case SVC_STATUS_DUPLICATE_NAME | ||
| 725 | + getServiceErrorMessage = "Status Duplicate Name" | ||
| 726 | + Case SVC_INVALID_NAME | ||
| 727 | + getServiceErrorMessage = "Status Invalid Name" | ||
| 728 | + Case SVC_STATUS_INVALID_PARAMETER | ||
| 729 | + getServiceErrorMessage = "Status Invalid Parameter" | ||
| 730 | + Case SVC_INVALID_SERVICES_ACCOUNT | ||
| 731 | + getServiceErrorMessage = "Status Invalid Service Account" | ||
| 732 | + Case SVC_STATUS_SERVICE_EXISTS | ||
| 733 | + getServiceErrorMessage = "Status Service Exists" | ||
| 734 | + Case SVC_SERVICE_ALREADY_PAUSED | ||
| 735 | + getServiceErrorMessage = "Service Already Paused" | ||
| 736 | + Case Else | ||
| 737 | + getServiceErrorMessage = "Unknown Failure" | ||
| 738 | + End Select | ||
| 739 | +End Function |
plugins/ktstandard/documentpreview/documentPreview.php
| @@ -176,7 +176,11 @@ class DocumentPreview { | @@ -176,7 +176,11 @@ class DocumentPreview { | ||
| 176 | 176 | ||
| 177 | $sInfo = $this->getMetadata(); | 177 | $sInfo = $this->getMetadata(); |
| 178 | 178 | ||
| 179 | - return '<div id="preview" class="preview" onclick="javascript: destroyPanel();">'.$sInfo.'</div>'; | 179 | + $sInfo = '<div id="preview" class="preview" onclick="javascript: destroyPanel();">'.$sInfo.'</div>'; |
| 180 | + | ||
| 181 | + $sInfo .= $this->getThumbnail(); | ||
| 182 | + | ||
| 183 | + return $sInfo; | ||
| 180 | } | 184 | } |
| 181 | 185 | ||
| 182 | /** | 186 | /** |
| @@ -280,8 +284,6 @@ class DocumentPreview { | @@ -280,8 +284,6 @@ class DocumentPreview { | ||
| 280 | $sInfo .= "<tr><td>{$sIdLb}</td><td><b>{$sId}</b></td></tr>"; | 284 | $sInfo .= "<tr><td>{$sIdLb}</td><td><b>{$sId}</b></td></tr>"; |
| 281 | $sInfo .= " </table></div>"; | 285 | $sInfo .= " </table></div>"; |
| 282 | 286 | ||
| 283 | - $sInfo .= $this->getThumbnail(); | ||
| 284 | - | ||
| 285 | return $sInfo; | 287 | return $sInfo; |
| 286 | } | 288 | } |
| 287 | 289 |
setup/migrate/steps/migrateDatabase.php
| @@ -171,7 +171,7 @@ class migrateDatabase extends Step | @@ -171,7 +171,7 @@ class migrateDatabase extends Step | ||
| 171 | $cmd = $exe.' -u"'.$dbAdminUser.'" -p"'.$dbAdminPass.'" --port="'.$port.'" '.$dbName.' > '.$sqlFile; | 171 | $cmd = $exe.' -u"'.$dbAdminUser.'" -p"'.$dbAdminPass.'" --port="'.$port.'" '.$dbName.' > '.$sqlFile; |
| 172 | if($noFile) { | 172 | if($noFile) { |
| 173 | $this->error[]['error'] = "The KnowledgeTree Setup Wizard was unable to connect to your KnowledgeTree 3.6.1 database."; | 173 | $this->error[]['error'] = "The KnowledgeTree Setup Wizard was unable to connect to your KnowledgeTree 3.6.1 database."; |
| 174 | - $this->error[]['msg'] = "Please ensure that all KnowledgeTree Services are running."; | 174 | + $this->error[]['msg'] = "Please ensure that your KnowledgeTree Mysql service is running."; |
| 175 | $this->error[]['cmd'] = "Click <b>Next</b> after resolving the above errors."; | 175 | $this->error[]['cmd'] = "Click <b>Next</b> after resolving the above errors."; |
| 176 | $this->temp_variables['manual_export'] = ""; | 176 | $this->temp_variables['manual_export'] = ""; |
| 177 | } else { | 177 | } else { |
setup/upgrade/steps/upgradeBackup.php
| @@ -208,7 +208,7 @@ class upgradeBackup extends Step { | @@ -208,7 +208,7 @@ class upgradeBackup extends Step { | ||
| 208 | $prefix = ''; | 208 | $prefix = ''; |
| 209 | if (!WINDOWS_OS) | 209 | if (!WINDOWS_OS) |
| 210 | { | 210 | { |
| 211 | - $prefix .= "./"; | 211 | + $prefix .= "";//$prefix .= "./"; |
| 212 | } | 212 | } |
| 213 | 213 | ||
| 214 | if (@stat($dbSocket) !== false) | 214 | if (@stat($dbSocket) !== false) |
setup/upgrade/templates/complete.tpl
| @@ -20,7 +20,8 @@ | @@ -20,7 +20,8 @@ | ||
| 20 | <br/> | 20 | <br/> |
| 21 | <br/> | 21 | <br/> |
| 22 | <?php } else { ?> | 22 | <?php } else { ?> |
| 23 | - To start the services, execute the dmsctl.bat batch file in the KnowledgeTree directory from a command prompt, run as administrator. | 23 | + To start the services, using the instructions below: |
| 24 | +<!-- execute the dmsctl.bat batch file in the KnowledgeTree directory from a command prompt, run as administrator.--> | ||
| 24 | <br/> | 25 | <br/> |
| 25 | <br/> | 26 | <br/> |
| 26 | <?php } ?> | 27 | <?php } ?> |
| @@ -30,11 +31,11 @@ | @@ -30,11 +31,11 @@ | ||
| 30 | <br/> | 31 | <br/> |
| 31 | [START MENU] => [Programs] => [KnowledgeTree 3.7.x] => [services] | 32 | [START MENU] => [Programs] => [KnowledgeTree 3.7.x] => [services] |
| 32 | <br/> | 33 | <br/> |
| 33 | - Click [Install Services] | 34 | + Right-Click and run [Install Services] as administrator |
| 34 | <br/> | 35 | <br/> |
| 35 | [START MENU] => [Programs] => [KnowledgeTree 3.7.x] => [services] | 36 | [START MENU] => [Programs] => [KnowledgeTree 3.7.x] => [services] |
| 36 | <br/> | 37 | <br/> |
| 37 | - Click [Start Services] | 38 | + Right-Click and run [Start Services] as administrator |
| 38 | <br/> | 39 | <br/> |
| 39 | <br/> | 40 | <br/> |
| 40 | <b>Alternatively:</b> | 41 | <b>Alternatively:</b> |
setup/wizard/installUtil.php
| @@ -1061,9 +1061,6 @@ class InstallUtil { | @@ -1061,9 +1061,6 @@ class InstallUtil { | ||
| 1061 | 1061 | ||
| 1062 | // {{{ copyDirectory | 1062 | // {{{ copyDirectory |
| 1063 | function copyDirectory($sSrc, $sDst, $bMove = false) { | 1063 | function copyDirectory($sSrc, $sDst, $bMove = false) { |
| 1064 | - if (file_exists($sDst)) { | ||
| 1065 | - return false; //PEAR::raiseError(_kt("Destination directory already exists.")); | ||
| 1066 | - } | ||
| 1067 | if (!WINDOWS_OS) { | 1064 | if (!WINDOWS_OS) { |
| 1068 | if ($bMove && file_exists('/bin/mv')) { | 1065 | if ($bMove && file_exists('/bin/mv')) { |
| 1069 | $this->pexec(array('/bin/mv', $sSrc, $sDst)); | 1066 | $this->pexec(array('/bin/mv', $sSrc, $sDst)); |
| @@ -1081,15 +1078,13 @@ class InstallUtil { | @@ -1081,15 +1078,13 @@ class InstallUtil { | ||
| 1081 | if ($hSrc === false) { | 1078 | if ($hSrc === false) { |
| 1082 | return false; //PEAR::raiseError(sprintf(_kt("Could not open source directory: %s"), $sSrc)); | 1079 | return false; //PEAR::raiseError(sprintf(_kt("Could not open source directory: %s"), $sSrc)); |
| 1083 | } | 1080 | } |
| 1084 | - if (@mkdir($sDst, 0777) === false) { | ||
| 1085 | - return false; //PEAR::raiseError(sprintf(_kt("Could not create destination directory: %s"), $sDst)); | ||
| 1086 | - } | 1081 | + @mkdir($sDst, 0777); |
| 1087 | while (($sFilename = readdir($hSrc)) !== false) { | 1082 | while (($sFilename = readdir($hSrc)) !== false) { |
| 1088 | if (in_array($sFilename, array('.', '..'))) { | 1083 | if (in_array($sFilename, array('.', '..'))) { |
| 1089 | continue; | 1084 | continue; |
| 1090 | } | 1085 | } |
| 1091 | - $sOldFile = sprintf("%s/%s", $sSrc, $sFilename); | ||
| 1092 | - $sNewFile = sprintf("%s/%s", $sDst, $sFilename); | 1086 | + $sOldFile = sprintf("%s" . DS . "%s", $sSrc, $sFilename); |
| 1087 | + $sNewFile = sprintf("%s" . DS . "%s", $sDst, $sFilename); | ||
| 1093 | if (is_dir($sOldFile)) { | 1088 | if (is_dir($sOldFile)) { |
| 1094 | $this->copyDirectory($sOldFile, $sNewFile, $bMove); | 1089 | $this->copyDirectory($sOldFile, $sNewFile, $bMove); |
| 1095 | continue; | 1090 | continue; |
setup/wizard/resources/css/wizard.css
| @@ -64,7 +64,7 @@ select { | @@ -64,7 +64,7 @@ select { | ||
| 64 | /* *** Layout Styles *** */ | 64 | /* *** Layout Styles *** */ |
| 65 | 65 | ||
| 66 | #wrapper { | 66 | #wrapper { |
| 67 | - background: white; min-height:410px; | 67 | + background: white; min-height:500px; |
| 68 | } | 68 | } |
| 69 | 69 | ||
| 70 | #outer-wrapper { | 70 | #outer-wrapper { |
| @@ -87,12 +87,12 @@ select { | @@ -87,12 +87,12 @@ select { | ||
| 87 | #container { | 87 | #container { |
| 88 | background: white url("../graphics/left.png") repeat-y left; | 88 | background: white url("../graphics/left.png") repeat-y left; |
| 89 | overflow:auto; | 89 | overflow:auto; |
| 90 | - /*min-height:630px;height:410px;*/min-height:410px; | 90 | + /*min-height:630px;height:410px;*/min-height:500px; |
| 91 | } | 91 | } |
| 92 | 92 | ||
| 93 | #content { | 93 | #content { |
| 94 | margin-left: 220px; | 94 | margin-left: 220px; |
| 95 | - /*height:515px;*/height:400px; | 95 | + /*height:515px;*/height:500px; |
| 96 | } | 96 | } |
| 97 | 97 | ||
| 98 | #content_container { | 98 | #content_container { |
setup/wizard/steps/install.php
| @@ -104,6 +104,14 @@ class install extends step | @@ -104,6 +104,14 @@ class install extends step | ||
| 104 | public function installStep() | 104 | public function installStep() |
| 105 | { | 105 | { |
| 106 | $this->callHome(); | 106 | $this->callHome(); |
| 107 | + // copy indexing directory if this is a migration | ||
| 108 | + $this->setDataFromSession(); | ||
| 109 | + if ($this->util->isMigration()) { | ||
| 110 | + $migrateSessionData = $this->getDataFromPackage('migrate', 'installation'); | ||
| 111 | + $src = $migrateSessionData['location'] . DS . 'var' . DS . 'indexes'; | ||
| 112 | + $dst = SYSTEM_DIR . 'var' . DS . 'indexes'; | ||
| 113 | + $this->util->copyDirectory($src, $dst); | ||
| 114 | + } | ||
| 107 | } | 115 | } |
| 108 | 116 | ||
| 109 | /** | 117 | /** |
setup/wizard/templates/complete.tpl
| @@ -23,7 +23,8 @@ | @@ -23,7 +23,8 @@ | ||
| 23 | <br/> | 23 | <br/> |
| 24 | <br/> | 24 | <br/> |
| 25 | <?php } else { ?> | 25 | <?php } else { ?> |
| 26 | - To start the services, execute the dmsctl.bat batch file in the KnowledgeTree directory from a command prompt, run as administrator. | 26 | + To start the services, using the instructions below: |
| 27 | +<!-- execute the dmsctl.bat batch file in the KnowledgeTree directory from a command prompt, run as administrator.--> | ||
| 27 | <br/> | 28 | <br/> |
| 28 | <br/> | 29 | <br/> |
| 29 | <?php } ?> | 30 | <?php } ?> |
| @@ -33,11 +34,11 @@ | @@ -33,11 +34,11 @@ | ||
| 33 | <br/> | 34 | <br/> |
| 34 | [START MENU] => [Programs] => [KnowledgeTree 3.7.x] => [services] | 35 | [START MENU] => [Programs] => [KnowledgeTree 3.7.x] => [services] |
| 35 | <br/> | 36 | <br/> |
| 36 | - Click [Install Services] | 37 | + Right-Click and run [Install Services] as administrator |
| 37 | <br/> | 38 | <br/> |
| 38 | [START MENU] => [Programs] => [KnowledgeTree 3.7.x] => [services] | 39 | [START MENU] => [Programs] => [KnowledgeTree 3.7.x] => [services] |
| 39 | <br/> | 40 | <br/> |
| 40 | - Click [Start Services] | 41 | + Right-Click and run [Start Services] as administrator |
| 41 | <br/> | 42 | <br/> |
| 42 | <br/> | 43 | <br/> |
| 43 | <b>Alternatively:</b> | 44 | <b>Alternatively:</b> |