2016年11月21日 星期一

filter by function 帶入自訂參數

javascript
====
$scope.filterFoods = function (detail) {
        return function (food ) {


html
====
ng-options="food.value as food.text for food in foods | filter:filterFoods(detail)"

Entity Framework 建立新物件並儲存後馬上取得關聯資料

使用 CreateProxy 建立物件,不要直接 new var newmodel = _contextXXX.CreateProxy<yyy>(); ... _contextXXX.yyy.Add(newmodel); await _contextXXX.SaveC...