Subversion Repositories DevTools

Rev

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

Rev 6970 Rev 6971
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
<% '------------ ACCESS CONTROL ------------------ %>
22
<% '------------ ACCESS CONTROL ------------------ %>
23
<!--#include file="_access_control_login.asp"-->
23
<!--#include file="_access_control_login_optional.asp"-->
24
<!--#include file="_access_control_general.asp"-->
24
<!--#include file="_access_control_general.asp"-->
25
<!--#include file="_access_control_action_project.asp"-->
25
<!--#include file="_access_control_action_project.asp"-->
26
<%
26
<%
27
'------------ Variable Definition -------------
27
'------------ Variable Definition -------------
28
Dim parRtagId
28
Dim parRtagId
-
 
29
Dim canModify
-
 
30
Dim disabledTxt : disabledTxt = ""
-
 
31
Dim disabledImage : disabledImage = ""
29
'------------ Constants Declaration -----------
32
'------------ Constants Declaration -----------
30
'------------ Variable Init -------------------
33
'------------ Variable Init -------------------
31
parRtagId = Request("rtag_id")
34
parRtagId = Request("rtag_id")
32
objPMod.PersistInQryString("rtag_id")
35
objPMod.PersistInQryString("rtag_id")
33
'----------------------------------------------
-
 
34
%>
-
 
35
<%
-
 
36
%>
-
 
37
<%
-
 
38
'------------ RUN BEFORE PAGE RENDER ----------
-
 
39
'----------------------------------------------------
-
 
40
' --- RUN onPostBack ---
-
 
41
If Request("action") <> "" AND objAccessControl.UserLogedIn Then
-
 
42
 
-
 
43
      If objEH.Finally Then
-
 
44
         Call OpenInWindow ( "release_config.asp?rtag_id="& parRtagId )
36
canModify = releaseIsMergable(releaseInfoHash("official"))
45
      End If
-
 
46
 
37
 
-
 
38
If NOT canModify Then
-
 
39
    disabledTxt = " - Disabled"
-
 
40
    disabledImage = ",url('images/abtn__small_remove.gif')  no-repeat center center"
47
End If
41
End If
-
 
42
 
-
 
43
'------------ RUN BEFORE PAGE RENDER ----------
48
'----------------------------------------------
44
'----------------------------------------------
49
Sub InsertLocalStyle %>
45
Sub InsertLocalStyle%>
50
    <style type="text/css">
46
    <style type="text/css">
51
        td.useThis:not(.useRemove) {background: url('images/i_added.gif') no-repeat center center; cursor: pointer; }
47
        td.useThis:not(.useRemove) {background: url('images/i_added.gif') no-repeat center center<%=disabledImage%>; cursor: pointer; }
52
        td.useThis.useRemove {background: url('images/i_removed.gif') no-repeat center center; cursor: pointer; }
48
        td.useThis.useRemove {background: url('images/i_removed.gif') no-repeat center center<%=disabledImage%>; cursor: pointer; }
53
        .tooOld:not(.forceShow),.hiddenChild:not(.forceShow) {display:none;}
49
        .tooOld:not(.forceShow),.hiddenChild:not(.forceShow) {display:none;}
-
 
50
        table.dataTable tbody tr.child{background-color: #e0e0e0;}
54
    </style>
51
    </style>
55
<%End Sub
52
<%End Sub
56
'----------------------------------------------
53
'----------------------------------------------
57
Sub InsertJavaScript %>
54
Sub InsertJavaScript %>
58
      <script language="JavaScript" type="text/JavaScript">
55
      <script language="JavaScript" type="text/JavaScript">
-
 
56
 
-
 
57
        formTips.tips.h_nvReport    = stdTip(400, 'Newer Version Report', 'This page will display newer (non-ripple) versions of packages in the current release.' +
-
 
58
                                                                    '<p>The intent of this page is to allow a developer to see if work has been performed on ' + 
-
 
59
                                                                    'packages in this release and consider including the new version into the release.' + 
-
 
60
                                                                    '<p>Its possible to merge a newer version into the current Release, and to undo the operation.' + 
-
 
61
                                                                    '<p>A filter allows only recent versions to be considered.' 
-
 
62
                                                                    );
-
 
63
 
-
 
64
        formTips.tips.h_merge       = stdTip(300, 'Merge Version', 'The selected version can be merged into the Release.' +
-
 
65
                                                                    '<p>The version will added as a Pending Merge.' + 
-
 
66
                                                                    '<p>Once all required versions have been selected they will need to be released into the Release.' 
-
 
67
                                                                    );
-
 
68
 
-
 
69
 
-
 
70
 
59
      $(document).ready(function() {
71
      $(document).ready(function() {
60
        var nvAgeLimit = 31; 
72
        var nvAgeLimit = 31; 
61
 
73
 
62
        // Generate Row Data from JavaScript data
74
        // Generate Row Data from JavaScript data
63
        function getPkgName ( row, type, set, meta ) {
75
        function getPkgName ( row, type, set, meta ) {
Line 72... Line 84...
72
          var hRef = "view_by_version.asp?pkg_id=" + row[2] + "&hideRipple=True" + "&fpkgversion=*" + row[5]
84
          var hRef = "view_by_version.asp?pkg_id=" + row[2] + "&hideRipple=True" + "&fpkgversion=*" + row[5]
73
          return img + "<a href=" + hRef + ">" + row[3] + "</a>"
85
          return img + "<a href=" + hRef + ">" + row[3] + "</a>"
74
        }
86
        }
75
 
87
 
76
        function getVersion ( row, type, set, meta ) {
88
        function getVersion ( row, type, set, meta ) {
77
          var hRef = "dependencies.asp?pv_id=" + row[0] + "&rtag_id=" + <%=parRtagId%>
89
          var hRef = "fixed_issues.asp?pv_id=" + row[0] + "&rtag_id=" + <%=parRtagId%>
78
          return "<a href=" + hRef + ">" + row[4] + "</a>"
90
          return "<a href=" + hRef + ">" + row[4] + "</a>"
79
        }
91
        }
80
 
92
 
81
        function getNewerVersion ( row, type, set, meta ) {
93
        function getNewerVersion ( row, type, set, meta ) {
82
          var hRef = "dependencies.asp?pv_id=" + row[7]
-
 
83
          return "<a href=" + hRef + ">" + row[8] + "</a>"
-
 
84
        }
-
 
85
 
-
 
86
        // Format row of data for extended version display
-
 
87
        // Return as a tr node so that the colums can be added to the current table
94
          var img = "<img src='images/history.png' width=11 height=11 border='0' align='absmiddle' hspace='3' class='pointer showHistory fright' title='Show History'>"
88
        // and have them line up with existing columns
-
 
89
        function format(d){
-
 
90
             var rv = [];
-
 
91
             var dd = d[10];
-
 
92
 
-
 
93
             for (var ii in dd) {
-
 
94
                 row = $('<tr/>').attr('data-npvid', dd[ii][0]).attr('data-pvid', d[0]);
-
 
95
                 row.append($('<td/>').append( '' ).attr('colspan', '4'));
-
 
96
                 row.append($('<td/>').append( $('<a/>').append( dd[ii][1]).attr('href', 'dependencies.asp?pv_id=' + dd[ii][0]) ));
95
          var img2 = "<img src='images/i_used_by.gif' width=11 height=11 border='0' align='absmiddle' hspace='3' class='pointer showProjects fright' title='Show Projects using this version'>"
97
                 row.append($('<td/>').append( dd[ii][2] ));
96
          var hRef = "fixed_issues.asp?pv_id=" + row[7]
98
                 row.append($('<td/>').addClass('useThis'));
97
          return "<a href=" + hRef + ">" + row[8] + "</a>" + img2 + img
99
                 rv.push(row);
-
 
100
             }
-
 
101
             return rv;
-
 
102
        }
98
        }
103
 
99
 
104
        var nvTable;
100
        var nvTable;
105
        function loadTable() {
101
        function loadTable() {
106
            /* Init DataTables */
102
            /* Init DataTables */
107
            nvTable = $('#nvtable').DataTable({
103
            nvTable = $('#nvtable').DataTable({
108
                //bLengthChange : false,
-
 
109
                sDom : "rti",
104
                sDom : "rti",
110
                data : dataSet,
105
                data : dataSet,
111
                columns : [
106
                columns : [
112
                { data : getPkgName },
107
                { data : getPkgName },
113
                { data : getVersion  , orderable : false},
108
                { data : getVersion  , orderable : false},
114
                { data : [1] },
109
                { data : [1] },
115
                { data : [6] },
110
                { data : [6] },
116
                { data : getNewerVersion  , orderable : false},
111
                { data : getNewerVersion  , orderable : false, className : 'tight'},
117
                { data : [9], orderData :[0,5] },
112
                { data : [9], orderData :[0,5] },
118
                { data : null, defaultContent: "", className : 'useThis' , orderable : false},
113
                { data : null, defaultContent: "", className : 'useThis' , orderable : false},
119
                ],
114
                ],
120
                createdRow : function( row, data, dataIndex, cells ) {
115
                createdRow : function( row, data, dataIndex, cells ) {
121
                    $(row).attr('data-npvid', data[7]).attr('data-pvid', data[0]);
116
                    $(row).attr('data-npvid', data[7]).attr('data-pvid', data[0]);
Line 129... Line 124...
129
                    if ( nvAgeLimit > 0 ) {
124
                    if ( nvAgeLimit > 0 ) {
130
                        if ( parseInt(data[11]) > nvAgeLimit ) {
125
                        if ( parseInt(data[11]) > nvAgeLimit ) {
131
                            $(row).addClass('tooOld');
126
                            $(row).addClass('tooOld');
132
                        }
127
                        }
133
                    }
128
                    }
134
                    
-
 
135
                },
129
                },
136
                infoCallback: function( settings, start, end, max, total, pre ) {
130
                infoCallback: function( settings, start, end, max, total, pre ) {
137
                     return getUpdateInfo();
131
                     return getUpdateInfo();
138
                },
132
                },
139
                scrollCollapse : true,
133
                scrollCollapse : true,
Line 144... Line 138...
144
                    {className : "dt-nowrap", targets: "_all" },
138
                    {className : "dt-nowrap", targets: "_all" },
145
                ],
139
                ],
146
            });
140
            });
147
        }
141
        }
148
 
142
 
149
        // Load Data once via AJAX
143
        //  Load Data once via AJAX
-
 
144
        //  When loaded
-
 
145
        //      display the datatable
-
 
146
        //      Update 'title' (hover text) on controls
150
        var dataSet;
147
        var dataSet;
151
        $.get({
148
        $.get({
152
            url: 'rep_new_versions_json.asp',
149
            url: 'rep_new_versions_json.asp',
153
            dataType : 'json',
150
            dataType : 'json',
154
            data : {
151
            data : {
Line 156... Line 153...
156
                   action : 'getData'
153
                   action : 'getData'
157
                   },
154
                   },
158
            success : function(data, textStatus, jqXHR){
155
            success : function(data, textStatus, jqXHR){
159
                dataSet = data.aaData;
156
                dataSet = data.aaData;
160
                loadTable();
157
                loadTable();
-
 
158
                $('td.useThis').prop('title', 'Merge this version into the Release<%=disabledTxt%>');
-
 
159
                $('td.useRemove').prop('title', 'Remove this version from pending merge<%=disabledTxt%>');
161
            }
160
            }
162
        }).done( function(){
161
        }).done( function(){
163
            $('#loading').remove();
162
            $('#loading').remove();
164
 
163
 
165
        }).fail( function(jqXHR, textStatus, errorThrown){
164
        }).fail( function(jqXHR, textStatus, errorThrown){
Line 186... Line 185...
186
                tr.addClass('shown');
185
                tr.addClass('shown');
187
                $(this).attr('src', 'images/bt_minus.gif');
186
                $(this).attr('src', 'images/bt_minus.gif');
188
            };
187
            };
189
            updateInfo();
188
            updateInfo();
190
        });
189
        });
191
 
-
 
-
 
190
<%If canModify Then %>
192
        // Add event listner to all a verion to be 'used'
191
        // Add event listner to all a verion to be 'used'
193
        $('#nvtable tbody').on('click', '.useThis', function () {
192
        $('#nvtable tbody').on('click', '.useThis', function () {
194
            var tgtEl = $(this)
193
            var tgtEl = $(this)
195
            var tr = $(this).closest('tr');
194
            var tr = $(this).closest('tr');
196
            var pvid = tr.data('pvid');
195
            var pvid = tr.data('pvid');
Line 210... Line 209...
210
                       mode : isaRemove ? 'R' : 'A'
209
                       mode : isaRemove ? 'R' : 'A'
211
                       },
210
                       },
212
                success : function(data, textStatus, jqXHR){
211
                success : function(data, textStatus, jqXHR){
213
                            if (data.result != 0){
212
                            if (data.result != 0){
214
                                setInfo("Error: " + (data.hasOwnProperty('emsgSummary') ? data.emsgSummary : "Reason not given"));
213
                                setInfo("Error: " + (data.hasOwnProperty('emsgSummary') ? data.emsgSummary : "Reason not given"));
-
 
214
                                return;
215
                            }
215
                            }
-
 
216
                            tgtEl.toggleClass('useRemove');
-
 
217
                            tr.toggleClass('forceShow');
216
                }
218
                    }
217
            }).done( function(){
219
            }).done( function(){
218
                tgtEl.toggleClass('useRemove');
-
 
219
                tr.toggleClass('forceShow');
-
 
220
 
220
 
221
            }).always( function(){
221
            }).always( function(){
222
                $("body").removeClass("cursor-wait");
222
                $("body").removeClass("cursor-wait");
223
 
223
 
224
            }).fail( function(jqXHR, textStatus, errorThrown){
224
            }).fail( function(jqXHR, textStatus, errorThrown){
225
                        setInfo("Error: " + errorThrown );
225
                        setInfo("Error: " + errorThrown );
226
            });
226
            });
227
 
-
 
228
 
-
 
229
        });
227
        });
-
 
228
<%End If%>
230
 
229
 
231
       //  Toggle All the extended versions
230
       //  Toggle All the extended versions
232
        //  Show/Hide the ALL children, unless they have been 'merged'
231
        //  Show/Hide the ALL children, unless they have been 'merged'
233
 
232
 
234
        $('#toggleAll').click(function(event){
233
        $('#toggleAll').click(function(event){
Line 260... Line 259...
260
                };
259
                };
261
            });
260
            });
262
            updateInfo();
261
            updateInfo();
263
        });
262
        });
264
 
263
 
-
 
264
        //  Show History button
-
 
265
        $('#nvtable tbody').on('click', '.showHistory', function (event) {
-
 
266
            var tr = $(this).closest('tr');
-
 
267
            var pvid = tr.data('pvid');
-
 
268
            var npvid = tr.data('npvid');
-
 
269
            var data = nvTable.row( tr ).data();
-
 
270
            var url = '_wform_versions_history_release_notes.asp?&rtag_id=<%=parRtagId%>&hideRipple=True&pv_id='+npvid+'&pkg_id='+data[2]+'&FLpkg_version=*'+data[5];
-
 
271
            var features = 'left=50,top=50,resizable=yes,scrollbars=yes,width=1000,height='+ ( screen.height - 100 );
-
 
272
            window.open(url,'History', features);
-
 
273
        });
-
 
274
 
-
 
275
        // Show Project Version dialog
-
 
276
        
-
 
277
        $('#nvtable tbody').on('click', '.showProjects', function (event) {
-
 
278
            var tr = $(this).closest('tr');
-
 
279
            var pvid = tr.data('pvid');
-
 
280
            var npvid = tr.data('npvid');
-
 
281
            var data = nvTable.row( tr ).data();
-
 
282
            $('#popmenu').load('rep_new_versions_info.asp', {pvid: npvid});
-
 
283
        });
-
 
284
 
265
        //  Ajax Error message support
285
        //  Ajax Error message support
266
        function setInfo(txt) {
286
        function setInfo(txt) {
267
            $("#nvError").text(txt).addClass("errorPanel").show();
287
            $("#nvError").text(txt).addClass("errorPanel").show();
268
        }
288
        }
269
 
289
 
Line 273... Line 293...
273
 
293
 
274
        // Update the (simulated ) table info
294
        // Update the (simulated ) table info
275
        function getUpdateInfo() {
295
        function getUpdateInfo() {
276
            var children = $('#nvtable tbody tr');
296
            var children = $('#nvtable tbody tr');
277
            var total = children.length;
297
            var total = children.length;
278
 
-
 
279
            var hidden = children.filter('.tooOld:not(.forceShow),.hiddenChild:not(.forceShow)').length;
298
            var hidden = children.filter('.tooOld:not(.forceShow),.hiddenChild:not(.forceShow)').length;
280
 
299
 
281
            return "Showing "+ (total - hidden) +" of " + total + ". (" + hidden + " not shown)";
300
            return "Showing "+ (total - hidden) +" of " + total + ". (" + hidden + " not shown)";
282
 
301
 
283
        }
302
        }
Line 323... Line 342...
323
Sub LeftPanelContent
342
Sub LeftPanelContent
324
%>
343
%>
325
<fieldset class="body_rowg fset">
344
<fieldset class="body_rowg fset">
326
    <legend>Filter</legend>
345
    <legend>Filter</legend>
327
        <span id=nvArg>
346
        <span id=nvArg>
328
            <input     type="radio" name="age" value="7"> Last Week
347
            <input     type="radio" name="age" value="1"> Last Day
-
 
348
            <br><input type="radio" name="age" value="7"> Last Week
329
            <br><input type="radio" name="age" value="14"> Last 2 Weeks
349
            <br><input type="radio" name="age" value="14"> Last 2 Weeks
330
            <br><input type="radio" name="age" value="21"> Last 3 Weeks
350
            <br><input type="radio" name="age" value="21"> Last 3 Weeks
331
            <br><input type="radio" name="age" value="31" checked="checked"> Last Month
351
            <br><input type="radio" name="age" value="31" checked="checked"> Last Month
332
            <br><input type="radio" name="age" value="62"> Last 2 Months
352
            <br><input type="radio" name="age" value="62"> Last 2 Months
333
            <br><input type="radio" name="age" value="365"> Last Year
353
            <br><input type="radio" name="age" value="365"> Last Year
Line 339... Line 359...
339
End Sub
359
End Sub
340
 
360
 
341
Sub MainPanelContent
361
Sub MainPanelContent
342
%>
362
%>
343
   <div class=Panel>
363
   <div class=Panel>
344
    <div class=rounded_box_caption>New Version Report</div>
364
    <div class=rounded_box_caption>Newer Version Report<%=Quick_Help("h_nvReport")%></div>
345
    <div class="rounded_box">
365
    <div class="rounded_box">
346
       <div class=PanelFrame>
366
       <div class=PanelFrame>
347
            <!-- MESSAGE +++++++++++++++++++++++++++++++++++++++++++++++++++ -->
367
            <!-- MESSAGE +++++++++++++++++++++++++++++++++++++++++++++++++++ -->
348
            <!--#include file="messages/_msg_inline.asp"-->
368
            <!--#include file="messages/_msg_inline.asp"-->
349
            <!-- +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ -->
369
            <!-- +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ -->
350
            <div class=textPanel>
370
            <div class=textPanel>
351
                <table id='nvtable' width="100%" class="stdGrey">
371
                <table id='nvtable' width="100%" class="stdGrey">
352
                   <thead>
372
                   <thead>
353
                      <th nowrap><img id='toggleAll' src='images/bt_plus.gif' border='0' align='absmiddle' hspace='3' class='pointer'>Package Name</th>
373
                      <th nowrap><img id='toggleAll' src='images/bt_plus.gif' border='0' align='absmiddle' hspace='3' class='pointer' title='Expand/Hide other versions'>Package Name</th>
354
                      <th nowrap>Version</th>
374
                      <th nowrap>Version</th>
355
                      <th nowrap>Base View</th>
375
                      <th nowrap>Base View</th>
356
                      <th nowrap>Created</th>
376
                      <th nowrap>Created</th>
357
                      <th nowrap>Newer Version</th>
377
                      <th nowrap>Newer Version</th>
358
                      <th nowrap>Created</th>
378
                      <th nowrap>Created</th>
359
                      <th nowrap></th>
379
                      <th nowrap><%=Quick_Help("h_merge")%></th>
360
                   </thead>
380
                   </thead>
361
                    <tr id='loading' >
381
                    <tr id='loading' >
362
                        <td colspan=7 class=tcenter>
382
                        <td colspan=7 class=tcenter>
363
                            <img src='images/transparent-background-loading.gif'>
383
                            <img src='images/transparent-background-loading.gif'>
364
                        </td>
384
                        </td>
Line 380... Line 400...
380
      <meta http-equiv="Pragma" content="no-cache">
400
      <meta http-equiv="Pragma" content="no-cache">
381
      <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
401
      <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
382
      <link rel="stylesheet" href="images/release_manager_style.css?ver=<%=VixVerNum%>" type="text/css">
402
      <link rel="stylesheet" href="images/release_manager_style.css?ver=<%=VixVerNum%>" type="text/css">
383
      <link rel="stylesheet" href="images/navigation.css?ver=<%=VixVerNum%>" type="text/css">
403
      <link rel="stylesheet" href="images/navigation.css?ver=<%=VixVerNum%>" type="text/css">
384
      <script language="JavaScript" src="images/common.js?ver=<%=VixVerNum%>"></script>
404
      <script language="JavaScript" src="images/common.js?ver=<%=VixVerNum%>"></script>
-
 
405
      <!-- TIPS -->
-
 
406
      <script language="JavaScript" src="images/tipster.js?ver=<%=VixVerNum%>"></script>
-
 
407
      <script language="JavaScript" src="images/_help_tips.js?ver=<%=VixVerNum%>"></script>
385
      <!-- DROPDOWN MENUS -->
408
      <!-- DROPDOWN MENUS -->
-
 
409
      <%bJqueryVix=TRUE%>
386
      <%bJqueryDataTables = TRUE%>
410
      <%bJqueryDataTables = TRUE%>
387
      <%sJqueryDataTablesCss="jquery/dataTables.vix.grey.css"%>
411
      <%sJqueryDataTablesCss="jquery/dataTables.vix.grey.css"%>
388
      <!--#include file="_jquery_includes.asp"-->
412
      <!--#include file="_jquery_includes.asp"-->
389
      <!--#include file="_menu_def.asp"-->
413
      <!--#include file="_menu_def.asp"-->
390
      <script language="JavaScript1.2" src="images/popup_menu.js?ver=<%=VixVerNum%>"></script>
414
      <script language="JavaScript1.2" src="images/popup_menu.js?ver=<%=VixVerNum%>"></script>