Zotonic
Zotonic
zotonic@conference.zotonic.com
Friday, 10 February 2012< ^ >
arjan has set the subject to: Zotonic - the Erlang CMS
Room Configuration

GMT+1
[07:12:41] maas.maarten.zeeman joins the room
[08:34:07] arjan joins the room
[09:29:53] vio42 joins the room
[09:29:58] vio42 leaves the room
[09:44:14] arjan leaves the room
[10:16:31] arjan joins the room
[10:39:20] Yves joins the room
[10:42:39] Yves leaves the room
[10:43:03] Yves joins the room
[10:43:58] <Yves> Hi everybody. The question of the day: how it is possible (if possible) to create a collection of images, then assign this collection to any authorized user, created before by the site admin ? By the way, any registered user (e.g. a "sub-admin") can do this manipulation out-of-the-box ?
[10:46:27] Michael Connors joins the room
[10:47:32] <Michael Connors> Goedemorgen
[10:52:40] <arjan> hi
[10:52:47] <arjan> Yves: what do you mean by "assign"?
[10:55:00] <Yves> I means a one-to-one link: one user is linked to one collection of media (images) and only this user is authorized to see this collection.
[10:55:59] <Yves> The user is logged trough a login password mechanism.
[10:57:50] <Yves> For example: the web site creator/author create a list of authorized users. Then one or more collection(s) of media. A collection is attached to one user (may be in the future, a collection can be linked to one or more users).
[11:05:38] <arjan> ok
[11:06:00] <arjan> yes that is possible but it requires making your own access control mechanism
[11:10:08] <Yves> ok. Thanks.
[11:11:31] <arjan> look in mod_acl_simple_roles.erl,
[11:11:39] <arjan> you can create your own observe_acl_is_allowed function
[11:12:00] <arjan> observe_acl_is_allowed(#acl_is_allowed{action=view, object=Id}, Context) when is_integer(Id)
[11:12:10] <arjan> for instance for the "view" action
[11:13:45] <Yves> ok. usefull information… I try to do this…
[11:18:37] <Michael Connors> Hi Arjan, sorry to disappear suddenly yesterday. Did you have a look at that stuff I pushed? Any ideas about what I could do with that chunk of javascript?
[11:19:49] <Michael Connors> Also, is it possible to write validators without touching livevalidation.js? It would be nice to be able to create validators as part of a module.
[11:22:39] <arjan> I looked at it
[11:22:55] <arjan> indeed it would be nice to make the validator architecture more modularized
[11:22:59] <arjan> in the javascript
[11:23:18] <arjan> currently it is not possible
[11:23:48] <arjan> also, why don't you use javascript's Date class to do the validation?
[11:23:56] <arjan> Saves you probably quite a bit of trouble
[11:24:25] <Michael Connors> hmm, to be honest, I just didn't think of it.
[11:25:38] <Michael Connors> Although I would still have to check the format, and the separator
[11:26:18] <Michael Connors> because I need to know them for the backend part
[11:27:36] <arjan> true
[11:27:57] <arjan> and converting it into a {Y,M,D} tuple\
[11:28:00] <arjan> probably
[11:31:23] <Michael Connors> I could replace line 54 to 66 with something that uses dateformat though
[11:31:36] <Michael Connors> sorry, uses Date
[11:33:21] <Michael Connors> that will also mean lines 1-15 will be redundant
[11:33:57] <Michael Connors> so it will be a much smaller after, perhaps it could go into livevalidation.js after that
[11:34:04] <arjan> :)
[11:42:43] maas.maarten.zeeman leaves the room
[12:02:33] maas.maarten.zeeman joins the room
[12:06:46] Michael Connors leaves the room
[12:07:18] Michael Connors joins the room
[12:20:06] <Michael Connors> d = new Date(1982, 05, 28); == Mon Jun 28 1982 00:00:00 GMT+0200 (CEST)
[12:20:23] <Michael Connors> Does anyone know what is happening here?
[12:20:52] <Michael Connors> perhaps I should lay off the prescription drugs
[12:25:53] <Michael Connors> the months are zero based in javascript??
[12:25:58] <Michael Connors> mental
[12:33:03] <arjan> yep
[12:38:54] <Michael Connors> also, it is very flexible, returns a valid date as long as all the fields are numbers
[13:12:44] <Michael Connors> I have rewritten and pushed that now
[13:58:03] <Michael Connors> and now rewritten with all teh code in livevalidation-1.3.js
[14:03:27] <arjan> nice
[14:03:36] <Michael Connors> perhaps a range check would be useful as well
[14:03:37] <arjan> sorry I'm pretty busy but I'll have a look again soon
[14:03:47] <Michael Connors> no hassle
[14:03:53] <Michael Connors> no hurry
[14:12:27] Juan Jose Comellas joins the room
[14:12:33] Juan Jose Comellas leaves the room
[14:27:32] Yves leaves the room
[14:27:50] Yves joins the room
[15:15:31] Michael Connors leaves the room
[15:46:22] Michael Connors joins the room
[15:48:18] Michael Connors leaves the room
[15:54:06] maas.maarten.zeeman leaves the room
[16:11:40] maas.maarten.zeeman joins the room
[16:25:08] Yves leaves the room
[17:32:24] Michael Connors joins the room
[17:49:15] Michael Connors leaves the room
[18:46:55] arjan leaves the room
[19:00:56] maas.maarten.zeeman leaves the room
[19:07:49] vio42 joins the room
[19:54:06] arjan joins the room
[20:16:19] maas.maarten.zeeman joins the room
[20:55:32] arjan leaves the room
[21:03:38] Michael Connors joins the room
[21:04:15] Michael Connors leaves the room
Powered by ejabberd Powered by Erlang Valid XHTML 1.0 Transitional Valid CSS!