##// END OF EJS Templates
Rebase fix CatalogueCatalogue
perrinel -
r1355:ce843f4ddfb0
parent child
Show More
@@ -190,22 +190,14 void CatalogueController::addEvent(std::shared_ptr<DBEvent> event)
190 190 impl->m_CatalogueDao.updateEvent(eventTemp);
191 191 }
192 192
193
194 // update event parameter
195 auto uniqIdPredicate = std::make_shared<ComparaisonPredicate>(
196 QString{"uniqId"}, event->getUniqId(), ComparaisonOperation::EQUALEQUAL);
197
198 auto workRepositoryPredicate = std::make_shared<ComparaisonPredicate>(
199 QString{"repository"}, impl->toWorkRepository(event->getRepository()),
200 ComparaisonOperation::EQUALEQUAL);
201
202 auto workPred = std::make_shared<CompoundPredicate>(CompoundOperation::AND);
203 workPred->AddRequestPredicate(uniqIdPredicate);
204 workPred->AddRequestPredicate(workRepositoryPredicate);
205
193 auto workPred = impl->createFinder(event->getUniqId(), event->getRepository(), DBType::WORK);
206 194
207 195 auto workEvent = impl->m_CatalogueDao.getEvent(workPred);
208 196 *event = workEvent;
197
198
199 auto uniqueId = impl->eventUniqueKey(event);
200 impl->m_EventKeysWithChanges.insert(uniqueId);
209 201 }
210 202
211 203 void CatalogueController::saveEvent(std::shared_ptr<DBEvent> event)
General Comments 0
You need to be logged in to leave comments. Login now