CiviCRM Community Forums (archive)

*

News:

Have a question about CiviCRM?
Get it answered quickly at the new
CiviCRM Stack Exchange Q+A site

This forum was archived on 25 November 2017. Learn more.
How to get involved.
What to do if you think you've found a bug.



  • CiviCRM Community Forums (archive) »
  • Old sections (read-only, deprecated) »
  • Support »
  • Using CiviCRM (Moderator: Dave Greenberg) »
  • Ownership and Relationships
Pages: [1]

Author Topic: Ownership and Relationships  (Read 3817 times)

corster

  • I post occasionally
  • **
  • Posts: 72
  • Karma: 0
  • CiviCRM version: CiviCRM 4.0.x
  • CMS version: Joomla 1.7.x
Ownership and Relationships
December 28, 2010, 03:09:04 pm
Hello,


Being a car organization, one of the things we would like to capture are vehicles and who owns them.  However, our ideal setup would be to build a unique profile for each vehicle and attach them using relationships.  A one to many relationship.  One owner has many vehicles.  Those vehicles would also need to transfer to new owners as they are sold/traded/parted out and crushed.

We experimented with making an org called Corvair Registry.  It does work if there is a one to one relationship, but not a one to many.  My problem is how can we create a contact type "Vehicle" without it requiring a unique email address, first/last name, etc?  I would need to replace that form with custom data fields that i've already made and built into a custom profile.  This seems to be nearly possible.  Any guidance on how to get around the form issue would be helpful.


Thank you,

Curtis
Curtis

Dave Greenberg

  • Administrator
  • I’m (like) Lobo ;)
  • *****
  • Posts: 5760
  • Karma: 226
    • My CiviCRM Blog
Re: Ownership and Relationships
December 28, 2010, 04:41:17 pm
How about making "Vehicle" a contact subtype of Organization. That way you only the "Organization Name" field is required and you could either use Word Replacement (Administer > Option Lists > Word Replacements) OR customize the Organization edit template.
Protect your investment in CiviCRM by  becoming a Member!

corster

  • I post occasionally
  • **
  • Posts: 72
  • Karma: 0
  • CiviCRM version: CiviCRM 4.0.x
  • CMS version: Joomla 1.7.x
Re: Ownership and Relationships
December 28, 2010, 08:04:14 pm
I will give this a try and report back.  Thank you for your help!

Also, do you know of anyway to make the system auto-associate the Vehicle with the user that is creating it?  In other words, once a user creates the Vehicle, how would they connect it with a relationship?


Thanks Dave!

Curtis
Curtis

Dave Greenberg

  • Administrator
  • I’m (like) Lobo ;)
  • *****
  • Posts: 5760
  • Karma: 226
    • My CiviCRM Blog
Re: Ownership and Relationships
December 29, 2010, 10:22:51 am
I think you'll have to use hooks to do this (which will require some PHP and MySQL skills). You can begin exploring this here:
 http://en.flossmanuals.net/CiviCRM/DevelopIntro
Protect your investment in CiviCRM by  becoming a Member!

corster

  • I post occasionally
  • **
  • Posts: 72
  • Karma: 0
  • CiviCRM version: CiviCRM 4.0.x
  • CMS version: Joomla 1.7.x
Re: Ownership and Relationships
December 29, 2010, 01:22:10 pm
Update:  (Don't hate me for twisting this system into a pretzel! :) )  I have it working - sort of.  Here's what i've done, and my new issue...

The Good:
1)  Created new Sub Contact Type (under Org) "Vehicle"
2)  Created Custom Fields:  Owner (Autocomplete-Select), Year, Make, Model, Image Upload, etc...)
3)  Created a Custom Profile (Vehicle Registration) to which i added the custom fields and "Vehicle: Organization Name" labeled "Vin".  (Vin being required and the only unique information provided)
4)  Created a Group called "Corvair Registry" where "Vehicles" are automatically added to when created.  Later, once i had records, i opted for a smart group instead.
5)  I tested out the form in the backed with the instructions here:  http://wiki.civicrm.org/confluence/display/CRMDOC33/Configuring+Front-end+Profile+Listings+and+Forms+in+Joomla%21+Sites


The Bad:

Created a new menu on the front end setup for "create" and have the Custom Profile "Vehicle Registration" selected.  When i login and select that link, it gives me this error:

Quote
Sorry. A non-recoverable error has occurred.
We can't load the requested web page due to an incomplete link. This can be caused by using your browser's Back button or by using an incomplete or invalid link.

Return to home page.


Update:  For some reason, the menu link created in Joomla was currupt.  I delete it and created a new one and it works now.


Thanks,

Curtis
« Last Edit: December 30, 2010, 06:55:32 am by corster »
Curtis

corster

  • I post occasionally
  • **
  • Posts: 72
  • Karma: 0
  • CiviCRM version: CiviCRM 4.0.x
  • CMS version: Joomla 1.7.x
Re: Ownership and Relationships
December 30, 2010, 07:04:04 am
In addition to my update about the menu link, i have an issue with the autocomplete-select field.  I created one called "Owner".  On the backend it works beautifully.  On the front end, it can't find any contacts.


Can someone assist me in getting this working?
Curtis

Dave Greenberg

  • Administrator
  • I’m (like) Lobo ;)
  • *****
  • Posts: 5760
  • Karma: 226
    • My CiviCRM Blog
Re: Ownership and Relationships
December 30, 2010, 10:51:24 am
I think this is a permissions issue - since front-end joomla pages don't have "view contacts" permission (and permissioning is currently hard-coded in Joomla!). Note that there is a fundraising campaign to add permissioning for Joomla 1.6:

http://civicrm.org/mih#joomla
Protect your investment in CiviCRM by  becoming a Member!

corster

  • I post occasionally
  • **
  • Posts: 72
  • Karma: 0
  • CiviCRM version: CiviCRM 4.0.x
  • CMS version: Joomla 1.7.x
Re: Ownership and Relationships
December 30, 2010, 11:16:30 am
Ok, so how do we give the front-end "View Contacts"?  This is a key piece of this form and the only way to tie the vehicles to the individuals.


Thanks,

Curtis
Curtis

Donald Lobo

  • Administrator
  • I’m (like) Lobo ;)
  • *****
  • Posts: 15963
  • Karma: 470
    • CiviCRM site
  • CiviCRM version: 4.2+
  • CMS version: Drupal 7, Joomla 2.5+
  • MySQL version: 5.5.x
  • PHP version: 5.4.x
Re: Ownership and Relationships
December 30, 2010, 11:37:52 am

You currently cannot do that in Joomla (since permission support is quite primitive)

we do hope that the Make It Happen is funded: http://civicrm.org/civicrm/contribute/transact?reset=1&id=14 (currently at 34%) which will enable such things to happen with Joomla!

lobo
A new CiviCRM Q&A resource needs YOUR help to get started. Visit our StackExchange proposed site, sign up and vote on 5 questions

dimpzor

  • I’m new here
  • *
  • Posts: 13
  • Karma: 0
  • CiviCRM version: 4.0.4
  • CMS version: Joomla 1.6
  • MySQL version: 5.1.56
  • PHP version: 5.2.17
Re: Ownership and Relationships
May 31, 2011, 02:56:03 am
Apologies for opening an old post......

Is this issue rectified in Joomla 1.6?

I have autoselect contact fields in a public registration form that don't populate when searching.
I have allowed (in Joomla Access Control) CiviCRM: view all contacts in Public permissions, and i have also setup a role for Everyone - All Custom Data in the manage ACL's.

Still can't seem to get this to work. It work's fine when logged in as a joomla frontend administrator user.

Andy

Dave Greenberg

  • Administrator
  • I’m (like) Lobo ;)
  • *****
  • Posts: 5760
  • Karma: 226
    • My CiviCRM Blog
Re: Ownership and Relationships
June 01, 2011, 06:22:21 pm
Andy - There may be specific permissioning for the autocomplete widget, or there may be some incomplete implementations?? You may have to debug things a bit using Firebug (check the ajax url that is being called when you type in the autocompletes and view that URL both as "everyone" and as front end admin. If you need some guidance on this, jump on IRC.

Protect your investment in CiviCRM by  becoming a Member!

dimpzor

  • I’m new here
  • *
  • Posts: 13
  • Karma: 0
  • CiviCRM version: 4.0.4
  • CMS version: Joomla 1.6
  • MySQL version: 5.1.56
  • PHP version: 5.2.17
Re: Ownership and Relationships
June 03, 2011, 01:36:27 am
Thanks for the info Dave - acl rules fixed the issue. I needed to enable access civicrm in the Joomla Access Control setting for public access.
Now, is there a way to limit the autcomplete field to display only organisations? I have enabled limit listing to a group of organisation contacts i have created in the profile, but the autocomplete displays ALL records.

Andy

Dave Greenberg

  • Administrator
  • I’m (like) Lobo ;)
  • *****
  • Posts: 5760
  • Karma: 226
    • My CiviCRM Blog
Re: Ownership and Relationships
June 03, 2011, 10:54:21 am
Andy - There was a successful MIH to make this option a built-in feature (wlll be part of 4.1 release later this year). In the meantime, this blog covers some ways to do it w/ a bit of customization: http://civicrm.org/node/528
Protect your investment in CiviCRM by  becoming a Member!

noven

  • I’m new here
  • *
  • Posts: 4
  • Karma: 0
  • CiviCRM version: 4.0.4
  • CMS version: Joomla 1.6
  • MySQL version: 5.5.14
  • PHP version: 5.2
Re: Ownership and Relationships
July 18, 2011, 11:35:03 pm
Dimpzor - where do you set this ACL rule? I must be blind, I cannot find CiviCRM specific ACL permissions.

Dave Greenberg

  • Administrator
  • I’m (like) Lobo ;)
  • *****
  • Posts: 5760
  • Karma: 226
    • My CiviCRM Blog
Re: Ownership and Relationships
July 19, 2011, 04:40:10 pm
Hopefully helpful to see the Access Control editing for Joomla (1.6) on our public demo:

1. Login at: http://j16.demo.civicrm.org/administrator/ (demo / demo)
2. Go to Components > CiviCRM >Administer > Manager > Access Control (http://j16.demo.civicrm.org/administrator/?option=com_civicrm&task=civicrm/admin/access&reset=1)
3. Click Joomla Access Control - you'll see a dialog w/ sets of CiviCRM permissions for each user group.
Protect your investment in CiviCRM by  becoming a Member!

Pages: [1]
  • CiviCRM Community Forums (archive) »
  • Old sections (read-only, deprecated) »
  • Support »
  • Using CiviCRM (Moderator: Dave Greenberg) »
  • Ownership and Relationships

This forum was archived on 2017-11-26.