ZhiYeJianKang_PeiXun/Song.Site/Manage/Sys/OrganizationIntro.aspx.cs
2025-02-20 15:41:53 +08:00

64 lines
1.7 KiB
C#

using System;
using System.Data;
using System.Configuration;
using System.Collections;
using System.Web;
using System.Web.Security;
using System.Web.UI;
using System.Web.UI.WebControls;
using System.Web.UI.WebControls.WebParts;
using System.Web.UI.HtmlControls;
using WeiSha.Common;
using Song.ServiceInterfaces;
using Song.Entities;
using WeiSha.WebControl;
namespace Song.Site.Manage.Sys
{
public partial class OrganizationIntro : Extend.CustomPage
{
protected void Page_Load(object sender, EventArgs e)
{
if (!this.IsPostBack)
{
fill();
}
}
/// <summary>
/// 设置初始界面
/// </summary>
private void fill()
{
Song.Entities.Organization org;
if (Extend.LoginState.Admin.IsSuperAdmin)
org = Business.Do<IOrganization>().OrganSingle(Extend.LoginState.Admin.CurrentUser.Org_ID);
else
org = Business.Do<IOrganization>().OrganCurrent();
if (org == null) return;
//单位介绍
tbIntro.Text = org.Org_Intro;
}
protected void BtnEnter_Click(object sender, EventArgs e)
{
try
{
Song.Entities.Organization org = Business.Do<IOrganization>().OrganCurrent();
if (org == null) return;
//单位介绍
org.Org_Intro = tbIntro.Text;
//
//保存
Business.Do<IOrganization>().OrganSave(org);
}
catch (Exception ex)
{
Message.ExceptionShow(ex);
}
}
}
}