Improve message about not having any WoT identities.
authorDavid ‘Bombe’ Roden <bombe@pterodactylus.net>
Fri, 5 Nov 2010 14:25:08 +0000 (15:25 +0100)
committerDavid ‘Bombe’ Roden <bombe@pterodactylus.net>
Fri, 5 Nov 2010 14:25:08 +0000 (15:25 +0100)
src/main/resources/i18n/sone.en.properties
src/main/resources/templates/include/createSone.html

index 7402be0..a665bb4 100644 (file)
@@ -156,6 +156,7 @@ Page.Tail.Text.KeyOfSone=Key of this Sone (give this to other people):
 View.CreateSone.Text.WotIdentityRequired=To create a Sone you need an identity from the {link}Web of Trust plugin{/link}.
 View.CreateSone.Select.Default=Select an identity
 View.CreateSone.Text.NoIdentities=You do not have any Web of Trust identities. Please head over to the {link}Web of Trust plugin{/link} and create an identity.
+View.CreateSone.Text.NoNonSoneIdentities=You do not have any Web of Trust identities that are not already a Sone. Please head over to the {link}Web of Trust plugin{/link} and create an identity.
 View.CreateSone.Button.Create=Create Sone
 View.CreateSone.Text.Error.NoIdentity=You have not selected an identity.
 
index ebd204e..30ce0f7 100644 (file)
@@ -22,5 +22,9 @@
 
        </form>
 <%else>
-       <p><%= View.CreateSone.Text.NoIdentities|l10n|html|replace needle="{link}" replacement='<a href="/WoT/OwnIdentities">'|replace needle="{/link}" replacement="</a>"></p>
+       <%if !sones.empty>
+               <p><%= View.CreateSone.Text.NoNonSoneIdentities|l10n|html|replace needle="{link}" replacement='<a href="/WoT/OwnIdentities">'|replace needle="{/link}" replacement="</a>"></p>
+       <%else>
+               <p><%= View.CreateSone.Text.NoIdentities|l10n|html|replace needle="{link}" replacement='<a href="/WoT/OwnIdentities">'|replace needle="{/link}" replacement="</a>"></p>
+       <%/if>
 <%/if>