Skip to content

Commit

Permalink
compile 1.7.0.1 for pre-release test
Browse files Browse the repository at this point in the history
  • Loading branch information
Artanemus committed Dec 23, 2023
1 parent 7c56440 commit fdfde90
Show file tree
Hide file tree
Showing 9 changed files with 345 additions and 289 deletions.
26 changes: 16 additions & 10 deletions MEMBERS/frmManageMember.dfm
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ object ManageMember: TManageMember
TextHeight = 19
object Panel1: TPanel
Left = 0
Top = 31
Top = 25
Width = 1363
Height = 49
Align = alTop
Expand Down Expand Up @@ -112,29 +112,27 @@ object ManageMember: TManageMember
end
object PageControl1: TPageControl
Left = 0
Top = 80
Top = 74
Width = 1363
Height = 696
ActivePage = TabSheet4
Height = 702
ActivePage = TabSheet1
Align = alClient
MultiLine = True
TabHeight = 40
TabOrder = 2
TabWidth = 180
ExplicitWidth = 1359
ExplicitHeight = 695
ExplicitHeight = 701
object TabSheet1: TTabSheet
Caption = 'Member'#39's Details 1'
object Panel7: TPanel
Left = 0
Top = 0
Width = 1355
Height = 646
Height = 652
Align = alClient
BevelOuter = bvNone
TabOrder = 0
ExplicitWidth = 1351
ExplicitHeight = 645
object Label3: TLabel
Left = 33
Top = 179
Expand Down Expand Up @@ -745,7 +743,7 @@ object ManageMember: TManageMember
Left = 0
Top = 0
Width = 1355
Height = 646
Height = 652
Align = alClient
BorderStyle = bsNone
DataSource = ManageMemberData.dsMember
Expand Down Expand Up @@ -777,34 +775,40 @@ object ManageMember: TManageMember
item
Expanded = False
FieldName = 'MembershipNum'
Width = 64
Visible = True
end
item
Expanded = False
FieldName = 'FirstName'
Width = 64
Visible = True
end
item
Expanded = False
FieldName = 'LastName'
Width = 64
Visible = True
end
item
ButtonStyle = cbsEllipsis
Expanded = False
FieldName = 'DOB'
Width = 64
Visible = True
end
item
Expanded = False
FieldName = 'luGender'
Width = 64
Visible = True
end
item
Alignment = taCenter
Expanded = False
FieldName = 'IsArchived'
Title.Caption = 'Archive'
Width = 64
Visible = True
end
item
Expand All @@ -818,11 +822,13 @@ object ManageMember: TManageMember
Expanded = False
FieldName = 'IsSwimmer'
Title.Caption = 'Swims'
Width = 64
Visible = True
end
item
Expanded = False
FieldName = 'luHouse'
Width = 64
Visible = True
end
item
Expand Down Expand Up @@ -955,7 +961,7 @@ object ManageMember: TManageMember
Left = 0
Top = 0
Width = 1363
Height = 31
Height = 25
UseSystemFont = False
ActionManager = ActnManagerMember
Caption = 'Member Menu Bar'
Expand Down
384 changes: 192 additions & 192 deletions SwimClubMeet.dproj

Large diffs are not rendered by default.

Binary file modified SwimClubMeet.res
Binary file not shown.
19 changes: 11 additions & 8 deletions dlgPreferences.dfm
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ object Preferences: TPreferences
Align = alTop
BevelOuter = bvNone
TabOrder = 0
ExplicitWidth = 650
ExplicitWidth = 642
object DBText1: TDBText
Left = 13
Top = 9
Expand All @@ -51,21 +51,21 @@ object Preferences: TPreferences
Align = alBottom
BevelOuter = bvNone
TabOrder = 1
ExplicitTop = 543
ExplicitWidth = 650
ExplicitTop = 541
ExplicitWidth = 642
DesignSize = (
646
48)
object btnClose: TButton
Left = 480
Left = 476
Top = 6
Width = 101
Height = 33
Anchors = [akTop, akRight]
Caption = 'Close'
TabOrder = 0
OnClick = btnCloseClick
ExplicitLeft = 492
ExplicitLeft = 472
end
end
object PageControl1: TPageControl
Expand All @@ -77,8 +77,8 @@ object Preferences: TPreferences
Align = alClient
TabOrder = 2
OnChanging = PageControl1Changing
ExplicitWidth = 650
ExplicitHeight = 502
ExplicitWidth = 642
ExplicitHeight = 500
object TabSheet1: TTabSheet
Caption = 'Club'
object Label2: TLabel
Expand Down Expand Up @@ -368,7 +368,7 @@ object Preferences: TPreferences
ParentFont = False
end
object btn1: TSpeedButton
Left = 149
Left = 145
Top = 15
Width = 33
Height = 33
Expand Down Expand Up @@ -550,7 +550,10 @@ object Preferences: TPreferences
Width = 241
Height = 19
Caption = 'Enable Team Events.'
Checked = True
State = cbChecked
TabOrder = 0
Visible = False
end
object prefEnableDCodes: TCheckBox
Left = 32
Expand Down
2 changes: 1 addition & 1 deletion dlgPreferences.pas
Original file line number Diff line number Diff line change
Expand Up @@ -445,7 +445,7 @@ procedure TPreferences.ReadPreferences(IniFileName: string);

// 2023.06.26
prefEnableTeamEvents.Checked := iFile.ReadBool('Preferences',
'EnableTeamEvents', false);
'EnableTeamEvents', true);
prefEnableDCodes.Checked := iFile.ReadBool('Preferences',
'EnableDCodes', false);
prefDisplaySwimmerCAT.Checked := iFile.ReadBool('Preferences',
Expand Down
5 changes: 5 additions & 0 deletions dmSCM.dfm
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,7 @@ object SCM: TSCM
Active = True
IndexFieldNames = 'StrokeID'
Connection = scmConnection
ResourceOptions.AssignedValues = [rvEscapeExpand]
UpdateOptions.UpdateTableName = 'SwimClubMeet..Stroke'
UpdateOptions.KeyFields = 'StrokeID'
TableName = 'SwimClubMeet..Stroke'
Expand All @@ -53,6 +54,7 @@ object SCM: TSCM
Active = True
IndexFieldNames = 'DistanceID'
Connection = scmConnection
ResourceOptions.AssignedValues = [rvEscapeExpand]
UpdateOptions.UpdateTableName = 'SwimClubMeet..Distance'
UpdateOptions.KeyFields = 'DistanceID'
TableName = 'SwimClubMeet..Distance'
Expand Down Expand Up @@ -119,6 +121,7 @@ object SCM: TSCM
Active = True
IndexFieldNames = 'EventStatusID'
Connection = scmConnection
ResourceOptions.AssignedValues = [rvEscapeExpand]
UpdateOptions.UpdateTableName = 'SwimClubMeet..EventStatus'
UpdateOptions.KeyFields = 'EventStatusID'
TableName = 'SwimClubMeet..EventStatus'
Expand Down Expand Up @@ -400,6 +403,7 @@ object SCM: TSCM
MasterFields = 'SwimClubID'
DetailFields = 'SwimClubID'
Connection = scmConnection
UpdateOptions.AssignedValues = [uvEInsert]
UpdateOptions.UpdateTableName = 'SwimClubMeet..Session'
UpdateOptions.KeyFields = 'SessionID'
SQL.Strings = (
Expand Down Expand Up @@ -1856,6 +1860,7 @@ object SCM: TSCM
Active = True
IndexFieldNames = 'SwimmerCategoryID'
Connection = scmConnection
ResourceOptions.AssignedValues = [rvEscapeExpand]
UpdateOptions.AssignedValues = [uvEDelete, uvEInsert, uvEUpdate]
UpdateOptions.EnableDelete = False
UpdateOptions.EnableInsert = False
Expand Down
34 changes: 30 additions & 4 deletions dmSCM.pas
Original file line number Diff line number Diff line change
Expand Up @@ -325,6 +325,8 @@ TSCM = class(TDataModule)
function Session_ID(): integer; // current session
function Session_IsLocked: Boolean; overload;// current session
function Session_IsLocked(aSessionID: integer): Boolean; overload;
// function Session_IsUnLocked: Boolean; overload;// current session
// function Session_IsUnLocked(aSessionID: integer): Boolean; overload;
function Session_Locate(SessionID: integer): Boolean;
function Session_Start(): TDateTime; overload;
function Session_Start(SessionID: integer): TDateTime; overload;
Expand Down Expand Up @@ -2923,28 +2925,52 @@ function TSCM.Session_ID: integer;

function TSCM.Session_IsLocked: Boolean;
begin
result := false;
result := true;
if not fSCMActive then exit;
if dsSession.DataSet.Active then
if not dsSession.DataSet.IsEmpty then
if (dsSession.DataSet.FieldByName('SessionStatusID').AsInteger = 2) then
result := true;
if (dsSession.DataSet.FieldByName('SessionStatusID').AsInteger <> 2) then
result := false;
end;

function TSCM.Session_IsLocked(aSessionID: integer): Boolean;
var
SQL: string;
v: variant;
begin
result := true;
if not fSCMActive then exit;
if (aSessionID = 0) then exit;
SQL := 'SELECT SessionStatusID FROM SwimClubMeet.dbo.Session ' +
'WHERE SessionID = :aID';
v := scmConnection.ExecSQLScalar(SQL, [aSessionID]);
if not VarIsNull(v) and not VarIsEmpty(v) and (v <> 2) then result := false;
end;
{
function TSCM.Session_IsUnLocked(aSessionID: integer): Boolean;
var
SQL: string;
v: variant;
begin
result := false;
if not fSCMActive then exit;
if (aSessionID = 0) then exit;
SQL := 'SELECT SessionStatusID FROM SwimClubMeet.dbo.Session ' +
'WHERE SessionID = :aID';
v := scmConnection.ExecSQLScalar(SQL, [aSessionID]);
if not VarIsNull(v) and not VarIsEmpty(v) and (v > 1) then result := true;
if not VarIsNull(v) and not VarIsEmpty(v) and (v <> 2) then result := true;
end;
function TSCM.Session_IsUnLocked: Boolean;
begin
result := false;
if fSCMActive then // we are connected
if dsSession.DataSet.Active then // table is active
if not dsSession.DataSet.IsEmpty then // we have sessions
if (dsSession.DataSet.FieldByName('SessionStatusID').AsInteger <> 2)
then result := true; // explicient not locked
end;
}
function TSCM.Session_Locate(SessionID: integer): Boolean;
var
SearchOptions: TLocateOptions;
Expand Down
Loading

0 comments on commit fdfde90

Please sign in to comment.