28 $communication_config =
$oModuleModel->getModuleConfig(
'communication');
30 if(!is_object($communication_config))
32 $communication_config =
new stdClass();
35 if(!$communication_config->skin)
37 $communication_config->skin =
'default';
40 if(!$communication_config->colorset)
42 $communication_config->colorset =
'white';
45 if(!$communication_config->editor_skin)
47 $communication_config->editor_skin =
'ckeditor';
50 if(!$communication_config->mskin)
52 $communication_config->mskin =
'default';
55 if(!$communication_config->grant_write)
57 $communication_config->grant_write = array(
'default_grant'=>
'member');
60 return $communication_config;
77 $grant = array(
"default_grant"=>
"site");
80 $grant = array(
"default_grant"=>
"manager");
83 $grant = array(
"default_grant"=>
"member");
87 else if(is_array($group))
90 $group_list = $oMemberModel->getGroups($this->
site_srl);
92 $group_grant = array();
93 foreach($group as $group_srl)
95 $group_grant[$group_srl] = $group_list[$group_srl]->title;
97 $grant = array(
'group_grant'=>$group_grant);
120 if($arrGrant[
'default_grant'])
122 if($arrGrant[
'default_grant'] ==
"member" &&
$logged_info)
128 if($arrGrant[
'default_grant'] ==
"manager" &&
$logged_info->is_admin ==
"Y")
132 if($arrGrant[
'group_grant'])
134 $group_grant = $arrGrant[
'group_grant'];
135 if(!is_array($group_grant))
140 if(isset($group_grant[$group_srl])&&$group_grant[$group_srl]==$title)
160 $args =
new stdClass();
161 $args->message_srl = $message_srl;
175 $member_info = $oMemberModel->getMemberInfoByMemberSrl(
$message->receiver_srl);
180 $member_info = $oMemberModel->getMemberInfoByMemberSrl(
$message->sender_srl);
185 foreach($member_info as $key => $val)
187 if($key ===
'title')
continue;
188 if($key ===
'content')
continue;
189 if($key ===
'sender_srl')
continue;
190 if($key ===
'password')
continue;
191 if($key ===
'regdate')
continue;
201 $oCommunicationController->setMessageReaded($message_srl);
216 $args =
new stdClass();
226 $message = array_pop(
$output->data);
229 $oCommunicationController->setMessageReaded($message->message_srl);
243 $args =
new stdClass();
245 switch($message_type)
249 $args->message_type =
'R';
250 $query_id =
'communication.getReceivedMessages';
255 $args->message_type =
'T';
256 $query_id =
'communication.getStoredMessages';
261 $args->message_type =
'S';
262 $query_id =
'communication.getSendedMessages';
267 $args->sort_index =
'message.list_order';
269 $args->list_count = 20;
270 $args->page_count = 10;
281 function getFriends($friend_group_srl = 0, $columnList = array())
285 $args =
new stdClass();
286 $args->friend_group_srl = $friend_group_srl;
291 $args->sort_index =
'friend.list_order';
292 $args->list_count = 10;
293 $args->page_count = 10;
309 $args =
new stdClass();
311 $args->target_srl = $member_srl;
327 $args =
new stdClass();
329 $args->friend_group_srl = $friend_group_srl;
344 $args =
new stdClass();
367 $args =
new stdClass();
368 $args->member_srl = $target_srl;
getController($module_name)
getFriendGroupInfo($friend_group_srl)
getGrantArray($default, $group)
get grant array for insert to database. table module_config's config field
getMessages($message_type="R", $columnList=array())
getNewMessage($columnList=array())
getFriends($friend_group_srl=0, $columnList=array())
executeQueryArray($query_id, $args=NULL, $arg_columns=NULL)
executeQuery($query_id, $args=NULL, $arg_columns=NULL)
checkGrant($arrGrant)
check member's grant
isAddedFriend($member_srl)
getSelectedMessage($message_srl, $columnList=array())