|
@@ -84,6 +84,7 @@ Type
|
|
|
|
|
|
TWebHandler = class(TComponent)
|
|
TWebHandler = class(TComponent)
|
|
private
|
|
private
|
|
|
|
+ FDefaultModuleName: String;
|
|
FOnIdle: TNotifyEvent;
|
|
FOnIdle: TNotifyEvent;
|
|
FOnInitModule: TInitModuleEvent;
|
|
FOnInitModule: TInitModuleEvent;
|
|
FOnUnknownRequestEncoding: TOnUnknownEncodingEvent;
|
|
FOnUnknownRequestEncoding: TOnUnknownEncodingEvent;
|
|
@@ -127,6 +128,7 @@ Type
|
|
Property RedirectOnErrorURL : string Read FRedirectOnErrorURL Write FRedirectOnErrorURL;
|
|
Property RedirectOnErrorURL : string Read FRedirectOnErrorURL Write FRedirectOnErrorURL;
|
|
Property ApplicationURL : String Read FApplicationURL Write FApplicationURL;
|
|
Property ApplicationURL : String Read FApplicationURL Write FApplicationURL;
|
|
Property AllowDefaultModule : Boolean Read FAllowDefaultModule Write FAllowDefaultModule;
|
|
Property AllowDefaultModule : Boolean Read FAllowDefaultModule Write FAllowDefaultModule;
|
|
|
|
+ Property DefaultModuleName : String Read FDefaultModuleName Write FDefaultModuleName;
|
|
Property ModuleVariable : String Read FModuleVar Write FModuleVar;
|
|
Property ModuleVariable : String Read FModuleVar Write FModuleVar;
|
|
Property OnGetModule : TGetModuleEvent Read FOnGetModule Write FOnGetModule;
|
|
Property OnGetModule : TGetModuleEvent Read FOnGetModule Write FOnGetModule;
|
|
Property Email : String Read GetEmail Write FEmail;
|
|
Property Email : String Read GetEmail Write FEmail;
|
|
@@ -147,6 +149,7 @@ Type
|
|
function GetAdministrator: String;
|
|
function GetAdministrator: String;
|
|
function GetAllowDefaultModule: Boolean;
|
|
function GetAllowDefaultModule: Boolean;
|
|
function GetApplicationURL: String;
|
|
function GetApplicationURL: String;
|
|
|
|
+ function GetDefaultModuleName: String;
|
|
function GetEmail: String;
|
|
function GetEmail: String;
|
|
function GetEventLog: TEventLog;
|
|
function GetEventLog: TEventLog;
|
|
function GetHandleGetOnPost: Boolean;
|
|
function GetHandleGetOnPost: Boolean;
|
|
@@ -160,6 +163,7 @@ Type
|
|
procedure SetAdministrator(const AValue: String);
|
|
procedure SetAdministrator(const AValue: String);
|
|
procedure SetAllowDefaultModule(const AValue: Boolean);
|
|
procedure SetAllowDefaultModule(const AValue: Boolean);
|
|
procedure SetApplicationURL(const AValue: String);
|
|
procedure SetApplicationURL(const AValue: String);
|
|
|
|
+ procedure SetDefaultModuleName(AValue: String);
|
|
procedure SetEmail(const AValue: String);
|
|
procedure SetEmail(const AValue: String);
|
|
procedure SetHandleGetOnPost(const AValue: Boolean);
|
|
procedure SetHandleGetOnPost(const AValue: Boolean);
|
|
procedure SetModuleVar(const AValue: String);
|
|
procedure SetModuleVar(const AValue: String);
|
|
@@ -187,6 +191,7 @@ Type
|
|
Property RedirectOnErrorURL : string Read GetRedirectOnErrorURL Write SetRedirectOnErrorURL;
|
|
Property RedirectOnErrorURL : string Read GetRedirectOnErrorURL Write SetRedirectOnErrorURL;
|
|
Property ApplicationURL : String Read GetApplicationURL Write SetApplicationURL;
|
|
Property ApplicationURL : String Read GetApplicationURL Write SetApplicationURL;
|
|
Property AllowDefaultModule : Boolean Read GetAllowDefaultModule Write SetAllowDefaultModule;
|
|
Property AllowDefaultModule : Boolean Read GetAllowDefaultModule Write SetAllowDefaultModule;
|
|
|
|
+ Property DefaultModuleName : String Read GetDefaultModuleName Write SetDefaultModuleName;
|
|
Property ModuleVariable : String Read GetModuleVar Write SetModuleVar;
|
|
Property ModuleVariable : String Read GetModuleVar Write SetModuleVar;
|
|
Property OnGetModule : TGetModuleEvent Read GetOnGetModule Write SetOnGetModule;
|
|
Property OnGetModule : TGetModuleEvent Read GetOnGetModule Write SetOnGetModule;
|
|
Property Email : String Read GetEmail Write SetEmail;
|
|
Property Email : String Read GetEmail Write SetEmail;
|
|
@@ -389,7 +394,9 @@ function TWebHandler.GetModuleName(Arequest: TRequest): string;
|
|
Function GetDefaultModuleName : String;
|
|
Function GetDefaultModuleName : String;
|
|
|
|
|
|
begin
|
|
begin
|
|
- If (ModuleFactory.Count=1) then
|
|
|
|
|
|
+ if (DefaultModuleName<>'') then
|
|
|
|
+ Result:=DefaultModuleName
|
|
|
|
+ else if (ModuleFactory.Count=1) then
|
|
Result:=ModuleFactory[0].ModuleName;
|
|
Result:=ModuleFactory[0].ModuleName;
|
|
end;
|
|
end;
|
|
|
|
|
|
@@ -493,6 +500,11 @@ begin
|
|
result := FWebHandler.ApplicationURL;
|
|
result := FWebHandler.ApplicationURL;
|
|
end;
|
|
end;
|
|
|
|
|
|
|
|
+function TCustomWebApplication.GetDefaultModuleName: String;
|
|
|
|
+begin
|
|
|
|
+ Result:=FWebHandler.DefaultModuleName;
|
|
|
|
+end;
|
|
|
|
+
|
|
function TCustomWebApplication.GetEmail: String;
|
|
function TCustomWebApplication.GetEmail: String;
|
|
begin
|
|
begin
|
|
result := FWebHandler.Email;
|
|
result := FWebHandler.Email;
|
|
@@ -567,6 +579,11 @@ begin
|
|
FWebHandler.ApplicationURL := AValue;
|
|
FWebHandler.ApplicationURL := AValue;
|
|
end;
|
|
end;
|
|
|
|
|
|
|
|
+procedure TCustomWebApplication.SetDefaultModuleName(AValue: String);
|
|
|
|
+begin
|
|
|
|
+ FWebHandler.DefaultModuleName:=AValue;
|
|
|
|
+end;
|
|
|
|
+
|
|
procedure TCustomWebApplication.SetEmail(const AValue: String);
|
|
procedure TCustomWebApplication.SetEmail(const AValue: String);
|
|
begin
|
|
begin
|
|
FWebHandler.Email := AValue;
|
|
FWebHandler.Email := AValue;
|