[spalenque] - #6968 *WIP
This commit is contained in:
parent
0d49a5b6cb
commit
a47bd50bcc
@ -187,7 +187,7 @@ class MarketPlaceAdminPage_Controller extends Page_Controller
|
||||
'consultants',
|
||||
'consultant',
|
||||
'preview',
|
||||
'pdf,'
|
||||
'pdf',
|
||||
);
|
||||
|
||||
|
||||
@ -964,7 +964,7 @@ class MarketPlaceAdminPage_Controller extends Page_Controller
|
||||
case 'private_cloud': {
|
||||
$private_cloud = $this->private_clouds_repository->getBy($query);
|
||||
$private_cloud->IsPreview = true;
|
||||
$render = new PrivatgeCloudSapphireRender($private_cloud);
|
||||
$render = new PrivateCloudSapphireRender($private_cloud);
|
||||
return $render->draw();
|
||||
|
||||
}
|
||||
@ -1032,7 +1032,106 @@ class MarketPlaceAdminPage_Controller extends Page_Controller
|
||||
}
|
||||
|
||||
public function pdf(){
|
||||
$html_inner = '';
|
||||
$marketplace_type = $this->request->param('MARKETPLACETYPE');
|
||||
$instance_id = intval($this->request->param('ID'));
|
||||
$base = Director::baseFolder();
|
||||
|
||||
$query = new QueryObject();
|
||||
$query->addAddCondition(QueryCriteria::equal('ID', $instance_id));
|
||||
|
||||
switch (strtolower($marketplace_type)) {
|
||||
case 'distribution': {
|
||||
$distribution = $this->distribution_repository->getBy($query);
|
||||
if (!$distribution) throw new NotFoundEntityException('', '');
|
||||
$render = new DistributionSapphireRender($distribution);
|
||||
$distribution ->IsPreview = true;
|
||||
$html_inner = $render->pdf();
|
||||
$css = @file_get_contents($base . "/marketplace/code/ui/admin/css/pdf.css");
|
||||
}
|
||||
break;
|
||||
case 'appliance': {
|
||||
$appliance = $this->appliance_repository->getBy($query);
|
||||
$appliance->IsPreview = true;
|
||||
$render = new ApplianceSapphireRender($appliance);
|
||||
$html_inner = $render->pdf();
|
||||
$css = @file_get_contents($base . "/themes/openstack/css/main.pdf.css");
|
||||
$css .= ' '.@file_get_contents($base . "/themes/openstack/css/chosen.css");
|
||||
//$css .= ' '.@file_get_contents($base . "/themes/openstack/css/combined.css");
|
||||
$css .= ' '.@file_get_contents($base . "/marketplace/code/ui/admin/css/colorpicker.css");
|
||||
$css .= ' '.@file_get_contents($base . "/marketplace/code/ui/frontend/css/marketplace.css");
|
||||
}
|
||||
break;
|
||||
case 'public_cloud': {
|
||||
$public_cloud = $this->public_clouds_repository->getBy($query);
|
||||
$public_cloud->IsPreview = true;
|
||||
if (!$public_cloud) throw new NotFoundEntityException('', '');
|
||||
$render = new PublicCloudSapphireRender($public_cloud);
|
||||
$html_inner = $render->pdf();
|
||||
$css = @file_get_contents($base . "/themes/openstack/css/main.pdf.css");
|
||||
$css .= ' '.@file_get_contents($base . "/themes/openstack/css/chosen.css");
|
||||
//$css .= ' '.@file_get_contents($base . "/themes/openstack/css/combined.css");
|
||||
$css .= ' '.@file_get_contents($base . "/marketplace/code/ui/admin/css/colorpicker.css");
|
||||
$css .= ' '.@file_get_contents($base . "/marketplace/code/ui/frontend/css/marketplace.css");
|
||||
}
|
||||
break;
|
||||
case 'private_cloud': {
|
||||
$private_cloud = $this->private_clouds_repository->getBy($query);
|
||||
$private_cloud->IsPreview = true;
|
||||
$render = new PrivateCloudSapphireRender($private_cloud);
|
||||
$html_inner = $render->pdf();
|
||||
$css = @file_get_contents($base . "/themes/openstack/css/main.pdf.css");
|
||||
$css .= ' '.@file_get_contents($base . "/themes/openstack/css/chosen.css");
|
||||
//$css .= ' '.@file_get_contents($base . "/themes/openstack/css/combined.css");
|
||||
$css .= ' '.@file_get_contents($base . "/marketplace/code/ui/admin/css/colorpicker.css");
|
||||
$css .= ' '.@file_get_contents($base . "/marketplace/code/ui/frontend/css/marketplace.css");
|
||||
|
||||
}
|
||||
break;
|
||||
case 'consultant': {
|
||||
$consultant = $this->consultant_repository->getBy($query);
|
||||
if (!$consultant) throw new NotFoundEntityException('', '');
|
||||
$consultant->IsPreview = true;
|
||||
$render = new ConsultantSapphireRender($consultant);
|
||||
$html_inner = $render->pdf();
|
||||
$css = @file_get_contents($base . "/themes/openstack/css/main.pdf.css");
|
||||
$css .= ' '.@file_get_contents($base . "/themes/openstack/css/chosen.css");
|
||||
//$css .= ' '.@file_get_contents($base . "/themes/openstack/css/combined.css");
|
||||
$css .= ' '.@file_get_contents($base . "/marketplace/code/ui/admin/css/colorpicker.css");
|
||||
$css .= ' '.@file_get_contents($base . "/marketplace/code/ui/frontend/css/marketplace.css");
|
||||
}
|
||||
break;
|
||||
default:
|
||||
$this->httpError(404);
|
||||
break;
|
||||
}
|
||||
|
||||
//create pdf
|
||||
$file = FileUtils::convertToFileName('preview') . '.pdf';
|
||||
//$html_inner = $this->customise(array('BASEURL' => Director::protocolAndHost()))->renderWith("UserStoryPDF");
|
||||
|
||||
$html_outer = sprintf("<html><head><style>%s</style></head><body><div class='container'>%s</div></body></html>",
|
||||
str_replace("@host", $base, $css),$html_inner);
|
||||
|
||||
|
||||
try {
|
||||
$html2pdf = new HTML2PDF('P', 'A4', 'en', true, 'UTF-8', array(15, 5, 15, 5));
|
||||
//$html2pdf->addFont('Open Sans', '', $base.'/themes/openstack/assets/fonts/PT-Sans/PTC75F-webfont.ttf');
|
||||
$html2pdf->WriteHTML($html_outer);
|
||||
//clean output buffer
|
||||
ob_end_clean();
|
||||
$html2pdf->Output($file, "D");
|
||||
} catch (HTML2PDF_exception $e) {
|
||||
$message = array(
|
||||
'errno' => '',
|
||||
'errstr' => $e->__toString(),
|
||||
'errfile' => 'UserStory.php',
|
||||
'errline' => '',
|
||||
'errcontext' => ''
|
||||
);
|
||||
SS_Log::log($message, SS_Log::ERR);
|
||||
$this->httpError(404,'There was an error on PDF generation!');
|
||||
}
|
||||
}
|
||||
|
||||
}
|
98
marketplace/code/ui/admin/css/pdf.css
Normal file
98
marketplace/code/ui/admin/css/pdf.css
Normal file
@ -0,0 +1,98 @@
|
||||
body, html {
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
}
|
||||
|
||||
body, h1, h2, h3, h4, h5, h6 {
|
||||
/*font-family: "Open Sans", Helvetica, Arial, sans-serif;*/
|
||||
font-weight: 400;
|
||||
}
|
||||
|
||||
h1 {
|
||||
color: rgb(7, 94, 165);
|
||||
font-size: 27px;
|
||||
font-weight: 300;
|
||||
margin-bottom: 10px;
|
||||
text-align: center;
|
||||
font-size: 25px;
|
||||
}
|
||||
|
||||
h2 {
|
||||
color: rgb(7, 94, 165);
|
||||
font-weight: 300;
|
||||
margin-bottom: 10px;
|
||||
margin-top:20px;
|
||||
text-align: left;
|
||||
font-size: 21px;
|
||||
}
|
||||
|
||||
h3 {
|
||||
color: rgb(7, 94, 165);
|
||||
font-size: 14px;
|
||||
text-transform: uppercase;
|
||||
margin-top: 8px;
|
||||
margin-bottom: 5px;
|
||||
}
|
||||
|
||||
h5 {
|
||||
color: #DA422F;
|
||||
margin-bottom: 0;
|
||||
}
|
||||
|
||||
a, a:visited {
|
||||
color: #30739C;
|
||||
}
|
||||
|
||||
th {
|
||||
text-align: left;
|
||||
padding: 0;
|
||||
}
|
||||
|
||||
.container {
|
||||
font-size: 11px;
|
||||
line-height: 1.1;
|
||||
color: #333;
|
||||
font-weight: 300;
|
||||
}
|
||||
|
||||
.primary-action-button {
|
||||
background: none repeat scroll 0 0 #0595D4;
|
||||
color: #FFFFFF!important;
|
||||
display: inline-block;
|
||||
font-size: 13px;
|
||||
line-height: 1em;
|
||||
margin-left: 16px;
|
||||
padding: 5px 16px;
|
||||
text-transform: uppercase;
|
||||
}
|
||||
|
||||
.grey-bar {
|
||||
background-color: #edf2f7;
|
||||
margin-top: 0;
|
||||
padding-bottom: 8px;
|
||||
padding-top: 8px;
|
||||
}
|
||||
|
||||
.grey-bar h1{
|
||||
margin-bottom:5px;
|
||||
padding-top:5px;
|
||||
}
|
||||
|
||||
.marketplace-content{
|
||||
margin-top:32px;
|
||||
}
|
||||
|
||||
.pullquote p{
|
||||
font-size:120%;
|
||||
margin-bottom:16px;
|
||||
}
|
||||
|
||||
.pullquote p.author{
|
||||
color:#7F7F7F;
|
||||
font-size:80%;
|
||||
}
|
||||
|
||||
.info-area{
|
||||
border-left:1px solid #DDDDDD;
|
||||
padding-left:8px;
|
||||
}
|
@ -20,4 +20,8 @@ final class ApplianceSapphireRender {
|
||||
Requirements::css("marketplace/code/ui/frontend/css/marketplace.css");
|
||||
return Controller::curr()->Customise($this->appliance)->renderWith(array('DistributionsDirectoryPage_implementation', 'DistributionsDirectoryPage', 'MarketPlacePage'));
|
||||
}
|
||||
|
||||
public function pdf(){
|
||||
return Controller::curr()->Customise($this->appliance)->renderWith(array('DistributionsDirectoryPage_pdf'));
|
||||
}
|
||||
}
|
@ -42,4 +42,25 @@ final class ConsultantSapphireRender {
|
||||
)
|
||||
)->renderWith(array('ConsultantsDirectoryPage_consultant', 'ConsultantsDirectoryPage', 'MarketPlacePage'));
|
||||
}
|
||||
|
||||
public function pdf(){
|
||||
$services = $this->consultant->getServicesOffered();
|
||||
$unique_services = array();
|
||||
$unique_regions = array();
|
||||
foreach ($services as $service) {
|
||||
if (!array_key_exists($service->getType(), $unique_services))
|
||||
$unique_services[$service->getType()] = $service;
|
||||
if (!array_key_exists($service->getRegionID(), $unique_regions)) {
|
||||
$region = $this->region_repository->getById($service->getRegionID());
|
||||
$unique_regions[$service->getRegionID()] = $region;
|
||||
}
|
||||
}
|
||||
return Controller::curr()->Customise(
|
||||
array(
|
||||
'Consultant' => $this->consultant,
|
||||
'Services' => new DataObjectSet(array_values($unique_services)),
|
||||
'Regions' => new DataObjectSet(array_values($unique_regions)),
|
||||
)
|
||||
)->renderWith(array('ConsultantsDirectoryPage_pdf'));
|
||||
}
|
||||
}
|
@ -20,4 +20,8 @@ final class DistributionSapphireRender {
|
||||
Requirements::css("marketplace/code/ui/frontend/css/marketplace.css");
|
||||
return Controller::curr()->Customise($this->distribution )->renderWith(array('DistributionsDirectoryPage_implementation', 'DistributionsDirectoryPage', 'MarketPlacePage'));
|
||||
}
|
||||
|
||||
public function pdf(){
|
||||
return Controller::curr()->Customise($this->distribution )->renderWith(array('DistributionsDirectoryPage_pdf'));
|
||||
}
|
||||
}
|
@ -27,4 +27,8 @@ final class PrivateCloudSapphireRender {
|
||||
Requirements::javascript("marketplace/code/ui/frontend/js/cloud.page.js");
|
||||
return Controller::curr()->Customise($this->cloud)->renderWith(array('CloudsDirectoryPage_cloud', 'PrivateCloudsDirectoryPage', 'MarketPlacePage'));
|
||||
}
|
||||
|
||||
public function pdf(){
|
||||
return Controller::curr()->Customise($this->cloud)->renderWith(array('CloudsDirectoryPage_pdf'));
|
||||
}
|
||||
}
|
@ -27,4 +27,8 @@ final class PublicCloudSapphireRender {
|
||||
Requirements::javascript("marketplace/code/ui/frontend/js/cloud.page.js");
|
||||
return Controller::curr()->Customise($this->cloud)->renderWith(array('CloudsDirectoryPage_cloud', 'PublicCloudsDirectoryPage', 'MarketPlacePage'));
|
||||
}
|
||||
|
||||
public function pdf(){
|
||||
return Controller::curr()->Customise($this->cloud)->renderWith(array('CloudsDirectoryPage_pdf'));
|
||||
}
|
||||
}
|
179
marketplace/templates/Layout/CloudsDirectoryPage_pdf.ss
Normal file
179
marketplace/templates/Layout/CloudsDirectoryPage_pdf.ss
Normal file
@ -0,0 +1,179 @@
|
||||
<div class="grey-bar">
|
||||
<div class="container">
|
||||
<p class="back-label">
|
||||
<a href="$Top.Link">All Clouds</a>
|
||||
</p>
|
||||
<h1>$Name</h1>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="container marketplace-content">
|
||||
<% include MarketPlaceCompany %>
|
||||
<div class="col-lg-6">
|
||||
<div class="info-area">
|
||||
<% if Capabilities %>
|
||||
<h3 style="color: #{$Company.CompanyColor} !important;">OpenStack Services Offered</h3>
|
||||
<table>
|
||||
<tbody>
|
||||
<tr>
|
||||
<th>Service</th>
|
||||
<th>OpenStack Version</th>
|
||||
</tr>
|
||||
<% loop Capabilities %>
|
||||
<tr>
|
||||
<td>
|
||||
<% loop ReleaseSupportedApiVersion %>
|
||||
<% loop OpenStackComponent %>
|
||||
$Name
|
||||
<% end_loop %>
|
||||
<% end_loop %>
|
||||
</td>
|
||||
<td>
|
||||
<% loop ReleaseSupportedApiVersion %>
|
||||
<% loop Release %>
|
||||
$Name
|
||||
<% end_loop %>
|
||||
<% end_loop %>
|
||||
</td>
|
||||
</tr>
|
||||
<% end_loop %>
|
||||
</tbody>
|
||||
</table>
|
||||
<% end_if %>
|
||||
<% if Top.PricingSchemas %>
|
||||
|
||||
<h3 style="color: #{$Company.CompanyColor} !important;">Pricing Options</h3>
|
||||
<table class="pricing">
|
||||
<tbody>
|
||||
<% loop Top.PricingSchemas %>
|
||||
<tr>
|
||||
<td>$Type</td>
|
||||
<td id="enabled_{$ID}"></td>
|
||||
</tr>
|
||||
<% end_loop %>
|
||||
</tbody>
|
||||
</table>
|
||||
<% end_if %>
|
||||
<% if HyperVisors %>
|
||||
<h3 style="color: #{$Company.CompanyColor} !important;">Supported Hypervisors</h3>
|
||||
<p>
|
||||
<% loop HyperVisors %>
|
||||
<% if First == 0 %>,<% end_if %>
|
||||
$Type
|
||||
<% end_loop %>
|
||||
</p>
|
||||
<% end_if %>
|
||||
|
||||
<% if Guests %>
|
||||
<hr>
|
||||
<h3 style="color: #{$Company.CompanyColor} !important;">Supported Guests</h3>
|
||||
<p>
|
||||
<% loop Guests %>
|
||||
<% if First == 0 %>,<% end_if %>
|
||||
$Type
|
||||
<% end_loop %>
|
||||
</p>
|
||||
<% end_if %>
|
||||
|
||||
<% if DataCenterRegions %>
|
||||
<hr>
|
||||
<h3 style="color: #{$Company.CompanyColor} !important;">Regions</h3>
|
||||
<table class="regions">
|
||||
<tbody>
|
||||
<% loop DataCenterRegions %>
|
||||
<tr>
|
||||
<td class="region-key">
|
||||
<span style="background-color: #{$Color}"></span>
|
||||
</td>
|
||||
<td>$Name</td>
|
||||
</tr>
|
||||
<% end_loop %>
|
||||
</tbody>
|
||||
</table>
|
||||
<% end_if %>
|
||||
<% if DataCenters %>
|
||||
<hr>
|
||||
<h3 style="color: #{$Company.CompanyColor} !important;" >Data Center Locations</h3>
|
||||
<p>
|
||||
<% loop DataCenters %>
|
||||
<% if First == 0 %>,<% end_if %>
|
||||
$City
|
||||
<% end_loop %>
|
||||
</p>
|
||||
<div style="width: 300px; height: 200px; position: relative;" id="mini-map" tabindex="0">
|
||||
</div>
|
||||
<p>Click any location to see availability zones and API endpoints</p>
|
||||
<% end_if %>
|
||||
<% if RegionalSupports %>
|
||||
<hr>
|
||||
<h3 style="color: #{$Company.CompanyColor} !important;">Regions where support is offered</h3>
|
||||
<table class="regions">
|
||||
<tbody>
|
||||
<% loop RegionalSupports %>
|
||||
<tr>
|
||||
<% loop Region %>
|
||||
<td>$Name</td>
|
||||
<% end_loop %>
|
||||
</tr>
|
||||
<% end_loop %>
|
||||
</tbody>
|
||||
</table>
|
||||
<% end_if %>
|
||||
<% if Capabilities %>
|
||||
<hr>
|
||||
<h3 style="color: #{$Company.CompanyColor} !important;">OpenStack API Coverage</h3>
|
||||
<table class="api-coverage">
|
||||
<tbody>
|
||||
<% loop Capabilities %>
|
||||
<% if SupportsVersioning %>
|
||||
<% loop ReleaseSupportedApiVersion %>
|
||||
<% if ApiVersion %>
|
||||
<% loop OpenStackComponent %>
|
||||
<tr>
|
||||
<td style="max-width:200px;" width="60%">
|
||||
$Name API
|
||||
<% if SupportsExtensions %> & Extensions<% end_if %>
|
||||
</td>
|
||||
<td width="30%">
|
||||
$CodeName
|
||||
<% end_loop %>
|
||||
<% loop ApiVersion %> $Version<% end_loop %>
|
||||
</td>
|
||||
<td width="10%" class="coverage"></td>
|
||||
</tr>
|
||||
<% end_if %>
|
||||
<% end_loop %>
|
||||
<% end_if %>
|
||||
<% end_loop %>
|
||||
</tbody>
|
||||
</table>
|
||||
<% end_if %>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-lg-6">
|
||||
<% include MarketPlaceDirectoryPage_Rating_Placeholder %>
|
||||
<% if Videos %>
|
||||
<div id="videos">
|
||||
<% loop Videos %>
|
||||
<h3 style="color: #{$Top.Company.CompanyColor} !important;" class="video-title">$Name<span class="video-duration">($FormattedLength)</span></h3>
|
||||
<iframe frameborder="0" width="250" height="200" allowfullscreen=""
|
||||
src="//www.youtube.com/embed/{$YouTubeId}?rel=0&showinfo=0&modestbranding=1&controls=2">
|
||||
</iframe>
|
||||
<% end_loop %>
|
||||
</div>
|
||||
<% end_if %>
|
||||
|
||||
<% if Resources %>
|
||||
<div id="more-resources">
|
||||
<h3 style="color: #{$Company.CompanyColor} !important;">More Resources</h3>
|
||||
<ul>
|
||||
<% loop Resources %>
|
||||
<li><a href="{$Uri}" style="color: #{$Company.CompanyColor} !important;" target="_blank" class="outbound-link">$Name</a></li>
|
||||
<% end_loop %>
|
||||
</ul>
|
||||
</div>
|
||||
<% end_if %>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
128
marketplace/templates/Layout/ConsultantsDirectoryPage_pdf.ss
Normal file
128
marketplace/templates/Layout/ConsultantsDirectoryPage_pdf.ss
Normal file
@ -0,0 +1,128 @@
|
||||
<div class="grey-bar">
|
||||
<div class="container">
|
||||
<p class="back-label">
|
||||
<a href="$Top.Link">All Providers</a>
|
||||
</p>
|
||||
<h1>$Name</h1>
|
||||
</div>
|
||||
</div>
|
||||
<% loop Consultant %>
|
||||
<div class="container marketplace-content">
|
||||
<% include MarketPlaceCompany %>
|
||||
<div class="col-lg-6">
|
||||
<div class="info-area">
|
||||
<% if ExpertiseAreas %>
|
||||
<h3 style="color: #{$Company.CompanyColor} !important;">Areas of OpenStack Expertise</h3>
|
||||
<table>
|
||||
<tbody>
|
||||
<% loop ExpertiseAreas %>
|
||||
<tr>
|
||||
<td>$Name</td>
|
||||
<td>$CodeName</td>
|
||||
</tr>
|
||||
<% end_loop %>
|
||||
</tbody>
|
||||
</table>
|
||||
<% end_if %>
|
||||
<% if Top.Services %>
|
||||
<hr>
|
||||
<h3 style="color: #{$Company.CompanyColor} !important;">Services Offered</h3>
|
||||
<ul>
|
||||
<% loop Top.Services %>
|
||||
<li>$Type</li>
|
||||
<% end_loop %>
|
||||
</ul>
|
||||
<% end_if %>
|
||||
<% if PreviousClients %>
|
||||
<hr>
|
||||
<h3 style="color: #{$Company.CompanyColor} !important;">Select Clients</h3>
|
||||
<ul>
|
||||
<% loop PreviousClients %>
|
||||
<li>$Name</li>
|
||||
<% end_loop %>
|
||||
</ul>
|
||||
<% end_if %>
|
||||
<% if ConfigurationManagementExpertises %>
|
||||
<hr>
|
||||
<h3 style="color: #{$Company.CompanyColor} !important;">Configuration Management Expertise</h3>
|
||||
<ul>
|
||||
<% loop ConfigurationManagementExpertises %>
|
||||
<li>$Type</li>
|
||||
<% end_loop %>
|
||||
</ul>
|
||||
<% end_if %>
|
||||
<% if SpokenLanguages %>
|
||||
<hr>
|
||||
<h3 style="color: #{$Company.CompanyColor} !important;">Languages</h3>
|
||||
<ul>
|
||||
<% loop SpokenLanguages %>
|
||||
<li>$Name</li>
|
||||
<% end_loop %>
|
||||
</ul>
|
||||
<% end_if %>
|
||||
<% if Top.Regions %>
|
||||
<hr>
|
||||
<h3 style="color: #{$Company.CompanyColor} !important;">Regions with local offices</h3>
|
||||
<ul>
|
||||
<% loop Top.Regions %>
|
||||
<li>$Name</li>
|
||||
<% end_loop %>
|
||||
</ul>
|
||||
<% end_if %>
|
||||
<% if Offices %>
|
||||
<hr>
|
||||
<h3 style="color: #{$Company.CompanyColor} !important;">Offices</h3>
|
||||
<script type="text/javascript">
|
||||
var offices_instance = $Top.CurrentOfficesLocationsJson;
|
||||
</script>
|
||||
<div style="width: 300px; height: 200px; position: relative;" id="mini-map" tabindex="0">
|
||||
</div>
|
||||
<p>
|
||||
Click any map pin to see office address
|
||||
</p>
|
||||
<% end_if %>
|
||||
<% if RegionalSupports %>
|
||||
<hr>
|
||||
<h3 style="color: #{$Company.CompanyColor} !important;">Regions where support is offered</h3>
|
||||
<table class="regions">
|
||||
<tbody>
|
||||
<% loop RegionalSupports %>
|
||||
<tr>
|
||||
<% loop Region %>
|
||||
<td>$Name</td>
|
||||
<% end_loop %>
|
||||
</tr>
|
||||
<% end_loop %>
|
||||
</tbody>
|
||||
</table>
|
||||
<% end_if %>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-lg-6">
|
||||
<% include MarketPlaceDirectoryPage_Rating_Placeholder %>
|
||||
<% if Videos %>
|
||||
<div id="videos">
|
||||
<% loop Videos %>
|
||||
<h3 style="color: #{$Top.Company.CompanyColor} !important;" class="video-title">$Name<span class="video-duration">($FormattedLength)</span></h3>
|
||||
<iframe frameborder="0" width="250" height="200" allowfullscreen=""
|
||||
src="//www.youtube.com/embed/{$YouTubeId}?rel=0&showinfo=0&modestbranding=1&controls=2">
|
||||
</iframe>
|
||||
<% end_loop %>
|
||||
</div>
|
||||
<% end_if %>
|
||||
|
||||
<% if Resources %>
|
||||
<div id="more-resources">
|
||||
<h3 style="color: #{$Company.CompanyColor} !important;">More Resources</h3>
|
||||
<ul>
|
||||
<% loop Resources %>
|
||||
<li><a href="{$Uri}" style="color: #{$Company.CompanyColor} !important;" class="outbound-link" target="_blank">$Name</a></li>
|
||||
<% end_loop %>
|
||||
</ul>
|
||||
</div>
|
||||
<% end_if %>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<% end_loop %>
|
159
marketplace/templates/Layout/DistributionsDirectoryPage_pdf.ss
Normal file
159
marketplace/templates/Layout/DistributionsDirectoryPage_pdf.ss
Normal file
@ -0,0 +1,159 @@
|
||||
<div class="grey-bar">
|
||||
<h1 style="color: #{$Company.CompanyColor} !important;">$Name</h1>
|
||||
</div>
|
||||
<div class="container marketplace-content">
|
||||
<table width="540px">
|
||||
<tr>
|
||||
<td rowspan="5" valign="top" style="width:140px;padding-right:15px">
|
||||
$Company.SmallLogoPreview(150)
|
||||
<h2 style="color: #{$Company.CompanyColor} !important;">About $Company.Name</h2>
|
||||
<p>$Company.Overview</p>
|
||||
<hr>
|
||||
<div class="pullquote">
|
||||
<h2 style="color: #{$Company.CompanyColor} !important;">$Company.Name Commitment</h2>
|
||||
<div <% if Company.CommitmentAuthor %>class="commitment"<% end_if %>>$Company.Commitment</div>
|
||||
<% if Company.CommitmentAuthor %>
|
||||
<p class="author">—$Company.CommitmentAuthor, $Company.Name</p>
|
||||
<% end_if %>
|
||||
</div>
|
||||
</td>
|
||||
<td colspan="2" valign="top" style="width:400px;padding-left:15px;">
|
||||
<div class="info-area">
|
||||
<h1 style="color: #{$Company.CompanyColor} !important;">
|
||||
$Name
|
||||
</h1>
|
||||
<p>$Overview</p>
|
||||
</div>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td valign="top" style="width:200px;padding-left:15px;">
|
||||
<div class="info-area">
|
||||
<% if Capabilities %>
|
||||
<h3 style="color: #{$Company.CompanyColor} !important;">OpenStack Services Enabled</h3>
|
||||
<table>
|
||||
<tbody>
|
||||
<tr>
|
||||
<th width="50%">Service</th>
|
||||
<th>OpenStack Version</th>
|
||||
</tr>
|
||||
<% loop Capabilities %>
|
||||
<tr>
|
||||
<td>
|
||||
<% loop ReleaseSupportedApiVersion %>
|
||||
<% loop OpenStackComponent %>
|
||||
$Name
|
||||
<% end_loop %>
|
||||
<% end_loop %>
|
||||
</td>
|
||||
<td>
|
||||
<% loop ReleaseSupportedApiVersion %>
|
||||
<% loop Release %>
|
||||
$Name
|
||||
<% end_loop %>
|
||||
<% end_loop %>
|
||||
</td>
|
||||
</tr>
|
||||
<% end_loop %>
|
||||
</tbody>
|
||||
</table>
|
||||
<% end_if %>
|
||||
<hr>
|
||||
<% if HyperVisors %>
|
||||
<h3 style="color: #{$Company.CompanyColor} !important;">Supported Hypervisors</h3>
|
||||
<p>
|
||||
<% loop HyperVisors %>
|
||||
<% if First == 0 %>,<% end_if %>
|
||||
$Type
|
||||
<% end_loop %>
|
||||
</p>
|
||||
<% end_if %>
|
||||
<% if Guests %>
|
||||
<h3 style="color: #{$Company.CompanyColor} !important;">Supported Guests</h3>
|
||||
<p>
|
||||
<% loop Guests %>
|
||||
<% if First == 0 %>,<% end_if %>
|
||||
$Type
|
||||
<% end_loop %>
|
||||
</p>
|
||||
<% end_if %>
|
||||
<% if RegionalSupports %>
|
||||
<hr>
|
||||
<h3 style="color: #{$Company.CompanyColor} !important;">Regions where support is offered</h3>
|
||||
<table class="regions">
|
||||
<tbody>
|
||||
<% loop RegionalSupports %>
|
||||
<tr>
|
||||
<% loop Region %>
|
||||
<td>$Name</td>
|
||||
<% end_loop %>
|
||||
</tr>
|
||||
<% end_loop %>
|
||||
</tbody>
|
||||
</table>
|
||||
<% end_if %>
|
||||
<% if Capabilities %>
|
||||
<hr>
|
||||
<h3 style="color: #{$Company.CompanyColor} !important;">OpenStack API Coverage</h3>
|
||||
<table class="api-coverage">
|
||||
<tbody>
|
||||
<% loop Capabilities %>
|
||||
<% if SupportsVersioning %>
|
||||
<% loop ReleaseSupportedApiVersion %>
|
||||
<% if ApiVersion %>
|
||||
<% loop OpenStackComponent %>
|
||||
<tr>
|
||||
<td>
|
||||
$Name API
|
||||
<% if SupportsExtensions %> & Extensions<% end_if %>
|
||||
</td>
|
||||
<td>
|
||||
$CodeName
|
||||
<% end_loop %>
|
||||
<% loop ApiVersion %> $Version<% end_loop %>
|
||||
</td>
|
||||
|
||||
<% end_if %>
|
||||
<% end_loop %>
|
||||
<td class="coverage">
|
||||
<span>$CoveragePercent %</span>
|
||||
</td>
|
||||
</tr>
|
||||
<% end_if %>
|
||||
<% end_loop %>
|
||||
</tbody>
|
||||
</table>
|
||||
<% end_if %>
|
||||
</div>
|
||||
</td>
|
||||
<td valign="top" style="width:200px;padding-left:15px;padding-right:15px">
|
||||
<% include MarketPlaceDirectoryPage_Rating_Placeholder %>
|
||||
<% if Videos %>
|
||||
<div id="videos">
|
||||
<% loop Videos %>
|
||||
<h3 style="color: #{$Top.Company.CompanyColor} !important;" class="video-title">$Name<span class="video-duration">($FormattedLength)</span></h3>
|
||||
<iframe frameborder="0" width="250" height="200" allowfullscreen=""
|
||||
src="//www.youtube.com/embed/{$YouTubeId}?rel=0&showinfo=0&modestbranding=1&controls=2">
|
||||
</iframe>
|
||||
<% end_loop %>
|
||||
</div>
|
||||
<% end_if %>
|
||||
|
||||
<% if Resources %>
|
||||
<div id="more-resources">
|
||||
<h3 style="color: #{$Company.CompanyColor} !important;">More Resources</h3>
|
||||
<ul>
|
||||
<% loop Resources %>
|
||||
<li><a href="{$Uri}" style="color: #{$Company.CompanyColor} !important;" target="_blank" class="outbound-link">$Name</a></li>
|
||||
<% end_loop %>
|
||||
</ul>
|
||||
</div>
|
||||
<% end_if %>
|
||||
</td>
|
||||
</tr>
|
||||
<tr><td></td><td></td></tr>
|
||||
<tr><td></td><td></td></tr>
|
||||
<tr><td></td><td></td></tr>
|
||||
<tr><td></td><td></td></tr>
|
||||
</table>
|
||||
</div>
|
@ -6,6 +6,9 @@
|
||||
<% if CurrentAppliance %>
|
||||
<a style="overflow:hidden;white-space: nowrap;font-weight:normal;float:right;margin-bottom:50px;text-align:center;margin-right:50px;" class="roundedButton addDeploymentBtn" target="_blank" href="$Top.Link(appliance)/$CurrentAppliance.ID/preview">Preview</a>
|
||||
<% end_if %>
|
||||
<% if CurrentAppliance %>
|
||||
<a style="overflow:hidden;white-space: nowrap;font-weight:normal;float:right;margin-bottom:50px;text-align:center;margin-right:50px;" class="roundedButton addDeploymentBtn" target="_blank" href="$Top.Link(appliance)/$CurrentAppliance.ID/pdf">Download PDF</a>
|
||||
<% end_if %>
|
||||
<a style="overflow:hidden;white-space: nowrap;font-weight:normal;float:right;margin-bottom:50px;text-align:center;margin-right:50px;" class="roundedButton addDeploymentBtn" href="$Top.Link"><< Back to Products</a>
|
||||
</div>
|
||||
<div style="clear:both">
|
||||
|
@ -6,6 +6,9 @@
|
||||
<% if CurrentConsultant %>
|
||||
<a style="overflow:hidden;white-space: nowrap;font-weight:normal;float:right;margin-bottom:50px;text-align:center;margin-right:50px;" class="roundedButton addDeploymentBtn" target="_blank" href="$Top.Link(consultant)/$CurrentConsultant.ID/preview">Preview</a>
|
||||
<% end_if %>
|
||||
<% if CurrentConsultant %>
|
||||
<a style="overflow:hidden;white-space: nowrap;font-weight:normal;float:right;margin-bottom:50px;text-align:center;margin-right:50px;" class="roundedButton addDeploymentBtn" target="_blank" href="$Top.Link(consultant)/$CurrentConsultant.ID/pdf">Download PDF</a>
|
||||
<% end_if %>
|
||||
<a style="overflow:hidden;white-space: nowrap;font-weight:normal;float:right;margin-bottom:50px;text-align:center;margin-right:50px;" class="roundedButton addDeploymentBtn" href="$Top.Link(consultants)"><< Back to Products</a>
|
||||
</div>
|
||||
<div style="clear:both">
|
||||
|
@ -6,6 +6,9 @@
|
||||
<% if CurrentDistribution %>
|
||||
<a style="overflow:hidden;white-space: nowrap;font-weight:normal;float:right;margin-bottom:50px;text-align:center;margin-right:50px;" class="roundedButton addDeploymentBtn" target="_blank" href="$Top.Link(distribution)/$CurrentDistribution.ID/preview">Preview</a>
|
||||
<% end_if %>
|
||||
<% if CurrentDistribution %>
|
||||
<a style="overflow:hidden;white-space: nowrap;font-weight:normal;float:right;margin-bottom:50px;text-align:center;margin-right:50px;" class="roundedButton addDeploymentBtn" target="_blank" href="$Top.Link(distribution)/$CurrentDistribution.ID/pdf">Download PDF</a>
|
||||
<% end_if %>
|
||||
<a style="overflow:hidden;white-space: nowrap;font-weight:normal;float:right;margin-bottom:50px;text-align:center;margin-right:50px;" class="roundedButton addDeploymentBtn" href="$Top.Link"><< Back to Products</a>
|
||||
</div>
|
||||
<div style="clear:both">
|
||||
|
@ -6,6 +6,9 @@
|
||||
<% if CurrentPrivateCloud %>
|
||||
<a style="overflow:hidden;white-space: nowrap;font-weight:normal;float:right;margin-bottom:50px;text-align:center;margin-right:50px;" class="roundedButton addDeploymentBtn" target="_blank" href="$Top.Link(private_cloud)/$CurrentPrivateCloud.ID/preview">Preview</a>
|
||||
<% end_if %>
|
||||
<% if CurrentPrivateCloud %>
|
||||
<a style="overflow:hidden;white-space: nowrap;font-weight:normal;float:right;margin-bottom:50px;text-align:center;margin-right:50px;" class="roundedButton addDeploymentBtn" target="_blank" href="$Top.Link(private_cloud)/$CurrentPrivateCloud.ID/pdf">Download PDF</a>
|
||||
<% end_if %>
|
||||
<a style="overflow:hidden;white-space: nowrap;font-weight:normal;float:right;margin-bottom:50px;text-align:center;margin-right:50px;" class="roundedButton addDeploymentBtn" href="$Top.Link(private_clouds)"><< Back to Products</a>
|
||||
</div>
|
||||
<div style="clear:both">
|
||||
|
@ -6,6 +6,9 @@
|
||||
<% if CurrentPublicCloud %>
|
||||
<a style="overflow:hidden;white-space: nowrap;font-weight:normal;float:right;margin-bottom:50px;text-align:center;margin-right:50px;" class="roundedButton addDeploymentBtn" target="_blank" href="$Top.Link(public_cloud)/$CurrentPublicCloud.ID/preview">Preview</a>
|
||||
<% end_if %>
|
||||
<% if CurrentPublicCloud %>
|
||||
<a style="overflow:hidden;white-space: nowrap;font-weight:normal;float:right;margin-bottom:50px;text-align:center;margin-right:50px;" class="roundedButton addDeploymentBtn" target="_blank" href="$Top.Link(public_cloud)/$CurrentPublicCloud.ID/pdf">Download PDF</a>
|
||||
<% end_if %>
|
||||
<a style="overflow:hidden;white-space: nowrap;font-weight:normal;float:right;margin-bottom:50px;text-align:center;margin-right:50px;" class="roundedButton addDeploymentBtn" href="$Top.Link(public_clouds)"><< Back to Products</a>
|
||||
</div>
|
||||
<div style="clear:both">
|
||||
|
Loading…
x
Reference in New Issue
Block a user