Index: openacs-4/packages/chat/www/index.tcl
===================================================================
RCS file: /usr/local/cvsroot/openacs-4/packages/chat/www/index.tcl,v
diff -u -r1.8 -r1.9
--- openacs-4/packages/chat/www/index.tcl 19 Nov 2007 01:14:16 -0000 1.8
+++ openacs-4/packages/chat/www/index.tcl 9 Nov 2008 23:29:23 -0000 1.9
@@ -29,10 +29,15 @@
lappend actions "#chat.Create_a_new_room#" room-edit "#chat.Create_a_new_room#"
}
-db_multirow -extend { active_users last_activity } rooms rooms_list {} {
- set room [::chat::Chat create new -volatile -chat_id $room_id]
- set active_users [$room nr_active_users]
- set last_activity [$room last_activity]
+db_multirow -extend { active_users last_activity room_url} rooms rooms_list {} {
+
+ set room [::chat::Chat create new -volatile -chat_id $room_id]
+ set active_users [$room nr_active_users]
+ set last_activity [$room last_activity]
+
+ if { $active_p } {
+ set room_url [export_vars -base "room-enter" {room_id {client $default_client}}]
+ }
}
list::create \
@@ -42,36 +47,28 @@
-pass_properties {room_create_p} \
-actions $actions \
-row_pretty_plural [_ chat.rooms] \
+ -no_data [_ chat.There_are_no_rooms_available] \
-elements {
active {
label "#chat.Active#"
- html { align "center" }
+ html { style "text-align: center" }
display_template {