Add message if a project is not shared

This commit is contained in:
Eike Foken
2011-09-09 00:49:11 +02:00
parent a017aaff06
commit 16517382da

View File

@@ -18,7 +18,8 @@
</thead> </thead>
<tbody> <tbody>
<?php <?php
foreach ($shares as $share): if (count($shares) > 0):
foreach ($shares as $share):
?> ?>
<tr> <tr>
<td><a href="<?=site_url('users/profile/' . $share['username']);?>"><?=$share['firstname'];?> <?=$share['lastname'];?></a></td> <td><a href="<?=site_url('users/profile/' . $share['username']);?>"><?=$share['firstname'];?> <?=$share['lastname'];?></a></td>
@@ -26,7 +27,14 @@
<td><a href="?action=delete&user_id=<?=$share['user_id'];?>"><?=_('Delete');?></a></td> <td><a href="?action=delete&user_id=<?=$share['user_id'];?>"><?=_('Delete');?></a></td>
</tr> </tr>
<?php <?php
endforeach; endforeach;
else:
?>
<tr>
<td colspan="3"><?=_('This project is not yet shared with anyone.');?></td>
</tr>
<?php
endif;
?> ?>
</tbody> </tbody>
</table> </table>
@@ -48,7 +56,7 @@
endforeach; endforeach;
?> ?>
</select> </select>
<?=form_dropdown('rights', array('Can view', 'Can edit'), $share['can_edit'], 'class="drop"')?> <?=form_dropdown('rights', array('Can view', 'Can edit'), 0, 'class="drop"')?>
<?=form_submit('add', _('Share'), 'class="submit"');?> <?=form_submit('add', _('Share'), 'class="submit"');?>
</div> </div>
</li> </li>