Skip to content

Instantly share code, notes, and snippets.

View albe's full-sized avatar
:octocat:

Alexander Berl albe

:octocat:
View GitHub Profile
<?php
namespace Db\Benchmark\Domain\Model;
/* *
* This script belongs to the TYPO3 Flow package "Db.Benchmark". *
* *
* */
use TYPO3\Flow\Annotations as Flow;
use Doctrine\ORM\Mapping as ORM;
<?php
namespace Albe\Extensions\Service;
/* *
* This script belongs to the TYPO3 Flow package "Trackmyrace.Portal". *
* *
* */
use TYPO3\Flow\Annotations as Flow;
Classes/TYPO3/Flow/Reflection/ObjectAccess.php | 47 ++++++++++++++++++++++++++
1 file changed, 47 insertions(+)
diff --git a/Classes/TYPO3/Flow/Reflection/ObjectAccess.php b/Classes/TYPO3/Flow/Reflection/ObjectAccess.php
index 014e2f3..0c84937 100644
--- a/Classes/TYPO3/Flow/Reflection/ObjectAccess.php
+++ b/Classes/TYPO3/Flow/Reflection/ObjectAccess.php
@@ -206,6 +206,7 @@ class ObjectAccess {
* Tries to set the property the following ways:
* - if target is an array, set value
15-03-20 18:28:57 CRITICAL Flow Uncaught exception #1416244515 in line 35 of C:\Users\Alex\workspace\TYPO3.Flow\Data\Temporary\Testing\Cache\Code\Flow_Object_Classes\TYPO3_Flow_Resource_Target_FileSystemSymlinkTarget.php: Could not publish "C:/Users/Alex/workspace/TYPO3.Flow/Packages/Framework/TYPO3.Fluid/Resources/Public" into resource publishing target "localWebDirectoryStaticResourcesTarget" because the source directory could not be symlinked at target location. - See also: 201503201828568d6805.txt
previousException => Uncaught exception #1: Warning: rename(C:/Users/Alex/workspace/TYPO3.Flow/Web/_Resources/Testing/Static/Packages/TYPO3.Fluid.550c58d9c3686.tmp,C:/Users/Alex/workspace/TYPO3.Flow/Web/_Resources/Testing/Static/Packages/TYPO3.Fluid): Zugriff verweigert (code: 5) in C:\Users\Alex\workspace\TYPO3.Flow\Data\Temporary\Testing\Cache\Code\Flow_Object_Classes\TYPO3_Flow_Resource_Target_FileSystemSymlinkTarget.php line 103
<f:for each="{results}" as="result">
<f:cycle values="{0: 'odd', 1: 'even'}" as="zebraClass">
<tr class="content_row result">
<tmr:table.column each="{columns}" as="column" value="val" iteration="it" result="{result}" partialPath="Results/Column/">
<td valign="middle" class="{zebraClass} {column.className}{f:if(condition:it.isFirst,then:' first')}">
<?php
namespace TYPO3\Flow\Persistence\Doctrine\Migrations;
use Doctrine\DBAL\Migrations\AbstractMigration,
Doctrine\DBAL\Schema\Schema;
/**
* Auto-generated Migration: Please modify to your need!
*/
class Version20150407145620 extends AbstractMigration {
[!!!][BUGFIX] Make bidirectional OneToOne relations work correctly
This change fixes bidirectional OneToOne relations, which previously
resulted in foreign keys being created on both sides. Therefore the
related entities could no longer be deleted.
The problem was that the joinColum mapping was created in every case,
which doctrine interprets as a secondary hint for the owning side.
The joinColumn should only be created for the owning side, i.e. only
for unidirectional OneToOne and for the inversedBy side of a
/**
* Delete a forum post
*
* @param \Examples\Forum\Domain\Model\Post $post
* @logged
* @return void
*/
public function deletePost(Post $post) {
$this->posts->remove($post);
}
/**
* Unlocks the site if this request has locked it.
*
* @return void
* @api
*/
public function unlockSite() {
if (is_resource($this->lockResource)) {
flock($this->lockResource, LOCK_UN);
$lockfile = fopen('lock', 'w+');
if (flock($lockfile, LOCK_EX | LOCK_NB)) {
unlink('lock');
echo 'locked...';
sleep(10);
flock($lockfile, LOCK_UN);
} else {
echo 'already locked...';
}