funny lol, no reply since april and within a day 3 people working on it
I am new to silverstripe cms, I require some guideline on how to add a new module in the admin cms. If you could assist some help for me, I would be very graceful to you. If you have any help doc with respect to silverstripe cms, please provide me the same. My email address is firstname.lastname@example.org.
Thanks in advance!
There might be better places than this thread for your question :-)
Module installation in short words:
- copy module folder to your Silverstripe directory
- run http://yoursiteurl/dev/Build
- expirience your newly installed module
First I thought "just extend the code" and now I'm in the middle of writing it completely from scratch.
Since the data had to be splitted into two tables (messages & attributes) I thought, some jQuery and Ajax might be nice, too.
Hopefully I can present a working prototype the upcoming week. At the moment most of the frontend-stuff with inbox/archive/sent folders, the Ajax handling etc. is done and I'm working on the data-stuff within the models :-)
As a short report:
I hab less time this week than I expected but I'm working on it atm.
implemented the delete and archive methods, the ajaxified interface and some other stuff. Hopefully I can present a (fully) working module soon :-)
Because I really like answering my own posts... ;-)
I've built a little pre-alpha version of this module. [url=https://svn.aschmann.org/dl.php?repname=privatemessage+module&path=%2Ftrunk%2Fprivatemessage%2F&rev=0&isdir=1]Downloadable here[/url].
You can just get a glimpse at the code [url=https://svn.aschmann.org/listing.php?repname=privatemessage+module&path=%2Ftrunk%2Fprivatemessage%2F#path_trunk_privatemessage_]here[/url].
Not the finest code and surely not the best oop, but at least I tried ;-)
What can it do?
- you have a private message page
- 3 folders: inbox, archive and sent
- you can move messages from inbox to archive
- you can delete messages (will set a "IsDeleted" flag)
- messages are shown as a list (pagination missing)
- message details are shown as a separate page
- optional e-mail message for receiver on new messages (switchable in admin backend)
- optional nickname support (atm only nicknames OR real names)
- all ajax (don't cry, I used simplest encapsulated jQuery and I really got mad sometimes with the logic -.-)
What can't it do (yet)?
- no *final* deleting messages yet, everything is only flagged in database. I'm unsure if I should create a "cleanup" button or a check when deleting messages like "if message and all attributes have 'IsDeleted' = 1, delete all datasets".
- the counts in the private message's menu aren't ajaxed, yet. So numbers will stay until pageload
- lot's of things I haven't seen/thought of, yet
So if anyone's out for alphatesting... otherwise I'll continue this path ;-)
In case someone is interested in coding, I can share SVN access - but beware: I'm not so into the Silverstripe coding guidlines. I tend to use typified variable names and so on ;-)
ill have a look at this in a few days, a bit busy with work at the mo, plus im working on a new module
as for the final deleting, i would check to see if both have marked as deleted, so when the second mark is made it will delete, i dont see the point in cleaning up. the ajax stuff is beyond me at this point, so cant comment there.
will post back in a few :) but a quick scan looks quite nice;)
thanks for the test!
The check for "IsDeleted" might be costly, because you can send a message to several receipients at once.
Therefore a PrivateMessage dataset wil be created and for every receiver a separate PrivateMessageAttributes dataset as 1:n.
So I can make sure, every user can put his messages into folders, delete, and so on.
I'll meditate on that :-)
And me again:
Had a little bit of time this weekend and began implementing the "delete everything if all message-parts are 'IsDeleted==true'" and added an jQuery autosuggest for the username. Don't know yet if it collides with the comma-separated multiple user, but we'll see.