From kde-pim Sat Feb 18 17:18:00 2012 From: Dan Vratil Date: Sat, 18 Feb 2012 17:18:00 +0000 To: kde-pim Subject: Re: [Kde-pim] Contacts, Groups, Akonadi and Nepomuk Message-Id: <15462404.0GfiFVb8v5 () odin> X-MARC-Message: https://marc.info/?l=kde-pim&m=132958551319151 MIME-Version: 1 Content-Type: multipart/mixed; boundary="--===============5883270346760195753==" --===============5883270346760195753== Content-Type: multipart/signed; boundary="nextPart1651717.AGQjHNSr4j"; micalg="pgp-sha1"; protocol="application/pgp-signature" Content-Transfer-Encoding: 7Bit --nextPart1651717.AGQjHNSr4j Content-Transfer-Encoding: 7Bit Content-Type: text/plain; charset="us-ascii" On Saturday 18 of February 2012 15:55:19 Kevin Krammer wrote: > Hi, > > sorry for not replying earlier, I have just returned from a business trip. Hi, no problem :) > > On Sunday, 2012-02-12, Dan Vratil wrote: > > On Saturday 11 of February 2012 16:41:33 Kevin Krammer wrote: > > > On Saturday, 2012-02-11, Dan Vratil wrote: > > > > Hello, > > > > > > > > I 'd like to bring full support for contact groups to the Google > > > > Contacts resource. The problem is, that a single contact on Google can > > > > be listed in multiple groups, but Akonadi does not seem to support > > > > storing single instance of Akonadi::Item in multiple collections > > > > without duplication. > > > > > > See Akonadi::LinkJob and/or KABC::ContactGroup > > > > Thanks, the Linkjob is exactly what I needed. I've run to some trouble > > using it though. > > > > I have the root collection properly synchronized (that works as expected) > > and then I have a subcollection. When retrieveItems() is called for this > > subcollection, I fetch all items from the main collection, check their > > groups membership and then I call LinkJob to link some of the items from > > main collection with the subcollection. This works for the first time - I > > can see the linked items in the subcollection (and they are properly > > linked in Akonadi database), but when I restart KAddressBook, the linked > > items will not appear in the subcollection, no matter what I do. > > Weird, restarting a client like KAddressBook should not change data in > Akonadi. > Can you check if the shutdown or the restart of KAddressBook makes the > linked items vanish from the collection? The items are still linked in Akonadi database, I can see them all in collectionpimitemrelation table. They are just not fetched by the model. I suspect that the problem is, that the collections are not virtual. From reading documentation and going through other resources I got the impression that linked items are accepted by virtual collections only. I haven't tested it though, because the Collection::isVirtual() method is hardcoded for the search and nepomuktag resources only. > > > Any idea what I could be missing? > > No idea, sorry. Haven't used linking myself yet, just remembered that there > was a job for that purpose. > > Cheers, > Kevin > > > -- > Kevin Krammer, KDE developer, xdg-utils developer > KDE user support, developer mentoring -- Dan Vratil www.progdan.cz | dan@progdan.cz | Jabber: progdan@jabber.cz Fingerprint: 76C9 2F08 5D0D 6F9E 5AD4 2BFD 3A85 0307 F506 5B61 --nextPart1651717.AGQjHNSr4j Content-Type: application/pgp-signature; name="signature.asc" Content-Description: This is a digitally signed message part. -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.12 (GNU/Linux) iQEcBAABAgAGBQJPP91IAAoJEDqFAwf1Blthum8IAJPQrq3pwEwRkXfm7ILmb2c0 iBFxto03w79cc5DfGs/x7mRnoRgS99lLxiwlTzTqYu8/iRu6G/7XvWwD4VGUH+6b 3u0PrVXaA8wjsGyn8ZCWAiOazNKYEPL1+5PNsectuDzcRj139mvQ9yB8tL0t4xBC vRPd679kMVq08WAapwmcwVcyb/4A/5bK6deRuk8lifnglgCe/6npeJArkQSnARJ2 6QsbicJufNKRTyVYXsKoMTZ0y1LI862bL2UyjXA3ay9GxuFyleirmJFndeMoJC1s Wi+a0SDCTfr39NSh7H3NNGIdWmE9/xasaqUogWceOkFUPBJz49svIjHNohdOvd0= =j6eJ -----END PGP SIGNATURE----- --nextPart1651717.AGQjHNSr4j-- --===============5883270346760195753== Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Disposition: inline _______________________________________________ KDE PIM mailing list kde-pim@kde.org https://mail.kde.org/mailman/listinfo/kde-pim KDE PIM home page at http://pim.kde.org/ --===============5883270346760195753==--