Subversion Repositories DevTools

Rev

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

Rev 5506 Rev 5590
Line 50... Line 50...
50
	OraDatabase.Parameters.Remove "BM_ID"
50
	OraDatabase.Parameters.Remove "BM_ID"
51
 
51
 
52
    Call OpenInWindow ("admin_gbe_machclass.asp")
52
    Call OpenInWindow ("admin_gbe_machclass.asp")
53
    
53
    
54
ElseIf CBool(Request("action")) Then
54
ElseIf CBool(Request("action")) Then
55
 
-
 
56
   ' Update an existing entry
55
 ' Update an existing entry
57
   If Request("bm_id") <> "" Then
56
   If Request("bm_id") <> "" Then
58
      Query_String = _
57
      Query_String = _
59
      "   SELECT * FROM BUILD_MACHINES WHERE BM_ID <> " & Request("bm_id") & " AND BM_NAME = '"& Request("BM_NAME") &"'"
58
      "   SELECT * FROM BUILD_MACHINES WHERE BM_ID <> " & Request("bm_id") & " AND UPPER(BM_NAME) = UPPER('"& Request("BM_NAME") &"')"
60
 
59
 
61
      Set rsQry = OraDatabase.DbCreateDynaset( Query_String, cint(0))
60
      Set rsQry = OraDatabase.DbCreateDynaset( Query_String, cint(0))
62
 
61
 
63
      If rsQry.RecordCount = 0 Then
62
      If rsQry.RecordCount = 0 Then
64
 
63
 
65
         OraDatabase.Parameters.Add "BM_ID",   Request("BM_ID"),   ORAPARM_INPUT, ORATYPE_NUMBER
64
         OraDatabase.Parameters.Add "BM_ID",   Request("BM_ID"),   ORAPARM_INPUT, ORATYPE_NUMBER
66
         OraDatabase.Parameters.Add "BM_NAME", Request("BM_NAME"), ORAPARM_INPUT, ORATYPE_VARCHAR2
65
         OraDatabase.Parameters.Add "BM_NAME", Request("BM_NAME"), ORAPARM_INPUT, ORATYPE_VARCHAR2
67
 
66
 
-
 
67
         objEH.ErrorRedirect = FALSE
68
         objEH.TryORA ( OraSession )
68
         objEH.TryORA ( OraSession )
69
         On Error Resume Next
69
         On Error Resume Next
70
 
70
 
71
         OraDatabase.ExecuteSQL _
71
         OraDatabase.ExecuteSQL _
72
         "BEGIN  PK_BUILDAPI.UPDATE_BUILDMACHINE(:BM_ID, :BM_NAME);  END;"
72
         "BEGIN  PK_BUILDAPI.UPDATE_BUILDMACHINE(:BM_ID, :BM_NAME);  END;"
Line 90... Line 90...
90
   Else
90
   Else
91
 
91
 
92
      ' Create a new entry
92
      ' Create a new entry
93
      '
93
      '
94
      Query_String = _
94
      Query_String = _
95
      "   SELECT * FROM BUILD_MACHINES WHERE BM_NAME = '"& Request("BM_NAME") &"'"
95
      "   SELECT * FROM BUILD_MACHINES WHERE UPPER(BM_NAME) = UPPER('"& Request("BM_NAME") &"')"
96
 
96
 
97
      Set rsQry = OraDatabase.DbCreateDynaset( Query_String, cint(0))
97
      Set rsQry = OraDatabase.DbCreateDynaset( Query_String, cint(0))
98
 
98
 
99
      If rsQry.RecordCount = 0 Then
99
      If rsQry.RecordCount = 0 Then
100
 
100
 
101
         OraDatabase.Parameters.Add "BM_NAME",   Request("BM_NAME"),    ORAPARM_INPUT, ORATYPE_VARCHAR2
101
         OraDatabase.Parameters.Add "BM_NAME",   Request("BM_NAME"),    ORAPARM_INPUT, ORATYPE_VARCHAR2
102
 
102
 
-
 
103
         objEH.ErrorRedirect = FALSE
103
         objEH.TryORA ( OraSession )
104
         objEH.TryORA ( OraSession )
104
         On Error Resume Next
105
         On Error Resume Next
105
 
106
 
106
         OraDatabase.ExecuteSQL _
107
         OraDatabase.ExecuteSQL _
107
         "BEGIN  PK_BUILDAPI.ADD_BUILDMACHINE(:BM_NAME);  END;"
108
         "BEGIN  PK_BUILDAPI.ADD_BUILDMACHINE(:BM_NAME);  END;"
Line 137... Line 138...
137
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
138
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
138
<link href="images/release_manager_style.css" rel="stylesheet" type="text/css">
139
<link href="images/release_manager_style.css" rel="stylesheet" type="text/css">
139
<script language="JavaScript" src="images/common.js"></script>
140
<script language="JavaScript" src="images/common.js"></script>
140
</head>
141
</head>
141
 
142
 
142
<body background="images/bg_bage_0.gif" leftmargin="0" topmargin="0" onLoad="self.focus();FormName.GBE_MACHTYPE.focus();">
143
<body leftmargin="0" topmargin="0" onLoad="self.focus();FormName.BM_NAME.focus();">
143
<table width="100%"  border="0" cellspacing="0" cellpadding="10">
144
<table width="100%"  border="0" cellspacing="0" cellpadding="10">
144
   <tr>
145
   <tr>
145
      <td bgcolor="#FFFFFF" class="body_txt"><span class="body_h1"><img src="icons/i_linkarrow_black.gif" width="11" height="11" align="absmiddle">&nbsp;Add/Update GBE_MACHTYPE</span> <br>
146
      <td class="body_txt">
146
         Add a new Machine Type or edit an existing Machine Type.
147
         Add a new Machine Type or edit an existing Machine Type.
147
      </td>
148
      </td>
148
   </tr>
149
   </tr>
149
 
-
 
150
 
-
 
151
   <%
150
   <%
152
   '-- FROM START --------------------------------------------------------------------------------------------------------------
151
   '-- FROM START --------------------------------------------------------------------------------------------------------------
153
   objFormComponent.FormName = "FormName"
152
   objFormComponent.FormName = "FormName"
-
 
153
   objFormComponent.FormClass = "form_tight"
154
   objFormComponent.Action = ScriptName
154
   objFormComponent.Action = ScriptName
155
   objFormComponent.OnSubmit = "MM_validateForm(""BM_NAME"",""Machine Type"",""RisCleanStrinLength4:"");return document.MM_returnValue"
155
   objFormComponent.OnSubmit = "MM_validateForm(""BM_NAME"",""Machine Type"",""RisCleanStrinLength4:"");return document.MM_returnValue"
156
   Call objFormComponent.FormStart()
156
   Call objFormComponent.FormStart()
157
 
-
 
158
   %>
157
   %>
159
   <tr>
158
   <tr>
160
      <td background="images/bg_login.gif">
159
      <td class="form_field_bg" >
161
         <table width="50%"  border="0" cellspacing="0" cellpadding="0">
-
 
162
            <tr>
-
 
163
               <td><%=ProgressBar()%></td>
-
 
164
               <td align="right"><input name="btn" type="submit" class="form_btn" value="Add/Update">
-
 
165
                  <input name="btn" type="reset" class="form_btn" value="Cancel" onClick="self.close();">
-
 
166
               </td>
-
 
167
            </tr>
-
 
168
         </table>
-
 
169
      </td>
-
 
170
   </tr>
-
 
171
   <tr>
-
 
172
      <td>
-
 
173
         <!-- NEW PRODUCT +++++++++++++++++++++++++++++++++++++++++++++++ -->
160
         <!-- NEW PRODUCT +++++++++++++++++++++++++++++++++++++++++++++++ -->
174
         <%Call Messenger ( sMessage , 1, "100%" )%>
161
         <%Call Messenger ( sMessage , 1, "100%" )%>
175
         <!-- MESSAGE +++++++++++++++++++++++++++++++++++++++++++++++++++ -->
162
         <!-- MESSAGE +++++++++++++++++++++++++++++++++++++++++++++++++++ -->
176
         <!--#include file="messages/_msg_inline.asp"-->
163
         <!--#include file="messages/_msg_inline.asp"-->
177
 
164
 
Line 195... Line 182...
195
               rsTemp.Close()
182
               rsTemp.Close()
196
               Set rsTemp = Nothing
183
               Set rsTemp = Nothing
197
            End   If
184
            End   If
198
            %>
185
            %>
199
            <tr>
186
            <tr>
200
               <td><span class="body_txt">Machine Type</span></td>
187
               <td><span class="body_txt nowrap">Machine Type</span></td>
201
               <td><input name="BM_NAME" type="text" class="body_txt" value="<%=GBE_MACHCLASS%>"></td>
188
               <td><input name="BM_NAME" type="text" class="body_txt" value="<%=GBE_MACHCLASS%>"></td>
202
            </tr>
189
            </tr>
-
 
190
         </table>
-
 
191
      </td>
-
 
192
   </tr>
-
 
193
   <tr>
-
 
194
      <td>
-
 
195
         <table class="full_table">
203
            <tr>
196
            <tr>
-
 
197
               <td><%=ProgressBar()%></td>
204
               <td>&nbsp;</td>
198
               <td align="right">
-
 
199
                  <input name="btn" type="submit" class="form_btn" value="Add/Update">
-
 
200
                  <input name="btn" type="reset" class="form_btn" value="Cancel" onclick="parent.closeIFrame();">
205
               <td>&nbsp;</td>
201
               </td>
206
            </tr>
202
            </tr>
207
         </table>
203
         </table>
208
      </td>
204
      </td>
209
   </tr>
205
   </tr>
210
   <%=objPMod.ComposeHiddenTags()%>
206
   <%=objPMod.ComposeHiddenTags()%>
211
   <input type="hidden" name="action" value="true">
207
   <input type="hidden" name="action" value="true">
212
 
-
 
213
   <%
208
   <%
214
   Call objFormComponent.FormEnd()
209
   Call objFormComponent.FormEnd()
215
   '-- FROM END ----------------------------------------------------------------------------------------------------------------
210
   '-- FROM END ----------------------------------------------------------------------------------------------------------------
216
   %>
211
   %>
217
</table>
212
</table>