<commit_before>﻿using System.ComponentModel.DataAnnotations;
using FluentNHibernate.Mapping;
using UCDArch.Core.DomainModel;

namespace Purchasing.Core.Domain
{
    public class Faq : DomainObject
    {
        [StringLength(50)]
        [Required]
        public virtual FaqCategory Category { get; set; }
        [Required]
        public virtual string Question { get; set; }
        [Required]
        [DataType(DataType.MultilineText)]
        public virtual string Answer { get; set; }
        [StringLength(10)]
        public virtual string OrgId { get; set; }
        public virtual int Like { get; set; }
    }

    public enum FaqCategory
    {
        General,
        Requester,
        Approver,
        ConditionalApprover,
        AccountManager,
        Purchaser
    }

    public class FaqMap : ClassMap<Faq>
    {
        public FaqMap()
        {
            Id(x => x.Id);

            Map(x => x.Category).Column("`Category`").CustomType(typeof(NHibernate.Type.EnumStringType<FaqCategory>)).Not.Nullable();
            Map(x => x.Question);
            Map(x => x.Answer);
            Map(x => x.OrgId);
            Map(x => x.Like);
        }
    }
}<commit_msg>Updated FAQ to alias reserved SQL ty pes and remove string validation from enum# Please enter the commit message for your changes. Lines starting<commit_after>﻿using System.ComponentModel.DataAnnotations;
using FluentNHibernate.Mapping;
using UCDArch.Core.DomainModel;

namespace Purchasing.Core.Domain
{
    public class Faq : DomainObject
    {
        [Required]
        public virtual FaqCategory Category { get; set; }
        [Required]
        public virtual string Question { get; set; }
        [Required]
        [DataType(DataType.MultilineText)]
        public virtual string Answer { get; set; }
        [StringLength(10)]
        public virtual string OrgId { get; set; }
        public virtual int Like { get; set; }
    }

    public enum FaqCategory
    {
        General,
        Requester,
        Approver,
        ConditionalApprover,
        AccountManager,
        Purchaser
    }

    public class FaqMap : ClassMap<Faq>
    {
        public FaqMap()
        {
            Id(x => x.Id);

            Map(x => x.Category).Column("`Category`").CustomType(typeof(NHibernate.Type.EnumStringType<FaqCategory>)).Not.Nullable();
            Map(x => x.Question);
            Map(x => x.Answer);
            Map(x => x.OrgId);
            Map(x => x.Like).Column("`Like`");
        }
    }
}
{'fraction_non_alphanumeric': 0.10625501202886929, 'fraction_numerical': 0.0024057738572574178, 'mean_word_length': 2.099378881987578, 'pattern_counts': {'":': 0, '<': 7, '<?xml version=': 0, '>': 19, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '5911033', 'n_tokens_mistral': 735, 'n_tokens_neox': 710, 'n_words': 172}