HSE管理月报放开编辑

This commit is contained in:
2023-11-03 10:19:27 +08:00
parent 48a0808bfb
commit c3481e1314
5 changed files with 39 additions and 1 deletions
@@ -7,6 +7,7 @@ using System.Text;
using BLL;
using AspNet = System.Web.UI.WebControls;
using Newtonsoft.Json.Linq;
using FineUIPro.Web.DataShow;
namespace FineUIPro.Web.HSSE.Manager
{
@@ -97,6 +98,7 @@ namespace FineUIPro.Web.HSSE.Manager
protected void Grid1_RowDataBound(object sender, GridRowEventArgs e)
{
int cm = GetCurMonth();
var getProject = ProjectService.GetProjectByProjectId(CurrUser.LoginProjectId);
for (int i = 1; i <= 12; i++)
{
@@ -104,7 +106,7 @@ namespace FineUIPro.Web.HSSE.Manager
if (i != cm)
{
DateTime temp = DateTime.Parse(DateTime.Now.Year + "-" + i + "-10");
if (temp.AddMonths(1) < DateTime.Now)
if (temp.AddMonths(1) < DateTime.Now &&(!getProject.IsHSEReportEditable.HasValue || !getProject.IsHSEReportEditable.Value) )
{
string monthC = "Month" + i.ToString();
RenderField month = Grid1.FindColumn(monthC) as RenderField;