comanage-dev - [comanage-dev] r641 - in registry/trunk/app: Controller View/CoLocalizations
Subject: COmanage Developers List
List archive
- From:
- To:
- Subject: [comanage-dev] r641 - in registry/trunk/app: Controller View/CoLocalizations
- Date: Thu, 12 Dec 2013 18:29:24 -0500
Author: benno
Date: 2013-12-12 18:29:24 -0500 (Thu, 12 Dec 2013)
New Revision: 641
Modified:
registry/trunk/app/Controller/CoLocalizationsController.php
registry/trunk/app/View/CoLocalizations/fields.inc
Log:
Cleanup Localization Override issues (CO-707)
Modified: registry/trunk/app/Controller/CoLocalizationsController.php
===================================================================
--- registry/trunk/app/Controller/CoLocalizationsController.php 2013-12-12
05:13:40 UTC (rev 640)
+++ registry/trunk/app/Controller/CoLocalizationsController.php 2013-12-12
23:29:24 UTC (rev 641)
@@ -91,6 +91,12 @@
$args['conditions']['CoLocalization.co_id'] =
$reqdata['CoLocalization']['co_id'];
$args['conditions']['CoLocalization.lkey'] =
$reqdata['CoLocalization']['lkey'];
$args['conditions']['CoLocalization.language'] =
$reqdata['CoLocalization']['language'];
+ if(!empty($curdata['CoLocalization']['id'])
+ && !empty($reqdata['CoLocalization']['id'])
+ && ($curdata['CoLocalization']['id'] ==
$reqdata['CoLocalization']['id'])) {
+ // We're editing the current record
+ $args['conditions']['CoLocalization.id <>'] =
$reqdata['CoLocalization']['id'];
+ }
$args['contain'] = false;
if($this->CoLocalization->find('count', $args)) {
Modified: registry/trunk/app/View/CoLocalizations/fields.inc
===================================================================
--- registry/trunk/app/View/CoLocalizations/fields.inc 2013-12-12 05:13:40
UTC (rev 640)
+++ registry/trunk/app/View/CoLocalizations/fields.inc 2013-12-12 23:29:24
UTC (rev 641)
@@ -115,12 +115,20 @@
<div id="original">
</div>
</td>
+ </tr>
+ <tr>
+ <td>
+ <i><font class="required"><?php echo _txt('fd.req');
?></font></i><br />
+ </td>
+ <td>
+ <?php
+ if($e) {
+ print $this->Form->submit($submit_label, array('onClick' =>
'on_submit()'));
+ print $this->Form->button(_txt('op.reset'),
+ array('type'=>'reset'));
+ }
+ ?>
+ </td>
+ </tr>
</tbody>
</table>
-<?php
- if($e) {
- print $this->Form->submit($submit_label, array('onClick' =>
'on_submit()'));
- print $this->Form->button(_txt('op.reset'),
- array('type'=>'reset'));
- }
-?>
- [comanage-dev] r641 - in registry/trunk/app: Controller View/CoLocalizations, svnlog, 12/12/2013
Archive powered by MHonArc 2.6.16.