nopCommerce
  • Product
    • Store demo
    • Showcase
    • Features
    • Why for developers
    • Why for store owners
  • Downloads
    • Download nopCommerce
    • Marketplace
    • Translations
    • Copyright removal key
  • Support & services
    • Documentation
    • Community forums
    • Premium support services
    • Request a quote
    • Contact us
  • Partners
Back
  • Product
    • Store demo
    • Showcase
    • Features
    • Why for developers
    • Why for store owners
  • Downloads
    • Download nopCommerce
    • Marketplace
    • Translations
    • Copyright removal key
  • Support & services
    • Documentation
    • Community forums
    • Premium support services
    • Request a quote
    • Contact us
  • Partners
  • 0
    • Log in
    • Register
Get started

Profile: implexisIT

  • Profile Info
  • Latest Posts
implexisIT
Statistics
Germany
5
65
Friday, November 10, 2017 4:38 AM
Send private message
Nop 4.2 _httpContextAccessor.HttpContext Null Referance Exception when using PictureService in a Task
We have a background task that depends on _pictureService.GetPictureUrl method. In the method GetImagesPathUrl (which is called by GetThumbUrl) the _httpContextAccessor.HttpContext is NULL and throws an error. In 4.10 this method didn't exist and the shop path was handled by webHelper.GetStoreLocation(); I guess the Task doesn't have a  context, hence the exception.
5 months ago
nopCommerce 4.1: Bug in CategoryService Method GetCategoryBreadCrumb
currently the method doesn't work properly when allCategories List is provided.
1 year ago
nopCommerce 4.1: Bug in CategoryService Method GetCategoryBreadCrumb
Line number 760 looks like this:
  

category = allCategories != null ? allCategories.FirstOrDefault(c => c.Id == c.ParentCategoryId)
  

it must be like this:

category = allCategories != null ? allCategories.FirstOrDefault(c => c.Id == category.ParentCategoryId)


here is the current full code:

public virtual IList<Category> GetCategoryBreadCrumb(Category category, IList<Category> allCategories = null, bool showHidden = false)
        {
            if (category == null)
                throw new ArgumentNullException(nameof(category));

            var result = new List<Category>();

            //used to prevent circular references
            var alreadyProcessedCategoryIds = new List<int>();

            while (category != null && //not null
                !category.Deleted && //not deleted
                (showHidden || category.Published) && //published
                (showHidden || _aclService.Authorize(category)) && //ACL
                (showHidden || _storeMappingService.Authorize(category)) && //Store mapping
                !alreadyProcessedCategoryIds.Contains(category.Id)) //prevent circular references
            {
                result.Add(category);

                alreadyProcessedCategoryIds.Add(category.Id);

                category = allCategories != null ? allCategories.FirstOrDefault(c => c.Id == category.ParentCategoryId)
                    : this.GetCategoryById(category.ParentCategoryId);
            }
            result.Reverse();
            return result;
        }
1 year ago
installed plugins not updating as installed in list (/Admin/Plugin/List)
same here, doesnt work for me, doesnt work for my colleagues. You have to restart the application to see the plugin changes. The list in PluginManager.ReferencedPlugins isn't updated after a plugin is installed or uninstalled. I haven't investigated further, but we are not the only ones who have this issue.
1 year ago
How can I register a global action filter from my plugin in NopCommere 4.0
Nop-Templates.com wrote:
Hi timmit,

First you need to implement this interface in your plugin INopStartup and set the order to be some number bigger than 2000 for example so that it is called after the default nopCommerce ones.

....


Been looking for hours for this... Documentation update would be very much appreciated. Hope nopCommerce team sees this. The upgrade guide only tells you to look at the new implemntation, but not on how to actually use it in a plugin... Thanks for your input.
2 years ago
Product
  • Get started
  • Store demo
  • Showcase
  • Case studies
  • Features
  • Why for developers
  • Why for store owners
Download
  • Download nopCommerce
  • Marketplace
  • Translations
  • Release notes
  • Copyright removal key
  • License
Support & services
  • Documentation
  • Community forums
  • Premium support services
  • Request a quote
Community
  • Contribute
  • Certified developer program
  • MVP program
  • Blog
Partners
  • Solution partners
  • Technology partners
  • Recommended hosting
  • Become a partner
Company
  • Advertise with us
  • About us
  • Contact us
  • Facebook
  • Twitter
  • LinkedIn
  • YouTube
  • Instagram
Copyright © 2008-2019 nopCommerce. All rights reserved. Privacy policy