Close

Profile: MarkHancock

Avatar

User posts

11 years ago

Hi,

Thanks for the feedback, it worked perfectly. I actually never installed 2.65 so I did not need an upgrade, but I did originally copy the 2.65 folders there by mistake and instead of deleting like I should have I overwrote, so I just deleted and copied the new one now and is working great,

Thanks for the assistance :)

11 years ago

Hi, Ok I managed to "Fix" it by changing the page to the code below, I have a new problem now where I click on Details of the product and I get the follow error
Compiler Error Message: CS0103: The name 'widgetZone' does not exist in the current context
Source Error:

Line 214:    }
Line 215:</div>
Line 216:@Html.Widget(widgetZone = "productdetails_bottom")

Source File: c:\nopCommerce_2.70_Source\Presentation\Nop.Web\Themes\ShopAll\Views\Catalog\ProductTemplate.SingleVariant.cshtml    Line: 216

I will have a look at this a little later and see if can fix it as well.

Here is the fix for the First error. Please verify if my Fix is correct :) as I have only tested on a standard install. This is for the CategoryNavigation.cshtml file

@model CategoryNavigationModel
@using Nop.Web.Models.Catalog;
@helper RenderCategoryLine(CategoryNavigationModel.CategoryModel category)
{

    var categoryPadding = 15;

    <div class="block block-category-navigation">
        <div class="title">
            @T("Categories")
        </div>
        <div class="clear">
        </div>
        <div class="listbox">
            <ul>
                
                    <li class="@(category.Id == Model.CurrentCategoryId ? "active" : "inactive")"
                    @if (category.NumberOfParentCategories > 0)
                    {
                        if (this.ShouldUseRtlTheme())
                        {
                        <text>style="padding-right: @(category.NumberOfParentCategories * categoryPadding)px"</text>
                        }
                        else
                        {
                        <text>style="padding-left: @(category.NumberOfParentCategories * categoryPadding)px"</text>
                        }
                    }
                    ><a href="@Url.RouteUrl("Category", new { categoryId = category.Id, SeName = category.SeName })">@category.Name
                        @if (category.NumberOfProducts.HasValue)
                        {
                            <text> (@(category.NumberOfProducts.Value))</text>
                        }
                    </a></li>
                
            </ul>
        </div>
    </div>
}

11 years ago

Hi just to add to that,

I looked at the CategoryNavigationModel of NopCommerce and it does not seem to reference most of the fields as it complains about all.

namespace Nop.Web.Models.Catalog
{
    public partial class CategoryNavigationModel : BaseNopModel
    {
        public CategoryNavigationModel()
        {
            Categories = new List<CategoryModel>();
        }

        public int CurrentCategoryId { get; set; }
        public List<CategoryModel> Categories { get; set; }

        public class CategoryModel : BaseNopEntityModel
        {
            public CategoryModel()
            {
                SubCategories = new List<CategoryModel>();
            }

            public string Name { get; set; }

            public string SeName { get; set; }

            public int NumberOfParentCategories { get; set; }

            public int? NumberOfProducts { get; set; }

            public List<CategoryModel> SubCategories { get; set; }
        }
    }

Hope this helps

11 years ago

Hi there,

I seem to have a few errors and maybe its just me :). but when I install the them. Click on the Public Store it shows the home page fine. I then click on any many and I get the following errors.


Compilation Error
  Description: An error occurred during the compilation of a resource required to service this request. Please review the following specific error details and modify your source code appropriately.

Compiler Error Message: CS1061: 'Nop.Web.Models.Catalog.CategoryNavigationModel' does not contain a definition for 'IsActive' and no extension method 'IsActive' accepting a first argument of type 'Nop.Web.Models.Catalog.CategoryNavigationModel' could be found (are you missing a using directive or an assembly reference?)

Source Error:
Line 19:                 @foreach (var category in Model)
Line 20:                 {
Line 21:                     <li class="@(category.IsActive ? "active" : "inactive")"
Line 22:                     @if (category.NumberOfParentCategories > 0)
Line 23:                     {
  

Source File: c:\nopCommerce_2.70_Source\Presentation\Nop.Web\Themes\ShopAll\Views\Catalog\CategoryNavigation.cshtml    Line: 21


I also get errors trying to upload pictures to a slider created. Just says fail. The picture is the right size as followed by the installation guide.

I also noticed that if I try to add my slider to the widget I get a fail message as well?

I am sure it must be something I missed.

Please assist

Thanks very much