修改WBS基础库内容

This commit is contained in:
高飞 2023-04-24 17:18:08 +08:00
parent e2076852e6
commit dbfd7086e1
29 changed files with 557 additions and 51 deletions

View File

@ -0,0 +1,28 @@
insert into [Base_CNProfessional] values
('13d9ee9a-e585-4b40-907a-91fefcfce370','DZ','µõ×°',12)
GO
insert into [Base_CNProfessional] values
('5111e93d-1e8c-4ffa-ade1-8ad7934c2871','JH','¼Æ»®',1)
GO
update [Base_CNProfessional] set SortIndex=6 where CNProfessionalId='BEFD0713-9BA2-4973-B0A8-7C54D41CCEC0'
GO
update [Base_CNProfessional] set SortIndex=9 where CNProfessionalId='CVDSFDSF-RFRE-CDDE-BFRE-DFVDFEFEW567'
GO
update [Base_CNProfessional] set SortIndex=5 where CNProfessionalId='DEB367FF-AD35-41A0-B68E-FA8E68737B93'
GO
insert into [Base_CNProfessional] values
('ee762383-15df-4612-8f44-e4bfb26b351d','HJ','º¸½Ó',10)
GO
update [Base_CNProfessional] set SortIndex=3,[ProfessionalName]='ÍÁ½¨' where CNProfessionalId='F41C5022-F499-4BD7-84B6-E87E4CE53CAC'
GO
delete from Base_CNProfessional where CNProfessionalId='13d9ee9a-e585-4b40-907a-91fefcfce370'
GO
delete from WBS_Breakdown
delete from WBS_Division
GO
alter table WBS_Division add SubItemType char(1) null
alter table WBS_Breakdown add CheckAcceptType char(1) null
GO
insert into WBS_Division select * from CNCEC_SUBQHSEDB..WBS_Division
insert into WBS_Breakdown select * from CNCEC_SUBQHSEDB..WBS_Breakdown
GO

View File

@ -0,0 +1,3 @@
--ADD BY GaoFei 2023-04-23
1、修改质量WBS库为集团QHSE平台版本内容
--END

View File

@ -260,6 +260,7 @@ namespace BLL
newBreakdownProject.YeZhu = breakdownProject.YeZhu;
newBreakdownProject.FenBao = breakdownProject.FenBao;
newBreakdownProject.SourceBreakdownId = breakdownProject.SourceBreakdownId;
newBreakdownProject.CheckAcceptType = breakdownProject.CheckAcceptType;
db.WBS_BreakdownProject.InsertOnSubmit(newBreakdownProject);
db.SubmitChanges();
@ -288,6 +289,7 @@ namespace BLL
newBreakdownProject.JianLi = breakdownProject.JianLi;
newBreakdownProject.YeZhu = breakdownProject.YeZhu;
newBreakdownProject.FenBao = breakdownProject.FenBao;
newBreakdownProject.CheckAcceptType = breakdownProject.CheckAcceptType;
db.SubmitChanges();
}

View File

@ -65,6 +65,7 @@ namespace BLL
x.WuHuan,
x.JianLi,
x.YeZhu,
x.CheckAcceptType,
CheckPointsDef = Funs.GetSubStr(x.CheckPoints, 15),
RecordAndCodeDef = Funs.GetSubStr(x.RecordAndCode, 15),
x.ModelURL
@ -107,6 +108,7 @@ namespace BLL
newBreakdown.WuHuan = breakdown.WuHuan;
newBreakdown.JianLi = breakdown.JianLi;
newBreakdown.YeZhu = breakdown.YeZhu;
newBreakdown.CheckAcceptType = breakdown.CheckAcceptType;
db.WBS_Breakdown.InsertOnSubmit(newBreakdown);
db.SubmitChanges();
@ -134,6 +136,7 @@ namespace BLL
newBreakdown.WuHuan = breakdown.WuHuan;
newBreakdown.JianLi = breakdown.JianLi;
newBreakdown.YeZhu = breakdown.YeZhu;
newBreakdown.CheckAcceptType = breakdown.CheckAcceptType;
db.SubmitChanges();
}

View File

@ -78,6 +78,7 @@ namespace BLL
newDivisionProject.CNProfessionalId = divisionProject.CNProfessionalId;
newDivisionProject.UnitWorkId = divisionProject.UnitWorkId;
newDivisionProject.OldDivisionId = divisionProject.OldDivisionId;
newDivisionProject.SubItemType = divisionProject.SubItemType;
db.WBS_DivisionProject.InsertOnSubmit(newDivisionProject);
db.SubmitChanges();
}
@ -96,6 +97,7 @@ namespace BLL
newDivisionProject.SuperDivisionId = divisionProject.SuperDivisionId;
newDivisionProject.CNProfessionalId = divisionProject.CNProfessionalId;
newDivisionProject.IsSelected = divisionProject.IsSelected;
newDivisionProject.SubItemType = divisionProject.SubItemType;
db.SubmitChanges();
}

View File

@ -75,6 +75,7 @@ namespace BLL
newDivision.SortIndex = division.SortIndex;
newDivision.SuperDivisionId = division.SuperDivisionId;
newDivision.CNProfessionalId = division.CNProfessionalId;
newDivision.SubItemType = division.SubItemType;
db.WBS_Division.InsertOnSubmit(newDivision);
db.SubmitChanges();
}
@ -92,6 +93,7 @@ namespace BLL
newDivision.SortIndex = division.SortIndex;
newDivision.SuperDivisionId = division.SuperDivisionId;
newDivision.CNProfessionalId = division.CNProfessionalId;
newDivision.SubItemType = division.SubItemType;
db.SubmitChanges();
}

View File

@ -472,5 +472,33 @@ namespace BLL
return list;
}
/// <summary>
/// 判断文件类型是否支持的预览
/// </summary>
/// <param name="FiletExtension"></param>
/// <returns></returns>
public static bool IsSupportFileType(string FiletExtension)
{
bool result = false;
List<String> list = new List<string>();
list.Add(".doc");
list.Add(".docx");
list.Add(".pdf");
list.Add(".txt");
list.Add(".xlsx");
list.Add(".xls");
foreach (var item in list)
{
if (item == FiletExtension)
{
result = true;
break;
}
}
return result;
}
}
}

View File

@ -0,0 +1,26 @@
<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="Look.aspx.cs" Inherits="FineUIPro.Web.AttachFile.Look" %>
<!DOCTYPE html>
<html xmlns="http://www.w3.org/1999/xhtml">
<head runat="server">
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title></title>
</head>
<body>
<form id="form1" runat="server">
<f:PageManager ID="PageManager1" AutoSizePanelID="TabStrip1" runat="server" />
<f:TabStrip ID="TabStrip1" IsFluid="true" ShowBorder="true" ActiveTabIndex="0"
runat="server">
<Tabs>
<f:Tab ID="Tab1" EnableIFrame="true"
Title="预览" runat="server">
</f:Tab>
</Tabs>
</f:TabStrip>
<f:Button ID="btnClose" EnablePostBack="false" ToolTip="关闭" hidden="true" Text="关闭" runat="server" Icon="SystemClose" Size="Medium">
</f:Button>
<iframe id="LookHtml" runat="server" width="700" height="600" name="LookHtml" hidden="hidden"></iframe>
</form>
</body>
</html>

View File

@ -0,0 +1,46 @@
using BLL;
using System;
using System.IO;
namespace FineUIPro.Web.AttachFile
{
public partial class Look : PageBase
{
protected void Page_Load(object sender, EventArgs e)
{
if (!IsPostBack)
{
this.btnClose.OnClientClick = ActiveWindow.GetHideReference();
var url = Request.Params["fileUrl"];
// var Baseurl = "https://view.officeapps.live.com/op/embed.aspx?src=";
var Baseurl = "https://view.xdocin.com/view?src=";
var Fileurl = Funs.SGGLUrl + url.Replace(Funs.RootPath, "");
var newurl = "";
var FiletExtension = Path.GetExtension(url);
if (FiletExtension == ".docx" || FiletExtension == ".doc"|| FiletExtension == ".xls" || FiletExtension == ".xlsx")
{
newurl = Baseurl + Fileurl;
}
else if (FiletExtension == ".txt"|| FiletExtension== "pdf")
{
newurl = Fileurl;
}
else
{
newurl = Fileurl;
}
this.LookHtml.Src = newurl;
this.Tab1.IFrameUrl = newurl;
//StreamReader fread = new StreamReader(url, System.Text.Encoding.GetEncoding("gb2312"));
//string ss = fread.ReadToEnd();
//Response.Write(ss);
//fread.Close();
//fread.Dispose();
}
}
}
}

View File

@ -0,0 +1,71 @@
//------------------------------------------------------------------------------
// <自动生成>
// 此代码由工具生成。
//
// 对此文件的更改可能导致不正确的行为,如果
// 重新生成代码,则所做更改将丢失。
// </自动生成>
//------------------------------------------------------------------------------
namespace FineUIPro.Web.AttachFile
{
public partial class Look
{
/// <summary>
/// form1 控件。
/// </summary>
/// <remarks>
/// 自动生成的字段。
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
/// </remarks>
protected global::System.Web.UI.HtmlControls.HtmlForm form1;
/// <summary>
/// PageManager1 控件。
/// </summary>
/// <remarks>
/// 自动生成的字段。
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
/// </remarks>
protected global::FineUIPro.PageManager PageManager1;
/// <summary>
/// TabStrip1 控件。
/// </summary>
/// <remarks>
/// 自动生成的字段。
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
/// </remarks>
protected global::FineUIPro.TabStrip TabStrip1;
/// <summary>
/// Tab1 控件。
/// </summary>
/// <remarks>
/// 自动生成的字段。
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
/// </remarks>
protected global::FineUIPro.Tab Tab1;
/// <summary>
/// btnClose 控件。
/// </summary>
/// <remarks>
/// 自动生成的字段。
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
/// </remarks>
protected global::FineUIPro.Button btnClose;
/// <summary>
/// LookHtml 控件。
/// </summary>
/// <remarks>
/// 自动生成的字段。
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
/// </remarks>
protected global::System.Web.UI.HtmlControls.HtmlIframe LookHtml;
}
}

View File

@ -1,5 +1,4 @@
<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="webuploader.aspx.cs" Inherits="FineUIPro.Web.AttachFile.webuploader" %>
<!DOCTYPE html>
<html>
<head runat="server">
@ -29,16 +28,17 @@
<Toolbars>
<f:Toolbar runat="server" ID="toolBar" Hidden="true" ToolbarAlign="Right">
<Items>
<f:Button ID="btnImageMagnify" runat="server" IconFont="Inbox" ToolTip="扫描文件" OnClick="btnImageMagnify_Click"></f:Button>
<f:Button ID="btnImageMagnify" runat="server" IconFont="Inbox" Text="扫描"
ToolTip="扫描文件" OnClick="btnImageMagnify_Click"></f:Button>
<f:ToolbarFill runat="server">
</f:ToolbarFill>
<f:Button ID="btnSelectFiles" ToolTip="选择文件上传" IconFont="Upload" runat="server" EnablePostBack="false">
<f:Button ID="btnSelectFiles" Text="上传" ToolTip="选择文件上传" IconFont="Upload" runat="server" EnablePostBack="false">
</f:Button>
<f:ToolbarSeparator runat="server"></f:ToolbarSeparator>
<f:Button ID="btnDelete" ToolTip="删除选中文件" IconFont="Trash" runat="server" OnClick="btnDelete_Click">
<f:Button ID="btnDelete" Text="删除" ToolTip="删除选中文件" IconFont="Trash" runat="server" OnClick="btnDelete_Click">
</f:Button>
<f:ToolbarSeparator ID="ToolbarSeparator2" runat="server"></f:ToolbarSeparator>
<f:Button ID="btnSave" ToolTip="保存" IconFont="Save" runat="server" OnClick="btnSave_Click">
<f:Button ID="btnSave" Text="保存" ToolTip="保存" IconFont="Save" runat="server" OnClick="btnSave_Click">
</f:Button>
</Items>
</f:Toolbar>
@ -48,7 +48,8 @@
ExpandUnusedSpace="True" CommandName="Attach" EnableAjax="false" />
<f:BoundField ColumnID="FileType" DataField="type" HeaderText="类型" Width="100px" />
<f:RenderField ColumnID="FileSize" DataField="size" HeaderText="大小" Renderer="FileSize" Width="90px" />
<f:BoundField ColumnID='FileStatus' DataField="status" NullDisplayText="已完成" HeaderText="状态" Width="90px" />
<f:BoundField ColumnID='FileStatus' DataField="status" NullDisplayText="已完成" HeaderText="状态" Width="90px" />
<f:LinkButtonField CommandName="Preview" Width="60px" Text="预览" />
<f:LinkButtonField Width="60px" ConfirmText="你确定要删除这个文件吗?" ConfirmTarget="Parent" Text="删除"
HeaderText="删除" CommandName="Delete" IconUrl="~/res/icon/delete.png" Hidden="true"/>
</Columns>
@ -57,7 +58,7 @@
本多附件上传支持的浏览器版本为Chrome、Firefox、Safari、IE10+ 。
<f:Window ID="Window1" Title="播放" Hidden="true" EnableIFrame="true" EnableMaximize="true"
Target="Parent" EnableResize="false" runat="server" IsModal="true"
Width="700px" Height="600px">
Width="1024px" Height="650px">
</f:Window>
</form>
<script src="res/webuploader/webuploader.nolog.js" type="text/javascript"></script>
@ -85,8 +86,8 @@
formData: {
owner: '<%= ParamStr%>'
},
// 单个文件大小限制单位byte这里限制为 500M
fileSingleSizeLimit: 500 * 1024 * 1024
// 单个文件大小限制单位byte这里限制为 800M
fileSingleSizeLimit: 6000 * 1024 * 1024
});

View File

@ -1,11 +1,11 @@
using System;
using BLL;
using Newtonsoft.Json.Linq;
using System;
using System.Collections.Generic;
using System.IO;
using System.Linq;
using BLL;
using Newtonsoft.Json.Linq;
using WIA;
using System.Collections.Generic;
using System.Text;
using WIA;
namespace FineUIPro.Web.AttachFile
{
@ -240,6 +240,7 @@ namespace FineUIPro.Web.AttachFile
/// <returns></returns>
private JArray SourceData()
{
if (Session[sessionName] == null && !string.IsNullOrEmpty(ToKeyId))
{
//Session[sessionName] = new JArray();
@ -334,7 +335,75 @@ namespace FineUIPro.Web.AttachFile
DeleteRow(e.RowID);
BindGrid();
}
if (e.CommandName == "Preview")
{
JArray source = GetSourceData();
for (int i = 0, count = source.Count; i < count; i++)
{
JObject item = source[i] as JObject;
if (item.Value<string>("id") == e.RowID)
{
try
{
string savedName = item.Value<string>("savedName");
string folder = item.Value<string>("folder");
string xnUrl = AttachPath + "\\" + savedName;
if (!string.IsNullOrEmpty(folder))
{
xnUrl = folder + savedName;
}
string url = Funs.RootPath + xnUrl;
if (savedName.Contains("FileUpLoad"))
{
url = Funs.RootPath + savedName.Replace('/', '\\');
}
FileInfo info = new FileInfo(url);
if (!info.Exists || string.IsNullOrEmpty(savedName))
{
url = Funs.RootPath + "Images//Null.jpg";
info = new FileInfo(url);
}
var FiletExtension = Path.GetExtension(savedName);
bool isSupportType = AttachFileService.IsSupportFileType(FiletExtension);
if (isSupportType)
{
PageContext.RegisterStartupScript(Window1.GetShowReference(String.Format("../AttachFile/Look.aspx?fileUrl={0}", url, "查看 -")));
}
else
{
ShowNotify("不支持预览", MessageBoxIcon.Warning);
}
//if (FiletExtension == ".docx" || FiletExtension == ".pdf")
//{
// string httpUrl = BLL.AsposeWordHelper.WordToHtml(url);
// PageContext.RegisterStartupScript(Window1.GetShowReference(String.Format("../AttachFile/Look.aspx?fileUrl={0}", httpUrl, "查看 -")));
//}
//else if (FiletExtension == ".txt")
//{
// PageContext.RegisterStartupScript(Window1.GetShowReference(String.Format("../AttachFile/Look.aspx?fileUrl={0}", url, "查看 -")));
//}
//else if (FiletExtension == ".xls")
//{
// string httpUrl = BLL.AsposeWordHelper.PriviewExcel(url);
// PageContext.RegisterStartupScript(Window1.GetShowReference(String.Format("../AttachFile/Look.aspx?fileUrl={0}", httpUrl, "查看 -")));
//}
//else
//{
// ShowNotify("不支持预览", MessageBoxIcon.Warning);
//}
}
catch (Exception)
{
}
}
}
}
if (e.CommandName == "Attach")
{
JArray source = GetSourceData();
@ -393,7 +462,7 @@ namespace FineUIPro.Web.AttachFile
}
}
}
catch (Exception)
catch (Exception ex)
{
}

View File

@ -55,8 +55,8 @@ namespace FineUIPro.Web.CQMS.WBS
this.trWBS.EnableSingleClickExpand = true;
TreeNode newNode1 = new TreeNode();
newNode1.Text = "建筑工程";
newNode1.NodeID = Const.CNProfessionalConstructId;
newNode1.CommandName = "CNProfessional";
newNode1.NodeID = "1";
newNode1.CommandName = "ProjectType";
newNode1.EnableExpandEvent = true;
newNode1.EnableClickEvent = true;
trWBS.Nodes.Add(newNode1);
@ -93,22 +93,45 @@ namespace FineUIPro.Web.CQMS.WBS
e.Node.Nodes.Clear();
if (e.Node.CommandName == "ProjectType") //展开工程类型
{
var cNProfessional = (from x in BLL.Funs.DB.Base_CNProfessional where x.CNProfessionalId != Const.CNProfessionalConstructId && x.CNProfessionalId != Const.CNProfessionalCVId orderby x.SortIndex select x).ToList();
foreach (var c in cNProfessional)
if (e.NodeID == "1")
{
TreeNode newCNProfessionalNode = new TreeNode();
newCNProfessionalNode.Text = c.ProfessionalName;
newCNProfessionalNode.NodeID = c.CNProfessionalId;
newCNProfessionalNode.CommandName = "CNProfessional";
newCNProfessionalNode.EnableExpandEvent = true;
newCNProfessionalNode.EnableClickEvent = true;
e.Node.Nodes.Add(newCNProfessionalNode);
TreeNode tempNode = new TreeNode();
tempNode.NodeID = "";
tempNode.Text = "";
tempNode.EnableExpandEvent = true;
tempNode.EnableClickEvent = true;
newCNProfessionalNode.Nodes.Add(tempNode);
var cNProfessional = (from x in BLL.Funs.DB.Base_CNProfessional where x.CNProfessionalId == Const.CNProfessionalCVId orderby x.SortIndex select x).ToList();
foreach (var c in cNProfessional)
{
TreeNode newCNProfessionalNode = new TreeNode();
newCNProfessionalNode.Text = c.ProfessionalName;
newCNProfessionalNode.NodeID = c.CNProfessionalId;
newCNProfessionalNode.CommandName = "CNProfessional";
newCNProfessionalNode.EnableExpandEvent = true;
newCNProfessionalNode.EnableClickEvent = true;
e.Node.Nodes.Add(newCNProfessionalNode);
TreeNode tempNode = new TreeNode();
tempNode.NodeID = "";
tempNode.Text = "";
tempNode.EnableExpandEvent = true;
tempNode.EnableClickEvent = true;
newCNProfessionalNode.Nodes.Add(tempNode);
}
}
else
{
var cNProfessional = (from x in BLL.Funs.DB.Base_CNProfessional where x.CNProfessionalId != Const.CNProfessionalConstructId && x.CNProfessionalId != Const.CNProfessionalCVId orderby x.SortIndex select x).ToList();
foreach (var c in cNProfessional)
{
TreeNode newCNProfessionalNode = new TreeNode();
newCNProfessionalNode.Text = c.ProfessionalName;
newCNProfessionalNode.NodeID = c.CNProfessionalId;
newCNProfessionalNode.CommandName = "CNProfessional";
newCNProfessionalNode.EnableExpandEvent = true;
newCNProfessionalNode.EnableClickEvent = true;
e.Node.Nodes.Add(newCNProfessionalNode);
TreeNode tempNode = new TreeNode();
tempNode.NodeID = "";
tempNode.Text = "";
tempNode.EnableExpandEvent = true;
tempNode.EnableClickEvent = true;
newCNProfessionalNode.Nodes.Add(tempNode);
}
}
}
else if (e.Node.CommandName == "CNProfessional") //展开专业

View File

@ -42,6 +42,17 @@
<Items>
<f:TextBox ID="txtClass" runat="server" Label="控制等级" LabelWidth="180px"></f:TextBox>
</Items>
</f:FormRow>
<f:FormRow>
<Items>
<f:DropDownList runat="server" ID="drpCheckAcceptType" Label="验收类型" LabelWidth="180px">
<f:ListItem Value="1" Text="关键工序验收" />
<f:ListItem Value="2" Text="特殊过程验收" />
<f:ListItem Value="3" Text="隐蔽工程验收" />
<f:ListItem Value="4" Text="单位工程一次验收" />
<f:ListItem Value="5" Text="材料进场复验" />
</f:DropDownList>
</Items>
</f:FormRow>
<f:FormRow runat="server" ID="tr1">
<Items>

View File

@ -33,6 +33,7 @@ namespace FineUIPro.Web.CQMS.WBS
{
string divisionId = Request.Params["divisionId"];
BreakdownId = Request.Params["breakdownId"];
Funs.FineUIPleaseSelect(this.drpCheckAcceptType);
Model.WBS_Breakdown breakdown = BLL.BreakdownService.GetBreakdownById(BreakdownId);
var division = BLL.DivisionService.GetDivisionById(divisionId);
if (division != null)
@ -77,6 +78,10 @@ namespace FineUIPro.Web.CQMS.WBS
{
this.txtSortIndex.Text = breakdown.SortIndex.ToString();
}
if (!string.IsNullOrEmpty(breakdown.CheckAcceptType))
{
this.drpCheckAcceptType.SelectedValue = breakdown.CheckAcceptType;
}
this.txtRemark.Text = breakdown.Remark;
}
}
@ -103,6 +108,10 @@ namespace FineUIPro.Web.CQMS.WBS
newBreakdown.WuHuan = this.WuHuan.Text.Trim();
newBreakdown.JianLi = this.JianLi.Text.Trim();
newBreakdown.YeZhu = this.YeZhu.Text.Trim();
if (this.drpCheckAcceptType.SelectedValue != BLL.Const._Null)
{
newBreakdown.CheckAcceptType = this.drpCheckAcceptType.SelectedValue;
}
if (!string.IsNullOrEmpty(this.txtSortIndex.Text.Trim()))
{
try

View File

@ -93,6 +93,15 @@ namespace FineUIPro.Web.CQMS.WBS {
/// </remarks>
protected global::FineUIPro.TextBox txtClass;
/// <summary>
/// drpCheckAcceptType 控件。
/// </summary>
/// <remarks>
/// 自动生成的字段。
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
/// </remarks>
protected global::FineUIPro.DropDownList drpCheckAcceptType;
/// <summary>
/// tr1 控件。
/// </summary>

View File

@ -42,6 +42,17 @@
<Items>
<f:TextBox ID="txtClass" runat="server" Label="控制等级" LabelWidth="180px"></f:TextBox>
</Items>
</f:FormRow>
<f:FormRow>
<Items>
<f:DropDownList runat="server" ID="drpCheckAcceptType" Label="验收类型" LabelWidth="180px">
<f:ListItem Value="1" Text="关键工序验收" />
<f:ListItem Value="2" Text="特殊过程验收" />
<f:ListItem Value="3" Text="隐蔽工程验收" />
<f:ListItem Value="4" Text="单位工程一次验收" />
<f:ListItem Value="5" Text="材料进场复验" />
</f:DropDownList>
</Items>
</f:FormRow>
<f:FormRow runat="server" ID="tr1">
<Items>

View File

@ -33,6 +33,7 @@ namespace FineUIPro.Web.CQMS.WBS
{
string divisionProjectId = Request.Params["divisionProjectId"];
BreakdownProjectId = Request.Params["breakdownProjectId"];
Funs.FineUIPleaseSelect(this.drpCheckAcceptType);
Model.WBS_BreakdownProject breakdownProject = BLL.BreakdownProjectService.GetBreakdownProjectById(BreakdownProjectId);
var division = BLL.DivisionProjectService.GetDivisionProjectById(divisionProjectId);
if (division != null)
@ -73,6 +74,10 @@ namespace FineUIPro.Web.CQMS.WBS
this.JianLi.Text = breakdownProject.JianLi;
this.WuHuan.Text = breakdownProject.WuHuan;
this.FenBao.Text = breakdownProject.FenBao;
if (!string.IsNullOrEmpty(breakdownProject.CheckAcceptType))
{
this.drpCheckAcceptType.SelectedValue = breakdownProject.CheckAcceptType;
}
if (breakdownProject.SortIndex != null)
{
this.txtSortIndex.Text = breakdownProject.SortIndex.ToString();
@ -103,6 +108,10 @@ namespace FineUIPro.Web.CQMS.WBS
newBreakdown.WuHuan = this.WuHuan.Text.Trim();
newBreakdown.JianLi = this.JianLi.Text.Trim();
newBreakdown.YeZhu = this.YeZhu.Text.Trim();
if (this.drpCheckAcceptType.SelectedValue != BLL.Const._Null)
{
newBreakdown.CheckAcceptType = this.drpCheckAcceptType.SelectedValue;
}
if (!string.IsNullOrEmpty(this.txtSortIndex.Text.Trim()))
{
try

View File

@ -93,6 +93,15 @@ namespace FineUIPro.Web.CQMS.WBS {
/// </remarks>
protected global::FineUIPro.TextBox txtClass;
/// <summary>
/// drpCheckAcceptType 控件。
/// </summary>
/// <remarks>
/// 自动生成的字段。
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
/// </remarks>
protected global::FineUIPro.DropDownList drpCheckAcceptType;
/// <summary>
/// tr1 控件。
/// </summary>

View File

@ -23,6 +23,16 @@
<f:TextBox ID="txtDivisionCode" runat="server" Label="序号" LabelWidth="130px" ></f:TextBox>
</Items>
</f:FormRow>
<f:FormRow>
<Items>
<f:DropDownList runat="server" ID="drpSubItemType" Label="分部分项类型" LabelWidth="130px">
<f:ListItem Value="1" Text="分部" />
<f:ListItem Value="2" Text="子分部" />
<f:ListItem Value="3" Text="分项" />
<f:ListItem Value="4" Text="子分项" />
</f:DropDownList>
</Items>
</f:FormRow>
<f:FormRow>
<Items>
<f:NumberBox ID="txtSortIndex" runat="server" Label="排序" LabelWidth="130px" NoDecimal="true" NoNegative="true"></f:NumberBox>

View File

@ -30,6 +30,7 @@ namespace FineUIPro.Web.CQMS.WBS
if (!IsPostBack)
{
string selectedCode = Request.Params["selectedCode"];
Funs.FineUIPleaseSelect(this.drpSubItemType);
if (Request.Params["type"] == "add")
{
Model.Base_CNProfessional cNProfessional = BLL.CNProfessionalService.GetCNProfessional(selectedCode);
@ -50,6 +51,10 @@ namespace FineUIPro.Web.CQMS.WBS
Model.WBS_Division divisionProject = BLL.DivisionService.GetDivisionById(selectedCode);
this.txtDivisionCode.Text = divisionProject.DivisionCode;
this.txtDivisionName.Text = divisionProject.DivisionName;
if (!string.IsNullOrEmpty(divisionProject.SubItemType))
{
this.drpSubItemType.SelectedValue = divisionProject.SubItemType;
}
if (divisionProject.SortIndex != null)
{
this.txtSortIndex.Text = divisionProject.SortIndex.ToString();
@ -65,6 +70,11 @@ namespace FineUIPro.Web.CQMS.WBS
/// <param name="e"></param>
protected void btnSave_Click(object sender, EventArgs e)
{
if (this.drpSubItemType.SelectedValue == BLL.Const._Null)
{
ShowNotify("请选择分部分项类型!", MessageBoxIcon.Warning);
return;
}
if (!string.IsNullOrEmpty(this.txtDivisionName.Text.Trim()))
{
string selectedCode = Request.Params["selectedCode"];
@ -75,6 +85,7 @@ namespace FineUIPro.Web.CQMS.WBS
Model.WBS_Division newDivision = new Model.WBS_Division();
newDivision.DivisionCode = this.txtDivisionCode.Text.Trim();
newDivision.DivisionName = this.txtDivisionName.Text.Trim();
newDivision.SubItemType = this.drpSubItemType.SelectedValue;
if (!string.IsNullOrEmpty(this.txtSortIndex.Text.Trim()))
{
try
@ -109,6 +120,7 @@ namespace FineUIPro.Web.CQMS.WBS
{
divisionProject.DivisionCode = this.txtDivisionCode.Text.Trim();
divisionProject.DivisionName = this.txtDivisionName.Text.Trim();
divisionProject.SubItemType = this.drpSubItemType.SelectedValue;
if (!string.IsNullOrEmpty(this.txtSortIndex.Text.Trim()))
{
divisionProject.SortIndex = Convert.ToInt32(this.txtSortIndex.Text.Trim());

View File

@ -57,6 +57,15 @@ namespace FineUIPro.Web.CQMS.WBS {
/// </remarks>
protected global::FineUIPro.TextBox txtDivisionCode;
/// <summary>
/// drpSubItemType 控件。
/// </summary>
/// <remarks>
/// 自动生成的字段。
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
/// </remarks>
protected global::FineUIPro.DropDownList drpSubItemType;
/// <summary>
/// txtSortIndex 控件。
/// </summary>

View File

@ -23,6 +23,16 @@
<f:TextBox ID="txtDivisionCode" runat="server" Label="序号" LabelWidth="130px" ></f:TextBox>
</Items>
</f:FormRow>
<f:FormRow>
<Items>
<f:DropDownList runat="server" ID="drpSubItemType" Label="分部分项类型" LabelWidth="130px">
<f:ListItem Value="1" Text="分部" />
<f:ListItem Value="2" Text="子分部" />
<f:ListItem Value="3" Text="分项" />
<f:ListItem Value="4" Text="子分项" />
</f:DropDownList>
</Items>
</f:FormRow>
<f:FormRow>
<Items>
<f:NumberBox ID="txtSortIndex" runat="server" Label="排序" LabelWidth="130px" NoDecimal="true" NoNegative="true"></f:NumberBox>

View File

@ -30,6 +30,7 @@ namespace FineUIPro.Web.CQMS.WBS
if (!IsPostBack)
{
string selectedCode = Request.Params["selectedCode"];
Funs.FineUIPleaseSelect(this.drpSubItemType);
if (Request.Params["type"] == "add")
{
Model.Base_CNProfessional cNProfessional = BLL.CNProfessionalService.GetCNProfessional(selectedCode);
@ -51,6 +52,10 @@ namespace FineUIPro.Web.CQMS.WBS
Model.WBS_DivisionProject divisionProject = BLL.DivisionProjectService.GetDivisionProjectById(selectedCode);
this.txtDivisionCode.Text = divisionProject.DivisionCode;
this.txtDivisionName.Text = divisionProject.DivisionName;
if (!string.IsNullOrEmpty(divisionProject.SubItemType))
{
this.drpSubItemType.SelectedValue = divisionProject.SubItemType;
}
if (divisionProject.SortIndex != null)
{
this.txtSortIndex.Text = divisionProject.SortIndex.ToString();
@ -66,6 +71,11 @@ namespace FineUIPro.Web.CQMS.WBS
/// <param name="e"></param>
protected void btnSave_Click(object sender, EventArgs e)
{
if (this.drpSubItemType.SelectedValue == BLL.Const._Null)
{
ShowNotify("请选择分部分项类型!", MessageBoxIcon.Warning);
return;
}
if (!string.IsNullOrEmpty(this.txtDivisionName.Text.Trim()))
{
string selectedCode = Request.Params["selectedCode"];
@ -77,6 +87,7 @@ namespace FineUIPro.Web.CQMS.WBS
newDivisionProject.DivisionCode = this.txtDivisionCode.Text.Trim();
newDivisionProject.DivisionName = this.txtDivisionName.Text.Trim();
newDivisionProject.UnitWorkId = Request.Params["unitWorkId"];
newDivisionProject.SubItemType = this.drpSubItemType.SelectedValue;
if (!string.IsNullOrEmpty(this.txtSortIndex.Text.Trim()))
{
try
@ -112,6 +123,7 @@ namespace FineUIPro.Web.CQMS.WBS
{
divisionProject.DivisionCode = this.txtDivisionCode.Text.Trim();
divisionProject.DivisionName = this.txtDivisionName.Text.Trim();
divisionProject.SubItemType = this.drpSubItemType.SelectedValue;
if (!string.IsNullOrEmpty(this.txtSortIndex.Text.Trim()))
{
divisionProject.SortIndex = Convert.ToInt32(this.txtSortIndex.Text.Trim());

View File

@ -57,6 +57,15 @@ namespace FineUIPro.Web.CQMS.WBS {
/// </remarks>
protected global::FineUIPro.TextBox txtDivisionCode;
/// <summary>
/// drpSubItemType 控件。
/// </summary>
/// <remarks>
/// 自动生成的字段。
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
/// </remarks>
protected global::FineUIPro.DropDownList drpSubItemType;
/// <summary>
/// txtSortIndex 控件。
/// </summary>

View File

@ -115,8 +115,8 @@ namespace FineUIPro.Web.CQMS.WBS
{
TreeNode newNode1 = new TreeNode();
newNode1.Text = "建筑工程";
newNode1.NodeID = e.NodeID + "|" + Const.CNProfessionalConstructId;
newNode1.CommandName = "CNProfessional";
newNode1.NodeID = e.NodeID + "|" + "1";
newNode1.CommandName = "ProjectType";
newNode1.EnableExpandEvent = true;
newNode1.EnableClickEvent = true;
e.Node.Nodes.Add(newNode1);
@ -142,22 +142,45 @@ namespace FineUIPro.Web.CQMS.WBS
}
else if (e.Node.CommandName == "ProjectType") //展开工程类型
{
var cNProfessional = (from x in BLL.Funs.DB.Base_CNProfessional where x.CNProfessionalId != Const.CNProfessionalConstructId && x.CNProfessionalId != Const.CNProfessionalCVId orderby x.SortIndex select x).ToList();
foreach (var c in cNProfessional)
if (e.NodeID.Split('|')[1] == "1")
{
TreeNode newCNProfessionalNode = new TreeNode();
newCNProfessionalNode.Text = c.ProfessionalName;
newCNProfessionalNode.NodeID = e.NodeID.Split('|')[0] + "|" + c.CNProfessionalId;
newCNProfessionalNode.CommandName = "CNProfessional";
newCNProfessionalNode.EnableExpandEvent = true;
newCNProfessionalNode.EnableClickEvent = true;
e.Node.Nodes.Add(newCNProfessionalNode);
TreeNode tempNode = new TreeNode();
tempNode.NodeID = "";
tempNode.Text = "";
tempNode.EnableExpandEvent = true;
tempNode.EnableClickEvent = true;
newCNProfessionalNode.Nodes.Add(tempNode);
var cNProfessional = (from x in BLL.Funs.DB.Base_CNProfessional where x.CNProfessionalId == Const.CNProfessionalCVId orderby x.SortIndex select x).ToList();
foreach (var c in cNProfessional)
{
TreeNode newCNProfessionalNode = new TreeNode();
newCNProfessionalNode.Text = c.ProfessionalName;
newCNProfessionalNode.NodeID = e.NodeID.Split('|')[0] + "|" + c.CNProfessionalId;
newCNProfessionalNode.CommandName = "CNProfessional";
newCNProfessionalNode.EnableExpandEvent = true;
newCNProfessionalNode.EnableClickEvent = true;
e.Node.Nodes.Add(newCNProfessionalNode);
TreeNode tempNode = new TreeNode();
tempNode.NodeID = "";
tempNode.Text = "";
tempNode.EnableExpandEvent = true;
tempNode.EnableClickEvent = true;
newCNProfessionalNode.Nodes.Add(tempNode);
}
}
else
{
var cNProfessional = (from x in BLL.Funs.DB.Base_CNProfessional where x.CNProfessionalId != Const.CNProfessionalConstructId && x.CNProfessionalId != Const.CNProfessionalCVId orderby x.SortIndex select x).ToList();
foreach (var c in cNProfessional)
{
TreeNode newCNProfessionalNode = new TreeNode();
newCNProfessionalNode.Text = c.ProfessionalName;
newCNProfessionalNode.NodeID = e.NodeID.Split('|')[0] + "|" + c.CNProfessionalId;
newCNProfessionalNode.CommandName = "CNProfessional";
newCNProfessionalNode.EnableExpandEvent = true;
newCNProfessionalNode.EnableClickEvent = true;
e.Node.Nodes.Add(newCNProfessionalNode);
TreeNode tempNode = new TreeNode();
tempNode.NodeID = "";
tempNode.Text = "";
tempNode.EnableExpandEvent = true;
tempNode.EnableClickEvent = true;
newCNProfessionalNode.Nodes.Add(tempNode);
}
}
}
else if (e.Node.CommandName == "CNProfessional") //展开专业

View File

@ -197,6 +197,7 @@
<Content Include="AttachFile\lib\popcorn.js" />
<Content Include="AttachFile\lib\popcorn.player.js" />
<Content Include="AttachFile\lib\popcorn.subtitle.js" />
<Content Include="AttachFile\Look.aspx" />
<Content Include="AttachFile\player.aspx" />
<Content Include="AttachFile\res\webuploader\Uploader.swf" />
<Content Include="AttachFile\res\webuploader\webuploader.nolog.js" />
@ -5884,6 +5885,13 @@
<Compile Include="AttachFile\fileupload.ashx.cs">
<DependentUpon>fileupload.ashx</DependentUpon>
</Compile>
<Compile Include="AttachFile\Look.aspx.cs">
<DependentUpon>Look.aspx</DependentUpon>
<SubType>ASPXCodeBehind</SubType>
</Compile>
<Compile Include="AttachFile\Look.aspx.designer.cs">
<DependentUpon>Look.aspx</DependentUpon>
</Compile>
<Compile Include="AttachFile\player.aspx.cs">
<DependentUpon>player.aspx</DependentUpon>
<SubType>ASPXCodeBehind</SubType>

View File

@ -125,6 +125,7 @@ namespace FineUIPro.Web.ProjectData
newDivisionProject.CNProfessionalId = d1.CNProfessionalId;
newDivisionProject.UnitWorkId = UnitWork.UnitWorkId;
newDivisionProject.OldDivisionId = d1.DivisionId;
newDivisionProject.SubItemType = d1.SubItemType;
BLL.DivisionProjectService.AddDivisionProject(newDivisionProject); //分部
List<Model.WBS_Division> divisions2 = (from x in Funs.DB.WBS_Division where x.SuperDivisionId == d1.DivisionId select x).ToList();
if (divisions2.Count() > 0)
@ -157,6 +158,7 @@ namespace FineUIPro.Web.ProjectData
bp.FenBao = b.FenBao;
bp.YeZhu = b.YeZhu;
bp.SourceBreakdownId = b.BreakdownId;
bp.CheckAcceptType = b.CheckAcceptType;
BLL.BreakdownProjectService.AddBreakdownProject(bp);
}
@ -324,6 +326,7 @@ namespace FineUIPro.Web.ProjectData
newDivisionProject.CNProfessionalId = d.CNProfessionalId;
newDivisionProject.UnitWorkId = unitWorkId;
newDivisionProject.OldDivisionId = d.DivisionId;
newDivisionProject.SubItemType = d.SubItemType;
BLL.DivisionProjectService.AddDivisionProject(newDivisionProject); //子级分部
List<Model.WBS_Division> divisions2 = (from x in Funs.DB.WBS_Division where x.SuperDivisionId == d.DivisionId select x).ToList();
if (divisions2.Count() > 0)

View File

@ -16803,7 +16803,7 @@ namespace Model
}
}
[global::System.Data.Linq.Mapping.AssociationAttribute(Name="FK_Base_DesignProfessional_Base_DesignProfessional", Storage="_Base_DesignProfessional", ThisKey="CNProfessionalId", OtherKey="ToCN", DeleteRule="NO ACTION")]
[global::System.Data.Linq.Mapping.AssociationAttribute(Name="FK_Base_DesignProfessional_Base_CNProfessional", Storage="_Base_DesignProfessional", ThisKey="CNProfessionalId", OtherKey="ToCN", DeleteRule="NO ACTION")]
public EntitySet<Base_DesignProfessional> Base_DesignProfessional
{
get
@ -18308,7 +18308,7 @@ namespace Model
}
}
[global::System.Data.Linq.Mapping.AssociationAttribute(Name="FK_Base_DesignProfessional_Base_DesignProfessional", Storage="_Base_CNProfessional", ThisKey="ToCN", OtherKey="CNProfessionalId", IsForeignKey=true)]
[global::System.Data.Linq.Mapping.AssociationAttribute(Name="FK_Base_DesignProfessional_Base_CNProfessional", Storage="_Base_CNProfessional", ThisKey="ToCN", OtherKey="CNProfessionalId", IsForeignKey=true)]
public Base_CNProfessional Base_CNProfessional
{
get
@ -381917,6 +381917,8 @@ namespace Model
private string _YeZhu;
private string _CheckAcceptType;
private EntityRef<WBS_Division> _WBS_Division;
#region
@ -381957,6 +381959,8 @@ namespace Model
partial void OnJianLiChanged();
partial void OnYeZhuChanging(string value);
partial void OnYeZhuChanged();
partial void OnCheckAcceptTypeChanging(string value);
partial void OnCheckAcceptTypeChanged();
#endregion
public WBS_Breakdown()
@ -382309,6 +382313,26 @@ namespace Model
}
}
[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_CheckAcceptType", DbType="Char(1)")]
public string CheckAcceptType
{
get
{
return this._CheckAcceptType;
}
set
{
if ((this._CheckAcceptType != value))
{
this.OnCheckAcceptTypeChanging(value);
this.SendPropertyChanging();
this._CheckAcceptType = value;
this.SendPropertyChanged("CheckAcceptType");
this.OnCheckAcceptTypeChanged();
}
}
}
[global::System.Data.Linq.Mapping.AssociationAttribute(Name="FK_WBS_Breakdown_WBS_Division", Storage="_WBS_Division", ThisKey="DivisionId", OtherKey="DivisionId", IsForeignKey=true)]
public WBS_Division WBS_Division
{
@ -386495,6 +386519,8 @@ namespace Model
private string _CNProfessionalId;
private string _SubItemType;
private EntitySet<WBS_Breakdown> _WBS_Breakdown;
private EntityRef<Base_CNProfessional> _Base_CNProfessional;
@ -386515,6 +386541,8 @@ namespace Model
partial void OnSuperDivisionIdChanged();
partial void OnCNProfessionalIdChanging(string value);
partial void OnCNProfessionalIdChanged();
partial void OnSubItemTypeChanging(string value);
partial void OnSubItemTypeChanged();
#endregion
public WBS_Division()
@ -386648,6 +386676,26 @@ namespace Model
}
}
[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_SubItemType", DbType="Char(1)")]
public string SubItemType
{
get
{
return this._SubItemType;
}
set
{
if ((this._SubItemType != value))
{
this.OnSubItemTypeChanging(value);
this.SendPropertyChanging();
this._SubItemType = value;
this.SendPropertyChanged("SubItemType");
this.OnSubItemTypeChanged();
}
}
}
[global::System.Data.Linq.Mapping.AssociationAttribute(Name="FK_WBS_Breakdown_WBS_Division", Storage="_WBS_Breakdown", ThisKey="DivisionId", OtherKey="DivisionId", DeleteRule="NO ACTION")]
public EntitySet<WBS_Breakdown> WBS_Breakdown
{