当前位置: 首页>>代码示例>>C#>>正文


C# Common.ContactUsModel类代码示例

本文整理汇总了C#中Nop.Web.Models.Common.ContactUsModel的典型用法代码示例。如果您正苦于以下问题:C# ContactUsModel类的具体用法?C# ContactUsModel怎么用?C# ContactUsModel使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。


ContactUsModel类属于Nop.Web.Models.Common命名空间,在下文中一共展示了ContactUsModel类的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。

示例1: Should_have_error_when_fullName_is_null_or_empty

 public void Should_have_error_when_fullName_is_null_or_empty()
 {
     var model = new ContactUsModel();
     model.FullName = null;
     _validator.ShouldHaveValidationErrorFor(x => x.FullName, model);
     model.FullName = "";
     _validator.ShouldHaveValidationErrorFor(x => x.FullName, model);
 }
开发者ID:jianghaihui,项目名称:nopCommerce,代码行数:8,代码来源:ContactUsValidatorTests.cs

示例2: Should_have_error_when_additional_comments_is_null_or_empty

 public void Should_have_error_when_additional_comments_is_null_or_empty()
 {
     var model = new ContactUsModel();
     model.AdditionalComments = null;
     _validator.ShouldHaveValidationErrorFor(x => x.AdditionalComments, model);
     model.AdditionalComments = "";
     _validator.ShouldHaveValidationErrorFor(x => x.AdditionalComments, model);
 }
开发者ID:aleks279,项目名称:atrend-test,代码行数:8,代码来源:ContactUsValidatorTests.cs

示例3: Should_have_error_when_buyer_email_is_null_or_empty

 public void Should_have_error_when_buyer_email_is_null_or_empty()
 {
     var model = new ContactUsModel();
     model.BuyerEmail = null;
     _validator.ShouldHaveValidationErrorFor(x => x.BuyerEmail, model);
     model.BuyerEmail = "";
     _validator.ShouldHaveValidationErrorFor(x => x.BuyerEmail, model);
 }
开发者ID:aleks279,项目名称:atrend-test,代码行数:8,代码来源:ContactUsValidatorTests.cs

示例4: Should_have_error_when_accounting_contact_is_null_or_empty

 public void Should_have_error_when_accounting_contact_is_null_or_empty()
 {
     var model = new ContactUsModel();
     model.AccountingContact = null;
     _validator.ShouldHaveValidationErrorFor(x => x.AccountingContact, model);
     model.AccountingContact = "";
     _validator.ShouldHaveValidationErrorFor(x => x.AccountingContact, model);
 }
开发者ID:aleks279,项目名称:atrend-test,代码行数:8,代码来源:ContactUsValidatorTests.cs

示例5: Should_have_error_when_business_address_is_null_or_empty

 public void Should_have_error_when_business_address_is_null_or_empty()
 {
     var model = new ContactUsModel();
     model.BusinessAddress = null;
     _validator.ShouldHaveValidationErrorFor(x => x.BusinessAddress, model);
     model.BusinessAddress = "";
     _validator.ShouldHaveValidationErrorFor(x => x.BusinessAddress, model);
 }
开发者ID:aleks279,项目名称:atrend-test,代码行数:8,代码来源:ContactUsValidatorTests.cs

示例6: Should_have_error_when_enquiry_is_null_or_empty

 public void Should_have_error_when_enquiry_is_null_or_empty()
 {
     var model = new ContactUsModel();
     model.Enquiry = null;
     _validator.ShouldHaveValidationErrorFor(x => x.Enquiry, model);
     model.Enquiry = "";
     _validator.ShouldHaveValidationErrorFor(x => x.Enquiry, model);
 }
开发者ID:jianghaihui,项目名称:nopCommerce,代码行数:8,代码来源:ContactUsValidatorTests.cs

示例7: Should_have_error_when_state_is_null_or_empty

 public void Should_have_error_when_state_is_null_or_empty()
 {
     var model = new ContactUsModel();
     model.StateProvince = null;
     _validator.ShouldHaveValidationErrorFor(x => x.StateProvince, model);
     model.StateProvince = "";
     _validator.ShouldHaveValidationErrorFor(x => x.StateProvince, model);
 }
开发者ID:aleks279,项目名称:atrend-test,代码行数:8,代码来源:ContactUsValidatorTests.cs

示例8: ContactUs

 public ActionResult ContactUs()
 {
     var model = new ContactUsModel()
     {
         Email = _workContext.CurrentCustomer.Email,
         FullName = _workContext.CurrentCustomer.GetFullName(),
         DisplayCaptcha = _captchaSettings.Enabled && _captchaSettings.ShowOnContactUsPage
     };
     return View(model);
 }
开发者ID:bane163,项目名称:nopcommerce-twilio-plugin,代码行数:10,代码来源:CommonController.cs

示例9: ContactUs

 //contact us page
 public ActionResult ContactUs()
 {
     var model = new ContactUsModel()
     {
         Email = _workContext.CurrentCustomer.Email,
         FullName = _workContext.CurrentCustomer.GetFullName()
     };
     return View(model);
 }
开发者ID:cmcginn,项目名称:StoreFront,代码行数:10,代码来源:CommonController.cs

示例10: Should_not_have_error_when_key_interest_is_specified

 public void Should_not_have_error_when_key_interest_is_specified()
 {
     var model = new ContactUsModel();
     model.KeyInterest = "Some key interest";
     _validator.ShouldNotHaveValidationErrorFor(x => x.KeyInterest, model);
 }
开发者ID:aleks279,项目名称:atrend-test,代码行数:6,代码来源:ContactUsValidatorTests.cs

示例11: Should_not_have_error_when_phonenumber_is_specified

 public void Should_not_have_error_when_phonenumber_is_specified()
 {
     var model = new ContactUsModel();
     model.BusinessPhoneNumber = "Texas";
     _validator.ShouldNotHaveValidationErrorFor(x => x.BusinessPhoneNumber, model);
 }
开发者ID:aleks279,项目名称:atrend-test,代码行数:6,代码来源:ContactUsValidatorTests.cs

示例12: Should_not_have_error_when_established_is_specified

 public void Should_not_have_error_when_established_is_specified()
 {
     var model = new ContactUsModel();
     model.Established = "something :|";
     _validator.ShouldNotHaveValidationErrorFor(x => x.Established, model);
 }
开发者ID:aleks279,项目名称:atrend-test,代码行数:6,代码来源:ContactUsValidatorTests.cs

示例13: Should_not_have_error_when_home_address_is_specified

 public void Should_not_have_error_when_home_address_is_specified()
 {
     var model = new ContactUsModel();
     model.BusinessAddress = "This is an address";
     _validator.ShouldNotHaveValidationErrorFor(x => x.HomeAddress, model);
 }
开发者ID:aleks279,项目名称:atrend-test,代码行数:6,代码来源:ContactUsValidatorTests.cs

示例14: Should_not_have_error_when_country_is_specified

 public void Should_not_have_error_when_country_is_specified()
 {
     var model = new ContactUsModel();
     model.Country = "Some country";
     _validator.ShouldNotHaveValidationErrorFor(x => x.Country, model);
 }
开发者ID:aleks279,项目名称:atrend-test,代码行数:6,代码来源:ContactUsValidatorTests.cs

示例15: Should_not_have_error_when_company_name_is_specified

 public void Should_not_have_error_when_company_name_is_specified()
 {
     var model = new ContactUsModel();
     model.CompanyName = "Company Co";
     _validator.ShouldNotHaveValidationErrorFor(x => x.CompanyName, model);
 }
开发者ID:aleks279,项目名称:atrend-test,代码行数:6,代码来源:ContactUsValidatorTests.cs


注:本文中的Nop.Web.Models.Common.ContactUsModel类示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。