QBD Query by Customer Name (DevKit) - quickbooks

I think this has been asked before, but I'm going to give it another shot in the hope of getting a useful answer.
Using the DevKit and C# (not XML) how can I look up a customer by name? In the SDK it was a no-brainer to look up a customer by FullName, but now I can't find any way to do it. It defies common sense that the DevKit wouldn't provide a way to do this.
Please don't reply with links to documentation that doesn't have the answer (I've read it several times), or XML that doesn't work. I'd love to see C# code that does this (heck, I'll even settle for VB), but if it can't be done, please just tell me so I can end this and get some rest.

var qbdCustomerQuery1 = new Intuit.Ipp.Data.Qbd.CustomerQuery();
qbdCustomerQuery1.Item1ElementName = Intuit.Ipp.Data.Qbd.Item1ChoiceType.FirstLastInside; qbdCustomerQuery1.Item1 = "Popeye";
List CustomerQueryResult = qbdCustomerQuery1.ExecuteQuery(context).ToList();
This should work.
We will try to improve the docs for such queries.

Can you give it a try
ServiceContext context = new ServiceContext(oauthValidator, appToken, realmId, IntuitServicesType.QBD)
CustomerQuery customerQuery = new CustomerQuery();
customerQuery.FirstLastName ="?"
IEnumerable<Customer> customers = customerQuery.ExecuteQuery<Customer>(context);
Ref - https://developer.intuit.com/docs/0025_quickbooksapi/0055_devkits/0100_ipp_.net_devkit/query_filters/quickbooks_desktop
In the client side, you can loop through 'customers' and use an if condition for only customer's name.
Thanks

Related

how to do manual search on NCBI with biopython and add link to publication

I'm trying to reproduce manual search on NCBI with biopython but obviously something is not good in my code..
NCBI gives me that : "Microbacterium"[Organism] AND "latest refseq"[filter] AND (all[filter] NOT partial[filter])
i'm trying :
query = "Microbacterium[Organism] AND latest refseq[filter] AND (all[filter] NOT partial[filter])"
handle = Entrez.esearch(term=query, db="nuccore", retmax=600)
ids = Entrez.read(handle)["IdList"]
but ids is empty, i'm supposed to find 512 genomes that i would like to get after.
if someone has an idea where i did mistake?
and to add point to my question, does everyone know if we can get only genomes related to a published paper?
thanks a lot!

Send Mautic Form to different Recipients based on Formfield

I've a Mautic form with Radiobuttons where the User can select which Department he want to connect with.
o General Question (1)
o Sales (2)
o Technical Support (3)
I want to send the Request to the Person in Charge. So for example:
1: info#company.org
2: sales#company.org
3: support#company.org
I've tried different approaches, but non worked.
The most dirty one was to set the values of the radio buttons as E-Mails and send the Form to the Contact. Worked in some way, but then off course saves the Radiobutton Input to the Database as customer E-Mail. So, only smart in the first place. ;)
I've also tried campaigns, but couldn't find a nice way to use Formfields in the Campaign Templates.
I cannot accept that this couldn't be possible in a easy way. This Form gonna replace a Powermail Form in TYPO3 and there it kind of works like a charm.
Any hint is very much appreciated.
Sorry that you found the documentation bad - we are actually in the process of improving and migrating our developer docs, so please take a look at the WIP docs here: https://mautic-developer.readthedocs.io/en/latest/plugins/getting_started.html which are much improved!
(will also post this on the forum thread!)
After weeks and weeks of research and workarounds I got at the Mautic Form, here is my solution to this Challenge.
I really love Mautic and its extensiveness. It’s just a great and powerful tool.
But at this point it totally misses the market. For me it just feels so wrong and like a big error by design, when you have to create fake fields to handle formfields for such a simple task.
Not talking about the problem when the user overwrite his records before the data being send.
As mentioned this is so easy to do in TYPO3 with Powermail and so I was thinking about creating a plugin, but the documentation on this is really bad.
So here is my solution, as I was looking for simple solution for me as well as the customer.
Solution is tested and worked like a charm for me. Here’s what you can do, for everyone also looking something like this:
Create 1 custom field and label it “Owner (form)” - set Type to Text
Create 2 MySQL Trigger as follows (just copy the code 1:1, should work out of the box):
DELIMITER ;;
CREATE TRIGGER set_lead_owner_from_radiobutton_on_insert BEFORE INSERT ON leads FOR EACH ROW
IF (NEW.owner_form != NULL) THEN
IF (SELECT count(id) FROM users WHERE users.id=NEW.owner_form) > 0 THEN
SET NEW.owner_id = NEW.owner_form;
ELSE
SET NEW.owner_id = NULL;
END IF;
END IF;;
DELIMITER ;
DELIMITER ;;
CREATE TRIGGER set_lead_owner_from_radiobutton_on_update BEFORE UPDATE ON leads FOR EACH ROW
IF (NEW.owner_form != NULL) THEN
IF (SELECT count(id) FROM users WHERE users.id=NEW.owner_form) > 0 THEN
SET NEW.owner_id = NEW.owner_form;
ELSE
SET NEW.owner_id = NULL;
END IF;
END IF;;
DELIMITER ;
Create a form with a Radiobutton or Selectbox and set the “Contact Field” to our custom field “Owner (Form)”
Note: Values of the Radiobuttons / Selectboxes need to be set to the User IDs of your Mautic Instance. So you have to create an user for every Select- oder Radiobutton-Option.
Select for example “Send form results” in Actions and set “Send to owner” to yes.
That’s it.
So what does it do. It’s basically all about the MySQL Triggers. Every time a new Lead is created or updated and our custom field “Owner (form)” is not null and has a valid entry (User ID), the trigger copies the value from our field to the original Owner Field of the lead. So we can then use Owner of the Lead (in my case a Department) to send him a E-Mail.
I hope this is helpfull to someone. But even more I hope that Mautic is gonna fix this in the future, as I believe this a very essential task when it come to enterprise Websites.
Cheers,
Lufi
Mautic Forum Discussion: https://forum.mautic.org/t/send-mautic-form-to-different-recipients-based-on-formfield/24363/13

What's the most efficient way to query Microsoft Graph events by id list?

Currently, in my code, I am taking a list of stored Event ids and fetching them like this:
results = await Task.WhenAll(
criteria.Identifiers
.Skip(offset).Take(pageSize)
.Select(i => userEvents[i].Request(options).GetAsync())
.ToList());
This works fine, but it makes pageSize number of calls to the API, which seems less than ideal. Is there a way to bundle these identifiers into a single API call?
My question proved similar to another:
Getting multiple users/groups by objectids
The answer, there, suggests this feature might be coming, but isn't here, yet. If anyone knows more about the timeline, please add another answer or comment.

How to access a reddit post using redditkit in ruby?

I have a reddit post link here:
https://www.reddit.com/r/dankmemes/comments/6m5k0o/teehee/
I wish to access the data of this post throught the redditkit API.
http://www.rubydoc.info/gems/redditkit/
I have tried countless times and the docs don't make too much sense to me. Can someone help show how to do this through the ruby console? Or even an implementation of this in rails would be really helpful!
Looking at the #comment method on the gem, it takes a comment_full_name and performs a GET to api/info.json with that parameter as an id (seen by viewing the source for that method). If we look at the reddit api for api/info the id parameter is a full name for the object with a link to what a full name is.
Following that link, a full name for a comment is
Fullnames start with the type prefix for the object's type, followed by the thing's unique ID in base 36.
and
type prefixes
t1_ Comment
So now we know the comment_full_name should be t1_#{comment's unique id} which appears to be 6m5k0o. Here, I'm unsure if that's already base36 or if they want you to convert that into base36 before passing it. Without seeing what all you've tried, I would say
client = RedditKit::Client.new 'username', 'password'
client.comment("t1_6m5k0o")
and if that doesn't work
client.comment("t1_#{'6m5k0o' base36 encoded}")
For questions like this, it would be nice to see some of your code and what you tried/results they gave. For all I know, you've already tried this and have a reason it didn't work for you.
I would test this out for you, but I don't have a reddit account for the gem to sign in with, this is just my guess glancing at the documentation.

Office 365 Calendar API

I am new to Office 365 api. I got online and tried to used the microsoft virtual academy and other similar to it. I followed the direction from this site linkhttps://msdn.microsoft.com/office/office365/howto/authenticate-and-use-services; step for step, but I am getting an error that looks like thisError message
The steps are not hard at all. When I go into debug mode these two lines always come back null. There is very little information out there about these two lines.
var signInUserId=ClaimsPrincipal.Current.FindFirst(ClaimTypes.Email).Value;
var userObjectId = ClaimsPrincipal.Current.FindFirst("http://schemas.microsoft.com/identity/claims/objectidentifier").Value;
If you are looking for my code it is provided in the link I gave above. Those are all my files. To the T. Thanks in advance for any help.
Question 1. Do anyone have better resources other than the ones I am using
Question 2. Can those lines be null.
Question 3. Where can I find a SOLID tutorial online that works 100%
The error is because that there is no “mail” type data in the claims. To construct the AuthenticationContext object, we should use the ‘ClaimTypes.NameIdentifier’ as the ’signInUserId’ instead of ‘ClaimTypes.Email’.
And you can refer to the whole sample code from here.

Resources