Example #1
0
        void DoSave(object parameter)
        {
            var ctl = parameter as ContentControl;
            var o   = ctl.Content as BaseObjDto;

            if (o.Id == 0)
            {
                BaseObj objNew = null;
                objNew = ObjFromDto(o, objNew);
                _bll.Add(objNew);
            }
            else
            {
                var objExisting = _bll.GetItemById(o.Id);
                ModuleAModule.TheMapper.Map(o, objExisting);
            }
            _bll.Flush();

            _bll = _container.Resolve <IBLL>(new ResolverOverride[]
            {
                new ParameterOverride("filePath", StoragePath)
            });
            var lst = _bll.GetFiltered("", 10, _currentOffset);

            PopulateFilteredList(lst);
        }