| 5357 |
dpurdie |
1 |
<%@LANGUAGE="VBSCRIPT"%>
|
|
|
2 |
<%
|
|
|
3 |
'=====================================================
|
|
|
4 |
'| |
|
|
|
5 |
'| MEMBERS |
|
|
|
6 |
'| PUBLIC VIEW |
|
|
|
7 |
'=====================================================
|
|
|
8 |
%>
|
|
|
9 |
<%
|
|
|
10 |
Option explicit
|
|
|
11 |
' Good idea to set when using redirect
|
|
|
12 |
Response.Expires = 0 ' always load the page, dont store
|
|
|
13 |
%>
|
|
|
14 |
<!--#include file="common/conf.asp"-->
|
|
|
15 |
<!--#include file="common/globals.asp"-->
|
|
|
16 |
<!--#include file="common/formating.asp"-->
|
|
|
17 |
<!--#include file="common/qstr.asp"-->
|
|
|
18 |
<!--#include file="common/common_subs.asp"-->
|
|
|
19 |
<%
|
|
|
20 |
'------------ ACCESS CONTROL ------------------
|
|
|
21 |
%>
|
|
|
22 |
<!--#include file="_access_control_login.asp"-->
|
|
|
23 |
<!--#include file="_access_control_general.asp"-->
|
|
|
24 |
<%
|
|
|
25 |
'------------ Variable Definition -------------
|
|
|
26 |
Dim rsTemp
|
|
|
27 |
'------------ Constants Declaration -----------
|
|
|
28 |
'------------ Variable Init -------------------
|
|
|
29 |
'----------------------------------------------
|
|
|
30 |
%>
|
|
|
31 |
<%
|
|
|
32 |
Function Get_Public_Views ( NNuser_id )
|
|
|
33 |
Get_Public_Views = ReadFile( rootPath & "queries\public_views_list.qry" )
|
|
|
34 |
Get_Public_Views = Replace( Get_Public_Views, "$USER_ID$", NNuser_id)
|
|
|
35 |
End Function
|
|
|
36 |
|
|
|
37 |
Sub Remove_View_Settings ( NNuser_id )
|
|
|
38 |
objEH.TryORA ( OraSession )
|
|
|
39 |
On Error Resume Next
|
|
|
40 |
OraDatabase.ExecuteSQL " DELETE FROM view_settings vis WHERE vis.user_id = "& NNuser_id &" AND vis.view_id IN (SELECT vi.view_id FROM views vi WHERE vi.owner_id = 0 OR vi.public_read = 'Y')"
|
|
|
41 |
objEH.CatchORA ( OraSession )
|
|
|
42 |
End Sub
|
|
|
43 |
|
|
|
44 |
Sub Insert_View_Settings ( NNuser_id, SSpublicshow )
|
|
|
45 |
If SSpublicshow <> "" Then
|
|
|
46 |
objEH.TryORA ( OraSession )
|
|
|
47 |
On Error Resume Next
|
|
|
48 |
OraDatabase.ExecuteSQL " INSERT INTO view_settings"&_
|
|
|
49 |
" SELECT TO_NUMBER('"& NNuser_id &"') AS user_id, vi.view_id FROM views vi WHERE vi.view_id IN ("& SSpublicshow &")"
|
|
|
50 |
objEH.CatchORA ( OraSession )
|
|
|
51 |
End If
|
|
|
52 |
End Sub
|
|
|
53 |
|
|
|
54 |
Function Owner_Format( NNuser_id, SSemail, SSname )
|
|
|
55 |
If CInt(NNuser_id) = 0 Then
|
|
|
56 |
Response.write "public"
|
|
|
57 |
Else
|
| 6612 |
dpurdie |
58 |
Response.write emailField(enum_imgUser & SSname ,SSemail)
|
| 5357 |
dpurdie |
59 |
End If
|
|
|
60 |
End Function
|
|
|
61 |
%>
|
|
|
62 |
<%
|
|
|
63 |
'--- Process submition ---
|
|
|
64 |
If (QStrPar("action") <> "") Then
|
|
|
65 |
' All mandatory parameters FOUND
|
|
|
66 |
Call Remove_View_Settings ( objAccessControl.UserId )
|
|
|
67 |
Call Insert_View_Settings ( objAccessControl.UserId, Request("FRpublicshow") )
|
|
|
68 |
End If
|
|
|
69 |
%>
|
|
|
70 |
<html>
|
|
|
71 |
<head>
|
|
|
72 |
<title>Release Manager</title>
|
|
|
73 |
<link rel="shortcut icon" href="<%=FavIcon%>"/>
|
|
|
74 |
<meta HTTP-EQUIV="Pragma" CONTENT="no-cache">
|
|
|
75 |
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
|
| 6579 |
dpurdie |
76 |
<link rel="stylesheet" href="images/release_manager_style.css?ver=<%=VixVerNum%>" type="text/css">
|
|
|
77 |
<link rel="stylesheet" href="images/navigation.css?ver=<%=VixVerNum%>" type="text/css">
|
|
|
78 |
<script language="JavaScript" src="images/common.js?ver=<%=VixVerNum%>"></script>
|
| 5984 |
dpurdie |
79 |
<!--#include file="_menu_def.asp"-->
|
| 6579 |
dpurdie |
80 |
<script language="JavaScript1.2" src="images/popup_menu.js?ver=<%=VixVerNum%>"></script>
|
| 5590 |
dpurdie |
81 |
<!--#include file="_jquery_includes.asp"-->
|
| 5357 |
dpurdie |
82 |
</head>
|
| 7030 |
dpurdie |
83 |
<body bgcolor="#FFFFFF" text="#000000" leftmargin="0" topmargin="0">
|
| 5357 |
dpurdie |
84 |
<!-- HEADER -->
|
|
|
85 |
<!--#include file="_header.asp"-->
|
|
|
86 |
<!-- BODY ---->
|
|
|
87 |
<table width="100%" border="0" cellspacing="0" cellpadding="0">
|
|
|
88 |
<tr>
|
|
|
89 |
<td width="1%" background="images/bg_member_dark.gif" valign="top">
|
|
|
90 |
<!-- MEMBERS MENU ---------------------------------------------->
|
|
|
91 |
<!--#include file="members_menu_def.asp"-->
|
|
|
92 |
<%Call Member_Menu( "views" )%>
|
|
|
93 |
<!-- MEMBERS MENU END ------------------------------------------>
|
|
|
94 |
</td>
|
| 5984 |
dpurdie |
95 |
<td width="1%" valign="top" background="images/bg_member_light.gif"></td>
|
| 5357 |
dpurdie |
96 |
<td rowspan="2" valign="top" width="1%" background="images/bg_member_light.gif" nowrap>
|
|
|
97 |
<!------------------------------------------->
|
|
|
98 |
<br>
|
|
|
99 |
<span class="mmb_ttl">Public View</span><br>
|
|
|
100 |
<table width="100%" border="0" cellspacing="0" cellpadding="0">
|
|
|
101 |
<form name="publicview" method="post" action="members_public_view.asp?done=done<%=QSTR%>">
|
|
|
102 |
<tr>
|
|
|
103 |
<td width="1%"> </td>
|
|
|
104 |
<td align="right"><img src="images/h_trsp_dot.gif" width="500" height="30"></td>
|
|
|
105 |
<td width="1%"> </td>
|
|
|
106 |
</tr>
|
|
|
107 |
<tr>
|
|
|
108 |
<td align="left" valign="top" width="1%" background="images/bg_member_dark.gif"><img src="images/h_trsp_dot.gif" width="13" height="13"></td>
|
| 5590 |
dpurdie |
109 |
<td background="images/bg_member_dark.gif" align="left" class="wform_ttl"><a href="#" onClick="MM_openVixIFrame('members_new_public_view.asp','Create New Public View')" class="wform_ttl"><img src="images/i_add_view.gif" width="32" height="18" border="0" align="absmiddle" hspace="2" vspace="10" alt="Create new public view">New View</a></td>
|
| 5357 |
dpurdie |
110 |
<td align="right" valign="top" width="1%" background="images/bg_member_dark.gif"> </td>
|
|
|
111 |
</tr>
|
|
|
112 |
<tr>
|
|
|
113 |
<td width="1%" bgcolor="#FFFFFF"><img src="images/h_trsp_dot.gif" width="10" height="100"></td>
|
| 7030 |
dpurdie |
114 |
<td bgcolor="#FFFFFF" valign="top"> <br>
|
|
|
115 |
<table width="100%" border="0" cellspacing="1" cellpadding="2" class=stdGrey>
|
|
|
116 |
<thead>
|
|
|
117 |
<th nowrap width="1%">Show</th>
|
|
|
118 |
<th nowrap width="100%">View Name</th>
|
|
|
119 |
<th nowrap width="1%">Package Count</th>
|
|
|
120 |
<th nowrap width="1%">Owner</th>
|
|
|
121 |
<th width="1%" colspan=2>Edit</th>
|
|
|
122 |
</thead>
|
| 5357 |
dpurdie |
123 |
<%Set rsTemp = OraDatabase.DbCreateDynaset( Get_Public_Views( objAccessControl.UserId ), cint(0))
|
|
|
124 |
While ((NOT rsTemp.BOF) AND (NOT rsTemp.EOF))%>
|
| 7030 |
dpurdie |
125 |
<tr class='tight nowrap'>
|
| 5357 |
dpurdie |
126 |
<%If rsTemp.Fields("base_view") = "Y" Then%>
|
| 7030 |
dpurdie |
127 |
<td align="center"><input type="checkbox" name="FRpublicshow" value="<%=rsTemp.Fields("view_id")%>" <%If CBool(rsTemp.Fields("show")) Then Response.write "checked"%>></td>
|
|
|
128 |
<td nowrap><%=rsTemp.Fields("view_name")%></td>
|
|
|
129 |
<td nowrap align="center"><%=rsTemp.Fields("pkg_count")%></td>
|
|
|
130 |
<td nowrap>Base View</td>
|
|
|
131 |
<td><img src="images/i_edit_disable.gif" width="12" height="12" hspace="5"></td>
|
|
|
132 |
<td><img src="images/i_delete_disable.gif" width="13" height="12" hspace="5"></td>
|
| 5357 |
dpurdie |
133 |
<%ElseIf rsTemp.Fields("base_view") = "S" Then%>
|
| 7030 |
dpurdie |
134 |
<td align="center"><input type="checkbox" disabled></td>
|
|
|
135 |
<td nowrap><%=rsTemp.Fields("view_name")%></td>
|
|
|
136 |
<td nowrap align="center"></td>
|
|
|
137 |
<td nowrap>SDK View</td>
|
|
|
138 |
<td><img src="images/i_edit_disable.gif" width="12" height="12" hspace="5"></td>
|
|
|
139 |
<td><img src="images/i_delete_disable.gif" width="13" height="12" hspace="5"></td>
|
| 5357 |
dpurdie |
140 |
<%Else%>
|
| 7030 |
dpurdie |
141 |
<td align="center"><input type="checkbox" name="FRpublicshow" value="<%=rsTemp.Fields("view_id")%>" <%If CBool(rsTemp.Fields("show")) Then Response.write "checked"%>></td>
|
| 7031 |
dpurdie |
142 |
<td nowrap><%=rsTemp.Fields("view_name")%></td>
|
|
|
143 |
<td nowrap align="center"><%=rsTemp.Fields("pkg_count")%></td>
|
|
|
144 |
<td nowrap><%=Owner_Format( rsTemp.Fields("owner_id"), rsTemp.Fields("owner_email"), rsTemp.Fields("owner_name") )%></td>
|
| 7030 |
dpurdie |
145 |
<%If (Cint(rsTemp.Fields("owner_id")) = Cint(objAccessControl.UserId)) OR (Cint(rsTemp.Fields("owner_id")) = 0) Then%>
|
|
|
146 |
<td><a href="#" onClick="MM_openVixIFrame('members_edit_public_view.asp?FRview_id=<%=rsTemp.Fields("view_id")%>','Edit Public View')"><img src="images/i_edit.gif" width="12" height="12" hspace="5" border="0" alt="Edit view" title="Edit view"></a></td>
|
|
|
147 |
<td><a href="_remove_public_view.asp?FRview_id=<%=rsTemp.Fields("view_id")%>"><img src="images/i_delete.gif" width="13" height="12" hspace="5" border="0" alt="Delete view permanently" title="Delete view permanently"></a></td>
|
| 5357 |
dpurdie |
148 |
<%Else%>
|
| 7030 |
dpurdie |
149 |
<td><img src="images/i_edit_disable.gif" width="12" height="12" hspace="5"></td>
|
| 7031 |
dpurdie |
150 |
<td><img src="images/i_delete_disable.gif" width="13" height="12" hspace="5"></td>
|
| 5357 |
dpurdie |
151 |
<%End If%>
|
|
|
152 |
<%End If%>
|
|
|
153 |
</tr>
|
|
|
154 |
<%rsTemp.MoveNext
|
|
|
155 |
WEnd%>
|
|
|
156 |
</table>
|
|
|
157 |
<br>
|
|
|
158 |
<input type="hidden" name="action" value="true">
|
|
|
159 |
<input type="submit" name="btn" value=" Apply " class="form_btn">
|
|
|
160 |
<input type="reset" name="btn" value="Reset" class="form_btn"><%If (QStrPar("action") <> "") Then Response.write " Changes applied!"%>
|
|
|
161 |
<br><br>
|
|
|
162 |
</td>
|
|
|
163 |
<td width="1%" background="images/lbox_bgside_white.gif"> </td>
|
|
|
164 |
</tr>
|
|
|
165 |
<tr>
|
|
|
166 |
<td width="1%" background="images/bg_member_dark.gif" valign="bottom"><img src="images/h_trsp_dot.gif" width="13" height="13"></td>
|
|
|
167 |
<td background="images/bg_member_dark.gif"></td>
|
|
|
168 |
<td width="1%" background="images/bg_member_dark.gif" valign="bottom" align="right"><img src="images/h_trsp_dot.gif" width="13" height="13"></td>
|
|
|
169 |
</tr>
|
|
|
170 |
</form>
|
|
|
171 |
</table>
|
|
|
172 |
<!-------------------------------------------------------->
|
|
|
173 |
</td>
|
|
|
174 |
<td rowspan="2" valign="bottom" width="100%" background="images/bg_member_light.gif" align="right"><img src="images/bg_img_view.gif" width="249" height="144" vspace="10" hspace="10"></td>
|
|
|
175 |
</tr>
|
|
|
176 |
<tr>
|
|
|
177 |
<td valign="bottom" align="center" background="images/bg_member_dark.gif"><img src="images/img_members.gif" width="81" height="57" vspace="20" hspace="30"></td>
|
|
|
178 |
<td background="images/bg_member_light.gif" valign="top"><img src="images/h_trsp_dot.gif" width="100" height="400"></td>
|
|
|
179 |
</tr>
|
|
|
180 |
</table>
|
|
|
181 |
<!-- FOOTER -->
|
|
|
182 |
<!--#include file="_footer.asp"-->
|
|
|
183 |
</body>
|
|
|
184 |
</html>
|