Esempio n. 1
0
        public async Task <ServiceResult> UpdateLibrary(MaterialTypeViewModel entity)
        {
            var isUpdated = await materialTypeWriteRepository.UpdateMaterialType(entity);

            ServiceResult result = new ServiceResult();

            if (!isUpdated)
            {
                result.SetFailure("Error while material library.");
            }
            else
            {
                result.SetSuccess("Material updated successfully.");
            }
            return(result);
        }
Esempio n. 2
0
 protected virtual async Task <bool> UpdateMaterialType(MaterialTypeViewModel entity)
 {
     return(await materialTypeWriteRepository.UpdateMaterialType(entity));
 }