From e5b4b1a635c75d131c81cb0dadf324ddd2cd24ad Mon Sep 17 00:00:00 2001 From: Alex Aragon Date: Mon, 28 Mar 2016 16:59:19 -0500 Subject: [PATCH 1/3] fix css tpl groups topics CT#8161 --- app/Resources/public/css/base.css | 234 +++--------------- main/inc/lib/message.lib.php | 132 +++++----- main/inc/lib/social.lib.php | 4 +- main/social/group_topics.php | 15 +- main/social/group_view.php | 35 ++- main/template/default/social/avatar_block.tpl | 2 +- main/template/default/social/group_view.tpl | 37 ++- .../template/default/social/groups_topics.tpl | 37 +++ 8 files changed, 215 insertions(+), 281 deletions(-) create mode 100644 main/template/default/social/groups_topics.tpl diff --git a/app/Resources/public/css/base.css b/app/Resources/public/css/base.css index 9b98efb754..3289057b2a 100644 --- a/app/Resources/public/css/base.css +++ b/app/Resources/public/css/base.css @@ -708,7 +708,6 @@ a.personal_agenda:hover, a.personal_agenda:hover { .social-home-anonymous-online { width: 200px; } - .menulist { margin: 0px; list-style: none; @@ -717,38 +716,15 @@ a.personal_agenda:hover, a.personal_agenda:hover { list-style-position:outside; list-style-type:none; } - .menulist li { /* float:left; */ /* margin-left:10px; */ margin-bottom:10px; display:list-item; } - .menulist li { margin-top: 10px; } - -.group_social_item { - float:left; - width:95%; -} - -.group_social_sub_item { - float:left; - /* width:600px; */ - background-color: #E9F4FA; - background-repeat: repeat-x; - - margin: 8px; - padding:5px; - width:100%; -} - -.group_social_sub_item_highlight { - background-color: #FFFFDD; -} - #profile .control-group .controls .files-production{ padding: 5px 25px; -webkit-border-radius: 10px; @@ -766,129 +742,17 @@ a.personal_agenda:hover, a.personal_agenda:hover { padding-bottom: 3px; } -.message-group-content { - float:right; - width:90%; - line-height: 100%; -} - -.message-group-date { - font-style:italic; - text-align:left; - margin-top:4px; -} -.message-reply-link { - float:right; -} - -.group_social_main_item { - float:left; - width:600px; - background-color: #fff; - background-repeat: repeat-x; - margin: 8px; - padding:5px; -} - -.group_discussions_replies { - background-color: #E9F4FA; - background-repeat: repeat-x; - border: 1px solid #D0E2EC; - border-radius: 3px 3px 3px 3px; - color: #999999; - float: left; - font-size: 0.8em; - margin-right: 10px; - overflow: hidden; - padding: 13px; - text-align: center; - width: 47px; - margin-bottom: 65px; -} - -.group_discussions_replies span { - display: block; - font-size: 2em; -} - -.group_discussions_info { - width:400px; - height: 80px; - overflow: hidden; - width: 400px; -} - -.group_social_grid { - float:left; - width:100%; -} - -.message-attach { - float:left; -} #sn-extra-information .list-group-item{ padding: 5px 10px; border: none; } - /** BUTTONS **/ - .left { float:left !important; } - .right { text-align: right; } - -/* Nice buttons v2 */ - -button.next.disabled { - cursor: default; - opacity: 0.65; -} - -.round { - -webkit-border-radius: 1em; - -moz-border-radius: 1em; - border-radius: 1em; -} - -.bigger { - font-size: 16px; - font-weight: bold; - padding: .8em 2em .62em; -} - -.big { - font-size: 14px; - font-weight: bold; - padding: .8em 2em .62em; -} -.medium { - font-size: 12px; - padding: .4em 1.5em .42em; -} -.small { - font-size: 11px; - padding: .2em 1em .275em; -} - -.no_link { - cursor:default; - -} - -.no_link:hover { - cursor:default; -} -.no_link:active { - cursor:default; - -} -.content-chat{ - height: 200px; -} /* Note */ .note { margin: 6px; @@ -1040,10 +904,6 @@ div.attendance-calendar-add div.row div.formw,div.attendance-calendar-edit div.r #inbox-menu ul li { padding:2px 0px; } - -#message-reply-link { - float:right; -} .message-item { -moz-background-clip:border; -moz-background-inline-policy:continuous; @@ -1057,43 +917,26 @@ div.attendance-calendar-add div.row div.formw,div.attendance-calendar-edit div.r padding:10px; } .message-topic { - -moz-background-clip:border; - -moz-background-inline-policy:continuous; - -moz-background-origin:padding; - -moz-border-radius-bottomleft:8px; - -moz-border-radius-bottomright:8px; - -moz-border-radius-topleft:8px; - -moz-border-radius-topright:8px; - background:#E6EEFB none repeat scroll 0 0; - margin:0 0 5px; - padding:10px; - -} -.message-group-title-topic { - font-size:180%; - margin:5px 0px 5px 0px; -} -.message-group-title { - font-size:120%; -} -.message-group-author { - margin:0px 5px 5px 0px; - float:left; + padding: 15px; + border-radius: 5px; + display: inline-block; + border: 1px solid #DDD; + box-shadow: 0px 1px 1px rgba(0, 0, 0, 0.05); } - -.message-group-content { - margin: 5px 0px 8px 0px; +.message-topic .avatar-author{ + float: right; } -.message-group-date { - color:#999; - width:100%; - font-size:98%; +.thread-body{ + padding-bottom: 20px; + padding-top: 20px; } -.view-message-content { - line-height:150%; - font-size:110%; +.message-post{ + border: 1px solid #DDD; + margin-bottom: 20px; + border-radius: 5px; + padding: 15px; + box-shadow: 0px 1px 1px rgba(0, 0, 0, 0.05); } - .message_view_table { cellspacing:0; cellpadding:0; @@ -1114,15 +957,7 @@ div.attendance-calendar-add div.row div.formw,div.attendance-calendar-edit div.r margin-top:23px; margin-left:20px; } - /* styles from the my.profile.php file */ -.message-content { - /* float:right; - background:#FFF; - padding: 10px 0 0 5px; - width:125px; - position:relative;*/ -} .message-content .message-delete { position: absolute; top: 10px; @@ -1241,8 +1076,6 @@ div.attendance-calendar-add div.row div.formw,div.attendance-calendar-edit div.r outline-style:none; background:#ffffff; } -.message-content-body-right:hover { -} a.unread { font-weight:bold; @@ -1483,10 +1316,7 @@ div.admin_section h4 { .toolbar-groups{ margin-bottom: 30px; } -#group_edit .form-group label span{ - display: block; - font-size: 12px; -} + .group_invitation_grid_container { width:100%;} .group_invitation_grid_item { border:1px dotted #CCCCCC; @@ -2193,18 +2023,11 @@ div.admin_section h4 { border-bottom: 1px solid #CCCCCC; margin-bottom: 20px; } - #div_content_table { border-bottom:1px solid #EAEAEA; margin-bottom:20px; padding-bottom:10px; } - -.group_description { - word-wrap: break-word; - font-size:11px; -} - /* Forms */ div.row div.form_header { white-space: nowrap; @@ -3958,7 +3781,12 @@ i.size-32.icon-new-work{ } .sm-groups .social-profile .img-responsive{ display: inline-block; - width: 100px; +} +.sm-groups-content .groups-messages{ + padding-top: 10px; + padding-bottom: 20px; + padding-left: 20px; + padding-right: 20px; } .social-post .mediaPost{ padding-top:10px; @@ -5298,15 +5126,22 @@ div#chat-remote-video video { #toolbar-agenda .show-tick{ width: 420px; } -.tab-wrapper .tab-content{ - padding: 25px 0px 25px 0px; -} .description-upload{ margin-bottom: 10px; } .files-table{ padding-top: 20px; } +.user-list{ + padding-top: 20px; + padding-bottom: 20px; +} +.items-user{ + text-align: center; + padding: 10px; + margin-bottom: 10px; + min-height: 170px; +} #whoisonline .items-user{ text-align: center; /*border:1px solid #dddddd; */ @@ -5848,9 +5683,6 @@ a.sessionView { padding: 5px; min-height: 300px; } - .col-xs-6{ - width: 100%; - } .gallery .canvas-two{ width: 100%; } diff --git a/main/inc/lib/message.lib.php b/main/inc/lib/message.lib.php index 6f12c553e7..bface654e3 100755 --- a/main/inc/lib/message.lib.php +++ b/main/inc/lib/message.lib.php @@ -1154,25 +1154,25 @@ class MessageManager // topics $user_sender_info = api_get_user_info($topic['user_sender_id']); $name = $user_sender_info['complete_name']; - + $html .= '
'; $html .= '
'; $items = $topic['count']; $reply_label = ($items == 1) ? get_lang('GroupReply') : get_lang('GroupReplies'); - $label = Display::label($items.' '.$reply_label); + $label = ' ' . $items . ' ' . $reply_label; $topic['title'] = trim($topic['title']); if (empty($topic['title'])) { $topic['title'] = get_lang('Untitled'); } - $html .= '
'; + $html .= '
'; $html .= Display::tag( 'h4', Display::url( Security::remove_XSS($topic['title'], STUDENT, true), api_get_path(WEB_CODE_PATH).'social/group_topics.php?id='.$group_id.'&topic_id='.$topic['id'] - ) + ), array('class'=>'title') ); $actions = ''; if ($my_group_role == GROUP_USER_PERMISSION_ADMIN || @@ -1186,24 +1186,24 @@ class MessageManager if (!empty($topic['update_date']) && $topic['update_date'] != '0000-00-00 00:00:00' ) { - $date .= '
'.get_lang('LastUpdate').' '.date_to_str_ago($topic['update_date']).'
'; + $date .= ' '.get_lang('LastUpdate').' '.date_to_str_ago($topic['update_date']); } } else { - $date .= '
'.get_lang('Created').' '.date_to_str_ago($topic['send_date']).'
'; + $date .= ' '.get_lang('Created').' '.date_to_str_ago($topic['send_date']); } - $html .= $date.$label.$actions; + $html .= '
'. $label.' - '.$date.$actions . '
'; $html .= '
'; $image = $user_sender_info['avatar']; - $user_info = ''.$name.' '; - $user_info .= '
'.$name.'
'; - $user_info .= ''; + $user_info = '
'.$name.'
'; + $user_info .= ''; - $html .= '
'; + $html .= '
'; $html .= $user_info; $html .= '
'; $html .= '
'; + $html .= '
'; $array_html[] = array($html); } @@ -1247,29 +1247,23 @@ class MessageManager $current_user_id = api_get_user_id(); $items_per_page = 50; - $query_vars = array('id' => $group_id, 'topic_id' => $topic_id, 'topics_page_nr' => 0); // Main message $links = ''; $main_content = ''; - - $items_page_nr = null; - $html = ''; - - $delete_button = ''; - if (api_is_platform_admin()) { - $delete_button = Display::url(Display::return_icon('delete.png', get_lang('Delete'), array(), ICON_SIZE_SMALL), 'group_topics.php?action=delete&id='.$group_id.'&topic_id='.$topic_id); - } - $html .= Display::page_subheader(Security::remove_XSS($main_message['title'].$delete_button, STUDENT, true)); + $items_page_nr = null; $user_sender_info = api_get_user_info($main_message['user_sender_id']); $files_attachments = self::get_links_message_attachment_files($main_message['id']); $name = $user_sender_info['complete_name']; $topic_page_nr = isset($_GET['topics_page_nr']) ? intval($_GET['topics_page_nr']) : null; - $links.= ' {% endif %} -<<<<<<< HEAD -<<<<<<< HEAD - -=======

{{ group_info.name }}

@@ -57,10 +53,6 @@ {{ social_forum }}
->>>>>>> d97f940... fix css tpl groups topics CT#8161 -======= - {{ social-forum }} ->>>>>>> 29d36f7... arranging menu display list groups CT#8161 {{ social_right_content }}