migrate to new git
This commit is contained in:
70
web/admin/activity/index.aspx.cs
Normal file
70
web/admin/activity/index.aspx.cs
Normal file
@@ -0,0 +1,70 @@
|
||||
using System;
|
||||
using System.Collections;
|
||||
using System.Collections.Generic;
|
||||
using System.Data;
|
||||
using System.Data.OleDb;
|
||||
using System.Web;
|
||||
using System.Web.UI;
|
||||
using System.Web.UI.WebControls;
|
||||
using System.Configuration;
|
||||
using System.IO;
|
||||
using System.Linq;
|
||||
using static TreeView;
|
||||
|
||||
public partial class admin_activity_index : MyWeb.config
|
||||
{
|
||||
private Model.ezEntities _db = new Model.ezEntities();
|
||||
protected void Page_Load(object sender, EventArgs e)
|
||||
{
|
||||
|
||||
if (!IsPostBack)
|
||||
{
|
||||
|
||||
BuildKind();
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
#region 分類
|
||||
|
||||
|
||||
|
||||
public void BuildKind()
|
||||
{
|
||||
s_kind.Items.Clear();
|
||||
s_kind.Items.Add(new ListItem("", ""));
|
||||
|
||||
//buildMultiKind(s_kind, "activity_kind", 0, "", 1, Model.activity.KindLevelMax);
|
||||
var qry1 = new TreeView().get_data2(_db.activity_kind.Select(o => new TreeItem()
|
||||
{
|
||||
kind = o.kind,
|
||||
num = o.num,
|
||||
root = o.root,
|
||||
range = o.range,
|
||||
}).OrderBy(x => x.root).ThenBy(x => x.kind).ToList(), 0, 0);
|
||||
if (qry1.Count() > 0)
|
||||
foreach (var qq in qry1)
|
||||
s_kind.Items.Add(new ListItem(new TreeView().RptDash(qq.Level) + qq.kind, qq.num.ToString()));
|
||||
|
||||
|
||||
}
|
||||
|
||||
|
||||
#endregion
|
||||
|
||||
|
||||
|
||||
#region 匯出Excel
|
||||
|
||||
protected void excel_Click(object sender, EventArgs e)
|
||||
{
|
||||
//請參考訂單系統的匯出
|
||||
|
||||
}
|
||||
|
||||
|
||||
#endregion
|
||||
|
||||
|
||||
}
|
||||
Reference in New Issue
Block a user