Webiant Logo Webiant Logo
  1. No results found.

    Try your search with a different keyword or use * as a wildcard.

StoreModel.cs

using System.ComponentModel.DataAnnotations;
using Microsoft.AspNetCore.Mvc.Rendering;
using Nop.Web.Framework.Models;
using Nop.Web.Framework.Mvc.ModelBinding;

namespace Nop.Web.Areas.Admin.Models.Stores;

/// 
/// Represents a store model
/// 
public partial record StoreModel : BaseNopEntityModel, ILocalizedModel
{
    #region Ctor

    public StoreModel()
    {
        Locales = new List();
        AvailableLanguages = new List();
    }

    #endregion

    #region Properties

    [NopResourceDisplayName("Admin.Configuration.Stores.Fields.Name")]
    public string Name { get; set; }

    [NopResourceDisplayName("Admin.Configuration.Stores.Fields.Url")]
    public string Url { get; set; }

    [NopResourceDisplayName("Admin.Configuration.Stores.Fields.SslEnabled")]
    public virtual bool SslEnabled { get; set; }

    [NopResourceDisplayName("Admin.Configuration.Stores.Fields.Hosts")]
    public string Hosts { get; set; }

    //default language
    [NopResourceDisplayName("Admin.Configuration.Stores.Fields.DefaultLanguage")]
    public int DefaultLanguageId { get; set; }

    public IList AvailableLanguages { get; set; }

    [NopResourceDisplayName("Admin.Configuration.Stores.Fields.DisplayOrder")]
    public int DisplayOrder { get; set; }

    [NopResourceDisplayName("Admin.Configuration.Stores.Fields.CompanyName")]
    public string CompanyName { get; set; }

    [NopResourceDisplayName("Admin.Configuration.Stores.Fields.CompanyAddress")]
    public string CompanyAddress { get; set; }

    [DataType(DataType.PhoneNumber)]
    [NopResourceDisplayName("Admin.Configuration.Stores.Fields.CompanyPhoneNumber")]
    public string CompanyPhoneNumber { get; set; }

    [NopResourceDisplayName("Admin.Configuration.Stores.Fields.CompanyVat")]
    public string CompanyVat { get; set; }

    [NopResourceDisplayName("Admin.Configuration.Stores.Fields.DefaultMetaKeywords")]
    public string DefaultMetaKeywords { get; set; }

    [NopResourceDisplayName("Admin.Configuration.Stores.Fields.DefaultMetaDescription")]
    public string DefaultMetaDescription { get; set; }

    [NopResourceDisplayName("Admin.Configuration.Stores.Fields.DefaultTitle")]
    public string DefaultTitle { get; set; }

    [NopResourceDisplayName("Admin.Configuration.Stores.Fields.HomepageTitle")]
    public string HomepageTitle { get; set; }

    [NopResourceDisplayName("Admin.Configuration.Stores.Fields.HomepageDescription")]
    public string HomepageDescription { get; set; }

    public IList Locales { get; set; }

    #endregion
}

public partial record StoreLocalizedModel : ILocalizedLocaleModel
{
    public int LanguageId { get; set; }

    [NopResourceDisplayName("Admin.Configuration.Stores.Fields.Name")]
    public string Name { get; set; }

    [NopResourceDisplayName("Admin.Configuration.Stores.Fields.DefaultMetaKeywords")]
    public string DefaultMetaKeywords { get; set; }

    [NopResourceDisplayName("Admin.Configuration.Stores.Fields.DefaultMetaDescription")]
    public string DefaultMetaDescription { get; set; }

    [NopResourceDisplayName("Admin.Configuration.Stores.Fields.DefaultTitle")]
    public string DefaultTitle { get; set; }

    [NopResourceDisplayName("Admin.Configuration.Stores.Fields.HomepageTitle")]
    public string HomepageTitle { get; set; }

    [NopResourceDisplayName("Admin.Configuration.Stores.Fields.HomepageDescription")]
    public string HomepageDescription { get; set; }
}