File contents
README
Intro
This a simple calendar of events/calendaring product. It makes use of the CalendarTag http://www.zope.org/Members/jdavid/Calendar.
Features:-
-provides events scheduling
-if a start date and end date is entered, the range will be updated/inserted.
However, to stop unneccessary DOS, only a 30 day range is allowed.
-easy interface to Calendar properties/attributes via form
-provides anonymous posting/authenticated posting
-Public and private events. Private events will only be seen by the user who posted it.
-with authenticated posting, authorized user will be able to edit his posts
-generic (i.e simplistic) enough to use any rdb. tested with Gadfly and postgres
-customization (cosmetic/sql queries) easily done. check example below.
Bugs/ToDo:-
-can't set Calendar modes/lang thru forms, since CalendarTag accept modes as string
only. anybody knows how to change the way it works?
-Security is not implemented well enuff, methinks. Comments?
-make use of ChrisW strip-o-gram to enable html posting
-mail me your bugs/features/wishlists/etc
Install:-
-untar SempoiCalendar.tar.gz to zope/path/lib/python/Products
-get Calendar product at http://www.zope.org/Members/jdavid/Calendar
-install Calendar product
-create a db connection (gadfly, postgres, etc)
-instantiate SempoiCalendar
-check the Security tab in SempoiCalendar instance. If you use anon postings,
give Anonymous User permission to 'Add SempoiCalendar Item'. Otherwise, give
the appropriate Local Role permission to use 'Add SempoiCalendar Item'.
-change the default index_html, view, addItemForm to your liking.
-go to Properties tab and change any properties you want. Add necessary
Categories for your events per line.
-create a db, and table calendar
schema
create table calendar (
obj_id float,
bodytext varchar(255),
username varchar(60),
title varchar(60),
category varchar(40),
start_date varchar(20),
end_date varchar(20),
start_event varchar(20),
end_event varchar(20),
status varchar(10)
)
Customizing sql queries
e.g, the default obj_id uses time.time() which may not work well if the site is busy. with postgres, we can change the obj_id implementation by editing the sqlAddItem query. instead of using the default
insert into calendar
(obj_id,
bodytext,
username, title,
category, start_date, end_date,
start_event, end_event, status
)
VALUES (<dtml-sqlvar obj_id type=float>,
<dtml-sqlvar bodytext type=string>,
<dtml-sqlvar username type=string>,
<dtml-sqlvar title type=string>,
<dtml-sqlvar category type=string>,
<dtml-sqlvar start_date type=string>,
<dtml-sqlvar end_date type=string>,
<dtml-sqlvar start_event type=string>,
<dtml-sqlvar end_event type=string>,
<dtml-sqlvar status type=string>)
we use
insert into calendar
(obj_id,
bodytext,
username, title,
category, start_date, end_date,
start_event, end_event, status
)
VALUES (nextval('myseq'),
<dtml-sqlvar bodytext type=string>,
<dtml-sqlvar username type=string>,
<dtml-sqlvar title type=string>,
<dtml-sqlvar category type=string>,
<dtml-sqlvar start_date type=string>,
<dtml-sqlvar end_date type=string>,
<dtml-sqlvar start_event type=string>,
<dtml-sqlvar end_event type=string>,
<dtml-sqlvar status type=string>)
This is pretty much alpha stuff. No major tests done. Lightly tested with
Gadfly and postgres. Enjoy, mail [email protected] any bug reports,
wishlist, coding style.
enjoy!