function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
Jai-SinghJai-Singh 

Queue Owner to specific user owner on custom object

hi

I ran into a problem that Admin created a workflow to update owner field of a custom object to a public Queue. Now how a member of the queue will claim the ownership of  any of the Record of the Custom Object? Will the ownership be automatically assigned to the first user access the record or there is any standard button to claim the ownership or the accessing user has to manually change the owner field to him/her self? If the last one is the solution then what if the accessing user is assigned to a profile not having Transfer Record Administrative Permission but is the member of the queue?

 

Can somebody help me out of this.

 

Thanks

Best Answer chosen by Admin (Salesforce Developers) 
TrimbleAgTrimbleAg

Personally I created a button for the case object called take cases. It is on the detail page and when clicked auto-assigns the ownership to the user and takes them straight to the edit screen.

 

However ownership can be manually change also as you know.

 

As long as the profile have the "Edit" right to the object, they can transfer ownership. I beleive that you are thinking about the admin rights for the mass transfer records, that only admins should have.

 

 

All Answers

TrimbleAgTrimbleAg

Personally I created a button for the case object called take cases. It is on the detail page and when clicked auto-assigns the ownership to the user and takes them straight to the edit screen.

 

However ownership can be manually change also as you know.

 

As long as the profile have the "Edit" right to the object, they can transfer ownership. I beleive that you are thinking about the admin rights for the mass transfer records, that only admins should have.

 

 

This was selected as the best answer
Jai-SinghJai-Singh

Thank you TrimbleAg,

 

So I am taking this as queue ownered records are claimed by the accessing user, member of the queue, by changing owner to him/her self.

 

one can also make custom button using Visualforce and Apex to assign the loged in user as owner of the record when the button is clicked

TrimbleAgTrimbleAg

Actually the button is just JavaScript and fairly simple really.

 

Here is the code below that is used for the Case object.

 

BehaviorExecute JavaScriptDisplay TypeDetail Page Button
OnClick JavaScript{!REQUIRESCRIPT("/soap/ajax/13.0/connection.js")}

var caseObj = new sforce.SObject("Case");
caseObj.Id = '{!Case.Id}';
caseObj.OwnerId = '{!$User.Id}';
var result = sforce.connection.update([caseObj]);

if (result[0].success=='false') {
alert(result[0].errors.message);
} else {
window.parent.location.href="/{!Case.Id}/e?retURL=%2F{!Case.Id}";
}
Nidhi MeshramNidhi Meshram
When you assign record to QUEUE any Queue member can take ownership of the record. It will allocate to only one user in the queue.
All users have options to take the ownership but only one user can take ownership at a time. So in case if any user is on leave then other user can handle that case. Need to build Lighning Component button so that lead queue members can assign that record to themselves. Change owner field would be changed to user name who had taken the ownership? I am new to Lightning Can anyone help me in coding?