Subversion Repositories DevTools

Rev

Rev 2362 | Rev 3897 | Go to most recent revision | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 2362 Rev 3894
Line 18... Line 18...
18
<!--#include file="common/common_subs.asp"-->
18
<!--#include file="common/common_subs.asp"-->
19
<!--#include file="common/_form_window_common.asp"-->
19
<!--#include file="common/_form_window_common.asp"-->
20
<!--#include file="_action_buttons.asp"-->
20
<!--#include file="_action_buttons.asp"-->
21
<!--#include file="class/classActionButtonControl.asp"-->
21
<!--#include file="class/classActionButtonControl.asp"-->
22
<!--#include file="common/daemon_instructions.asp"-->
22
<!--#include file="common/daemon_instructions.asp"-->
-
 
23
<script type="text/javascript" src="scripts/json2.js"></script>
23
<%
24
<%
24
' Set rfile parameter. This is a return page after Login
25
' Set rfile parameter. This is a return page after Login
25
Call objPMod.StoreParameter ( "rfile", "rtree.asp" )
26
Call objPMod.StoreParameter ( "rfile", "rtree.asp" )
26
objPMod.PersistInQryString("proj_id")
27
objPMod.PersistInQryString("proj_id")
27
'------------ ACCESS CONTROL ------------------
28
'------------ ACCESS CONTROL ------------------
Line 37... Line 38...
37
Dim objSortHelper
38
Dim objSortHelper
38
Dim rsQry
39
Dim rsQry
39
Dim parRtagId
40
Dim parRtagId
40
Dim parSourceRtagId
41
Dim parSourceRtagId
41
Dim query_string
42
Dim query_string
42
Dim objBtnControl
-
 
43
Dim rcon_id
43
Dim rcon_id
44
Dim shref_base
44
Dim shref_base
45
'------------ Constants Declaration -----------
45
'------------ Constants Declaration -----------
46
'------------ Variable Init -------------------
46
'------------ Variable Init -------------------
47
parRtagId = Request("rtag_id")
47
parRtagId = Request("rtag_id")
48
objPMod.PersistInQryString("rtag_id")
48
objPMod.PersistInQryString("rtag_id")
49
Set objBtnControl = New ActionButtonControl
-
 
-
 
49
 
50
'----------------------------------------------
50
'----------------------------------------------
51
%>
51
%>
52
<%
52
<%
53
'--------------------------------------------------------------------------------------------------------------------------
53
'--------------------------------------------------------------------------------------------------------------------------
54
Sub GetFormDetails ( parRtagId, ByRef outobjDetails )
54
Sub GetFormDetails ( parRtagId, ByRef outobjDetails )
Line 178... Line 178...
178
 
178
 
179
End If
179
End If
180
 
180
 
181
'----------------------------------------------
181
'----------------------------------------------
182
%>
182
%>
-
 
183
<script language="JavaScript" type="text/JavaScript">
-
 
184
 
-
 
185
window.addEventListener ?
-
 
186
window.addEventListener("load",InitShow,false) :
-
 
187
window.attachEvent && window.attachEvent("onload",InitShow);
-
 
188
 
-
 
189
function InitShow(e)
-
 
190
{
-
 
191
    toggleClass('rootCause',0);
-
 
192
    toggleClass('rootFile',0);
-
 
193
}
-
 
194
 
-
 
195
function getElementsByClassName(classname, node)  {
-
 
196
    if(!node) node = document.getElementsByTagName("body")[0];
-
 
197
    var a = [];
-
 
198
    var re = new RegExp('\\b' + classname + '\\b');
-
 
199
    var els = node.getElementsByTagName("*");
-
 
200
    for(var i=0,j=els.length; i<j; i++)
-
 
201
        if(re.test(els[i].className))a.push(els[i]);
-
 
202
    return a;
-
 
203
}
-
 
204
 
-
 
205
 
-
 
206
function toggleClass(cname,flip)
-
 
207
{
-
 
208
    var cookieName = 'RELMGR_BUILDSTATUS';
-
 
209
    var cv = JSON.parse(getCookie(cookieName));
-
 
210
    var state;
-
 
211
    if (!cv)
-
 
212
        cv = new Object;
-
 
213
    if (!cv.BuildStatus)
-
 
214
        cv.BuildStatus = new Object;
-
 
215
    state = cv.BuildStatus[cname];
-
 
216
 
-
 
217
    if (!state)
-
 
218
        state = false;
-
 
219
 
-
 
220
    if (flip>0)
-
 
221
        state = !state;
-
 
222
 
-
 
223
    cv.BuildStatus[cname] = state;
-
 
224
 
-
 
225
    // Reflect the current state in the checkbox
-
 
226
    var de = document.getElementById(cname);
-
 
227
    if (de)
-
 
228
        de.checked = state;
-
 
229
 
-
 
230
    var elements = new Array();
-
 
231
    elements = getElementsByClassName(cname);
-
 
232
    for(i in elements ){
-
 
233
        if (!state) {
-
 
234
            elements[i].style.display = "";
-
 
235
        }
-
 
236
        else {
-
 
237
            elements[i].style.display = "none";
-
 
238
        }
-
 
239
    }
-
 
240
 
-
 
241
//alert("cv" + JSON.stringify(cv) );
-
 
242
    setCookie(cookieName, JSON.stringify(cv), 10 );
-
 
243
}
-
 
244
 
-
 
245
function setCookie(c_name,value,exdays)
-
 
246
{
-
 
247
var exdate=new Date();
-
 
248
exdate.setDate(exdate.getDate() + exdays);
-
 
249
var c_value=escape(value) + ((exdays==null) ? "" : "; expires="+exdate.toUTCString());
-
 
250
document.cookie=c_name + "=" + c_value;
-
 
251
}
-
 
252
 
-
 
253
function getCookie(c_name)
-
 
254
{
-
 
255
var c_value = document.cookie;
-
 
256
var c_start = c_value.indexOf(" " + c_name + "=");
-
 
257
if (c_start == -1)
-
 
258
  {
-
 
259
  c_start = c_value.indexOf(c_name + "=");
-
 
260
  }
-
 
261
if (c_start == -1)
-
 
262
  {
-
 
263
  c_value = null;
-
 
264
  }
-
 
265
else
-
 
266
  {
-
 
267
  c_start = c_value.indexOf("=", c_start) + 1;
-
 
268
  var c_end = c_value.indexOf(";", c_start);
-
 
269
  if (c_end == -1)
-
 
270
  {
-
 
271
c_end = c_value.length;
-
 
272
}
-
 
273
c_value = unescape(c_value.substring(c_start,c_end));
-
 
274
}
-
 
275
return c_value;
-
 
276
}
-
 
277
 
-
 
278
</script>
-
 
279
 
183
<html>
280
<html>
184
   <head>
281
   <head>
185
      <title>Release Manager</title>
282
      <title>Release Manager</title>
186
      <meta http-equiv="Pragma" content="no-cache">
283
      <meta http-equiv="Pragma" content="no-cache">
187
      <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
284
      <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
Line 252... Line 349...
252
                           </span>
349
                           </span>
253
                           <tr>
350
                           <tr>
254
                              <td background="images/bg_table_col.gif" class="err_alert"><b>Directly</b></td>
351
                              <td background="images/bg_table_col.gif" class="err_alert"><b>Directly</b></td>
255
                              <td valign="top" nowrap background="images/bg_table_col.gif" class="body_col">PACKAGE NAME</td>
352
                              <td valign="top" nowrap background="images/bg_table_col.gif" class="body_col">PACKAGE NAME</td>
256
                              <td valign="top" nowrap background="images/bg_table_col.gif" class="body_col">PACKAGE VERSION</td>
353
                              <td valign="top" nowrap background="images/bg_table_col.gif" class="body_col">PACKAGE VERSION</td>
257
                              <td valign="top" nowrap background="images/bg_table_col.gif" class="body_col">ROOT CAUSE
354
                              <td valign="top" nowrap background="images/bg_table_col.gif" class="body_col">ROOT CAUSE</td>
-
 
355
                           </tr>
-
 
356
                           <tr>
-
 
357
                           <td colspan=3></td>
-
 
358
                           <td class="body_row">
-
 
359
                           <fieldset class="fset" xalign="right">
-
 
360
                                Hide
-
 
361
                                <input type="checkbox" value=0 name="showCause" id="rootCause" onClick="toggleClass('rootCause',1);">Cause
-
 
362
                                <input type="checkbox" value=0 name="showFile"  id="rootFile"  onClick="toggleClass('rootFile',1);">Build Errors
-
 
363
                           </fieldset>
258
                              </td>
364
                           </td>
259
                           </tr>
365
                           </tr>
260
                           <%
366
                           <%
261
                           query_string = " select pkg.pkg_name, pv.pkg_version, pv.pv_id, dnr.rtag_id, dnr.root_cause, dnr.root_file, pv.pv_description"&_
367
                           query_string = " select pkg.pkg_name, pv.pkg_version, pv.pv_id, dnr.rtag_id, dnr.root_cause, dnr.root_file, pv.pv_description"&_
262
                                          "   from do_not_ripple dnr, package_versions pv, packages pkg"&_
368
                                          "   from do_not_ripple dnr, package_versions pv, packages pkg"&_
263
                                          "  where dnr.rtag_id = "& parRtagId &_
369
                                          "  where dnr.rtag_id = "& parRtagId &_
Line 266... Line 372...
266
                                          "    and dnr.root_pv_id is null"&_
372
                                          "    and dnr.root_pv_id is null"&_
267
                                          "  order by pkg_name"
373
                                          "  order by pkg_name"
268
                           Set rsQry = OraDatabase.DbCreateDynaset( query_string, ORADYN_DEFAULT )
374
                           Set rsQry = OraDatabase.DbCreateDynaset( query_string, ORADYN_DEFAULT )
269
                           '--- Render rows ---
375
                           '--- Render rows ---
270
                           Do While (NOT rsQry.BOF) AND (NOT rsQry.EOF)
376
                           Do While (NOT rsQry.BOF) AND (NOT rsQry.EOF)
-
 
377
                            Dim rowClass
-
 
378
                            Dim rowData
-
 
379
                            ' root_file, if supplied, indicates a build failure log file exists
-
 
380
                            ' this should always prevail over the textual root_cause
-
 
381
                           
-
 
382
                            If IsNull(rsQry("root_file")) Then
-
 
383
                               rowClass = "rootCause"
-
 
384
                               rowData = rsQry("root_cause")
-
 
385
                            Else
-
 
386
                                rowClass = "rootFile"
-
 
387
                                rowData = "<a class=""txt_linked"" title=""" & rsQry("root_file") &_
-
 
388
                                          " Log file may have expired."" " &_
-
 
389
                                          "href=""" & shref_base & rsQry("root_file") & """>" &_
-
 
390
                                          "Build Failure Log File</a>"
-
 
391
                            End If
271
                           %>
392
                           %>
272
                              <tr>
393
                              <tr class="<%=rowClass%>">
273
                                 <td colspan="5" background="images/bg_rep_line.gif"><img src="images/spacer.gif" width="1" height="1"></td>
394
                                 <td colspan="5" background="images/bg_rep_line.gif"><img src="images/spacer.gif" width="1" height="1"></td>
274
                              </tr>
395
                              </tr>
275
                              <tr>
396
                              <tr class="<%=rowClass%>">
276
                                 <td nowrap width="1%">
397
                                 <td nowrap width="1%">
277
                                    <!-- The use of the isChecked() javascript function below, enables the submit button if any checkboxes are checked, -->
398
                                    <!-- The use of the isChecked() javascript function below, enables the submit button if any checkboxes are checked, -->
278
                                    <!-- else it will disable the submit button. The function is badly named, but nevertheless, that is what it does.   -->
399
                                    <!-- else it will disable the submit button. The function is badly named, but nevertheless, that is what it does.   -->
279
                                    <input type="checkbox" value="<%=rsQry("pv_id")%>" name="pv_id_list" id="pv_id_list" onClick="isChecked('pv_id_list','submit');">
400
                                    <input type="checkbox" value="<%=rsQry("pv_id")%>" name="pv_id_list" id="pv_id_list" onClick="isChecked('pv_id_list','submit');">
280
                                 </td>
401
                                 </td>
281
                                 <td nowrap class="body_rowg"><a class="txt_linked" href="dependencies.asp?pv_id=<%=rsQry("pv_id")%>&rtag_id=<%=rsQry("rtag_id")%>" title="<%=rsQry("pv_description")%>"><%=rsQry("pkg_name")%></a></td>
402
                                 <td nowrap class="body_rowg"><a class="txt_linked" href="dependencies.asp?pv_id=<%=rsQry("pv_id")%>&rtag_id=<%=rsQry("rtag_id")%>" title="<%=rsQry("pv_description")%>"><%=rsQry("pkg_name")%></a></td>
282
                                 <td nowrap class="body_rowg"><%=rsQry("pkg_version")%></td>
403
                                 <td nowrap class="body_rowg"><%=rsQry("pkg_version")%></td>
283
                                 <%
-
 
284
                                 ' root_file, if supplied, indicates a build failure log file exists
-
 
285
                                 ' this should always prevail over the textual root_cause
-
 
286
                                 If IsNull(rsQry("root_file")) Then%>
-
 
287
                                    <td nowrap class="body_rowg"><%=rsQry("root_cause")%></td>
404
                                 <td nowrap class="body_rowg"><%=rowData%></td>
288
                                 <%Else%>
-
 
289
                                    <td nowrap class="body_rowg">
-
 
290
                                       <a class="txt_linked" title="<%=rsQry("root_file")%> Log file may have expired." href="<%=shref_base & rsQry("root_file")%>">
-
 
291
                                          Build Failure Log File
-
 
292
                                       </a>
-
 
293
                                    </td>
-
 
294
                                 <%End If%>
-
 
295
                              </tr>
405
                              </tr>
296
                              <%
406
                           <%
297
                              rsQry.MoveNext
407
                            rsQry.MoveNext
298
                           Loop%>
408
                           Loop%>
299
                           <tr>
409
                           <tr>
300
                              <td background="images/bg_table_col.gif" class="err_alert"><b>Indirectly</b></td>
410
                              <td background="images/bg_table_col.gif" class="err_alert"><b>Indirectly</b></td>
301
                              <td valign="top" nowrap background="images/bg_table_col.gif" class="body_col">PACKAGE NAME</td>
411
                              <td valign="top" nowrap background="images/bg_table_col.gif" class="body_col">PACKAGE NAME</td>
302
                              <td valign="top" nowrap background="images/bg_table_col.gif" class="body_col">PACKAGE VERSION</td>
412
                              <td valign="top" nowrap background="images/bg_table_col.gif" class="body_col">PACKAGE VERSION</td>