当前位置: 首页>>代码示例>>PHP>>正文


PHP Organization::getResources方法代码示例

本文整理汇总了PHP中Organization::getResources方法的典型用法代码示例。如果您正苦于以下问题:PHP Organization::getResources方法的具体用法?PHP Organization::getResources怎么用?PHP Organization::getResources使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在Organization的用法示例。


在下文中一共展示了Organization::getResources方法的3个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。

示例1: foreach

 }
 foreach ($formDataArray as $key => $value) {
     $newIssue->{$key} = $value;
 }
 $newIssue->save();
 //start building the email body
 $emailMessage = "Subject: {$newIssue->subjectText}\r\n\r\n\r\n\t\t\t\t\tBody: {$newIssue->bodyText}\r\n\r\n\r\n\t\t\t\t\tApplies To: ";
 if ($organizationID) {
     $newIssueRelationship = new IssueRelationship();
     $newIssueRelationship->issueID = $newIssue->primaryKey;
     $newIssueRelationship->entityID = $organizationID;
     $newIssueRelationship->entityTypeID = 1;
     $newIssueRelationship->save();
     $emailMessage .= "{$organization->name}\r\n";
 } else {
     $orgResourcesArray = $sourceOrganization->getResources(5);
     $orgResourcesIndexed = array();
     foreach ($orgResources as $resource) {
         $orgResourcesIndexed[$resource['resourceID']] = $resource;
     }
     foreach ($resourceIDArray as $resourceID) {
         $newIssueRelationship = new IssueRelationship();
         $newIssueRelationship->issueID = $newIssue->primaryKey;
         $newIssueRelationship->entityID = $resourceID;
         $newIssueRelationship->entityTypeID = 2;
         $newIssueRelationship->save();
         unset($newIssueRelationship);
         $emailMessage .= "{$orgResourcesIndexed[$resourceID]->titleText}\r\n";
     }
 }
 if (count($issueEmails) > 0) {
开发者ID:pontifechs,项目名称:organizations,代码行数:31,代码来源:ajax_processing.php

示例2: OrganizationRole

        <div style="width: 303px; float:right; border: 1px solid #DAD5C9; padding:5px;">
            <h3>Helpful Links</h3>
	    	<div class='rightPanelLink' style='padding-left:10px;'><a href='summary.php?organizationID=<?php 
        echo $organizationID;
        ?>
' target='_blank' class='helpfulLink'>Print View</a></div>

            <?php 
        //get all possible roles, sort by name, get associated resources
        $org_role_obj = new OrganizationRole();
        $org_roles = $org_role_obj->allAsArray();
        usort($org_roles, function ($a, $b) {
            return strcmp($a["shortName"], $b["shortName"]);
        });
        foreach ($org_roles as $role) {
            $resources = $organization->getResources($role["organizationRoleID"]);
            if (count($resources) > 0) {
                ?>
            <h4 style="margin-top:8px"><?php 
                echo $role["shortName"];
                ?>
 of:</h4>
            <div style="padding-left:10px;">
            <?php 
                foreach ($resources as $resource) {
                    $temp_style = "";
                    if ($resource['archived']) {
                        echo "<span style='color:grey; font-size:80%;'>(archived) </span>";
                        $temp_style = "style='color:#888888'";
                    }
                    echo "<a href='" . $util->getResourceRecordURL() . $resource['resourceID'] . "' target='_BLANK' {$temp_style}>" . $resource['titleText'] . "&nbsp;&nbsp;<img src='images/arrow-up-right.gif' alt='view resource' title='View " . $resource['titleText'] . "' style='vertical-align:top;'></a><br />";
开发者ID:veggiematts,项目名称:coral-organizations,代码行数:31,代码来源:orgDetail.php

示例3: Organization

				<table class='noBorderTable' style='width:125px;'>
					<tr>
						<td class="text-left"><input type="button" value="submit" name="submitCloseResourceIssue" id="submitCloseResourceIssue"></td>
						<td class='text-right'><input type='button' value='cancel' onclick="tb_remove();"></td>
					</tr>
				</table>

			</form>
		</div>
<?php 
        break;
    case 'getNewIssueForm':
        $organizationID = $_GET["organizationID"];
        $organization = new Organization(new NamedArguments(array('primaryKey' => $organizationID)));
        $organizationContactsArray = $organization->getContacts();
        $organizationResourcesArray = $organization->getResources(5);
        ?>

<form id='newIssueForm'>
	<input type="hidden" id="sourceOrganizationID" name="sourceOrganizationID" value="<?php 
        echo $organizationID;
        ?>
" />
	<table class="thickboxTable">
		<tr>
			<td colspan="2">
				<h1> Report New Problem</h1>
				<span class='error smallDarkRedText'>* required fields</span>
			</td>
		</tr>
		<tr>
开发者ID:ndlibersa,项目名称:organizations,代码行数:31,代码来源:ajax_forms.php


注:本文中的Organization::getResources方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。