医药CRM系统开发

自已做医药CRM系统有四年了,终于可以算个产品了,努力市场化,今年重种将医药营销的理念加入CRM

导航

生成求十二个月和的codesmith源代码

Posted on 2008-02-19 21:26  hhq80  阅读(239)  评论(0编辑  收藏  举报

<%--
Name:
Author:
Description:
--%>
<%@ CodeTemplate Language="C#" TargetLanguage="T-SQL" ResponseEncoding="UTF-8"   Src="" Inherits="" Debug="False" Description="Template description here." %>

<%for(int i=1;i<=13;i++){%>
private decimal _Totalsl<%=i%>;
<%}%>

   if(e.Item.ItemType==ListItemType.Item || e.Item.ItemType==ListItemType.AlternatingItem)
   {//相加
    
    
    <%for(int i=1;i<=13;i++){%>
    decimal sl<%=i%> = Convert.ToDecimal(e.Item.Cells[<%=i+5%>].Text);
                _Totalsl<%=i%> += sl<%=i%>;
    <%}%>
   }
   else if(e.Item.ItemType==ListItemType.Footer)
   {//总和
    e.Item.Cells[0].Text = "合计:";
                e.Item.Cells[0].HorizontalAlign = HorizontalAlign.Right;
                e.Item.Cells[0].CssClass = "ItemStyleRightBold";
    <%for(int i=1;i<=13;i++){%>
                e.Item.Cells[<%=i+5%>].Text = string.Format("{0:0.00}", _Totalsl<%=i%>);
                e.Item.Cells[<%=i+5%>].CssClass = "ItemStyleRightBold";
    <%}%>
   }