Example #1
0
        public SupplierInfoData RetrieveSupplierInfo(object supplierId)
        {
            SupplierInfoData result = null;

            RepositoryExceptionWrapper.Wrap(GetType(), () =>
            {
                ICriteria query = CurrentSession.CreateCriteria <SupplierInfoData>();

                query.AddExpressionEq <SupplierInfoData, object>(o => o.SupplierId, supplierId);

                result = query.UniqueResult <SupplierInfoData>();
            });

            return(result);
        }
        public IServiceQueryResult <SupplierInfoData> RetrieveSupplierInfo(object supplierId)
        {
            SupplierInfoData result = Repository.RetrieveSupplierInfo(supplierId);

            return(ServiceResultFactory.BuildServiceQueryResult <SupplierInfoData>(result));
        }