mirror of
https://github.com/gosticks/DefinitelyTyped.git
synced 2026-07-05 09:40:02 +00:00
updated angular-odata-resources definitions to have support count and inlinecount
This commit is contained in:
@@ -186,4 +186,14 @@ var combination2 = Predicate.and([combination1, predicate2]);
|
||||
|
||||
var predicate = new Predicate("FirstName", "John")
|
||||
.or(new Predicate("LastName", '!=', "Doe"))
|
||||
.and(new Predicate("Age", '>', 10));
|
||||
.and(new Predicate("Age", '>', 10));
|
||||
|
||||
|
||||
users = odataResourceClass.odata()
|
||||
.withInlineCount()
|
||||
.query();
|
||||
|
||||
|
||||
var countResult = odataResourceClass.odata().count();
|
||||
var total = countResult.result;
|
||||
|
||||
|
||||
@@ -264,6 +264,11 @@ declare module OData {
|
||||
(queryString: string, success: () => any, error: () => any): T[];
|
||||
(queryString: string, success: () => any, error: () => any, isSingleElement?: boolean, forceSingleElement?: boolean): T;
|
||||
}
|
||||
|
||||
interface ICountResult{
|
||||
result: number;
|
||||
}
|
||||
|
||||
class Provider<T> {
|
||||
private callback;
|
||||
private filters;
|
||||
@@ -281,6 +286,8 @@ declare module OData {
|
||||
single(success?: any, error?: any): T;
|
||||
get(data: any, success?: any, error?: any): T;
|
||||
expand(params: any, otherParam1?: any, otherParam2?: any, otherParam3?: any, otherParam4?: any, otherParam5?: any, otherParam6?: any, otherParam7?: any): Provider<T>;
|
||||
count(success?: (result: ICountResult) => any, error?: () => any);
|
||||
withInlineCount();
|
||||
}
|
||||
|
||||
interface ValueFactory {
|
||||
|
||||
Reference in New Issue
Block a user