Infusionsoft populate custom field via API - infusionsoft

I am trying to set the value of a custom field that belongs to a contact via the Infusionsoft API.
When I try to create or update the contact with the custom field value set I receive the following response:
[NoFieldFound]No field found: Contact.InitialSiteVisitTime
Which leads me to believe that the custom field value is stored in a different table. Can anyone please tell me the name of the table that holds Infusionsofts custom field values?

Infusionsoft automatically prefixes custom field names with an underscore. Adding the underscore to the name allows to populate this value via the API successfully.
Note, that custom fields API names (the way they stored in Infusionsoft database) not always equal to how you name a custom field on creation.
This article shows where your actual custom fields API names are listed.

Related

How to include SR related work log long description when using maximo oslc rest api?

I am doing an HTTP GET request to /maximo/oslc/os/mxsr and using the oslc.select query string parameter to choose:
*,doclinks{*},worklog{*},rel.commlog{*},rel.woactivity{*,rel.woactivity{*}}
This lets me get related data, including related worklogs, but the worklog does not include the 'description_longdescription' field.
The only way I seem to be able to get that field is if I do a separate HTTP GET to query a worklog id directly through /maxrest/rest/mbo/worklog . Then it provides the description_longdescription field.
I understand this field is stored separately through the linked longdescription table, but I was hoping to get the data through the "next gen" oslc api with one http get request.
I've tried putting in 'worklog{*,description_longdescription}', as I read somewhere that longdescription is a "non-persistent" field and must be explicitly named for inclusion, but it had no effect.
I figured out that for the /maximo/oslc/os/mxsr object in the API, I needed to reference the related MODIFYWORKLOG object through the rel.modifyworklog syntax in the oslc.select query string:
oslc.select=*,doclinks{*},rel.modifyworklog{*,description_longdescription},rel.commlog{*},rel.woactivity{*,rel.woactivity{*}}
I also had to explicitly name the non-persistent field description_longdescription for it to be included.
Ref. for the "rel." syntax: https://developer.ibm.com/static/site-id/155/maximodev/restguide/Maximo_Nextgen_REST_API.html#_querying_maximo_asset_management_by_using_the_rest_api

Function field for many2many odoo 8

I need to declare a many2many field as functional field. I tried below code but doesn't create any relational table in database.
def _get_function(self,cr,uid,ids,name,args,context=None):
resp={}
for data in self.browse(cr,uid,ids):
print'inside get Function'
return resp
'many2many_ids': fields.function(_get_function, method=True, relation="table.table1", obj='table1_table2_rel', type="many2many" , string="Many2Many")
Now data saved in form view, but i can't access that values in another function. like,
for data in self.browse(cr,uid,ids):
print'many2many_ids',data.many2many_ids
Here print no values.
How can i do that?
if you want the field to be stored use "store" option.
Also, you might consider using new API on v8. Check "Computed field" in official docs https://www.odoo.com/documentation/8.0/reference/orm.html

Admin - Add new post - hook to display some custom input fields

i have a custom post type
this post type needs some fields to be inserted into a custom MySQL table (wp_my_custom_table) where i store some relations IDs with other products and a number to sort them
i don't know how to put these input fields them after the textarea. I know how to insert them at "save_post" action hook.
these are not registered as "custom fields", are just a few input fields needed for each post type like this
The tag doesn't work, so i put the code that i have tried as image:
I have found, there is a hook "edit_form_after_editor".

Filter a rest service by category or field

I am using the extension library's rest control to provide a json data feed. Is it possible to filter by a category or a field with a URL parameter?
I understand that I can use a search string "&search=something" but that can provide me with erroneous results. I have tried searching for a field equal to some value but that doesn't seem to work for me.
If I cannot do this with the rest control, is it possible with Domino Data Services?
You can filter by a category or field value in a viewJsonService if you add ?keys=yourValue to URL.
The REST service returns the same documents as you would get with view.getAllDocumentsByKey("yourValue").
Default is non-exact-match filtering which means that only the beginning of column value has to match. If you want the exact match then add &keysexactmatch=true to URL which would be the equivalent to view.getAllDocumentsByKey("yourValue", true).
Example:
Assuming, we have a view "Forms" with a first sorted column "Form".
With the REST service
<xe:restService
id="restService1"
pathInfo="DocsByForm">
<xe:this.service>
<xe:viewJsonService
viewName="Forms"
defaultColumns="true">
</xe:viewJsonService>
</xe:this.service>
</xe:restService>
and the URL
http://server/database.nsf/RestServices.xsp/DocsByForm?keys=Memo&keysexactmatch=true
we'd get all documents with Form="Memo" as JSON
[
{
"#entryid":"7-D5029CB83351A9A6C1257D820031E927",
"#unid":"D5029CB83351A9A6C1257D820031E927",
"#noteid":"11DA",
"#position":"7",
"#siblings":14,
"#form":"Memo",
"Form":"Memo",
... other columns ...
},
... other documents
]
We'd get the same result if the first column is categorized.

Change post type name without losing custom field values

I need to change the name of one of my custom post types. These posts have several custom fields associated with them. After changing the name, I update the name of the post types in the database and all of the posts appear again in Wordpress. However, they seem to have lost their custom field information. Is this also updatable?
Just Run following query in your wp_posts
UPDATE `wp_posts` SET `post_type`='<old-value>' WHERE `post_type`='new value';
Do remember to enter your old post type name and new post type name, changing post type name will not effect custom fields as meta fields are associated with post id only.
Cheers...