99 lines
1.9 KiB
C#
99 lines
1.9 KiB
C#
using System;
|
|
using DeiNiu.wms.Data.Model;
|
|
using System.Data;
|
|
namespace DeiNiu.wms.Logical
|
|
{
|
|
[Serializable]
|
|
public class LPublicNews
|
|
{
|
|
PublicNews _obj;
|
|
|
|
|
|
public LPublicNews()
|
|
{
|
|
|
|
Initialize();
|
|
}
|
|
|
|
public PublicNews GetPublicNews
|
|
{
|
|
get
|
|
{
|
|
return _obj;
|
|
}
|
|
}
|
|
|
|
/// <summary>
|
|
/// get all data
|
|
/// </summary>
|
|
public DataSet GetAllData()
|
|
{
|
|
return _obj.Query();
|
|
}
|
|
|
|
/// <summary>
|
|
/// get all data
|
|
/// </summary>
|
|
public DataSet GetAllActiveData()
|
|
{
|
|
return _obj.QueryActived();
|
|
}
|
|
|
|
|
|
/// <summary>
|
|
/// get a record by id
|
|
/// </summary>
|
|
public void Initialize(int id)
|
|
{
|
|
_obj = id != 0 ? new PublicNews(id) : new PublicNews();
|
|
}
|
|
|
|
/// <summary>
|
|
/// get a record by id 0
|
|
/// </summary>
|
|
public void Initialize()
|
|
{
|
|
Initialize(0);
|
|
}
|
|
|
|
/// <summary>
|
|
/// 查询公共新闻信息分类
|
|
/// </summary>
|
|
/// <returns></returns>
|
|
public DataTable QueryPublicInfomation()
|
|
{
|
|
return new Authority().QueryPublicInfomation();
|
|
}
|
|
/// <summary>
|
|
/// 查询公共新闻信息
|
|
/// </summary>
|
|
/// <returns></returns>
|
|
public DataTable QueryNews(int auth)
|
|
{
|
|
|
|
return _obj.QueryByAuth(auth);
|
|
}
|
|
/// <summary>
|
|
/// 返回顶级信息分类
|
|
/// </summary>
|
|
/// <returns></returns>
|
|
public DataTable QueryTopCatagory()
|
|
{
|
|
|
|
return _obj.QueryTopCatagory();
|
|
}
|
|
|
|
/// <summary>
|
|
/// 查询跑马灯
|
|
/// </summary>
|
|
/// <returns></returns>
|
|
public DataTable QueryMarqueen()
|
|
{
|
|
|
|
return _obj.QueryMarqueen();
|
|
}
|
|
}
|
|
|
|
|
|
}
|