{"id":7,"date":"2009-04-14T10:17:27","date_gmt":"2009-04-14T10:17:27","guid":{"rendered":"http:\/\/mahenderpal.wordpress.com\/?p=3"},"modified":"2009-04-14T10:17:27","modified_gmt":"2009-04-14T10:17:27","slug":"hide-ms-crm-picklist-items","status":"publish","type":"post","link":"https:\/\/himbap.com\/blog\/?p=7","title":{"rendered":"Hide ms crm picklist items"},"content":{"rendered":"<p>Today i got requirement to hide some picklist option based on customer type selection(in my case \ud83d\ude42 ) here is how i did this<\/p>\n<p>like we have one picklist for customer option &#8220;A&#8221; and &#8220;B&#8221; and we have a picklist crmpicklistfacility with different facilities like<\/p>\n<p>1 &#8220;Create new User&#8221;<\/p>\n<p>2 &#8220;Modify User&#8221;<\/p>\n<p>3 &#8220;Delete User&#8221;<\/p>\n<p>now we want to present picklist option 1,3 for customer A and 2 for customer B.<\/p>\n<p>we do like this in javascript<\/p>\n<p>var Cust_type=crmForm.all.customertype.DataValue;<\/p>\n<p>var crmpickObj=crmForm.all.facility;<\/p>\n<p>if(Cust_type==&#8221;1&#8243;)<\/p>\n<p>{<\/p>\n<p>crmpickObj.DeleteOption(2);<\/p>\n<p>}<\/p>\n<p>else if(Cust_type==&#8221;2&#8243;)<\/p>\n<p>{<\/p>\n<p>crmpickObj.DeleteOption(1);<\/p>\n<p>crmpickObj.DeleteOption(3);<\/p>\n<p>}<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Today i got requirement to hide some picklist option based on customer type selection(in my case \ud83d\ude42 ) here is how i did this like we have one picklist for customer option &#8220;A&#8221; and &#8220;B&#8221; and we have a picklist crmpicklistfacility with different facilities like 1 &#8220;Create new User&#8221; 2 &#8220;Modify User&#8221; 3 &#8220;Delete User&#8221; now we want to present&#8230; <a href=\"https:\/\/himbap.com\/blog\/?p=7\">Read more &raquo;<\/a><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":[],"categories":[25],"tags":[],"_links":{"self":[{"href":"https:\/\/himbap.com\/blog\/index.php?rest_route=\/wp\/v2\/posts\/7"}],"collection":[{"href":"https:\/\/himbap.com\/blog\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/himbap.com\/blog\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/himbap.com\/blog\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/himbap.com\/blog\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=7"}],"version-history":[{"count":0,"href":"https:\/\/himbap.com\/blog\/index.php?rest_route=\/wp\/v2\/posts\/7\/revisions"}],"wp:attachment":[{"href":"https:\/\/himbap.com\/blog\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=7"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/himbap.com\/blog\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=7"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/himbap.com\/blog\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=7"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}