1 |
296 |
ahitrov |
% if ( $m->comp_exists ("/comps/$prj/header.msn") ) { |
2 |
|
|
<& "/comps/$prj/header.msn", alias => 'main' &> |
3 |
|
|
% } else { |
4 |
|
|
<& "/comps/header.msn", alias => 'main' &> |
5 |
|
|
% } |
6 |
|
|
|
7 |
|
|
|
8 |
|
|
<table width="100%" cellpadding="0" cellspacing="0" border="0"> |
9 |
|
|
<tr valign="top"><td style="padding:0 32px 0 18px;" width="1%" nowrap> |
10 |
|
|
<!--Menus--> |
11 |
|
|
% if ( $m->comp_exists ("/comps/$prj/left.msn") ) { |
12 |
|
|
<& "/comps/$prj/left.msn" &> |
13 |
|
|
% } |
14 |
|
|
<!--/Menus--> |
15 |
|
|
</td> |
16 |
|
|
|
17 |
|
|
<td width="1%"><img src="/i/<% $prj %>/diaton_device.png" width="84" height="334" alt="DIATON tonometer"></td> |
18 |
|
|
<td style="padding:0 30px 20px;" width="98%"> |
19 |
|
|
<!--Information--> |
20 |
|
|
<h2><% $section->name %></h2> |
21 |
|
|
|
22 |
|
|
% foreach my $doc (@documents ) { |
23 |
|
|
% my $logo = $doc->get_image('logo'); |
24 |
|
|
% if ( $doc->country && $doc->country ne $country ) { |
25 |
|
|
% $country = $doc->country; |
26 |
|
|
<h4 class="text"><% $doc->country %>:</h4> |
27 |
|
|
% } |
28 |
|
|
% if ( $doc->type ) { |
29 |
|
|
<p class="text"><% $doc->type %></p> |
30 |
|
|
% } |
31 |
|
|
% if ( ref $logo && exists $logo->{filename} ) { |
32 |
|
|
% my $mini = $logo->{mini}{'100x100'}; |
33 |
|
|
<img src="<% $mini->{filename} %>" width="<% $mini->{width} %>" height="<% $mini->{height} %>" vspace="6" hspace="5" align="left"> |
34 |
|
|
% } |
35 |
|
|
<p class="text"><b><% $doc->name %></b><br> |
36 |
|
|
% if ( $doc->address ) { |
37 |
|
|
<& /inc/text_format.msn, doc => $doc, field => 'address' &><br> |
38 |
|
|
% } |
39 |
|
|
% if ( $doc->phone ) { |
40 |
|
|
% my @data = split /,\s*/, $doc->phone; |
41 |
|
|
Tel: <% $data[0] %><br> |
42 |
|
|
% if ( scalar @data > 1 ) { |
43 |
|
|
% for ( 1..$#data ) { |
44 |
|
|
<% $data[$_] %><br> |
45 |
|
|
% } |
46 |
|
|
% } |
47 |
|
|
% } |
48 |
|
|
% if ( $doc->phonefax ) { |
49 |
|
|
% my @data = split /,\s*/, $doc->phonefax; |
50 |
|
|
Tel/Fax: <% $data[0] %><br> |
51 |
|
|
% if ( scalar @data > 1 ) { |
52 |
|
|
% for ( 1..$#data ) { |
53 |
|
|
<% $data[$_] %><br> |
54 |
|
|
% } |
55 |
|
|
% } |
56 |
|
|
% } |
57 |
|
|
% if ( $doc->fax ) { |
58 |
|
|
% my @data = split /,\s*/, $doc->fax; |
59 |
|
|
Fax: <% $data[0] %><br> |
60 |
|
|
% if ( scalar @data > 1 ) { |
61 |
|
|
% for ( 1..$#data ) { |
62 |
|
|
<% $data[$_] %><br> |
63 |
|
|
% } |
64 |
|
|
% } |
65 |
|
|
% } |
66 |
|
|
% if ( $doc->email ) { |
67 |
|
|
% my @data = split /,\s*/, $doc->email; |
68 |
|
|
E-mail: <a href="mailto:<% $data[0] %>"><% $data[0] %></a><br> |
69 |
|
|
% if ( scalar @data > 1 ) { |
70 |
|
|
% for ( 1..$#data ) { |
71 |
|
|
<a href="mailto:<% $data[$_] %>"><% $data[$_] %></a><br> |
72 |
|
|
% } |
73 |
|
|
% } |
74 |
|
|
% } |
75 |
|
|
</p> |
76 |
|
|
% } |
77 |
|
|
|
78 |
|
|
|
79 |
|
|
<!--/Information--> |
80 |
|
|
</td></tr> |
81 |
|
|
</table> |
82 |
|
|
|
83 |
|
|
|
84 |
|
|
|
85 |
|
|
% ### Футер |
86 |
|
|
% ############################################## |
87 |
|
|
% if ( $m->comp_exists ("/comps/$prj/footer.msn") ) { |
88 |
|
|
<& "/comps/$prj/footer.msn" &> |
89 |
|
|
% } else { |
90 |
|
|
<& "/comps/footer.msn" &> |
91 |
|
|
% } |
92 |
|
|
% ### /Футер |
93 |
|
|
<%args> |
94 |
|
|
|
95 |
|
|
$p => 1 |
96 |
|
|
$id => undef |
97 |
|
|
|
98 |
|
|
</%args> |
99 |
|
|
<%init> |
100 |
|
|
|
101 |
|
|
my $prj = $request->{project}; |
102 |
|
|
my $profile = $request->{project_profile}; |
103 |
|
|
my $root = $request->{project_section}; |
104 |
|
|
&abort404 if $id && $id !~ /^\d+$/; |
105 |
|
|
|
106 |
|
|
my @documents; |
107 |
|
|
my ($section) = $keeper->get_sections ( |
108 |
|
|
s => $root->id, |
109 |
|
|
class => 'promosuite::AnnoSection', |
110 |
|
|
limit => 1, |
111 |
|
|
status => 1, |
112 |
|
|
); |
113 |
|
|
if ( ref $section ) { |
114 |
|
|
@documents = $keeper->get_documents ( |
115 |
|
|
s => $section->id, |
116 |
|
|
class => 'promosuite::Company', |
117 |
|
|
status => [1,2], |
118 |
|
|
order_by => 'status desc, country, name', |
119 |
|
|
); |
120 |
|
|
} |
121 |
|
|
my $country = ''; |
122 |
|
|
|
123 |
|
|
</%init> |