From 7ab4fd0a17257b52ecc4e41f2dcded2edf7baeb7 Mon Sep 17 00:00:00 2001 From: bshuttle Date: Thu, 17 Aug 2006 15:50:07 +0000 Subject: [PATCH] - don't show version info for document on normal page - highlight it on compare page - allow one-click return to normal view (since details is turned off at this point). --- templates/kt3/view_document.smarty | 77 ----------------------------------------------------------------------------- templates/ktcore/document/compare.smarty | 14 ++++++-------- templates/ktcore/document/view.smarty | 59 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 3 files changed, 65 insertions(+), 85 deletions(-) delete mode 100644 templates/kt3/view_document.smarty create mode 100644 templates/ktcore/document/view.smarty diff --git a/templates/kt3/view_document.smarty b/templates/kt3/view_document.smarty deleted file mode 100644 index 0f3e08c..0000000 --- a/templates/kt3/view_document.smarty +++ /dev/null @@ -1,77 +0,0 @@ -

{$document->getName()|escape}

-{capture assign=version} -{$document->getMajorVersionNumber()}.{$document->getMinorVersionNumber()} -{/capture} -

{i18n arg_version=$version}showing information for version -#version#{/i18n}

-{if ($document->getIsCheckedOut() == 1)} -{capture assign=checkout_user}{$sCheckoutUser}{/capture} -{if ($isCheckoutUser)} -
-

{i18n}This document is currently checked out by you. If -this is incorrect, or you no longer need to make changes to it, please cancel the checkout.{/i18n}

-
-{else} -{if ($canCheckin)} -
-

{i18n arg_checkoutuser=$checkout_user}This document is currently checked out by #checkoutuser#, but you -have sufficient priviledges to cancel their checkout.{/i18n}

-
-{else} -
-

{i18n arg_checkoutuser=$checkout_user}This document is currently checked out by #checkoutuser#. You cannot make -changes until that user checks it in. If you have urgent modifications to make, please -contact your KnowledgeTree Administrator.{/i18n}

-
-{/if} -{/if} -{/if} - -{if ($document->getImmutable() == true)} -
-

{i18n}This document is immutable. No further content changes can be -made to this document, and only administrators (in administration mode) -can make changes to the metadata or can move or delete it.{/i18n} -{if 1} - {i18n}If you require assistance from an administrator to perform one of -these tasks, use the Request Assistance action.{/i18n} -{/if} -

-
-{/if} - -{foreach item=oFieldset from=$fieldsets} -{$oFieldset->render($document_data)} -{/foreach} - - -
- -
- - Note: this is a mockup - only some would be here, obviously. -
- -
-

Information about "asd asd s"

- -
- -
\ No newline at end of file diff --git a/templates/ktcore/document/compare.smarty b/templates/ktcore/document/compare.smarty index b811dda..2b6db80 100644 --- a/templates/ktcore/document/compare.smarty +++ b/templates/ktcore/document/compare.smarty @@ -1,18 +1,16 @@

{i18n}Version Comparison{/i18n}: {$document->getName()}

+ + {capture assign=from} {$document->getMajorVersionNumber()}.{$document->getMinorVersionNumber()} ({$document->getMetadataVersion()}) {/capture} {capture assign=to} {$comparison_document->getMajorVersionNumber()}.{$comparison_document->getMinorVersionNumber()} ({$comparison_document->getMetadataVersion()}) {/capture} -

-{i18n arg_from=$from arg_to=$to}showing comparison between versions #from# and #to#{/i18n}

- - +

+{i18n arg_from=$from arg_to=$to}showing comparison between versions #from# and #to#. {/i18n} +{i18n}View current version{/i18n}. +

{if ($document_data.is_manufactured)}

{i18n}Please diff --git a/templates/ktcore/document/view.smarty b/templates/ktcore/document/view.smarty new file mode 100644 index 0000000..eebe3a7 --- /dev/null +++ b/templates/ktcore/document/view.smarty @@ -0,0 +1,59 @@ +

{$document->getName()|escape}

+ +{if ($document->getIsCheckedOut() == 1)} +{capture assign=checkout_user}{$sCheckoutUser}{/capture} +{if ($isCheckoutUser)} +
+

{i18n}This document is currently checked out by you. If +this is incorrect, or you no longer need to make changes to it, please cancel the checkout.{/i18n}

+
+{else} +{if ($canCheckin)} +
+

{i18n arg_checkoutuser=$checkout_user}This document is currently checked out by #checkoutuser#, but you +have sufficient priviledges to cancel their checkout.{/i18n}

+
+{else} +
+

{i18n arg_checkoutuser=$checkout_user}This document is currently checked out by #checkoutuser#. You cannot make +changes until that user checks it in. If you have urgent modifications to make, please +contact your KnowledgeTree Administrator.{/i18n}

+
+{/if} +{/if} +{/if} + +{if ($document->getImmutable() == true)} +
+

{i18n}This document is immutable. No further content changes can be +made to this document, and only administrators (in administration mode) +can make changes to the metadata or can move or delete it.{/i18n} +{if 1} + {i18n}If you require assistance from an administrator to perform one of +these tasks, use the Request Assistance action.{/i18n} +{/if} +

+
+{/if} + +{foreach item=oFieldset from=$fieldsets} +{$oFieldset->render($document_data)} +{/foreach} + + +
+ +

Someone please suggest some "viewlets" we can ship by default ... +this is a tad bare.

+ +{* +
+
    + {foreach from=$viewlet_info item=aInfo} +
  • {$aInfo.name}
  • + {/foreach} +
+
+*} + +
-- libgit2 0.21.4