mirror of
https://github.com/danieleteti/delphimvcframework.git
synced 2024-11-15 15:55:54 +01:00
Renamed templatepro filter "query" to "fromquery"
Some checks failed
TOC Generator / TOC Generator (push) Has been cancelled
Some checks failed
TOC Generator / TOC Generator (push) Has been cancelled
This commit is contained in:
parent
f9d5850914
commit
bc065284f8
@ -79,7 +79,7 @@ begin
|
|||||||
end
|
end
|
||||||
else
|
else
|
||||||
begin
|
begin
|
||||||
if TDuckTypedList.CanBeWrappedAsList(aValue.AsObject, lWrappedList) then
|
if (aValue.AsObject <> nil) and TDuckTypedList.CanBeWrappedAsList(aValue.AsObject, lWrappedList) then
|
||||||
begin
|
begin
|
||||||
Result := lWrappedList.Count;
|
Result := lWrappedList.Count;
|
||||||
end
|
end
|
||||||
@ -176,7 +176,7 @@ begin
|
|||||||
end;
|
end;
|
||||||
lCompiledTemplate.AddFilter('json', DumpAsJSONString);
|
lCompiledTemplate.AddFilter('json', DumpAsJSONString);
|
||||||
lCompiledTemplate.AddFilter('count', GetDataSetOrObjectListCount);
|
lCompiledTemplate.AddFilter('count', GetDataSetOrObjectListCount);
|
||||||
lCompiledTemplate.AddFilter('query',
|
lCompiledTemplate.AddFilter('fromquery',
|
||||||
function (const aValue: TValue; const aParameters: TArray<string>): TValue
|
function (const aValue: TValue; const aParameters: TArray<string>): TValue
|
||||||
begin
|
begin
|
||||||
if Length(aParameters) = 1 then
|
if Length(aParameters) = 1 then
|
||||||
|
@ -923,6 +923,7 @@ type
|
|||||||
/// PageFragment ignore header and footer views
|
/// PageFragment ignore header and footer views
|
||||||
/// </summary>
|
/// </summary>
|
||||||
function Page(const AViewNames: TArray<string>; const UseCommonHeadersAndFooters: Boolean = True): string; overload; inline;
|
function Page(const AViewNames: TArray<string>; const UseCommonHeadersAndFooters: Boolean = True): string; overload; inline;
|
||||||
|
function Page(const AViewName: string; const UseCommonHeadersAndFooters: Boolean = True): string; overload; inline;
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Page calls GetRenderedView with sensible defaults.
|
/// Page calls GetRenderedView with sensible defaults.
|
||||||
@ -4392,6 +4393,11 @@ begin
|
|||||||
Result := GetRenderedView(AViewNames, JSONModel)
|
Result := GetRenderedView(AViewNames, JSONModel)
|
||||||
end;
|
end;
|
||||||
|
|
||||||
|
function TMVCController.Page(const AViewName: string; const UseCommonHeadersAndFooters: Boolean): string;
|
||||||
|
begin
|
||||||
|
Result := Page([AViewName], UseCommonHeadersAndFooters);
|
||||||
|
end;
|
||||||
|
|
||||||
function TMVCController.PageFragment(const AViewNames: TArray<string>;
|
function TMVCController.PageFragment(const AViewNames: TArray<string>;
|
||||||
const JSONModel: TJSONObject): string;
|
const JSONModel: TJSONObject): string;
|
||||||
begin
|
begin
|
||||||
|
Loading…
Reference in New Issue
Block a user