Changeset 1407

Show
Ignore:
Timestamp:
12/07/07 10:31:21 (1 year ago)
Author:
misja
Message:

Misja Hoebe <misja@curverider.co.uk> Fix menu entry only to appear for persons, not communities. Misc text tweaks.

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • devel/mod/community/lib.php

    r1397 r1407  
    142142 
    143143    // Add membership requests to the personal network page 
    144     if (defined("context") && context == "network") { 
     144    if (defined("context") && context == "network" && $page_owner == $_SESSION['userid']) { 
    145145          $PAGE->menu_sub[] = array( 'name' => 'membership:invites', 
    146146                                   'html' => a_href( "{$CFG->wwwroot}{$username}/communities/invitations", 
    147                                                       __gettext("Membership invitations"))); 
     147                                                      __gettext("Community invitations"))); 
    148148    } 
    149149} 
  • devel/mod/community/lib/communities_actions.php

    r1398 r1407  
    153153                     if (insert_record('friends',$f)) { 
    154154                         delete_records('friends_requests','ident',$request_id); 
    155                          $messages[] = sprintf(__gettext("You accepted the community invitation. You are now a member of the community %s."),stripslashes($request->name)); 
    156                          $message_body = sprintf(__gettext("%s has approved your community invitation!\n\nRegards,\n\nThe %s team."),user_name($request->friend), $CFG->sitename); 
     155                         $messages[] = sprintf(__gettext("You accepted the community membership invitation. You are now a member of the community %s."),stripslashes($request->name)); 
     156                         $message_body = sprintf(__gettext("%s has approved your community membership invitation!\n\nRegards,\n\nThe %s team."),user_name($request->friend), $CFG->sitename); 
    157157                         $title = __gettext("Community invitation accepted!"); 
    158158                         notify_user($request->owner,$title,$message_body); 
     
    161161                     } 
    162162                 } else { 
    163                      $messages[] = __gettext("Error: you do not have authority to accept this membership invitation."); 
     163                     $messages[] = __gettext("Error: you do not have authority to accept this community membership invitation."); 
    164164                 } 
    165165             } else { 
    166                  $messages[] = __gettext("An error occurred: the invitation could not be found."); 
     166                 $messages[] = __gettext("An error occurred: the community membership invitation could not be found."); 
    167167             } 
    168168              
     
    177177                 if (run("permissions:check",array("userdetails:change", $page_owner))) { 
    178178                     delete_records('friends_requests','ident',$request_id); 
    179                      $messages[] = sprintf(__gettext("You declined the community invitation. You are not a member of community %s."),stripslashes($request->name)); 
    180                      $message_body = sprintf(__gettext("%s has denied your community invitation.\n\nRegards,\n\nThe %s team."),user_name($request->friend), $CFG->sitename); 
     179                     $messages[] = sprintf(__gettext("You declined the community membership invitation. You are not a member of community %s."),stripslashes($request->name)); 
     180                     $message_body = sprintf(__gettext("%s has denied your community membership invitation.\n\nRegards,\n\nThe %s team."),user_name($request->friend), $CFG->sitename); 
    181181                     $title = sprintf(__gettext("%s friend request denied"), $CFG->sitename); 
    182182                     notify_user($request->owner,$title,$message_body); 
    183183                 } else { 
    184                      $messages[] = __gettext("Error: you do not have authority to modify this membership invitation."); 
     184                     $messages[] = __gettext("Error: you do not have authority to modify this community membership invitation."); 
    185185                 } 
    186186             } else { 
    187                  $messages[] = __gettext("An error occurred: the invitation could not be found."); 
     187                 $messages[] = __gettext("An error occurred: the community membership invitation could not be found."); 
    188188             } 
    189189              
  • devel/mod/community/lib/community_membership_invitations.php

    r1390 r1407  
    4949 
    5050            } else { 
    51                 $body = "<p>" . __gettext("You have no pending membership invitations.") . "</p>"; 
     51                $body = "<p>" . __gettext("You have no pending community membership invitations.") . "</p>"; 
    5252            } 
    5353