zoukankan      html  css  js  c++  java
  • 动软代码生成器生成model

    model

    <#@ template language="c#" HostSpecific="True" #>
    <#@ output extension= ".cs" #>
    <#
        TableHost host = (TableHost)(Host);
        host.Fieldlist.Sort(CodeCommon.CompareByintOrder);
    #>
    using System;
    using System.Collections.Generic;
    using System.Linq;
    using System.Text;
    using Chloe.Entity;
    namespace <#= host.NameSpace #><# if( host.Folder.Length > 0) {#>.<#= host.Folder #><# } #>
    {
        <# if( host.TableDescription.Length > 0) {#>
         //<#= host.TableDescription #>
        <# } #>
            public class <#= host.GetModelClass(host.TableName) #>
        {  
              <# foreach (ColumnInfo c in host.Fieldlist)
            { #>/// <summary>
            /// <#= string.IsNullOrEmpty(c.Description) ? c.ColumnName : c.Description #>
            /// </summary>
            public <#= CodeCommon.DbTypeToCS(c.TypeName) #> <#= c.ColumnName #> { get; set; }        
            <# } #>
        }
    }
    萌橙 你瞅啥?
  • 相关阅读:
    HTML框架
    HTML链接
    kzalloc 函数详解(转载)
    LCD接口(转载)
    S3C2440上RTC时钟驱动开发实例讲解(转载)
    PHP 真值与空值
    http chunked 理解
    c# 基础
    美式音标注意事项
    groovy 闭包
  • 原文地址:https://www.cnblogs.com/daimaxuejia/p/11598224.html
Copyright © 2011-2022 走看看