Re: Bug 1852: support creation of xmpp: field types in OGo
Helge Hess <[email protected]> Sun, 25 Mar 2007 12:52:05 +0200
| Newsgroups | gmane.comp.cms.opengroupware.discuss.general |
|---|---|
| Message-ID | <[email protected]> |
On Mar 25, 2007, at 12:28, Sebastian Reitenbach wrote:
>> 20 would mean: URL which points to a chat identity (in every other
>> way it would be a regular URL field anyways? [do we have a URL
>> type?? ;-)])
>
> so I changed the patch to be able to define arbitrary link types via
> OGoExtendedUrlAttributesMap Default, for example:
>
> OGoExtendedUrlAttributesMap = (
> {
> type = 3;
> urlpattern = "mailto:%@";
> },
> {
> type = 4;
> urlpattern = "%@";
> },
> {
> type = 20;
> urlpattern = "xmpp:%@";
> },
> {
> type = 21;
> urlpattern = "fish://%@";
> },
> {
> type = 22;
> urlpattern = "imaps://%@";
> }
> );
>
>
> SkyPublicExtendedPersonAttributes = (
> {
> key = jabberid;
> target = "_self";
> type = 20;
> },
No, I don't see why we need that many different type codes. Eg the
imaps and fish pattern are useless because the value still needs to
be structure.
A new type only makes sense when the semantic information would be
useful. In all other cases its the task of the UI to process URLs in
a better way.
Wrt to URL patterns, those should be but in the attribute
configuration! Eg:
{
key = jabberid;
target = "_self";
type = 20;
urlpattern = "xmpp:%@";
},
and
{
key = aimid;
target = "_self";
type = 20;
urlpattern = "aim:%@";
},
'20' would just mean its an IM address (having an own type for IM
might make sense, though I'm not entirely convinced of that either
since a generic URL UI can easily detect that a URL is a chat one).
Though I also dislike the urlpattern in this case. The database
should store the full URL, not just the value the user entered. Maybe
'defaultUrlScheme' might make sense (the editor would check whether
the value entered by the user has a scheme and if not, would add the
default scheme).
Thinking about it, for the specific case of IM addresses we should
really use the Outlook field in the way Microsoft uses it. Its sounds
kinda stupid to reinvent the wheel here (how long before people ask
about having IM addresses in Outlook/Evolution ...)
Hm, all that doesn't look very appealing to me. The patches are not
very dangerous and are great fast hacks, but IMHO the issue is not
thought out well enough (and I won't have the time to do it right now).
So feel free to apply them, but I reserve the right to drop support
for that in future versions of OGo ;-)
Thanks,
Helge
--
Helge Hess
http://www.helgehess.eu/
--
OpenGroupware.org Discussion [email protected]
http://mail.opengroupware.org/mailman/listinfo/discuss