|
90 | 90 | use Microsoft\BingAds\V12\CampaignManagement\GetSharedEntityAssociationsByEntityIdsRequest; |
91 | 91 | use Microsoft\BingAds\V12\CampaignManagement\GetSharedEntityAssociationsBySharedEntityIdsRequest; |
92 | 92 | use Microsoft\BingAds\V12\CampaignManagement\GetUetTagsByIdsRequest; |
| 93 | +use Microsoft\BingAds\V12\CampaignManagement\SearchCompaniesRequest; |
93 | 94 | use Microsoft\BingAds\V12\CampaignManagement\SetAccountPropertiesRequest; |
94 | 95 | use Microsoft\BingAds\V12\CampaignManagement\SetAdExtensionsAssociationsRequest; |
95 | 96 | use Microsoft\BingAds\V12\CampaignManagement\SetLabelAssociationsRequest; |
@@ -1258,6 +1259,20 @@ static function GetUetTagsByIds( |
1258 | 1259 |
|
1259 | 1260 | return $GLOBALS['CampaignManagementProxy']->GetService()->GetUetTagsByIds($request); |
1260 | 1261 | } |
| 1262 | + static function SearchCompanies( |
| 1263 | + $companyNameFilter, |
| 1264 | + $languageLocale) |
| 1265 | + { |
| 1266 | + $GLOBALS['CampaignManagementProxy']->SetAuthorizationData($GLOBALS['AuthorizationData']); |
| 1267 | + $GLOBALS['Proxy'] = $GLOBALS['CampaignManagementProxy']; |
| 1268 | + |
| 1269 | + $request = new SearchCompaniesRequest(); |
| 1270 | + |
| 1271 | + $request->CompanyNameFilter = $companyNameFilter; |
| 1272 | + $request->LanguageLocale = $languageLocale; |
| 1273 | + |
| 1274 | + return $GLOBALS['CampaignManagementProxy']->GetService()->SearchCompanies($request); |
| 1275 | + } |
1261 | 1276 | static function SetAccountProperties( |
1262 | 1277 | $accountProperties) |
1263 | 1278 | { |
@@ -2783,6 +2798,29 @@ static function OutputArrayOfCampaignNegativeSites($dataObjects) |
2783 | 2798 | self::OutputCampaignNegativeSites($dataObject); |
2784 | 2799 | } |
2785 | 2800 | } |
| 2801 | + static function OutputCompany($dataObject) |
| 2802 | + { |
| 2803 | + if (!empty($dataObject)) |
| 2804 | + { |
| 2805 | + self::OutputStatusMessage("* * * Begin OutputCompany * * *"); |
| 2806 | + self::OutputStatusMessage(sprintf("LogoUrl: %s", $dataObject->LogoUrl)); |
| 2807 | + self::OutputStatusMessage(sprintf("Name: %s", $dataObject->Name)); |
| 2808 | + self::OutputStatusMessage(sprintf("ProfileId: %s", $dataObject->ProfileId)); |
| 2809 | + self::OutputStatusMessage(sprintf("Status: %s", $dataObject->Status)); |
| 2810 | + self::OutputStatusMessage("* * * End OutputCompany * * *"); |
| 2811 | + } |
| 2812 | + } |
| 2813 | + static function OutputArrayOfCompany($dataObjects) |
| 2814 | + { |
| 2815 | + if(count((array)$dataObjects) == 0 || !isset($dataObjects->Company)) |
| 2816 | + { |
| 2817 | + return; |
| 2818 | + } |
| 2819 | + foreach ($dataObjects->Company as $dataObject) |
| 2820 | + { |
| 2821 | + self::OutputCompany($dataObject); |
| 2822 | + } |
| 2823 | + } |
2786 | 2824 | static function OutputConversionGoal($dataObject) |
2787 | 2825 | { |
2788 | 2826 | if (!empty($dataObject)) |
|
0 commit comments