Commit 85a21221 authored by Vincent Horváth's avatar Vincent Horváth

hot fix

parent f832977b
......@@ -79,10 +79,10 @@ public class EntityOverwriteGenerator extends SymfonyGenerator {
"* @ORM\\Joinfield(name=\"`" + field.getName() + "_id`\", referencedfieldName=\"`id`\")");
} else if (field.getType().equals(FieldType.ONE_TO_MANY)) {
fieldsTemplate.add("metadata", "* @ORM\\ManyToOne(targetEntity=\"\\App\\Entity\\" + field.getRelationShip().getName() + "\")\n" +
"* @ORM\\Joinfield(name=\"`" + field.getName() + "_id`\", referencedfieldName=\"`id`\")");
"* @ORM\\JoinColumn(name=\"`" + field.getName() + "_id`\", referencedColumnName=\"`id`\")");
} else if (field.getType().equals(FieldType.MANY_TO_MANY)) {
fieldsTemplate.add("metadata", "* @ORM\\ManyToMany(targetEntity=\"\\App\\Entity\\" + field.getRelationShip().getName() + "\")\n" +
"* @ORM\\Joinfield(name=\"`" + field.getName() + "_id`\", referencedfieldName=\"`id`\")");
"* @ORM\\JoinColumn(name=\"`" + field.getName() + "_id`\", referencedColumnName=\"`id`\")");
} else {
fieldsTemplate.add("metadata", "* @ORM\\Column(type=\"" + doctrineMapperHelper.get(field.getType().toString()) + "\", name=\"`" + HelperFunctions.mysqlFormat(field.getName()) + "`\")");
}
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment