Browse Source

- Some little fixes

- Fixing comments publication
- Add numbers to bookmarks parts
- CSS fixs
pull/16/head
Jaussoin Timothée 12 years ago
parent
commit
5889449da4
  1. 4
      app/models/contact/Contact.php
  2. 10
      app/models/contact/ContactDAO.php
  3. 2
      app/models/postn/PostnDAO.php
  4. 98
      app/widgets/About/About.php
  5. 91
      app/widgets/About/about.tpl
  6. 3
      app/widgets/Account/Account.php
  7. 14
      app/widgets/Bookmark/Bookmark.php
  8. 4
      app/widgets/Discover/Discover.php
  9. 28
      app/widgets/Feed/Feed.php
  10. 1
      app/widgets/WidgetCommon/WidgetCommon.php
  11. 7
      themes/movim/css/forms.css
  12. 11
      themes/movim/css/posts.css

4
app/models/contact/Contact.php

@ -90,8 +90,6 @@ class Contact extends ModlModel {
{"type":"text"},
"description" :
{"type":"text"},
"privacy" :
{"type":"int", "size":11 },
"mood" :
{"type":"string", "size":128 },
"activity" :
@ -166,8 +164,6 @@ class Contact extends ModlModel {
$this->photobin = (string)$vcard->vCard->PHOTO->BINVAL;
$this->description = (string)$vcard->vCard->DESC;
$this->privacy = 0;
}
public function createThumbnails() {

10
app/models/contact/ContactDAO.php

@ -46,8 +46,6 @@ class ContactDAO extends ModlSQL {
description = :description,
privacy = :privacy,
mood = :mood,
activity = :activity,
@ -98,8 +96,6 @@ class ContactDAO extends ModlSQL {
'description' => $contact->description,
'privacy' => $contact->privacy,
// User Mood (contain serialized array) - XEP 0107
'mood' => $contact->mood,
@ -161,8 +157,6 @@ class ContactDAO extends ModlSQL {
description,
privacy,
mood,
activity,
@ -210,8 +204,6 @@ class ContactDAO extends ModlSQL {
:description,
:privacy,
:mood,
:activity,
@ -262,8 +254,6 @@ class ContactDAO extends ModlSQL {
'photobin' => $contact->photobin,
'description' => $contact->description,
'privacy' => $contact->privacy,
// User Mood (contain serialized array) - XEP 0107
'mood' => $contact->mood,

2
app/models/postn/PostnDAO.php

@ -290,7 +290,7 @@ class PostnDAO extends ModlSQL {
where postn.session = :session
and postn.node in ('.$commentsid.')
order by postn.published';
$this->prepare(
'Postn',
array(

98
app/widgets/About/About.php

@ -22,102 +22,4 @@ class About extends WidgetBase
{
function WidgetLoad() {
}
function build()
{
?>
<div class="tabelem padded" title="<?php echo t('About'); ?>" id="about">
<p>Movim is an XMPP-based communication platform. All the project, except the following software and resources, is under
<a href="http://www.gnu.org/licenses/agpl-3.0.html">GNU Affero General Public License v3</a>.
</p>
<h2><?php echo t('Thanks'); ?></h2>
<dl>
<dt>Developers</dt><dd><a href="http://edhelas.mov.im/">Jaussoin Timothée aka edhelas</a></dd>
<dt></dt><dd><a href="https://launchpad.net/~nodpounod">Ho Christine aka nodpounod</a></dd>
<dt></dt><dd><a href="https://etenil.net/">Pasquet Guillaume aka Etenil</a></dd>
<dt>Translators</dt><dd>Arabic - <a href="https://launchpad.net/~gharbeia">Ahmad Gharbeia أحمد غربية</a></dd>
<dt></dt><dd>Brazilian - <a href="https://launchpad.net/~dnieper650">millemiglia</a></dd>
<dt></dt><dd>Chinese - <a href="https://launchpad.net/~dudumomo">dudumomo</a></dd>
<dt></dt><dd>Danish - <a href="https://launchpad.net/~ole-carlsen-web">Ole Carlsen</a></dd>
<dt></dt><dd>Dutch - <a href="https://launchpad.net/~laurens-debackere">Laurens Debackere</a></dd>
<dt></dt><dd>English UK - <a href="https://launchpad.net/~kevinbeynon">Kevin Beynon</a>, <a href="https://launchpad.net/~influence-pc">Vincent</a></dd>
<dt></dt><dd>Esperanto - <a href="https://launchpad.net/~eliovir">Eliovir</a></dd>
<dt></dt><dd>Finish - <a href="https://launchpad.net/~e1484180">Timo</a></dd>
<dt></dt><dd>French -
<a href="https://launchpad.net/~hyogapag">Hyogapag</a>,
<a href="https://launchpad.net/~e1484180">Hélion du Mas des Bourboux</a>,
<a href="https://launchpad.net/~jonathanmm">JonathanMM</a>,
<a href="https://launchpad.net/~grossard-o">Ludovic Grossard</a>,
<a href="https://launchpad.net/~schoewilliam">Schoewilliam</a>,
<a href="https://launchpad.net/~influence-pc">Vincent</a>,
<a href="https://launchpad.net/~edhelas">edhelas</a>,
<a href="https://launchpad.net/~nodpounod">pou</a>
</dd>
<dt></dt><dd>German -
<a href="https://launchpad.net/~q-d">Daniel Winzen</a>,
<a href="https://launchpad.net/~jonas-ehrhard">Jonas Ehrhard</a>,
<a href="https://launchpad.net/~jonatan-zeidler-gmx">Jonatan Zeidler</a>,
<a href="https://launchpad.net/~kili4n">Kilian Holzinger</a>,
</dd>
<dt></dt><dd>Greek -
<a href="https://launchpad.net/~d-rotarou">Rotaru Dorin</a>,
<a href="https://launchpad.net/~yang-hellug">aitolos</a>
</dd>
<dt></dt><dd>Hebrew - <a href="https://launchpad.net/~genghiskhan">GenghisKhan</a></dd>
<dt></dt><dd>Hungarian - <a href="https://launchpad.net/~batisteo">Baptiste Darthenay</a></dd>
<dt></dt><dd>Italian -
<a href="https://launchpad.net/~andrea-caratti-phys">Andrea Caratti</a>,
<a href="https://launchpad.net/~giacomo-alzetta">Giacomo Alzetta</a>,
<a href="https://launchpad.net/~emailadhoc">kimj</a>
</dd>
<dt></dt><dd>Japanese - <a href="https://launchpad.net/~fdelbrayelle">Franky</a></dd>
<dt></dt><dd>Occitan (post 1500) -
<a href="https://launchpad.net/~cvalmary">Cédric VALMARY (Tot en òc)</a>,
<a href="https://launchpad.net/~caillonm">Maime</a>
</dd>
<dt></dt><dd>Portuguese -
<a href="https://launchpad.net/~jonathanmm">JonathanMM</a>,
<a href="https://launchpad.net/~dnieper650">millemiglia</a>
</dd>
<dt></dt><dd>Russian -
<a href="https://launchpad.net/~ak099">Aleksey Kabanov</a>,
<a href="https://launchpad.net/~vsharmanov">Vyacheslav Sharmanov</a>,
<a href="https://launchpad.net/~hailaga">hailaga</a>,
<a href="https://launchpad.net/~salnsg">Сергей Сальников</a>,
<a href="https://launchpad.net/~mr-filinkov">DeforaD</a>
</dd>
<dt></dt><dd>Spanish -
<a href="https://launchpad.net/~alejandrosg">Alejandro Serrano González</a>,
<a href="https://launchpad.net/~edu5800">Eduardo Alberto Calvo</a>,
<a href="https://launchpad.net/~estebanmainieri">Esteban Mainieri</a>,
<a href="https://launchpad.net/~victormezio">Oizem Mushroom</a>,
<a href="https://launchpad.net/~kaiser-715-deactivatedaccount">Ricardo Sánchez Baamonde</a>,
<a href="https://launchpad.net/~invrom">Ubuntu</a>,
<a href="https://launchpad.net/~orochiforja">orochiforja</a>
</dd>
<dt></dt><dd>Turkish -
<a href="https://launchpad.net/~basaran-caner">Caner Başaran</a>,
<a href="https://launchpad.net/~emreakca">emre akça</a>
</dd>
</dl>
<h2><?php echo t('Software'); ?></h2>
<dl>
<dt>Database Library</dt><dd>Modl - Movim DB Layer <a href="https://launchpad.net/modl">launchpad.net/modl</a> under AGPLv3</dd>
<dt>XMPP Library</dt><dd>Moxl - Movim XMPP Library <a href="https://launchpad.net/moxl">launchpad.net/moxl</a> under AGPLv3</dd>
</dl>
<br />
<dl>
<dt>Map Library</dt><dd>Leaflet <a href="http://leafletjs.com/">leafletjs.com</a> under BSD</dd>
<dt>Markdown</dt><dd>Michel Fortin <a href="http://michelf.ca/projects/php-markdown/">michelf.ca</a> ©Michel Fortin</dd>
<dt>HTML Fixer</dt><dd> Giulio Pons <a href="http://www.barattalo.it">barattalo.it</a></dd>
</dl>
<h2><?php echo t('Resources'); ?></h2>
<dl>
<dt>Icons</dt><dd>Famfamfam <a href="http://www.famfamfam.com/">www.famfamfam.com</a> under CC BY 3.0</dd>
<dt></dt><dd>Icomoon <a href="http://keyamoon.com/">by Keyamoon</a> under CC BY 3.0</dd>
</dl>
</div>
<?php
}
}

91
app/widgets/About/about.tpl

@ -0,0 +1,91 @@
<div class="tabelem padded" title="{$c->t('About')}" id="about">
<p>Movim is an XMPP-based communication platform. All the project, except the following software and resources, is under
<a href="http://www.gnu.org/licenses/agpl-3.0.html">GNU Affero General Public License v3</a>.
</p>
<h2>{$c->t('Thanks')}</h2>
<dl>
<dt>Developers</dt><dd><a href="http://edhelas.mov.im/">Jaussoin Timothée aka edhelas</a></dd>
<dt></dt><dd><a href="https://launchpad.net/~nodpounod">Ho Christine aka nodpounod</a></dd>
<dt></dt><dd><a href="https://etenil.net/">Pasquet Guillaume aka Etenil</a></dd>
<dt>Translators</dt><dd>Arabic - <a href="https://launchpad.net/~gharbeia">Ahmad Gharbeia أحمد غربية</a></dd>
<dt></dt><dd>Brazilian - <a href="https://launchpad.net/~dnieper650">millemiglia</a></dd>
<dt></dt><dd>Chinese - <a href="https://launchpad.net/~dudumomo">dudumomo</a></dd>
<dt></dt><dd>Danish - <a href="https://launchpad.net/~ole-carlsen-web">Ole Carlsen</a></dd>
<dt></dt><dd>Dutch - <a href="https://launchpad.net/~laurens-debackere">Laurens Debackere</a></dd>
<dt></dt><dd>English UK - <a href="https://launchpad.net/~kevinbeynon">Kevin Beynon</a>, <a href="https://launchpad.net/~influence-pc">Vincent</a></dd>
<dt></dt><dd>Esperanto - <a href="https://launchpad.net/~eliovir">Eliovir</a></dd>
<dt></dt><dd>Finish - <a href="https://launchpad.net/~e1484180">Timo</a></dd>
<dt></dt><dd>French -
<a href="https://launchpad.net/~hyogapag">Hyogapag</a>,
<a href="https://launchpad.net/~e1484180">Hélion du Mas des Bourboux</a>,
<a href="https://launchpad.net/~jonathanmm">JonathanMM</a>,
<a href="https://launchpad.net/~grossard-o">Ludovic Grossard</a>,
<a href="https://launchpad.net/~schoewilliam">Schoewilliam</a>,
<a href="https://launchpad.net/~influence-pc">Vincent</a>,
<a href="https://launchpad.net/~edhelas">edhelas</a>,
<a href="https://launchpad.net/~nodpounod">pou</a>
</dd>
<dt></dt><dd>German -
<a href="https://launchpad.net/~q-d">Daniel Winzen</a>,
<a href="https://launchpad.net/~jonas-ehrhard">Jonas Ehrhard</a>,
<a href="https://launchpad.net/~jonatan-zeidler-gmx">Jonatan Zeidler</a>,
<a href="https://launchpad.net/~kili4n">Kilian Holzinger</a>,
</dd>
<dt></dt><dd>Greek -
<a href="https://launchpad.net/~d-rotarou">Rotaru Dorin</a>,
<a href="https://launchpad.net/~yang-hellug">aitolos</a>
</dd>
<dt></dt><dd>Hebrew - <a href="https://launchpad.net/~genghiskhan">GenghisKhan</a></dd>
<dt></dt><dd>Hungarian - <a href="https://launchpad.net/~batisteo">Baptiste Darthenay</a></dd>
<dt></dt><dd>Italian -
<a href="https://launchpad.net/~andrea-caratti-phys">Andrea Caratti</a>,
<a href="https://launchpad.net/~giacomo-alzetta">Giacomo Alzetta</a>,
<a href="https://launchpad.net/~emailadhoc">kimj</a>
</dd>
<dt></dt><dd>Japanese - <a href="https://launchpad.net/~fdelbrayelle">Franky</a></dd>
<dt></dt><dd>Occitan (post 1500) -
<a href="https://launchpad.net/~cvalmary">Cédric VALMARY (Tot en òc)</a>,
<a href="https://launchpad.net/~caillonm">Maime</a>
</dd>
<dt></dt><dd>Portuguese -
<a href="https://launchpad.net/~jonathanmm">JonathanMM</a>,
<a href="https://launchpad.net/~dnieper650">millemiglia</a>
</dd>
<dt></dt><dd>Russian -
<a href="https://launchpad.net/~ak099">Aleksey Kabanov</a>,
<a href="https://launchpad.net/~vsharmanov">Vyacheslav Sharmanov</a>,
<a href="https://launchpad.net/~hailaga">hailaga</a>,
<a href="https://launchpad.net/~salnsg">Сергей Сальников</a>,
<a href="https://launchpad.net/~mr-filinkov">DeforaD</a>
</dd>
<dt></dt><dd>Spanish -
<a href="https://launchpad.net/~alejandrosg">Alejandro Serrano González</a>,
<a href="https://launchpad.net/~edu5800">Eduardo Alberto Calvo</a>,
<a href="https://launchpad.net/~estebanmainieri">Esteban Mainieri</a>,
<a href="https://launchpad.net/~victormezio">Oizem Mushroom</a>,
<a href="https://launchpad.net/~kaiser-715-deactivatedaccount">Ricardo Sánchez Baamonde</a>,
<a href="https://launchpad.net/~invrom">Ubuntu</a>,
<a href="https://launchpad.net/~orochiforja">orochiforja</a>
</dd>
<dt></dt><dd>Turkish -
<a href="https://launchpad.net/~basaran-caner">Caner Başaran</a>,
<a href="https://launchpad.net/~emreakca">emre akça</a>
</dd>
</dl>
<h2>{$c->t('Software')}</h2>
<dl>
<dt>Database Library</dt><dd>Modl - Movim DB Layer <a href="https://launchpad.net/modl">launchpad.net/modl</a> under AGPLv3</dd>
<dt>XMPP Library</dt><dd>Moxl - Movim XMPP Library <a href="https://launchpad.net/moxl">launchpad.net/moxl</a> under AGPLv3</dd>
</dl>
<br />
<dl>
<dt>Map Library</dt><dd>Leaflet <a href="http://leafletjs.com/">leafletjs.com</a> under BSD</dd>
<dt>Markdown</dt><dd>Michel Fortin <a href="http://michelf.ca/projects/php-markdown/">michelf.ca</a> ©Michel Fortin</dd>
</dl>
<h2>{$c->t('Resources')}</h2>
<dl>
<dt>Icons</dt><dd>Famfamfam <a href="http://www.famfamfam.com/">www.famfamfam.com</a> under CC BY 3.0</dd>
<dt></dt><dd>Icomoon <a href="http://keyamoon.com/">by Keyamoon</a> under CC BY 3.0</dd>
</dl>
</div>

3
app/widgets/Account/Account.php

@ -377,6 +377,9 @@ class Account extends WidgetBase {
function build()
{
$warning = '';
if(isset($_GET['err']))
switch ($_GET['err']) {
case 'datamissing':
$warning = '

14
app/widgets/Bookmark/Bookmark.php

@ -217,6 +217,8 @@ class Bookmark extends WidgetBase
$url = '';
$conference = '';
$subscription = '';
$urlnum = $conferencenum = $subscriptionnum = 0;
$sd = new \modl\SubscriptionDAO();
@ -230,6 +232,8 @@ class Bookmark extends WidgetBase
$s->node.'
</a>
</li>';
$subscriptionnum++;
}
}
@ -249,6 +253,8 @@ class Bookmark extends WidgetBase
<a href="#" onclick="'.$join.'">'.$b['name'].'</a>
<a href="#" onclick="'.$remove.'">X</a>
</li>';
$conferencenum++;
break;
case 'url':
$remove = $this->genCallAjax('ajaxBookmarkUrlRemove', "'".$b['url']."'");
@ -259,13 +265,15 @@ class Bookmark extends WidgetBase
</a>
<a href="#" onclick="'.$remove.'">X</a>
</li>';
$urlnum++;
break;
}
}
if($conference != '') {
$html .= '
<h3>'.t('Conferences').'</h3>
<h3>'.t('Conferences').' - '.$conferencenum.'</h3>
<ul>'.
$conference.'
</ul>';
@ -273,7 +281,7 @@ class Bookmark extends WidgetBase
if($subscription != '') {
$html .= '
<h3>'.t('Groups').'</h3>
<h3>'.t('Groups').' - '.$subscriptionnum.'</h3>
<ul>'.
$subscription.'
</ul>';
@ -281,7 +289,7 @@ class Bookmark extends WidgetBase
if($url != '') {
$html .= '
<h3>'.t('Links').'</h3>
<h3>'.t('Links').' - '.$urlnum.'</h3>
<ul>'.
$url.'
</ul>';

4
app/widgets/Discover/Discover.php

@ -20,12 +20,12 @@ class Discover extends WidgetCommon {
foreach($users as $user) {
$html .= '
<div class="post">
<a href="'.Route::urlize('blog', array($user->jid, false)).'">
<a href="'.Route::urlize('blog', array($user->jid, 'urn:xmpp:microblog:0')).'">
<img class="avatar" src="'.$user->getPhoto('m').'"/>
</a>
<div class="postbubble">
<span class="name">
<a href="'.Route::urlize('blog', array($user->jid, false)).'">'.
<a href="'.Route::urlize('blog', array($user->jid, 'urn:xmpp:microblog:0')).'">'.
$user->getTrueName().'
</a>
</span>

28
app/widgets/Feed/Feed.php

@ -156,28 +156,6 @@ class Feed extends WidgetCommon {
return $html;
}
/*function prepareNews($start) {
$pd = new \modl\PostnDAO();
$pl = $pd->getNews($start+1, $this->_feedsize);
$html = $this->preparePosts($pl);
$html .= $this->prepareNext($start, $html, $pl, 'ajaxGetNews');
return $html;
}*/
/*function prepareFeeds() {
$html = '
<div class="tabelem" id="feedposts" title="'.t('Feed').'">
'.$this->prepareFeed(-1).'
</div>
<div class="tabelem" id="newsposts" title="'.t('News').'">
'.$this->prepareNews(-1).'
</div>';
return $html;
}*/
function ajaxGetFeed($start) {
$html = $this->prepareFeed($start);
@ -185,12 +163,6 @@ class Feed extends WidgetCommon {
RPC::commit();
}
/*function ajaxGetNews($start) {
$html = $this->prepareNews($start);
RPC::call('movim_append', 'newsposts', $html);
RPC::commit();
}*/
function onStream($payload) {
$html = $this->prepareFeed(-1);

1
app/widgets/WidgetCommon/WidgetCommon.php

@ -217,7 +217,6 @@ class WidgetCommon extends WidgetBase {
}
protected function printComments($post, $comments, $public = false) {
$view = $this->loadTemplate();
$view->assign('post', $post);
$view->assign('comments', $this->prepareComments($comments));

7
themes/movim/css/forms.css

@ -142,8 +142,11 @@ legend {
.element input[type="radio"] + label {
float: left;
width: 46%;
margin-right: 3%;
width: 18%;
margin-right: 2%;
box-sizing: border-box;
-webkit-box-sizing: border-box;
-moz-box-sizing: border-box;
}
.element input[type="radio"] + label:hover {

11
themes/movim/css/posts.css

@ -66,7 +66,7 @@
-moz-box-sizing: border-box;
}
.post span {
.post .header span {
font-weight: bold;
overflow: hidden;
padding-right: 0.5em;
@ -80,11 +80,6 @@
float: left;
}
.post span.fold {
float: right;
margin-right: 1.5em;
}
.post span a:hover {
text-decoration: underline;
}
@ -100,7 +95,7 @@
color: white;
margin-right: 1em;
font-size: 0.8em;
padding: 0 1em;
padding: 0.5em 1em;
position: relative;
border-radius: 0.2em;
}
@ -126,7 +121,7 @@
float: right;
margin-left: 1em;
padding-right: 0.5em;
line-height: 2em;
max-width: 300px;
white-space: nowrap;
overflow: hidden;

Loading…
Cancel
Save