Changeset 16091
- Timestamp:
- 04/15/08 14:31:32 (6 months ago)
- Files:
Legend:
- Unmodified
- Added
- Removed
- Modified
- Copied
- Moved
trunk/midcom/midcom.helper.replicator/exporter/staging2live.php
r16087 r16091 188 188 function _check_approval(&$object) 189 189 { 190 static $parent_check_stack = array(); 190 191 debug_push_class(__CLASS__, __FUNCTION__); 191 192 debug_add("Called for {$object->guid}"); … … 244 245 // Check the parent also, as that may be unapproved 245 246 $parent = $object->get_parent(); 246 if ($parent) 247 { 247 if ( is_object($parent) 248 && isset($parent->guid) 249 && !empty($parent->guid)) 250 { 251 array_push($parent_check_stack, $object->guid); 248 252 $this->exportability[$object->guid] = $this->is_exportable($parent, false); 249 253 array_pop($parent_check_stack); 250 254 if (!$this->exportability[$object->guid]) 251 255 { 252 256 // TODO: Uimessage, but how to give only one ?? 253 257 $GLOBALS['midcom_helper_replicator_logger']->log_object($object, 'Parent not approved, skipping'); 258 if (empty($parent_check_stack)) 259 { 260 // Empty stack means we're not inside parent recursion, thus we can raise an UIMessage 261 $_MIDCOM->load_library('midcom.helper.reflector'); 262 $ref = new midcom_helper_reflector($object); 263 $_MIDCOM->uimessages->add 264 ( 265 $this->_l10n->get('midcom.helper.replicator'), 266 sprintf 267 ( 268 $this->_l10n->get('%s %s could not be exported for replication because one of its parents is not approved'), 269 $ref->get_class_label(), 270 $ref->get_object_label($object) 271 ), 272 'warning' 273 ); 274 } 254 275 } 255 276 } trunk/midcom/midcom.helper.replicator/locale/default.en.txt
r15833 r16091 56 56 ---STRINGEND 57 57 58 ---STRING http post transport 59 HTTP POST transport 60 ---STRINGEND 61 58 62 ---STRING imported 59 63 Imported to database … … 69 73 70 74 ---STRING mirroring subscription 71 Mirror 75 Mirroring Subscription 72 76 ---STRINGEND 73 77 … … 88 92 ---STRINGEND 89 93 94 ---STRING replication queue %s cannot be written by Apache user 95 Replication queue %s cannot be written by Apache user 96 ---STRINGEND 97 90 98 ---STRING replication queue %s does not exist 91 99 Replication queue %s does not exist 92 ---STRINGEND93 94 ---STRING replication queue %s cannot be written by Apache user95 Replication queue %s cannot be written by Apache user96 100 ---STRINGEND 97 101 … … 106 110 ---STRING staging2live subscription 107 111 Staging/live 112 ---STRINGEND 113 114 ---STRING staging2live subscription with type filter 115 Staging2live subscription with type filter 108 116 ---STRINGEND 109 117 … … 132 140 ---STRINGEND 133 141 134 ---STRING http post transport135 HTTP POST transport 142 ---STRING %s %s could not be exported for replication because one of its parents is not approved 143 %s %s could not be exported for replication because one of its parents is not approved 136 144 ---STRINGEND 137 145 138 ---STRING mirroring subscription139 Mirroring Subscription140 ---STRINGEND141 142 ---STRING staging2live subscription with type filter143 Staging2live subscription with type filter144 ---STRINGENDtrunk/midcom/midcom.helper.replicator/locale/default.fi.txt
r12743 r16091 120 120 ---STRINGEND 121 121 122 ---STRING %s %s could not be exported for replication because one of its parents is not approved 123 %s %s ei voida replikoida koska jokin sen vanhemmista ei ole hyvÀksytty. 124 ---STRINGEND 125
