* Data Abstract namespaced

This commit is contained in:
Michaël Van Canneyt 2023-11-27 22:24:24 +01:00
parent 1b3e30146a
commit 2b5c74fe7e
8 changed files with 55 additions and 5 deletions

View File

@ -0,0 +1,3 @@
{$DEFINE FPC_DOTTEDUNITS}
unit Api.DA.Server;
{$include ../src/dasdk.pas}

View File

@ -0,0 +1,3 @@
{$DEFINE FPC_DOTTEDUNITS}
unit Api.DA;
{$include ../src/da.pas}

View File

@ -0,0 +1,3 @@
{$DEFINE FPC_DOTTEDUNITS}
unit Api.RO.Server;
{$include ../src/rosdk.pas}

View File

@ -0,0 +1,3 @@
{$DEFINE FPC_DOTTEDUNITS}
unit Data.DA;
{$include ../src/dadataset.pas}

View File

@ -13,14 +13,21 @@
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
**********************************************************************}
{$IFNDEF FPC_DOTTEDUNITS}
unit DA;
{$ENDIF}
{$mode objfpc}
{$modeswitch externalclass}
interface
uses Sysutils, Types, JS, DASDK;
uses
{$IFDEF FPC_DOTTEDUNITS}
System.SysUtils, System.Types, JSApi.JS, Api.DA.Server;
{$ELSE}
Sysutils, Types, JS, DASDK;
{$ENDIF}
Type
TDADataType = ( datUnknown, datString, datDateTime, datFloat, datCurrency,

View File

@ -13,7 +13,9 @@
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
**********************************************************************}
{$IFNDEF FPC_DOTTEDUNITS}
unit dadataset;
{$ENDIF}
{$mode objfpc}
{$modeswitch externalclass}
@ -21,7 +23,13 @@ unit dadataset;
interface
uses Types, Classes, DB, jsonDataset, JS, rosdk, da, dasdk;
uses
{$IFDEF FPC_DOTTEDUNITS}
System.Types, System.Classes, Data.DB, Data.JsonDataset, JSApi.JS,
Api.RO.Server, Api.DA, Api.DA.Server;
{$ELSE}
Types, Classes, DB, jsonDataset, JS, rosdk, da, dasdk;
{$ENDIF}
Type
// Server sends data as a regular string.
@ -277,7 +285,12 @@ Type
implementation
uses strutils, sysutils;
uses
{$IFDEF FPC_DOTTEDUNITS}
System.StrUtils, System.SysUtils;
{$ELSE}
strutils, sysutils;
{$ENDIF}
resourcestring
SErrInvalidDate = '%s is not a valid date value for %s';

View File

@ -13,14 +13,21 @@
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
**********************************************************************}
{$IFNDEF FPC_DOTTEDUNITS}
unit dasdk;
{$ENDIF}
{$mode objfpc}
{$modeswitch externalclass}
interface
uses JS, ROSDK;
uses
{$IFDEF FPC_DOTTEDUNITS}
JSApi.JS, Api.RO.Server;
{$ELSE}
JS, ROSDK;
{$ENDIF}
Type
TDAUserInfo = Class;

View File

@ -13,7 +13,9 @@
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
**********************************************************************}
{$IFNDEF FPC_DOTTEDUNITS}
unit ROSDK;
{$ENDIF}
{$mode objfpc}
{$modeswitch externalclass}
@ -21,7 +23,11 @@ unit ROSDK;
interface
uses
{$IFDEF FPC_DOTTEDUNITS}
System.Types, JSApi.JS;
{$ELSE}
Types, JS;
{$ENDIF}
Type
TROValue = record
@ -220,7 +226,12 @@ Var
implementation
uses Sysutils;
uses
{$IFDEF FPC_DOTTEDUNITS}
System.SysUtils;
{$ELSE}
Sysutils;
{$ENDIF}
Resourcestring
SDefaultUnexpectedErrorMsg = 'An unexpected error occurred';