[Isocial-svn] SF.net SVN: isocial: [116] public/stylesheets/groupapp
Status: Pre-Alpha
Brought to you by:
aguidrevitch
From: <di...@us...> - 2008-03-28 16:54:20
|
Revision: 116 http://isocial.svn.sourceforge.net/isocial/?rev=116&view=rev Author: dim0s77 Date: 2008-03-28 09:54:26 -0700 (Fri, 28 Mar 2008) Log Message: ----------- Added tabs customize and members to the groups Modified Paths: -------------- app/controllers/groupapp/group_controller.php app/locales/groupapp/group/ru.php app/views/groupapp/group/_bar.tpl app/views/groupapp/group/create.tpl public/stylesheets/Application.css public/stylesheets/groupapp/Group.css Added Paths: ----------- app/views/groupapp/group/customize.tpl app/views/groupapp/group/members.tpl Removed Paths: ------------- app/views/groupapp/group/_group_customize.tpl app/views/groupapp/group/_group_info.tpl Modified: app/controllers/groupapp/group_controller.php =================================================================== --- app/controllers/groupapp/group_controller.php 2008-03-27 08:23:02 UTC (rev 115) +++ app/controllers/groupapp/group_controller.php 2008-03-28 16:54:26 UTC (rev 116) @@ -14,12 +14,37 @@ $this->GroupappGroup->setAttributes($this->params['group']); if ($this->Request->isPost() && $this->GroupappGroup->save()){ $this->step = 'group_customize'; + $this->redirectToAction('customize'); } else { $this->importErrors( $this->GroupappGroup->getErrors() ); } } } + function customize () { + $this->step = 'group_customize'; + if (!empty($this->params['group'])){ + $this->GroupappGroup->setAttributes($this->params['group']); + if ($this->Request->isPost() && $this->GroupappGroup->save()){ + $this->step = 'group_members'; + $this->redirectToAction('members'); + } else { + $this->importErrors( $this->GroupappGroup->getErrors() ); + } + } + } + + function members () { + $this->step = 'group_members'; + if (!empty($this->params['member'])){ + $this->GroupappGroup->setAttributes($this->params['member']); + if ($this->Request->isPost() && $this->GroupappGroup->save()){ + } else { + $this->importErrors( $this->GroupappGroup->getErrors() ); + } + } + } + function browse () { } Modified: app/locales/groupapp/group/ru.php =================================================================== --- app/locales/groupapp/group/ru.php 2008-03-27 08:23:02 UTC (rev 115) +++ app/locales/groupapp/group/ru.php 2008-03-28 16:54:26 UTC (rev 116) @@ -25,7 +25,6 @@ $dictionary['Description'] = 'Описание'; $dictionary['Group Type'] = 'Тип группы'; $dictionary['Select Category:'] = 'Выберите категорию:'; -$dictionary['Select'] = 'Выберите'; $dictionary['Recent News'] = 'Последние новости'; $dictionary['Office'] = 'Офис'; $dictionary['Street'] = 'Улица'; @@ -43,4 +42,35 @@ $dictionary['Group type is missing'] = 'Тип группы отсутствует'; $dictionary['please enter the group category'] = 'выберите, пожалуйста, категорию группы'; +$dictionary['Edit'] = 'Редактирование'; +$dictionary['Website'] = 'Адрес сайта'; +$dictionary['Options'] = 'Настройки'; +$dictionary['Show related groups'] = 'Показывать похожие группы'; +$dictionary['Enable discussion board'] = 'Включить форум'; +$dictionary['Enable the Wall'] = 'Включить доску объявлений'; +$dictionary['Enable photos'] = 'Включить фотографии'; +$dictionary['Allow all members to upload photos'] = 'Разрешить всем участникам загружать фото'; +$dictionary['Only allow admins to upload photos'] = 'Только администраторы могут загружать фото'; +$dictionary['Enable videos'] = 'Включить видео'; +$dictionary['Allow all members to upload videos'] = 'Разрешить всем участникам загружать видео'; +$dictionary['Only allow admins to upload videos'] = 'Только администраторы могут загружать видео'; +$dictionary['Access'] = 'Доступ'; +$dictionary['This group is open'] = 'Это открытая группа'; +$dictionary['This group is closed'] = 'Это закрытая группа'; +$dictionary['This group is secret'] = 'Это засекреченная группа'; +$dictionary['Anyone can join and invite others to join. Anyone can see the group information. Anyone can see the following: the discussion board, the wall, videos and photos.'] = + 'Каждый может присоединиться и пригласить других. Информацию о группе может увидеть каждый. Любой может увидеть форум, доску объявлений, видео и фото.'; +$dictionary['Administrative approval is required for new members to join. Anyone can see the group information. Only the members will be able to see the following: the discussion board, the wall, videos and photos.'] = + 'Для присоединения нового участника требуется разрешение администраторов. Информацию о группе может увидеть только участник группы. Только участники группы смогут увидеть форум, доску объявлений, видео и фото.'; +$dictionary['The group will not appear in search results or in the profiles of its members. Membership is by invitation only, and only members can see the group information. Only the members will be able to see the following: the discussion board, the wall, videos and photos.'] = + 'Эта группа не будет отображаться в результатах поиска или в профилях своих участников. Членство в группе возможно только по приглашению, и только участники группы могут видеть информацию о группе. Только участники смогут увидеть форум, доску объявлений, видео и фото.'; +$dictionary['Publicize'] = 'Опубликовать'; +$dictionary['Show this group in search results'] = 'Показывать эту группу в результатах поиска'; + +$dictionary['Invite people to'] = 'Пригласить людей в'; +$dictionary['Show'] = 'Показать'; +$dictionary['out of'] = 'из'; +$dictionary['Invite Friends'] = 'Пригласить друзей'; +$dictionary['Invite Friends on PROJECT_NAME'] = 'Пригласить друзей по PROJECT_NAME'; + ?> Modified: app/views/groupapp/group/_bar.tpl =================================================================== --- app/views/groupapp/group/_bar.tpl 2008-03-27 08:23:02 UTC (rev 115) +++ app/views/groupapp/group/_bar.tpl 2008-03-28 16:54:26 UTC (rev 116) @@ -2,8 +2,11 @@ <div class="left"> <ul class="toggle_minitabs"> <li class="first"><a href="/groupapp/group/create" class="<?= $step == 'group_info' ? 'selected' : '' ?>">_{Step} 1: _{Group Info}</a></li><? - ?><li><a class="disabled">_{Step} 2: _{Customize}</a></li><? - ?><li><a class="disabled">_{Step} 3: _{Members}</a></li> + ?><li><a href="/groupapp/group/customize/{group_id?}" class="<? if ($step == 'group_customize') { echo 'selected'; } + else if ($step == 'group_members') { echo ''; } + else echo 'disabled' ?>">_{Step} 2: _{Customize}</a></li><? + ?><li><a href="/groupapp/group/members/{group_id?}" class="<? if ($step == 'group_members') { echo 'selected'; } + else echo 'disabled' ?>">_{Step} 3: _{Members}</a></li> </ul> </div> </div> Deleted: app/views/groupapp/group/_group_customize.tpl =================================================================== --- app/views/groupapp/group/_group_customize.tpl 2008-03-27 08:23:02 UTC (rev 115) +++ app/views/groupapp/group/_group_customize.tpl 2008-03-28 16:54:26 UTC (rev 116) @@ -1 +0,0 @@ -customize \ No newline at end of file Deleted: app/views/groupapp/group/_group_info.tpl =================================================================== --- app/views/groupapp/group/_group_info.tpl 2008-03-27 08:23:02 UTC (rev 115) +++ app/views/groupapp/group/_group_info.tpl 2008-03-28 16:54:26 UTC (rev 116) @@ -1,55 +0,0 @@ -<tr> - <td class="tlabel">_{Group Name}:<br><small>(_{required})</small></td> - <td><?= $form_helper->text_field('group', 'name', array('class' => 'textinput')) ?></td> -</tr> -<tr> - <td class="tlabel">_{Description}:<br><small>(_{required})</small></td> - <td><?= $form_helper->text_area('group', 'description', array('rows' => '5')) ?></td> -</tr> -<tr> - <td class="tlabel">_{Group Type}:<br><small>(_{required})</small></td> - <td> - <?= $form_options_helper->select('group', - 'type_id', - $GroupappGroupType->collect( - $GroupappGroupType->find('all', array('conditions' => array("parent_id = 0"))), - 'name', - 'id'), - array(), - array('prompt' => $controller->t('Select')) - ) ?> - </td> -</tr> -<tr> - <td class="tlabel">_{Recent News}:</td> - <td><?= $form_helper->text_area('group', 'recent_news', array('rows' => '5')) ?></td> -</tr> -<tr> - <td class="tlabel">_{Office}:</td> - <td><?= $form_helper->text_field('group', 'office', array('class' => 'textinput')) ?></td> -</tr> -<tr> - <td class="tlabel">_{Email}:</td> - <td><?= $form_helper->text_field('group', 'email', array('class' => 'textinput')) ?></td> -</tr> -<tr> - <td class="tlabel">_{Street}:</td> - <td><?= $form_helper->text_field('group', 'street', array('class' => 'textinput')) ?></td> -</tr> -<tr> - <td class="tlabel">_{City/Town}:</td> - <td><?= $form_helper->text_field('group', 'city', array('class' => 'textinput') )?></td> -</tr> -<tr> - <td class="tlabel"> </td> - <td class="tsubmit"> - <input class="submitinput" type="submit" value="_{Create Group}"> - <input class="cancelinput" type="button" value="_{Cancel}"> - </td> -</tr> -<tr> - <td class="tlabel"> </td> - <td class="tnote"> - _{Note: groups that attack a specific person or group of people (e.g. racist, sexist, or other hate groups) will not be tolerated. Creating such a group will result in immediate termination of your PROJECT_NAME account.} - </td> -</tr> Modified: app/views/groupapp/group/create.tpl =================================================================== --- app/views/groupapp/group/create.tpl 2008-03-27 08:23:02 UTC (rev 115) +++ app/views/groupapp/group/create.tpl 2008-03-28 16:54:26 UTC (rev 116) @@ -14,7 +14,61 @@ <form action="/groupapp/group/create" method="post"> <table class="editor"> <tbody> - <?= $controller->renderPartial($step) ?> + <tr> + <td class="tlabel">_{Group Name}:<br><small>(_{required})</small></td> + <td><?= $form_helper->text_field('group', 'name', array('class' => 'textinput')) ?></td> + </tr> + <tr> + <td class="tlabel">_{Description}:<br><small>(_{required})</small></td> + <td><?= $form_helper->text_area('group', 'description', array('rows' => '5')) ?></td> + </tr> + <tr> + <td class="tlabel">_{Group Type}:<br><small>(_{required})</small></td> + <td> + <?= $form_options_helper->select('group', + 'type_id', + $GroupappGroupType->collect( + $GroupappGroupType->find('all', array('conditions' => array("parent_id = 0"))), + 'name', + 'id'), + array(), + array('prompt' => $controller->t('Select Category:')) + ) ?> + </td> + </tr> + <tr> + <td class="tlabel">_{Recent News}:</td> + <td><?= $form_helper->text_area('group', 'recent_news', array('rows' => '5')) ?></td> + </tr> + <tr> + <td class="tlabel">_{Office}:</td> + <td><?= $form_helper->text_field('group', 'office', array('class' => 'textinput')) ?></td> + </tr> + <tr> + <td class="tlabel">_{Email}:</td> + <td><?= $form_helper->text_field('group', 'email', array('class' => 'textinput')) ?></td> + </tr> + <tr> + <td class="tlabel">_{Street}:</td> + <td><?= $form_helper->text_field('group', 'street', array('class' => 'textinput')) ?></td> + </tr> + <tr> + <td class="tlabel">_{City/Town}:</td> + <td><?= $form_helper->text_field('group', 'city', array('class' => 'textinput') )?></td> + </tr> + <tr> + <td class="tlabel"> </td> + <td class="tsubmit"> + <input class="submitinput" type="submit" value="_{Create Group}"> + <input class="cancelinput" type="button" value="_{Cancel}"> + </td> + </tr> + <tr> + <td class="tlabel"> </td> + <td class="tnote"> + _{Note: groups that attack a specific person or group of people (e.g. racist, sexist, or other hate groups) will not be tolerated. Creating such a group will result in immediate termination of your PROJECT_NAME account.} + </td> + </tr> </tbody> </table> </form> Added: app/views/groupapp/group/customize.tpl =================================================================== --- app/views/groupapp/group/customize.tpl (rev 0) +++ app/views/groupapp/group/customize.tpl 2008-03-28 16:54:26 UTC (rev 116) @@ -0,0 +1,161 @@ +<?= $controller->renderPartial("menu") ?> + +<div class="title_bar"> + <div class="head"> + <div class="name groupapp">_{Edit} {group_name?}</div> + </div> +</div> +<div class="clearfix"></div> + +<?= $controller->renderPartial("bar") ?> + +<div class="editform"> + <form action="/groupapp/group/customize/{group_id?}" method="post"> + <div class="picture"></div> + + <div class="formrow"> + <?= $controller->renderErrors() ?> + </div> + + <div class="formrow"> + <label>_{Website}:</label> + <div class="formcol"> + <?= $form_helper->text_field('group', 'website', array('class' => 'textinput')) ?> + </div> + <div class="clearfix"></div> + </div> + + <div class="formrow"> + <label>_{Options}:</label> + <div class="formcol"> + <label class="checkbox"><?= $form_helper->check_box('group', 'show_related_groups', array('class' => 'checkboxinput', 'checked' => 'checked')) ?> _{Show related groups}.</label> + </div> + <div class="clearfix"></div> + </div> + + <div class="formrow"> + <label> </label> + <div class="formcol"> + <label class="checkbox"><?= $form_helper->check_box('group', 'enable_discussion_board', array('class' => 'checkboxinput', 'checked' => 'checked')) ?> _{Enable discussion board}.</label> + </div> + <div class="clearfix"></div> + </div> + + <div class="formrow"> + <label> </label> + <div class="formcol"> + <label class="checkbox"><?= $form_helper->check_box('group', 'enable_the_wall', array('class' => 'checkboxinput', 'checked' => 'checked')) ?> _{Enable the Wall}.</label> + </div> + <div class="clearfix"></div> + </div> + + <div class="formrow"> + <label> </label> + <div class="formcol"> + <label class="checkbox"><?= $form_helper->check_box('group', 'enable_photos', array('class' => 'checkboxinput', 'checked' => 'checked')) ?> _{Enable photos}.</label> + </div> + <div class="clearfix"></div> + </div> + <div class="formrow"> + <label> </label> + <div class="formcol"> + <div class="formblock border"> + <label class="radiobutton"><?= $form_helper->radio_button('group', 'photo_member', 'members', array('checked' => 'checked')) ?> _{Allow all members to upload photos}.</label> + <label class="radiobutton"><?= $form_helper->radio_button('group', 'photo_member', 'admins') ?> _{Only allow admins to upload photos}.</label> + <div class="clearfix"></div> + </div> + </div> + <div class="clearfix"></div> + </div> + + <div class="formrow"> + <label> </label> + <div class="formcol"> + <label class="checkbox"><?= $form_helper->check_box('group', 'enable_videos', array('class' => 'checkboxinput', 'checked' => 'checked')) ?> _{Enable videos}.</label> + </div> + <div class="clearfix"></div> + </div> + <div class="formrow"> + <label> </label> + <div class="formcol"> + <div class="formblock border"> + <label class="radiobutton"><?= $form_helper->radio_button('group', 'video_member', 'members', array('checked' => 'checked')) ?> _{Allow all members to upload videos}.</label> + <label class="radiobutton"><?= $form_helper->radio_button('group', 'video_member', 'admins') ?> _{Only allow admins to upload videos}.</label> + <div class="clearfix"></div> + </div> + </div> + <div class="clearfix"></div> + </div> + + <div class="formrow"> + <label>_{Access}:</label> + <div class="formcol"> + <label class="radiobutton"><?= $form_helper->radio_button('group', 'access', 'open', array('checked' => 'checked')) ?> _{This group is open}.</label> + </div> + <div class="clearfix"></div> + </div> + <div class="formrow"> + <label> </label> + <div class="formcol"> + <div class="formblock gray"> + _{Anyone can join and invite others to join. Anyone can see the group information. Anyone can see the following: the discussion board, the wall, videos and photos.} + </div> + </div> + <div class="clearfix"></div> + </div> + + <div class="formrow"> + <label> </label> + <div class="formcol"> + <label class="radiobutton"><?= $form_helper->radio_button('group', 'access', 'closed') ?> _{This group is closed}.</label> + </div> + <div class="clearfix"></div> + </div> + <div class="formrow"> + <label> </label> + <div class="formcol"> + <div class="formblock gray"> + _{Administrative approval is required for new members to join. Anyone can see the group information. Only the members will be able to see the following: the discussion board, the wall, videos and photos.} + </div> + </div> + <div class="clearfix"></div> + </div> + + <div class="formrow"> + <label> </label> + <div class="formcol"> + <label class="radiobutton"><?= $form_helper->radio_button('group', 'access', 'secret') ?> _{This group is secret}.</label> + </div> + <div class="clearfix"></div> + </div> + <div class="formrow"> + <label> </label> + <div class="formcol"> + <div class="formblock gray"> + _{The group will not appear in search results or in the profiles of its members. Membership is by invitation only, and only members can see the group information. Only the members will be able to see the following: the discussion board, the wall, videos and photos.} + </div> + </div> + <div class="clearfix"></div> + </div> + + <div class="formrow"> + <label>_{Publicize}:</label> + <div class="formcol"> + <label class="checkbox"><?= $form_helper->check_box('group', 'is_show_in_search', array('class' => 'checkboxinput', 'checked' => 'checked')) ?> _{Show this group in search results}.</label> + </div> + <div class="clearfix"></div> + </div> + + <div class="formrow"> + <label> </label> + <div class="formcol"> + <input class="submitinput" type="submit" value="_{Create Group}"> + <input class="cancelinput" type="button" value="_{Cancel}"> + </div> + <div class="clearfix"></div> + </div> + <div class="clearfix"></div> + + </form> +</div> + Added: app/views/groupapp/group/members.tpl =================================================================== --- app/views/groupapp/group/members.tpl (rev 0) +++ app/views/groupapp/group/members.tpl 2008-03-28 16:54:26 UTC (rev 116) @@ -0,0 +1,46 @@ +<?= $controller->renderPartial("menu") ?> + +<div class="title_bar"> + <div class="head"> + <div class="name groupapp">_{Invite people to} {group_name?}</div> + </div> +</div> +<div class="clearfix"></div> + +<?= $controller->renderPartial("bar") ?> + +<div class="formwrapper"> +<form action="/groupapp/group/edit_members/{group_id?}" method="post"> + <div class="invite_column"> + <div class="header_text">_{Invite Friends on PROJECT_NAME}:</div> + <div class="friends_list"></div> + <div class="submit"> + <input class="submitinput" type="submit" value="_{Invite Friends}"> + </div> + </div> + + <div class="members"> + <div class="submenushort"> + <div class="menu_block selector"> + <label for="action_select">_{Show}: + <select onchange="doselect(this)" id="action_select" name="action_select"> + <option selected="selected" value="members">_{Members}</option> + <option value="not_replied">_{Not Yet Replied}</option> + <option value="blocked">_{Blocked}</option> + </select> + </label> + </div> + </div> + <div class="list_header"> + _{Members}: 0 _{out of} 0 + </div> + <div class="members_list"> + </div> + </div> + + + <div class="clearfix"></div> + +</form> +</div> + Modified: public/stylesheets/Application.css =================================================================== --- public/stylesheets/Application.css 2008-03-27 08:23:02 UTC (rev 115) +++ public/stylesheets/Application.css 2008-03-28 16:54:26 UTC (rev 116) @@ -461,12 +461,18 @@ #content .submenu { background: #f7f7f7; - border-bottom: 1px solid #ccc; + border-bottom: 1px solid #cccccc; padding: 8px 20px 8px 20px; float: left; width: 605px; } +#content .submenushort { + background: #f7f7f7; + border-bottom: 1px solid #cccccc; + padding: 5px 0px 5px 15px; +} + .submenu .menu_block { float: left; } @@ -506,9 +512,14 @@ } #content .editform { - margin: 20px auto 20px auto; + padding: 20px 0px 20px 0px; + background: #f7f7f7; } +#content .formwrapper { + background: #f7f7f7; +} + .editform .formrow { clear: both; vertical-align: top; @@ -521,7 +532,7 @@ width: 150px; float: left; text-align: right; - padding: 3px 10px 3px; + padding: 3px 10px 3px 0px; } .formrow label.shortlabel { @@ -533,15 +544,24 @@ .formrow label.checkbox { font-weight: normal; - color: #000; + color: #000000; text-align: left; - padding: 3px 0px 3px; + padding: 3px 0px 3px 0px; + width: 400px; } +.formrow label.radiobutton { + font-weight: normal; + color: #000000; + text-align: left; + padding: 3px 0px 3px 0px; + width: 300px; +} + .formrow .formcol { float: left; width: 360px; - padding: 3px 0px 3px 0px; + padding: 0px 0px 5px 0px; margin: 0px; } @@ -556,6 +576,21 @@ background: url('/images/lock.png') no-repeat 0px; } +.formrow .formblock { + width: 235px; + margin: 3px 0px 3px 10px; +} + +.formrow .formblock.border { + border-top: 1px solid #aaaaaa; + border-bottom: 1px solid #aaaaaa; +} + +.formrow .formblock.gray { + color: #777777; + margin: 0px 0px 0px 25px; +} + .formrow textarea { width: 200px; height: 100px; @@ -618,8 +653,7 @@ display: block; color: #3b5998; padding: 5px 4px 5px 4px; - margin: 0px 4px 0px 4px; - background: #ffffff; + margin: 0px 4px 1px 4px; } .toggle_minitabs li a:focus { @@ -631,34 +665,17 @@ color: #ffffff; } +.toggle_minitabs li a.selected:hover { + text-decoration: none; +} + .toggle_minitabs li a.disabled { background: #ffffff; color: #999999; cursor: default; - border-bottom: 1px solid #3b5998; } .toggle_minitabs li a.disabled:hover { - text-decoration:none; -} - -.toggle_minitabs li.last a.selected { - margin-left: -1px; - border-left: 1px solid #5973a9; - border-right: 1px solid #36538f; -} - -.toggle_minitabs li.first a.selected { - margin: 0px; - border-left: 1px solid #36538f; - border-right: 1px solid #5973a9; -} - -.toggle_minitabs li.first.last a.selected { - border: 1px solid #36538f; -} - -.toggle_minitabs li a.selected:hover { text-decoration: none; } Modified: public/stylesheets/groupapp/Group.css =================================================================== --- public/stylesheets/groupapp/Group.css 2008-03-27 08:23:02 UTC (rev 115) +++ public/stylesheets/groupapp/Group.css 2008-03-28 16:54:26 UTC (rev 116) @@ -133,3 +133,46 @@ padding: 10px 0px 0px 0px; width: 300px; } + +.formwrapper .invite_column { + float: right; + width: 230px; + height: 300px; + border-left: 1px solid #cccccc; +} + +.invite_column .header_text { + font-weight: bold; + font-size: 12px; + text-align: center; + padding: 10px 0px 3px 0px; + color: #777777; +} + +.invite_column .friends_list { + margin: 0px 10px 5px 10px; + background: #ffffff; + border: 1px solid #cccccc; + height: 230px; +} + +.invite_column .submit { + text-align: center; +} + +.formwrapper .members { + background: #ffffff; + margin-right: 231px; +} + +.members .list_header { + background: #ffffff; + border-bottom: 1px solid #dddddd; + padding: 8px 0px 5px 15px; + font-weight: bold; +} + +.members .members_list { + background: #ffffff; + height: 240px; +} \ No newline at end of file This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |