Пример #1
0
        private void UpdateProvider(TProviderResource providerResource)
        {
            var providerDefinition = GetDefinition(providerResource);

            Validate(providerDefinition);

            _providerFactory.Update(providerDefinition);
        }
Пример #2
0
        private void UpdateProvider(TProviderResource providerResource)
        {
            var providerDefinition = GetDefinition(providerResource, false);

            Test(providerDefinition, false);

            _providerFactory.Update(providerDefinition);
        }
Пример #3
0
        private void UpdateProvider(TProviderResource providerResource)
        {
            var providerDefinition = GetDefinition(providerResource);

            if (providerDefinition.Enable)
            {
                Test(providerDefinition);
            }

            _providerFactory.Update(providerDefinition);
        }
Пример #4
0
        private void UpdateProvider(TProviderResource providerResource)
        {
            var providerDefinition = GetDefinition(providerResource, false);
            var forceSave          = Request.GetBooleanQueryParameter("forceSave");

            // Only test existing definitions if it is enabled and forceSave isn't set.
            if (providerDefinition.Enable && !forceSave)
            {
                Test(providerDefinition, false);
            }

            _providerFactory.Update(providerDefinition);
        }
Пример #5
0
        public ActionResult <TProviderResource> UpdateProvider(TProviderResource providerResource)
        {
            var providerDefinition = GetDefinition(providerResource, false);

            if (providerDefinition.Enable)
            {
                Test(providerDefinition, false);
            }

            _providerFactory.Update(providerDefinition);

            return(Accepted(providerResource.Id));
        }
Пример #6
0
        private void UpdateProvider(TProviderResource providerResource)
        {
            var providerDefinition = GetDefinition(providerResource, false);
            var existingDefinition = _providerFactory.Get(providerDefinition.Id);

            // Only test existing definitions if it was previously disabled
            if (providerDefinition.Enable && !existingDefinition.Enable)
            {
                Test(providerDefinition, false);
            }

            _providerFactory.Update(providerDefinition);
        }
Пример #7
0
        public ActionResult <TProviderResource> UpdateProvider(TProviderResource providerResource)
        {
            var providerDefinition = GetDefinition(providerResource, true, false, false);
            var forceSave          = Request.GetBooleanQueryParameter("forceSave");

            // Only test existing definitions if it is enabled and forceSave isn't set.
            if (providerDefinition.Enable && !forceSave)
            {
                Test(providerDefinition, false);
            }

            _providerFactory.Update(providerDefinition);

            return(Accepted(providerResource.Id));
        }
Пример #8
0
        public ActionResult <TProviderResource> UpdateProvider(TProviderResource providerResource)
        {
            var providerDefinition = GetDefinition(providerResource, false);
            var existingDefinition = _providerFactory.Get(providerDefinition.Id);

            // Only test existing definitions if it was previously disabled
            if (providerDefinition.Enable && !existingDefinition.Enable)
            {
                Test(providerDefinition, false);
            }

            _providerFactory.Update(providerDefinition);

            return(Accepted(providerResource.Id));
        }