Can Price Book be manually shared in Salesforce?
(I am not seeing the button "Sharing" on the Price Book UI)
Thank you.
If you don't see the "Sharing" button check the Sharing Settings for your Price Book object. It will probably be set to "Use" where doesn't really make sense to have a Sharing button.
Related
I am outputting form inputs on the final page of a checkout field, titled "Review & checkout"... on this page I display the plan the customer picked and the personal info they provided so far.
I have no problem showing fields like Name or Email, as the value inputted is being shown, as Angular displays whatever was in the value="" field of the input.
To display the subscription plan that the customer picked, it's trickier.
The value field is already being utilized to tell stripe which plan the customer should be charged for.
How can I get around this problem?
I am able to display the stripe-id for the plan but it is not user-friendly. They are id's like trad-2-5, trad-2-6, trad-2-7... so what I want to do is display a custom title when trad-2-5 is selected, and so on...
Any help is greatly appreciated!!Thanks
There are a couple of ways you could do this.
The really silly answer is that you can just create a map of plan ids to human-readable descriptions in the Angular controller code, then display that. This might be enough for what you want, but it's also pretty hacky, and not a lot of fun to maintain.
The less silly answer depends on where these plan ids are coming from. If they are coming from an endpoint on your server, which gets them from Stripe's plans endpoint, then you could also pass along the display name of the plan from that endpoint. If the plan id's are hard coded somewhere, or whitelisted, then this may not make sense. However, that display name is what will appear on the customer's invoice, and credit card statement, so it'd be nice to make it match up with what they see on the checkout page.
I'm a Yii newbie. We have two MVC's in our test app: Apparatus and Order. I should be able to give a function where if a user clicks so, I import the selected row to Order, including the foreign key. It's like a makeshift cart. The problem is, since we are using GII, the CRUD and MODEL are already hard coded and it's confusing whether I should just put something like
$db->createCommand('INSERT INTO customer (name) VALUES (:name)', [':name' => 'Qiang',])->execute();
Does anybody have advice on how to go about it?
From your question I can see you are newbie to MVC as well. So I strongly recommend you to follow guide in http://www.yiiframework.com/doc/guide/1.1/en/basics.mvc and the fundamentals section.
Don't worry about Gii's auto generated codes. You can go ahead and customize them to achieve your goals.
For your question, There should be a create() function in OrderController if you have used Gii's CRUD generation. So you have to pass the apparatus_id to order controller from add to cart button/link. From there you get the foreign key.
I have the next issue.
I have a custom object called 'Application', and I have this requirement:
"Show all Contacts related to an Application. Create a field on Application object, must be read only".
I solve it with apex code. 'Application' has a lookup to Opportunity, Opportunity to Account, and all my contacts have AccountId, so this way, I get all the contacts using apex code in a trigger.
But, I've been ask to change this to a Formula field in Application object.
So, my issue is next. I'm not able to get all contacts with advance formula editor, because they're not part of any object. I have no master-detail relationship.
Does any one know how can I achieve this using configuration? I should not use apex code for this req.
Thank in advance guys.
I don't think you can do it.
In formulas / merge fields syntax there's no way to go "up, up then down" (Application -> Opportunity -> Account -> down to Contacts related list). There's also nothing that would let you loop through Contacts (and display what? Ids? Names? Emails?). Roughly speaking you can only go up through dots.
You might want to explore path of "cross object workflow" rules but I imagine that when I add a new Contact to Account it should somehow "spread itself" to all related Applications? There's no straight way to fire a workflow on delete too - so you'd eventually end up with inaccurate list.
I'd say trigger was a good solution. Maybe it ws unoptimized but if it has to be in a field - tough.
There might be a fairly simple way of achieving that by embedding a visualforce page within Application page layout.
This should be doable with pure Visualforce (so technically there will be no Apex code ;))
Something as simple as
<apex:relatedList list="Contacts" subject="Application__c.Opportunity__r.AccountId" />
would be a good start (if you want your own layout and not a rel. list - you should be still able to pull it off with <apex:repeat> or <apex:pageBlockTable>.
There's one BUT here: it's not a field, just a display trick. Forget about using it in reports, mobile applications etc.
Another way - would it be acceptable to be 1 click away from these contacts? You could make a report "Account with Contacts", filter it by Id of one Account and later use "URL hacking" to change the filter depending on from which Application you'll click it. This link could be either a formula field or a real custom button/link. Technically - it's pure config, no apex & VF.
You can read more about URL hacking at Ray Dehler's excellent post and specifically about dynamic Reports here or here.
I'm still working my way up the learning curve for Drupal and I can't seem to find an answer.
I have created a custom content type. In my case, it describes an investment property (purchase price, rental income, etc).
I now want to create another couple content types: Expense and Income that will be used to track any expenses or income that apply to a particular property.
What I can't figure out is how to let the user choose which property an expense or income would apply to. That is, I want a field where the user can select the property.
Do I need to write a module that makes the property available as a field?
Thanks in advance.
I think the references module might help.
http://drupal.org/project/references
I don't have extensive experience with it, although I thought I'd point you towards it. If it's what you need, I'm sure others with more experience than myself will chip in and help you out if you have more specific questions.
Can anyone help?
I have a created a relationship between my Reservation(prim key) and Insurance(for key) tables and imported into linq2sql and checked my automatically created c# files and sure enough i have reservation.MyFieldNames etc etc PLUS reservation.Insurance which is my relationship but reservation.Insurance i can't see the fieldnames of Insurance - am i missing something?
Do i have to call a GetInsurances or something? I don't see anything.. In fact Insurance is of type Linq.entityset???
Also i was hoping to create my reservation table (which was nice and easy) and then automatically "INJECT" a Insurance (i.e. 1 to many) from Ilist or something..
Is this not possible,
Any help really appreciated
p.s. I did create my automatically created c# dto files via T4 Toolbox but this shouldn't make any difference. I just have a separate file for each entity..
Not 100% sure what you mean by "I don't see anything".
Assuming you have a Reservations table and an Insurance table which references the "reservations" - what kind of relationship is this? 1:1 ? 1:many ? Which way around?? Can you post a screenshot of your DBML designer surface? (upload it to www.tinypic.com and include the link as an image here in your question)?
The "Reservations" class will contain one instance of an "Insurance" (EntityRef<Insurance>) or a list (EntitySet) of "Insurance" objects (EntitySet<Insurance>) - depending on the nature of the relationship - and you should be able to navigate those in code, e.g.
string foo = myReservation.Insurance.CustomerName; // or whatever
You won't see those on the designer surface - that's just a link to another class somehwere on your design surface, right?
Same goes for the other way around - if the Insurance is associated with exactly one Reservation, you should be able (in code) to do:
string bar = myInsuranceObject.Reservation.MyFieldName1; // or whatever
So it's not quite clear to me which case you're really referring to - can you elaborate on your question a bit more and make it clearer??
Based on the NerdDinner sample, I'll try to elaborate. Check out the DBML design surface:
Here, you don't see any of the properties used to move back and forth between the objects. But you do see that the "RSVP" class has a "DinnerID" foreign key which links it to the "Dinner" class. So this is a 1:n relationship: one Dinner has n RSVP's, and every RSVP is for exactly one Dinner.
In your code, you see these created properties now - check out the RSVP class first:
You can see that the RSVP class has a EntityRef<Dinner> - a reference (link) to exactly one Dinner - that dinner that this RSVP is for.
On the other hand, the Dinner class has a whole list of RSVPs of all the geek planning to attend that dinner!
So in the Dinner class, you have a EntitySet<RSVP> - a whole list of attendees, which you can then navigate when you're working with your Dinner class.
Does this make things a bit clearer?
Marc