0

As mentioned in following document

Developing-Step-By-Step-Angular-DevExtreme-Using-GetPeople-Method-from-Angular

 this.dataSource = new CustomStore({
            key: "id",
            load: (loadOptions) => {
                return this._personService.getPeople("").toPromise();
            }
        });

the getPeople("") has no parameter. when I change it to getPeople(loadOptions) then I get null reference in DataSourceLoadOptions in Back-End. While testing I just ignored the generated proxy and sent it by http and now it works.

Is there something that I should do?

1 Answer 1

0

So, I am not an angular expert by any stretch. But I did find this code located here:

DevExtreme ASP.NET Zero Integration

in the Angular section, they had this code:

this.dataSource.store = new CustomStore({
        load(loadOptions: any) {
            var maxResultCount = loadOptions.take || 10;
            var skipCount = loadOptions.skip || 0;
            var sorting = '';

            if (loadOptions.sort) {
                sorting = loadOptions.sort[0].selector;
                if (loadOptions.sort[0].desc) {
                    sorting += ' desc';
                } else {
                    sorting += ' asc';
                }
            }

            return self._auditLogService.getAuditLogs(
                self.startDate,
                self.endDate,
                self.username,
                self.serviceName,
                self.methodName,

..........

Maybe this would help.

Good luck. Let us know how you resolved it!

--Dave

Sign up to request clarification or add additional context in comments.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.