Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
K
KGOrders
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Cam Hayes
KGOrders
Commits
37788721
Commit
37788721
authored
Jan 30, 2025
by
Mac Stephens
Browse files
Options
Browse Files
Download
Plain Diff
Merge remote-tracking branch 'origin/mac3'
parents
6417f9f6
7c0f2fe8
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
8 changed files
with
47 additions
and
69 deletions
+47
-69
View.Orders.dfm
kgOrdersClient/View.Orders.dfm
+14
-12
View.Orders.html
kgOrdersClient/View.Orders.html
+5
-3
View.Orders.pas
kgOrdersClient/View.Orders.pas
+9
-8
View.Search.dfm
kgOrdersClient/View.Search.dfm
+16
-14
Lookup.ServiceImpl.pas
kgOrdersServer/Source/Lookup.ServiceImpl.pas
+0
-0
rOrders.pas
kgOrdersServer/Source/rOrders.pas
+2
-2
uLibrary.pas
kgOrdersServer/Source/uLibrary.pas
+0
-29
kgOrdersServer.ini
kgOrdersServer/kgOrdersServer.ini
+1
-1
No files found.
kgOrdersClient/View.Orders.dfm
View file @
37788721
...
...
@@ -24,18 +24,6 @@ object FViewOrders: TFViewOrders
HeightPercent = 100.000000000000000000
WidthPercent = 100.000000000000000000
end
object lblSearch: TWebLabel
Left = 594
Top = 116
Width = 47
Height = 13
Caption = 'Search = '
ElementID = 'lblsearch'
ElementFont = efCSS
HeightStyle = ssAuto
HeightPercent = 100.000000000000000000
WidthPercent = 100.000000000000000000
end
object btnAddOrder: TWebButton
Left = 59
Top = 79
...
...
@@ -340,6 +328,20 @@ object FViewOrders: TFViewOrders
DisplayText = 'Ship Done'
end>
end
object edtSearch: TWebEdit
Left = 428
Top = 110
Width = 121
Height = 22
ChildOrder = 10
ElementClassName = 'form-control'
ElementID = 'edtsearch'
ElementFont = efCSS
Enabled = False
HeightStyle = ssAuto
HeightPercent = 100.000000000000000000
WidthPercent = 100.000000000000000000
end
object XDataWebClient1: TXDataWebClient
Connection = DMConnection.ApiConnection
Left = 28
...
...
kgOrdersClient/View.Orders.html
View file @
37788721
...
...
@@ -36,11 +36,13 @@
<!-- Entries Label Section d-flex justify-content-between w-100 mt-2-->
<div
class=
"row"
>
<div
class=
"col
text-start
"
>
<div
class=
"col
-auto
"
>
<label
id=
"lblentries"
></label>
</div>
<div
class=
"col text-end"
>
<label
id=
"lblsearch"
></label>
</div>
<div
class=
"row"
>
<div
class=
"col-12"
>
<input
id=
"edtsearch"
type=
"text"
class=
"form-control"
style=
"width: 100%;"
/>
</div>
</div>
...
...
kgOrdersClient/View.Orders.pas
View file @
37788721
...
...
@@ -58,7 +58,7 @@ type
wdbtcOrders
:
TWebDBTableControl
;
wcbPageSize
:
TWebComboBox
;
wlcbOrderBy
:
TWebLookupComboBox
;
lblSearch
:
TWebLabel
;
edtSearch
:
TWebEdit
;
procedure
WebFormCreate
(
Sender
:
TObject
);
procedure
btnAddOrderClick
(
Sender
:
TObject
);
procedure
btnSearchClick
(
Sender
:
TObject
);
...
...
@@ -291,7 +291,7 @@ begin
orderType
:=
newform
.
wcbOrderType
.
Text
;
searchOptions
:=
generateSearchOptions
();
lblSearch
.
Caption
:=
searchOptions
;
edtSearch
.
Text
:=
searchOptions
;
getOrders
(
searchOptions
);
end
;
end
...
...
@@ -646,13 +646,13 @@ searchOptions: string;
begin
searchOptions
:=
'&pagenumber='
+
IntToStr
(
PageNumber
)
+
'&pagesize='
+
IntToStr
(
PageSize
)
+
'&orderby='
+
OrderBy
+
'&orderby='
+
OrderBy
;
//Status 1
'&filterType1='
+
filterType1
;
if
(
(
filterType1
<>
''
)
and
(
filterType1
<>
'NONE'
)
)
then
begin
searchOptions
:=
searchOptions
+
'&filterType1='
+
filterType1
+
'&null1='
+
BoolToStr
(
null1
);
if
(
not
(
null1
))
then
begin
...
...
@@ -664,11 +664,11 @@ begin
// Status2
searchOptions
:=
searchOptions
+
'&filterType2='
+
filterType2
;
if
(
(
filterType2
<>
''
)
and
(
filterType2
<>
'NONE'
)
)
then
begin
searchOptions
:=
searchOptions
+
'&null2='
+
BoolToStr
(
null2
);
searchOptions
:=
searchOptions
+
'&filterType2='
+
filterType2
+
'&null2='
+
BoolToStr
(
null2
);
if
(
not
(
null2
))
then
begin
searchOptions
:=
searchOptions
+
...
...
@@ -677,7 +677,8 @@ begin
end
;
end
;
if
(
(
orderType
<>
''
)
AND
(
orderType
<>
'ANY'
)
)
then
console
.
log
(
orderType
);
if
(
(
orderType
<>
''
)
AND
(
orderType
<>
'Any'
)
)
then
searchOptions
:=
searchOptions
+
'&orderType='
+
orderType
;
if
jobName
<>
''
then
...
...
kgOrdersClient/View.Search.dfm
View file @
37788721
...
...
@@ -40,7 +40,7 @@ object FSearch: TFSearch
WidthPercent = 100.000000000000000000
end
object lblStartDate1: TWebLabel
Left =
200
Left =
404
Top = 442
Width = 56
Height = 14
...
...
@@ -55,7 +55,7 @@ object FSearch: TFSearch
WidthPercent = 100.000000000000000000
end
object lblEndDate1: TWebLabel
Left =
384
Left =
588
Top = 442
Width = 47
Height = 14
...
...
@@ -100,8 +100,8 @@ object FSearch: TFSearch
WidthPercent = 100.000000000000000000
end
object lblStartDate2: TWebLabel
Left =
200
Top = 5
16
Left =
404
Top = 5
20
Width = 56
Height = 14
Caption = 'Start Date:'
...
...
@@ -115,8 +115,8 @@ object FSearch: TFSearch
WidthPercent = 100.000000000000000000
end
object lblEndDate2: TWebLabel
Left =
384
Top = 5
16
Left =
588
Top = 5
20
Width = 47
Height = 14
Caption = 'End Date'
...
...
@@ -277,6 +277,7 @@ object FSearch: TFSearch
ItemIndex = -1
Items.Strings = (
'NONE'
'ORDER DATE'
'PROOF DUE'
'PROOF DONE'
'ART DUE'
...
...
@@ -326,7 +327,7 @@ object FSearch: TFSearch
WidthPercent = 100.000000000000000000
end
object dtpStartDate1: TWebDateTimePicker
Left =
200
Left =
404
Top = 462
Width = 127
Height = 22
...
...
@@ -348,7 +349,7 @@ object FSearch: TFSearch
Text = ''
end
object dtpEndDate1: TWebDateTimePicker
Left =
384
Left =
588
Top = 462
Width = 135
Height = 22
...
...
@@ -370,7 +371,7 @@ object FSearch: TFSearch
Text = ''
end
object cbNull1: TWebCheckBox
Left =
566
Left =
188
Top = 462
Width = 185
Height = 22
...
...
@@ -409,6 +410,7 @@ object FSearch: TFSearch
ItemIndex = -1
Items.Strings = (
'NONE'
'ORDER DATE'
'PROOF DUE'
'PROOF DONE'
'ART DUE'
...
...
@@ -421,8 +423,8 @@ object FSearch: TFSearch
'SHIP DONE')
end
object dtpStartDate2: TWebDateTimePicker
Left =
200
Top = 5
36
Left =
404
Top = 5
40
Width = 127
Height = 22
HeightStyle = ssAuto
...
...
@@ -437,8 +439,8 @@ object FSearch: TFSearch
Text = ''
end
object dtpEndDate2: TWebDateTimePicker
Left =
384
Top = 5
36
Left =
588
Top = 5
40
Width = 135
Height = 22
HeightStyle = ssAuto
...
...
@@ -453,7 +455,7 @@ object FSearch: TFSearch
Text = ''
end
object cbNull2: TWebCheckBox
Left =
566
Left =
188
Top = 536
Width = 185
Height = 22
...
...
kgOrdersServer/Source/Lookup.ServiceImpl.pas
View file @
37788721
This diff is collapsed.
Click to expand it.
kgOrdersServer/Source/rOrders.pas
View file @
37788721
...
...
@@ -133,7 +133,7 @@ begin
colorList
:=
TJSONArray
(
colorObject
.
GetValue
(
'items'
));
result
:=
IntToStr
(
colorList
.
Count
);
finally
colorObject
.
Free
;
// Free TJSONObject to avoid leaks
colorObject
.
Free
;
end
;
end
;
end
;
...
...
@@ -161,7 +161,7 @@ begin
frxOrders
.
Export
(
frxPDFExport1
);
//frxOrders.ShowPreparedReport;
finally
frxOrders
.
Clear
;
// Clear
the report to avoid memory bloat
frxOrders
.
Clear
;
// Clears
the report to avoid memory bloat
end
;
Logger
.
Log
(
5
,
'PDF saved to: '
+
ReportFileName
);
...
...
kgOrdersServer/Source/uLibrary.pas
View file @
37788721
...
...
@@ -7,7 +7,6 @@ uses
procedure
LoadDatabaseSettings
(
uc
:
TUniConnection
;
iniFilename
:
string
);
procedure
DoQuery
(
uq
:
TUniQuery
;
sql
:
string
);
function
CalculateAge
(
const
dob
,
dt
:
TDateTime
):
Integer
;
implementation
...
...
@@ -39,33 +38,5 @@ begin
uq
.
Open
;
end
;
function
CalculateAge
(
const
dob
,
dt
:
TDateTime
):
Integer
;
var
age
:
Integer
;
y1
,
m1
,
d1
,
y2
,
m2
,
d2
:
Word
;
begin
Result
:=
0
;
if
dt
<
dob
then
Exit
;
DecodeDate
(
dob
,
y1
,
m1
,
d1
);
DecodeDate
(
dt
,
y2
,
m2
,
d2
);
age
:=
y2
-
y1
;
// Feb 29
//if ( (m1=2) and (d1=29) ) and ( not IsLeapYear(y2) ) then
// d1 := 28;
if
(
m1
=
2
)
and
(
d1
=
29
)
and
(
not
(
IsLeapYear
(
y2
)))
then
begin
m1
:=
3
;
d1
:=
1
;
end
;
if
(
m2
<
m1
)
or
((
m2
=
m1
)
and
(
d2
<
d1
))
then
Dec
(
age
);
Result
:=
age
end
;
end
.
kgOrdersServer/kgOrdersServer.ini
View file @
37788721
[Settings]
MemoLogLevel
=
4
FileLogLevel
=
5
LogFileNum
=
63
LogFileNum
=
90
webClientVersion
=
1.0.0
[Database]
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment