는 또한 전에이 질문을 게시하고 아직 내 응용 프로그램에 대한 symfony2을 사용하고여러 엔티티 매니저
를 해결하지 않는 한 내가 다시 게시, 그리고 난 두 개의 데이터베이스 연결을 생성 읽기, 즉이를 위해 작성해야 내가 검색하고 우리가 다른 엔티티 관리자를 만들 수 있다는 것을 쉽게 발견하고 내가 그런 식으로 만들었습니다
내 parameters.ini 파일 http://dpaste.com/hold/800957/
내 config.yml 파일 http://dpaste.com/hold/800954/
개내 사용자 Entity 클래스 http://dpaste.com/hold/800963/
내 추종자 엔티티 클래스 : 컨트롤러 http://dpaste.com/hold/800964/
만들기 객체
$emWrite = $this->getDoctrine()->getEntityManager('write');
$em = $this->getDoctrine()->getEntityManager();
나는 그것이 나에게 다음과 같은 오류 제공 엔티티 계속 될 경우 :
을A new entity was found through the relationship '
AppBundle\Entity\Follower#user' that was not configured to cascade persist
operations for entity: adeel. Explicitly persist the new entity or configure
cascading persist operations on the relationship. If you cannot find out which
entity causes the problem implement AppBundle\Entity\User#__toString()
to get a clue. (500 Internal Server Error)
제발 이미 관련 기관의 양쪽에 속성을 유지주고 같은 많은 일들을 시도함에 따라이 같은 상세 페이지 나 ....
저를 도와주세요 ... 나를 위해 큰 문제를 만드는
나는 또한 나의 실체를 공유하고있다. 그러나 나는 벌써 이것을 시도했다. 그러나 그것은 잘 작동하지 않았다. –
@MuhammadUmair 두 엔티티 관리자 사이의 엔티티 공유는 훌륭한 선택이 아니며 다음과 같은 것을 할 수 없다고 생각한다. 계단식 동작 .... – DonCallisto
나는 내 질문을 편집하고 엔티티 세부 사항을 확인하십시오.이 질문에 답하고 정교하게 답하십시오. –