1质量巡检导出补充无图导出功能
This commit is contained in:
		
							parent
							
								
									6bebbe15ef
								
							
						
					
					
						commit
						b66d6aeba3
					
				| 
						 | 
				
			
			@ -4,7 +4,7 @@
 | 
			
		|||
 | 
			
		||||
<html xmlns="http://www.w3.org/1999/xhtml">
 | 
			
		||||
<head runat="server">
 | 
			
		||||
<link href="../../res/css/common.css" rel="stylesheet" type="text/css" />
 | 
			
		||||
    <link href="../../res/css/common.css" rel="stylesheet" type="text/css" />
 | 
			
		||||
    <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
 | 
			
		||||
    <script src="../../Controls/My97DatePicker/WdatePicker.js" type="text/javascript"></script>
 | 
			
		||||
    <title>质量巡检</title>
 | 
			
		||||
| 
						 | 
				
			
			@ -37,8 +37,9 @@
 | 
			
		|||
 | 
			
		||||
        .Green {
 | 
			
		||||
            background-color: Green;
 | 
			
		||||
            color:white;
 | 
			
		||||
            color: white;
 | 
			
		||||
        }
 | 
			
		||||
 | 
			
		||||
        .Yellow {
 | 
			
		||||
            background-color: #FFFF93;
 | 
			
		||||
        }
 | 
			
		||||
| 
						 | 
				
			
			@ -50,6 +51,7 @@
 | 
			
		|||
        .LightGreen {
 | 
			
		||||
            background-color: LightGreen
 | 
			
		||||
        }
 | 
			
		||||
 | 
			
		||||
        .f-grid-colheader-text {
 | 
			
		||||
            white-space: normal;
 | 
			
		||||
            word-break: break-all;
 | 
			
		||||
| 
						 | 
				
			
			@ -62,7 +64,6 @@
 | 
			
		|||
        <f:Panel ID="Panel1" runat="server" Margin="5px" BodyPadding="5px" ShowBorder="false"
 | 
			
		||||
            ShowHeader="false" Layout="VBox" BoxConfigAlign="Stretch">
 | 
			
		||||
            <Items>
 | 
			
		||||
 | 
			
		||||
                <f:Grid ID="Grid1" ShowBorder="true" EnableAjax="false" ShowHeader="false" Title="质量巡检记录" EnableCollapse="true"
 | 
			
		||||
                    runat="server" BoxFlex="1" DataKeyNames="CheckControlCode" AllowCellEditing="true"
 | 
			
		||||
                    ClicksToEdit="2" DataIDField="CheckControlCode" AllowSorting="true" SortField="CheckDate"
 | 
			
		||||
| 
						 | 
				
			
			@ -76,18 +77,24 @@
 | 
			
		|||
                                <f:DropDownList ID="drpSponsorUnit" runat="server" Label="施工单位" EnableEdit="true" EmptyText="请选择查询条件"
 | 
			
		||||
                                    LabelAlign="right">
 | 
			
		||||
                                </f:DropDownList>
 | 
			
		||||
 | 
			
		||||
                                <f:DropDownList ID="drpUnitWork" runat="server" Label="单位工程" LabelAlign="Right" EnableEdit="true">
 | 
			
		||||
                                </f:DropDownList>
 | 
			
		||||
                                <f:DropDownList ID="drpCNProfessional" runat="server" Label="专业" LabelAlign="Right" EnableEdit="true">
 | 
			
		||||
                                </f:DropDownList>
 | 
			
		||||
                                <f:DropDownList ID="drpQuestionType" runat="server" Label="问题类别" Width="210px" LabelAlign="Right" EnableEdit="true">
 | 
			
		||||
                                </f:DropDownList>
 | 
			
		||||
                                <f:ToolbarFill runat="server"></f:ToolbarFill>
 | 
			
		||||
                                <f:Button ID="btnQuery" OnClick="btnQuery_Click" ToolTip="查询" Icon="SystemSearch" EnablePostBack="true" runat="server">
 | 
			
		||||
                                </f:Button>
 | 
			
		||||
                                <f:Button ID="btnRset" OnClick="btnRset_Click" ToolTip="重置" Icon="ArrowUndo" EnablePostBack="true" runat="server">
 | 
			
		||||
                                </f:Button>
 | 
			
		||||
                                <f:Button ID="btnNew" ToolTip="新增" Icon="Add" EnablePostBack="false" runat="server"
 | 
			
		||||
                                    Hidden="true">
 | 
			
		||||
                                </f:Button>
 | 
			
		||||
                            </Items>
 | 
			
		||||
                        </f:Toolbar>
 | 
			
		||||
                        <f:Toolbar ID="Toolbar2" Position="Top" runat="server" ToolbarAlign="Left">
 | 
			
		||||
                            <Items>
 | 
			
		||||
              
 | 
			
		||||
                                <f:DropDownList ID="dpHandelStatus" runat="server" Label="整改状态" LabelAlign="Right" EnableEdit="true">
 | 
			
		||||
                                    <f:ListItem Text="未确认" Value="1" />
 | 
			
		||||
                                    <f:ListItem Text="已闭环" Value="2" />
 | 
			
		||||
| 
						 | 
				
			
			@ -95,26 +102,21 @@
 | 
			
		|||
                                    <f:ListItem Text="未整改" Value="4" />
 | 
			
		||||
                                </f:DropDownList>
 | 
			
		||||
                                <f:DatePicker runat="server" DateFormatString="yyyy-MM-dd" Label="开始日期" ID="txtStartTime"
 | 
			
		||||
                                      LabelAlign="right" >
 | 
			
		||||
                                    LabelAlign="right">
 | 
			
		||||
                                </f:DatePicker>
 | 
			
		||||
                                <f:DatePicker runat="server" DateFormatString="yyyy-MM-dd" Label="结束日期" ID="txtEndTime"
 | 
			
		||||
                                      LabelAlign="right"  >
 | 
			
		||||
                                    LabelAlign="right">
 | 
			
		||||
                                </f:DatePicker>
 | 
			
		||||
                                   
 | 
			
		||||
                                <f:ToolbarFill runat="server"></f:ToolbarFill>
 | 
			
		||||
                                 <f:Button ID="btnQuery" OnClick="btnQuery_Click" ToolTip="查询"    Icon="SystemSearch" EnablePostBack="true" runat="server" >
 | 
			
		||||
                                </f:Button>
 | 
			
		||||
                                 <f:Button ID="btnRset"  OnClick="btnRset_Click" ToolTip="重置"    Icon="ArrowUndo" EnablePostBack="true" runat="server" >
 | 
			
		||||
                                </f:Button>
 | 
			
		||||
                                <f:Button ID="btnNew" ToolTip="新增" Icon="Add" EnablePostBack="false" runat="server"
 | 
			
		||||
                                    Hidden="true">
 | 
			
		||||
                                </f:Button>
 | 
			
		||||
                                <f:RadioButtonList ID="rbOutType" Label="导出" runat="server" LabelWidth="50px" Width="180px">
 | 
			
		||||
                                    <f:RadioItem Text="无图" Value="0" Selected="true" />
 | 
			
		||||
                                    <f:RadioItem Text="有图" Value="1" />
 | 
			
		||||
                                </f:RadioButtonList>
 | 
			
		||||
                                <f:Button ID="btnOut" OnClick="btnOut_Click" runat="server" ToolTip="导出" Icon="FolderUp"
 | 
			
		||||
                                    EnableAjax="false" DisableControlBeforePostBack="false">
 | 
			
		||||
                                </f:Button>
 | 
			
		||||
                            </Items>
 | 
			
		||||
                        </f:Toolbar>
 | 
			
		||||
                       
 | 
			
		||||
                    </Toolbars>
 | 
			
		||||
                    <Columns>
 | 
			
		||||
                        <f:TemplateField ColumnID="tfPageIndex" Width="55px" HeaderText="序号" HeaderTextAlign="Center" TextAlign="Center"
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
| 
						 | 
				
			
			@ -434,7 +434,7 @@ namespace FineUIPro.Web.CQMS.Check
 | 
			
		|||
                });
 | 
			
		||||
                var RoleName = string.Join(",", names);
 | 
			
		||||
 | 
			
		||||
                if (RoleName.Contains("质量") || RoleName.Contains("施工") )
 | 
			
		||||
                if (RoleName.Contains("质量") || RoleName.Contains("施工"))
 | 
			
		||||
                {
 | 
			
		||||
                    isAuthenticated = true;
 | 
			
		||||
                }
 | 
			
		||||
| 
						 | 
				
			
			@ -784,21 +784,18 @@ namespace FineUIPro.Web.CQMS.Check
 | 
			
		|||
                    if (!string.IsNullOrEmpty(item.QuestionType))
 | 
			
		||||
                    {
 | 
			
		||||
                        var qt = Funs.DB.Base_QualityQuestionType.FirstOrDefault(x => x.QualityQuestionTypeId == item.QuestionType);
 | 
			
		||||
                        if (qt!=null)
 | 
			
		||||
                        if (qt != null)
 | 
			
		||||
                        {
 | 
			
		||||
                            t = qt.QualityQuestionType;
 | 
			
		||||
                        }
 | 
			
		||||
                    }
 | 
			
		||||
                    cell.SetCellValue(t);//问题类别                   
 | 
			
		||||
 | 
			
		||||
                    if (rbOutType.SelectedValue == "1")
 | 
			
		||||
                    {//导出带图片
 | 
			
		||||
 | 
			
		||||
                    // cell = row.CreateCell(5);
 | 
			
		||||
                    // cell.CellStyle = cellStyle;
 | 
			
		||||
                    // cell.SetCellValue(item.CheckSite);//整改前照片
 | 
			
		||||
                        //整改前照片
 | 
			
		||||
                    var attachFile = Funs.DB.AttachFile
 | 
			
		||||
                        .Where(p => p.MenuId == BLL.Const.CheckListMenuId && p.ToKeyId == item.CheckControlCode)
 | 
			
		||||
                        .FirstOrDefault();
 | 
			
		||||
                        var attachFile = Funs.DB.AttachFile.Where(p => p.MenuId == BLL.Const.CheckListMenuId && p.ToKeyId == item.CheckControlCode).FirstOrDefault();
 | 
			
		||||
                        if (attachFile != null)
 | 
			
		||||
                        {
 | 
			
		||||
                            var photoesUrl = attachFile.AttachUrl;
 | 
			
		||||
| 
						 | 
				
			
			@ -828,9 +825,7 @@ namespace FineUIPro.Web.CQMS.Check
 | 
			
		|||
                        }
 | 
			
		||||
 | 
			
		||||
                        //整改后照片
 | 
			
		||||
                    var attachFile1 = Funs.DB.AttachFile.Where(p =>
 | 
			
		||||
                            p.MenuId == BLL.Const.CheckListMenuId && p.ToKeyId == item.CheckControlCode + "r")
 | 
			
		||||
                        .FirstOrDefault();
 | 
			
		||||
                        var attachFile1 = Funs.DB.AttachFile.Where(p => p.MenuId == BLL.Const.CheckListMenuId && p.ToKeyId == item.CheckControlCode + "r").FirstOrDefault();
 | 
			
		||||
                        if (attachFile1 != null)
 | 
			
		||||
                        {
 | 
			
		||||
                            var photoesUrl1 = attachFile1.AttachUrl;
 | 
			
		||||
| 
						 | 
				
			
			@ -859,13 +854,16 @@ namespace FineUIPro.Web.CQMS.Check
 | 
			
		|||
                            }
 | 
			
		||||
                        }
 | 
			
		||||
 | 
			
		||||
                    // cell = row.CreateCell(6);
 | 
			
		||||
                    // cell.CellStyle = cellStyle;
 | 
			
		||||
                    // cell.SetCellValue(item.CheckSite);//整改后照片
 | 
			
		||||
                    
 | 
			
		||||
                    // cell = row.CreateCell(5);
 | 
			
		||||
                    // cell.CellStyle = cellStyle;
 | 
			
		||||
                    // cell.SetCellValue(item.CheckSite);//部位
 | 
			
		||||
                    }
 | 
			
		||||
                    else
 | 
			
		||||
                    {
 | 
			
		||||
                        cell = row.CreateCell(5);
 | 
			
		||||
                        cell.CellStyle = cellStyle;
 | 
			
		||||
                        cell.SetCellValue("");//整改前图片
 | 
			
		||||
                        cell = row.CreateCell(6);
 | 
			
		||||
                        cell.CellStyle = cellStyle;
 | 
			
		||||
                        cell.SetCellValue("");//整改后图片
 | 
			
		||||
                    }
 | 
			
		||||
 | 
			
		||||
                    cell = row.CreateCell(7);
 | 
			
		||||
                    cell.CellStyle = cellStyle;
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
| 
						 | 
				
			
			@ -95,6 +95,33 @@ namespace FineUIPro.Web.CQMS.Check
 | 
			
		|||
        /// </remarks>
 | 
			
		||||
        protected global::FineUIPro.DropDownList drpQuestionType;
 | 
			
		||||
 | 
			
		||||
        /// <summary>
 | 
			
		||||
        /// btnQuery 控件。
 | 
			
		||||
        /// </summary>
 | 
			
		||||
        /// <remarks>
 | 
			
		||||
        /// 自动生成的字段。
 | 
			
		||||
        /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
 | 
			
		||||
        /// </remarks>
 | 
			
		||||
        protected global::FineUIPro.Button btnQuery;
 | 
			
		||||
 | 
			
		||||
        /// <summary>
 | 
			
		||||
        /// btnRset 控件。
 | 
			
		||||
        /// </summary>
 | 
			
		||||
        /// <remarks>
 | 
			
		||||
        /// 自动生成的字段。
 | 
			
		||||
        /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
 | 
			
		||||
        /// </remarks>
 | 
			
		||||
        protected global::FineUIPro.Button btnRset;
 | 
			
		||||
 | 
			
		||||
        /// <summary>
 | 
			
		||||
        /// btnNew 控件。
 | 
			
		||||
        /// </summary>
 | 
			
		||||
        /// <remarks>
 | 
			
		||||
        /// 自动生成的字段。
 | 
			
		||||
        /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
 | 
			
		||||
        /// </remarks>
 | 
			
		||||
        protected global::FineUIPro.Button btnNew;
 | 
			
		||||
 | 
			
		||||
        /// <summary>
 | 
			
		||||
        /// Toolbar2 控件。
 | 
			
		||||
        /// </summary>
 | 
			
		||||
| 
						 | 
				
			
			@ -132,31 +159,13 @@ namespace FineUIPro.Web.CQMS.Check
 | 
			
		|||
        protected global::FineUIPro.DatePicker txtEndTime;
 | 
			
		||||
 | 
			
		||||
        /// <summary>
 | 
			
		||||
        /// btnQuery 控件。
 | 
			
		||||
        /// rbOutType 控件。
 | 
			
		||||
        /// </summary>
 | 
			
		||||
        /// <remarks>
 | 
			
		||||
        /// 自动生成的字段。
 | 
			
		||||
        /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
 | 
			
		||||
        /// </remarks>
 | 
			
		||||
        protected global::FineUIPro.Button btnQuery;
 | 
			
		||||
 | 
			
		||||
        /// <summary>
 | 
			
		||||
        /// btnRset 控件。
 | 
			
		||||
        /// </summary>
 | 
			
		||||
        /// <remarks>
 | 
			
		||||
        /// 自动生成的字段。
 | 
			
		||||
        /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
 | 
			
		||||
        /// </remarks>
 | 
			
		||||
        protected global::FineUIPro.Button btnRset;
 | 
			
		||||
 | 
			
		||||
        /// <summary>
 | 
			
		||||
        /// btnNew 控件。
 | 
			
		||||
        /// </summary>
 | 
			
		||||
        /// <remarks>
 | 
			
		||||
        /// 自动生成的字段。
 | 
			
		||||
        /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
 | 
			
		||||
        /// </remarks>
 | 
			
		||||
        protected global::FineUIPro.Button btnNew;
 | 
			
		||||
        protected global::FineUIPro.RadioButtonList rbOutType;
 | 
			
		||||
 | 
			
		||||
        /// <summary>
 | 
			
		||||
        /// btnOut 控件。
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
		Loading…
	
		Reference in New Issue