开发者

Domain Service Changeset on Update Call is Null?

开发者 https://www.devze.com 2023-03-11 06:13 出处:网络
I am working on a WPF project and have added a domain service which I have tied to my DataContext using EF. The problem is the \"Update\" on my domain service for my object \'Cat\' is returning a null

I am working on a WPF project and have added a domain service which I have tied to my DataContext using EF. The problem is the "Update" on my domain service for my object 'Cat' is returning a null changeset. The changeset in the following line is null when I click Save and I have changed a prop value on my view, for example, I changed the description of the Cat to something like 'Furry Cat' and this is set on the property if I hover on the currentCat and check the desc property???

    public void UpdateCat(Cat currentCat)
    {
        this.ObjectContext.Cats.AttachAsModified(currentCat, ChangeSet.GetOriginal(currentCat));
    }
开发者_Go百科

Is there something I am missing?Please help..

0

精彩评论

暂无评论...
验证码 换一张
取 消