Subversion Repositories DevTools

Rev

Details | Last modification | View Log | RSS feed

Rev Author Line No. Line
119 ghuddy 1
<%@LANGUAGE="VBSCRIPT"%>
2
<%
3
'=====================================================
129 ghuddy 4
'                  MAKE UNOFFICIAL
119 ghuddy 5
'               --- PROCESS FORM ---
6
'=====================================================
7
%>
8
<%
9
Option explicit
10
' Good idea to set when using redirect
129 ghuddy 11
Response.Expires = 0   ' always load the page, dont store
119 ghuddy 12
%>
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
<!--#include file="common/common_dbedit.asp"-->
20
<%
21
'------------ ACCESS CONTROL ------------------
22
%>
23
<!--#include file="_access_control_login.asp"-->
24
<!--#include file="_access_control_general.asp"-->
25
<!--#include file="_access_control_project.asp"-->
26
<%
27
'------------ Variable Definition -------------
28
'------------ Constants Declaration -----------
29
'------------ Variable Init -------------------
30
'----------------------------------------------
31
%>
32
<%
33
Sub MakeReject ()
129 ghuddy 34
   Dim objWSH
35
   Set objWSH = Server.CreateObject("WScript.Shell")
36
 
37
   objEH.TryORA ( OraSession )
38
   On Error Resume Next
39
 
40
   OraDatabase.Parameters.Add "PV_ID",       Request("pv_id"),   ORAPARM_INPUT, ORATYPE_NUMBER
41
   OraDatabase.Parameters.Add "RTAG_ID",       Request("rtag_id"),   ORAPARM_INPUT, ORATYPE_NUMBER
42
   OraDatabase.Parameters.Add "USER_ID",       objAccessControl.UserId,   ORAPARM_INPUT, ORATYPE_NUMBER
43
 
44
   OraDatabase.ExecuteSQL _
45
   "BEGIN "&_
46
   " PK_ENVIRONMENT.MAKE_REJECT ( :PV_ID, :RTAG_ID, :USER_ID ); "&_
47
   "END; "
48
 
49
   objEH.CatchORA ( OraSession )
50
 
51
   OraDatabase.Parameters.Remove "PV_ID"
52
   OraDatabase.Parameters.Remove "RTAG_ID"
53
   OraDatabase.Parameters.Remove "USER_ID"
54
 
55
   If objEH.LastOraFailed = FALSE Then
56
      objWSH.Run   "cmd.exe /c cscript.exe //B //NoLogo "& rootPath & SCRIPTS_FOLDER &"\Admin_Tools.wsf //job:onMakeUnofficial "&_
57
                  "/pv_id:"& Request("pv_id") , _
58
                  0, FALSE
59
   End If
60
 
119 ghuddy 61
End Sub
62
%>
63
<%
64
'-----------------------  MAIN LINE  ---------------------------
65
 
66
'--- Process submition ---
67
If (Request("rtag_id") <> "") AND (Request("pv_id") <> "")  Then
129 ghuddy 68
 
69
   'COMPLETE THE REQUEST...
70
   Call MakeReject ( )
71
 
72
 
73
   If Request("rfile") <> "" Then
74
      Response.Redirect ( Request("rfile") &"?pv_id="& Request("pv_id") &"&rtag_id="& Request("rtag_id") )
75
   Else
76
      Response.Redirect ( "dependencies?pv_id="& Request("pv_id") &"&rtag_id="& Request("rtag_id") )
77
   End If
78
 
119 ghuddy 79
Else
129 ghuddy 80
   Response.write "Some mendatory parameters are missing!" & "<br>" 'TODO
81
   Response.write QSTR_All
119 ghuddy 82
End If
83
%>
84
 
85
<!-- DESTRUCTOR ------->
129 ghuddy 86
<!--#include file="common/destructor.asp"-->