1.1 --- a/imiptools/client.py Sat Aug 29 00:14:32 2015 +0200
1.2 +++ b/imiptools/client.py Mon Aug 31 15:44:46 2015 +0200
1.3 @@ -20,6 +20,7 @@
1.4 """
1.5
1.6 from datetime import datetime
1.7 +from imiptools.config import MANAGER_INTERFACE
1.8 from imiptools.data import Object, get_address, get_uri, get_window_end, \
1.9 is_new_object, make_freebusy, to_part, \
1.10 uri_dict, uri_items, uri_values
1.11 @@ -85,6 +86,9 @@
1.12 prefs = self.get_preferences()
1.13 return prefs and prefs.get("freebusy_messages") == "notify" or False
1.14
1.15 + def have_manager(self):
1.16 + return MANAGER_INTERFACE
1.17 +
1.18 def get_scheduling_resolution(self):
1.19
1.20 """
2.1 --- a/imiptools/config.py Sat Aug 29 00:14:32 2015 +0200
2.2 +++ b/imiptools/config.py Mon Aug 31 15:44:46 2015 +0200
2.3 @@ -32,6 +32,12 @@
2.4
2.5 DEFAULT_DIR_PERMISSIONS = 02770
2.6
2.7 +# The availability of a management interface for calendar information.
2.8 +# True: provide links in notifications to the interface described below.
2.9 +# False: omit links in notifications.
2.10 +
2.11 +MANAGER_INTERFACE = True
2.12 +
2.13 # The published location of the manager application.
2.14 # This must match any Web site configuration details for the manager.
2.15
3.1 --- a/imiptools/handlers/__init__.py Sat Aug 29 00:14:32 2015 +0200
3.2 +++ b/imiptools/handlers/__init__.py Mon Aug 31 15:44:46 2015 +0200
3.3 @@ -70,7 +70,7 @@
3.4
3.5 texts = []
3.6 texts.append(text)
3.7 - if link:
3.8 + if link and self.have_manager():
3.9 texts.append("If your mail program cannot handle this "
3.10 "message, you may view the details here:\n\n%s" %
3.11 get_object_url(self.uid, self.recurrenceid))
4.1 --- a/imiptools/handlers/person.py Sat Aug 29 00:14:32 2015 +0200
4.2 +++ b/imiptools/handlers/person.py Mon Aug 31 15:44:46 2015 +0200
4.3 @@ -153,19 +153,19 @@
4.4 "Queue a cancellation of any active event."
4.5
4.6 if self._record(from_organiser=True, queue=False, cancel=True):
4.7 - return self.wrap("A cancellation has been received.", link=False)
4.8 + return self.wrap("An event cancellation has been received.", link=False)
4.9
4.10 def counter(self):
4.11
4.12 # NOTE: Queue a suggested modification to any active event.
4.13
4.14 - return self.wrap("A counter proposal has been received.", link=False)
4.15 + return self.wrap("A counter proposal to an event invitation has been received.", link=False)
4.16
4.17 def declinecounter(self):
4.18
4.19 # NOTE: Queue a rejected modification to any active event.
4.20
4.21 - return self.wrap("A declining counter proposal has been received.", link=False)
4.22 + return self.wrap("Your counter proposal to an event invitation has been declined.", link=False)
4.23
4.24 def publish(self):
4.25
4.26 @@ -187,14 +187,14 @@
4.27 "Record replies and notify the recipient."
4.28
4.29 if self._record(from_organiser=False, queue=False):
4.30 - return self.wrap("A reply has been received.")
4.31 + return self.wrap("A reply to an event invitation has been received.")
4.32
4.33 def request(self):
4.34
4.35 "Hold requests and notify the recipient."
4.36
4.37 if self._record(from_organiser=True, queue=True):
4.38 - return self.wrap("A request has been received.")
4.39 + return self.wrap("An event invitation has been received.")
4.40
4.41 class Freebusy(PersonHandler, CommonFreebusy):
4.42
5.1 --- a/tools/install.sh Sat Aug 29 00:14:32 2015 +0200
5.2 +++ b/tools/install.sh Mon Aug 31 15:44:46 2015 +0200
5.3 @@ -13,14 +13,20 @@
5.4 cp $MODULES "$INSTALL_DIR"
5.5
5.6 if [ ! -e "$INSTALL_DIR/imiptools" ]; then
5.7 - mkdir "$INSTALL_DIR"/imiptools
5.8 + mkdir "$INSTALL_DIR/imiptools"
5.9 if [ ! -e "$INSTALL_DIR/imiptools" ]; then
5.10 - mkdir "$INSTALL_DIR"/imiptools/handlers
5.11 + mkdir "$INSTALL_DIR/imiptools/handlers"
5.12 fi
5.13 fi
5.14
5.15 -cp imiptools/*.py "$INSTALL_DIR"/imiptools/
5.16 -cp imiptools/handlers/*.py "$INSTALL_DIR"/imiptools/handlers/
5.17 +if [ -e "$INSTALL_DIR/imiptools/config.py" ]; then
5.18 + if [ ! -e "$INSTALL_DIR/imiptools/config.py.backup" ]; then
5.19 + mv "$INSTALL_DIR/imiptools/config.py" "$INSTALL_DIR/imiptools/config.py.backup"
5.20 + fi
5.21 +fi
5.22 +
5.23 +cp imiptools/*.py "$INSTALL_DIR/imiptools/"
5.24 +cp imiptools/handlers/*.py "$INSTALL_DIR/imiptools/handlers/"
5.25
5.26 if [ ! -e "$WEB_INSTALL_DIR" ]; then
5.27 mkdir -p "$WEB_INSTALL_DIR"
5.28 @@ -30,7 +36,7 @@
5.29 cp htdocs/styles.css "$WEB_INSTALL_DIR"
5.30
5.31 if [ ! -e "$WEB_INSTALL_DIR/imipweb" ]; then
5.32 - mkdir "$WEB_INSTALL_DIR"/imipweb
5.33 + mkdir "$WEB_INSTALL_DIR/imipweb"
5.34 fi
5.35
5.36 -cp imipweb/*.py "$WEB_INSTALL_DIR"/imipweb/
5.37 +cp imipweb/*.py "$WEB_INSTALL_DIR/imipweb/"