[Joomla-commits] r18750 - in development/branches/jcamp/components/com_projects: models views/documents/tmpl

0 views
Skip to first unread message

3den...@jcode001.directrouter.com

unread,
Sep 1, 2010, 4:29:56 PM9/1/10
to joomla-...@joomlacode.org
Author: 3dentech
Date: 2010-09-01 15:29:56 -0500 (Wed, 01 Sep 2010)
New Revision: 18750

Modified:
development/branches/jcamp/components/com_projects/models/project.php
development/branches/jcamp/components/com_projects/models/projects.php
development/branches/jcamp/components/com_projects/views/documents/tmpl/default_articles.php
Log:


Modified: development/branches/jcamp/components/com_projects/models/project.php
===================================================================
--- development/branches/jcamp/components/com_projects/models/project.php 2010-09-01 20:09:41 UTC (rev 18749)
+++ development/branches/jcamp/components/com_projects/models/project.php 2010-09-01 20:29:56 UTC (rev 18750)
@@ -194,7 +194,7 @@
$query = $db->getQuery(true);
$query->from('`#__projects` AS p');
$query->select(' FLOOR((COUNT(DISTINCT ntf.id) / COUNT(DISTINCT nt.id)) * 100) AS progress');
- $query->join('LEFT', '#__project_tasks AS nt ON nt.project_id=p.id');
+ $query->join('LEFT', '#__project_tasks AS nt ON nt.project_id=p.id AND nt.state != 0');
$query->join('LEFT', '#__project_tasks AS ntf ON ntf.project_id=p.id AND ntf.state=2');
$query->where('p.id='.$this->item->id);
$db->setQuery($query);

Modified: development/branches/jcamp/components/com_projects/models/projects.php
===================================================================
--- development/branches/jcamp/components/com_projects/models/projects.php 2010-09-01 20:09:41 UTC (rev 18749)
+++ development/branches/jcamp/components/com_projects/models/projects.php 2010-09-01 20:29:56 UTC (rev 18750)
@@ -66,7 +66,7 @@

// Progress
$query->select(' FLOOR((COUNT(DISTINCT ntf.id) / COUNT(DISTINCT nt.id)) * 100) AS progress');
- $query->join('LEFT', '#__project_tasks AS nt ON nt.project_id=p.id');
+ $query->join('LEFT', '#__project_tasks AS nt ON nt.project_id=p.id AND nt.state != 0');
$query->join('LEFT', '#__project_tasks AS ntf ON ntf.project_id=p.id AND ntf.state=2');
$query->group('p.id');

Modified: development/branches/jcamp/components/com_projects/views/documents/tmpl/default_articles.php
===================================================================
--- development/branches/jcamp/components/com_projects/views/documents/tmpl/default_articles.php 2010-09-01 20:09:41 UTC (rev 18749)
+++ development/branches/jcamp/components/com_projects/views/documents/tmpl/default_articles.php 2010-09-01 20:29:56 UTC (rev 18750)
@@ -50,10 +50,6 @@
<th class="list-title" id="tableOrdering">
<?php echo JHTML::_('grid.sort', 'JGLOBAL_TITLE', 'a.title', $listDirn, $listOrder) ; ?>
</th>
-
- <th class="list-category" id="tableOrdering">
- <?php echo JHTML::_('grid.sort', 'JCATEGORY', 'category_title', $listDirn, $listOrder) ; ?>
- </th>

<th class="list-author" id="tableOrdering3">
<?php echo JHTML::_('grid.sort', 'JAUTHOR', 'author', $listDirn, $listOrder); ?>
@@ -77,12 +73,15 @@

<td class="list-title">
<a href="<?php echo ProjectsHelper::getLink('document', $item->id); ?>">
- <?php echo $item->title; ?></a>
+ <?php echo $item->title; ?></a>
+
+ <?php if(!empty($item->category_title)): ?>
+ <span class="category">
+ (<?php echo $item->category_title; ?>)
+ </span>
+ <?php endif; ?>
</td>

- <td class="list-category">
- <?php echo $item->category_title; ?>
- </td>

<td class="list-author">
<?php echo $this->params->get('link_author', 0) ?

_______________________________________________
Joomla-commits mailing list
Joomla-...@joomlacode.org
http://joomlacode.org/mailman/listinfo/joomla-commits

Reply all
Reply to author
Forward
0 new messages