Exemplo n.º 1
0
 protected void RF0G2( )
 {
     /* GeneXus formulas. */
     AV8Pgmname     = "NotAuthorized";
     context.Gx_err = 0;
     if (String.IsNullOrEmpty(StringUtil.RTrim(context.wjLoc)) && (context.nUserReturn != 1))
     {
         if (1 != 0)
         {
             WebComp_Headerbc.componentstart();
         }
     }
     if (String.IsNullOrEmpty(StringUtil.RTrim(context.wjLoc)) && (context.nUserReturn != 1))
     {
         if (1 != 0)
         {
             if (StringUtil.Len(WebComp_Recentlinks_Component) != 0)
             {
                 WebComp_Recentlinks.componentstart();
             }
         }
     }
     if (String.IsNullOrEmpty(StringUtil.RTrim(context.wjLoc)) && (context.nUserReturn != 1))
     {
         /* Execute user event: E120G2 */
         E120G2();
         WB0G0( );
     }
 }
Exemplo n.º 2
0
 protected void E110G2( )
 {
     /* Start Routine */
     /* Object Property */
     if (StringUtil.StrCmp(StringUtil.Lower(WebComp_Recentlinks_Component), StringUtil.Lower("RecentLinks")) != 0)
     {
         WebComp_Recentlinks = getWebComponent(GetType(), "GeneXus.Programs", "recentlinks", new Object[] { context });
         WebComp_Recentlinks.ComponentInit();
         WebComp_Recentlinks.Name      = "RecentLinks";
         WebComp_Recentlinks_Component = "RecentLinks";
     }
     if (StringUtil.Len(WebComp_Recentlinks_Component) != 0)
     {
         WebComp_Recentlinks.setjustcreated();
         WebComp_Recentlinks.componentprepare(new Object[] { (String)"W0003", (String)"", context.GetMessage("Not Authorized", ""), (String)AV8Pgmname });
         WebComp_Recentlinks.componentbind(new Object[] { (String)"" + "" + "", (String)"" });
     }
     GX_msglist.addItem(context.GetMessage("You are not authorized to do this action", ""));
 }
Exemplo n.º 3
0
 public override void RenderHtmlCloseForm( )
 {
     /* Send hidden variables. */
     /* Send saved values. */
     GxWebStd.gx_hidden_field(context, "vGXOBJECT", StringUtil.RTrim(GxObject));
     context.WriteHtmlText("<script type=\"text/javascript\">");
     context.WriteHtmlText("gx.setLanguageCode(\"" + context.GetLanguageProperty("code") + "\");");
     if (!context.isSpaRequest( ))
     {
         context.WriteHtmlText("gx.setDateFormat(\"" + context.GetLanguageProperty("date_fmt") + "\");");
         context.WriteHtmlText("gx.setTimeFormat(" + context.GetLanguageProperty("time_fmt") + ");");
         context.WriteHtmlText("gx.setCenturyFirstYear(" + 40 + ");");
         context.WriteHtmlText("gx.setDecimalPoint(\"" + context.GetLanguageProperty("decimal_point") + "\");");
         context.WriteHtmlText("gx.setThousandSeparator(\"" + context.GetLanguageProperty("thousand_sep") + "\");");
         context.WriteHtmlText("gx.StorageTimeZone = " + 1 + ";");
     }
     context.WriteHtmlText("</script>");
     GxWebStd.gx_hidden_field(context, "GX_FocusControl", GX_FocusControl);
     SendAjaxEncryptionKey();
     SendSecurityToken((String)(sPrefix));
     SendComponentObjects();
     SendServerCommands();
     SendState();
     if (context.isSpaRequest( ))
     {
         disableOutput();
     }
     context.WriteHtmlTextNl("</form>");
     if (context.isSpaRequest( ))
     {
         enableOutput();
     }
     include_jscripts( );
     if (!(WebComp_Headerbc == null))
     {
         WebComp_Headerbc.componentjscripts();
     }
     if (!(WebComp_Recentlinks == null))
     {
         WebComp_Recentlinks.componentjscripts();
     }
 }
Exemplo n.º 4
0
 protected void define_styles( )
 {
     AddThemeStyleSheetFile("", context.GetTheme( ) + ".css", "?11145295");
     if (!(WebComp_Headerbc == null))
     {
         WebComp_Headerbc.componentthemes();
     }
     if (!(WebComp_Recentlinks == null))
     {
         if (StringUtil.Len(WebComp_Recentlinks_Component) != 0)
         {
             WebComp_Recentlinks.componentthemes();
         }
     }
     idxLst = 1;
     while (idxLst <= Form.Jscriptsrc.Count)
     {
         context.AddJavascriptSource(StringUtil.RTrim(((String)Form.Jscriptsrc.Item(idxLst))), "?20151261115254");
         idxLst = (int)(idxLst + 1);
     }
     /* End function define_styles */
 }
Exemplo n.º 5
0
 protected void EVT0G2( )
 {
     if (StringUtil.StrCmp(context.GetRequestMethod( ), "POST") == 0)
     {
         if (String.IsNullOrEmpty(StringUtil.RTrim(context.wjLoc)) && (context.nUserReturn != 1) && !wbErr)
         {
             /* Read Web Panel buttons. */
             sEvt      = cgiGet("_EventName");
             EvtGridId = cgiGet("_EventGridId");
             EvtRowId  = cgiGet("_EventRowId");
             if (StringUtil.Len(sEvt) > 0)
             {
                 sEvtType = StringUtil.Left(sEvt, 1);
                 sEvt     = StringUtil.Right(sEvt, (short)(StringUtil.Len(sEvt) - 1));
                 if (StringUtil.StrCmp(sEvtType, "M") != 0)
                 {
                     if (StringUtil.StrCmp(sEvtType, "E") == 0)
                     {
                         sEvtType = StringUtil.Right(sEvt, 1);
                         if (StringUtil.StrCmp(sEvtType, ".") == 0)
                         {
                             sEvt = StringUtil.Left(sEvt, (short)(StringUtil.Len(sEvt) - 1));
                             if (StringUtil.StrCmp(sEvt, "RFR") == 0)
                             {
                                 context.wbHandled = 1;
                                 dynload_actions( );
                             }
                             else if (StringUtil.StrCmp(sEvt, "START") == 0)
                             {
                                 context.wbHandled = 1;
                                 dynload_actions( );
                                 /* Execute user event: E110G2 */
                                 E110G2();
                             }
                             else if (StringUtil.StrCmp(sEvt, "LOAD") == 0)
                             {
                                 context.wbHandled = 1;
                                 dynload_actions( );
                                 /* Execute user event: E120G2 */
                                 E120G2();
                             }
                             else if (StringUtil.StrCmp(sEvt, "ENTER") == 0)
                             {
                                 context.wbHandled = 1;
                                 if (!wbErr)
                                 {
                                     Rfr0gs = false;
                                     if (!Rfr0gs)
                                     {
                                     }
                                     dynload_actions( );
                                 }
                                 /* No code required for Cancel button. It is implemented as the Reset button. */
                             }
                             else if (StringUtil.StrCmp(sEvt, "LSCR") == 0)
                             {
                                 context.wbHandled = 1;
                                 dynload_actions( );
                                 dynload_actions( );
                             }
                         }
                         else
                         {
                         }
                     }
                     else if (StringUtil.StrCmp(sEvtType, "W") == 0)
                     {
                         sEvtType = StringUtil.Left(sEvt, 4);
                         sEvt     = StringUtil.Right(sEvt, (short)(StringUtil.Len(sEvt) - 4));
                         nCmpId   = (short)(NumberUtil.Val(sEvtType, "."));
                         if (nCmpId == 2)
                         {
                             OldHeaderbc = cgiGet("W0002");
                             if ((StringUtil.Len(OldHeaderbc) == 0) || (StringUtil.StrCmp(OldHeaderbc, WebComp_Headerbc_Component) != 0))
                             {
                                 WebComp_Headerbc = getWebComponent(GetType(), "GeneXus.Programs", OldHeaderbc, new Object[] { context });
                                 WebComp_Headerbc.ComponentInit();
                                 WebComp_Headerbc.Name      = "OldHeaderbc";
                                 WebComp_Headerbc_Component = OldHeaderbc;
                             }
                             WebComp_Headerbc.componentprocess("W0002", "", sEvt);
                             WebComp_Headerbc_Component = OldHeaderbc;
                         }
                         else if (nCmpId == 3)
                         {
                             OldRecentlinks = cgiGet("W0003");
                             if ((StringUtil.Len(OldRecentlinks) == 0) || (StringUtil.StrCmp(OldRecentlinks, WebComp_Recentlinks_Component) != 0))
                             {
                                 WebComp_Recentlinks = getWebComponent(GetType(), "GeneXus.Programs", OldRecentlinks, new Object[] { context });
                                 WebComp_Recentlinks.ComponentInit();
                                 WebComp_Recentlinks.Name      = "OldRecentlinks";
                                 WebComp_Recentlinks_Component = OldRecentlinks;
                             }
                             if (StringUtil.Len(WebComp_Recentlinks_Component) != 0)
                             {
                                 WebComp_Recentlinks.componentprocess("W0003", "", sEvt);
                             }
                             WebComp_Recentlinks_Component = OldRecentlinks;
                         }
                     }
                     context.wbHandled = 1;
                 }
             }
         }
     }
 }
Exemplo n.º 6
0
 protected void WB0G0( )
 {
     if (context.isAjaxRequest( ))
     {
         disableOutput();
     }
     if (!wbLoad)
     {
         if (nGXWrapped == 1)
         {
             RenderHtmlHeaders( );
             RenderHtmlOpenForm( );
         }
         if (!isFullAjaxMode( ))
         {
             /* WebComponent */
             GxWebStd.gx_hidden_field(context, "W0002" + "", StringUtil.RTrim(WebComp_Headerbc_Component));
             context.WriteHtmlText("<div");
             GxWebStd.ClassAttribute(context, "gxwebcomponent");
             context.WriteHtmlText(" id=\"" + "gxHTMLWrpW0002" + "" + "\"" + "");
             context.WriteHtmlText(">");
             if (StringUtil.StrCmp(StringUtil.Lower(OldHeaderbc), StringUtil.Lower(WebComp_Headerbc_Component)) != 0)
             {
                 context.httpAjaxContext.ajax_rspStartCmp("gxHTMLWrpW0002" + "");
             }
             WebComp_Headerbc.componentdraw();
             if (StringUtil.StrCmp(StringUtil.Lower(OldHeaderbc), StringUtil.Lower(WebComp_Headerbc_Component)) != 0)
             {
                 context.httpAjaxContext.ajax_rspEndCmp();
             }
             context.WriteHtmlText("</div>");
         }
         if (!isFullAjaxMode( ))
         {
             /* WebComponent */
             GxWebStd.gx_hidden_field(context, "W0003" + "", StringUtil.RTrim(WebComp_Recentlinks_Component));
             context.WriteHtmlText("<div");
             GxWebStd.ClassAttribute(context, "gxwebcomponent");
             context.WriteHtmlText(" id=\"" + "gxHTMLWrpW0003" + "" + "\"" + "");
             context.WriteHtmlText(">");
             if (StringUtil.Len(WebComp_Recentlinks_Component) != 0)
             {
                 if (StringUtil.StrCmp(StringUtil.Lower(OldRecentlinks), StringUtil.Lower(WebComp_Recentlinks_Component)) != 0)
                 {
                     context.httpAjaxContext.ajax_rspStartCmp("gxHTMLWrpW0003" + "");
                 }
                 WebComp_Recentlinks.componentdraw();
                 if (StringUtil.StrCmp(StringUtil.Lower(OldRecentlinks), StringUtil.Lower(WebComp_Recentlinks_Component)) != 0)
                 {
                     context.httpAjaxContext.ajax_rspEndCmp();
                 }
             }
             context.WriteHtmlText("</div>");
         }
         wb_table1_4_0G2(true);
     }
     else
     {
         wb_table1_4_0G2(false);
     }
     return;
 }