From 24ac6e50da797cc3372f67f346618be86b86c4d1 Mon Sep 17 00:00:00 2001
From: username@email.com <yzy2002yzy@163.com>
Date: 星期五, 21 十一月 2025 15:06:15 +0800
Subject: [PATCH] 提交
---
CY_ECommercePlatform/CY.WebForm/Pages/work/GongzuoneirongList.aspx.cs | 117 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
1 files changed, 117 insertions(+), 0 deletions(-)
diff --git a/CY_ECommercePlatform/CY.WebForm/Pages/work/GongzuoneirongList.aspx.cs b/CY_ECommercePlatform/CY.WebForm/Pages/work/GongzuoneirongList.aspx.cs
new file mode 100644
index 0000000..0ad2a1a
--- /dev/null
+++ b/CY_ECommercePlatform/CY.WebForm/Pages/work/GongzuoneirongList.aspx.cs
@@ -0,0 +1,117 @@
+锘縰sing System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Web;
+using System.Web.UI;
+using System.Web.UI.WebControls;
+using CY.BLL;
+using CY.BLL.Sys;
+using CY.Model;
+using CY.Infrastructure.Query;
+using CY.Infrastructure.Common;
+
+namespace CY.WebForm.Pages.work
+{
+ //鍚磋緣
+ //琛屾斂鐗╁搧绠$悊
+ public partial class GongzuoneirongList : BasePage
+ {
+
+ OA_GongzuoneirongBLL bll_OA_GongzuoneirongBLL = null;
+ OA_StaffBLL bll_OA_StaffBLL = null;
+
+ //鍒濆鍖�
+ public GongzuoneirongList()
+ {
+
+ bll_OA_GongzuoneirongBLL = new OA_GongzuoneirongBLL();
+ bll_OA_StaffBLL = new OA_StaffBLL();
+
+ }
+
+ //椤甸潰鍔犺浇
+ protected void Page_Load(object sender, EventArgs e)
+ {
+ UCPager1.AspNetPager.PageChanged += AspNetPager1_PageChanged;
+ if (!IsPostBack)
+ {
+ InitData();
+ BindList();
+ }
+ if (Request["delete"] != null)
+ {
+ OA_Gongzuoneirong model = bll_OA_GongzuoneirongBLL.GetModelByKeyid(Request["delete"].ToInt32());
+ if (model != null && model.Keyid != null)
+ {
+
+ bll_OA_GongzuoneirongBLL.DeleteModel(model);
+ JavaScript.MessageBox("鍒犻櫎鎴愬姛", this);
+ Response.Redirect("/Pages/work/GongzuoneirongList.aspx");
+ }
+ else
+ JavaScript.MessageBox("鍒犻櫎澶辫触", this);
+ }
+
+ if (Request["deleteKeyIds"] != null)
+ {
+ List<int> deleteKeyIdList = new List<int>();
+ string deleteKeyIds = Request["deleteKeyIds"].ToString().Trim(',');
+ string[] keyIdArry = deleteKeyIds.Split(',');
+ foreach (string keyId in keyIdArry)
+ {
+ OA_Gongzuoneirong model = bll_OA_GongzuoneirongBLL.GetModelByKeyid(keyId.ToInt32());
+ if (model.Keyid != null && model != null)
+ bll_OA_GongzuoneirongBLL.DeleteModel(model);
+ else
+ {
+ JavaScript.MessageBox("鍒犻櫎澶辫触", this);
+ return;
+ }
+ }
+ JavaScript.MessageBox("鍒犻櫎鎴愬姛", this);
+ Response.Redirect("/Pages/work/GongzuoneirongList.aspx");
+ }
+ }
+
+ //缁戝畾鍒嗙被
+ private void InitData()
+ {
+
+
+
+ this.selZerenren.DataSource = bll_OA_StaffBLL.SelectListByFirmId(CurrentUser.MemberId,null, null);
+ this.selZerenren.DataTextField = "Name";
+ this.selZerenren.DataValueField = "Keyid";
+ this.selZerenren.DataBind();
+ this.selZerenren.Items.Insert(0, new ListItem("鍏ㄩ儴", ""));
+ this.selZerenren.Value = "";
+
+ }
+
+ //缁戝畾鏁版嵁
+ private void BindList()
+ {
+ Pagination pa = new Pagination();
+ pa.PageSize = 50;
+ pa.PageIndex = UCPager1.AspNetPager.CurrentPageIndex;
+ var Gongzuoneirongs = bll_OA_GongzuoneirongBLL.SelectModelPage(pa, CurrentUser.MemberId, this.txtName.Value, this.selZerenren.Value.ToInt32());
+
+
+ this.RepClientList.DataSource = Gongzuoneirongs;
+ this.RepClientList.DataBind();
+ UCPager1.AspNetPager.RecordCount = pa.RecordCount;
+ }
+
+ //鍒嗛〉浜嬩欢
+ protected void AspNetPager1_PageChanged(object src, EventArgs e)
+ {
+ BindList();
+ }
+
+ //鏌ヨ浜嬩欢
+ protected void btn_Search_Click(object src, EventArgs e)
+ {
+ BindList();
+ }
+ }
+}
\ No newline at end of file
--
Gitblit v1.9.1