프로젝트

일반

사용자정보

개정판 284fa2c9

ID284fa2c97e925f7a6ff8139ff12234b93a46c44b
상위 dd27861e
하위 e87a55ae, 9e04d900

이지연이(가) 약 3년 전에 추가함

issue #000:

Change-Id: I6a600a1d1869b65f32f28368718a9fc357738a86

차이점 보기:

DTI_PID/ID2PSN/DB.cs
383 383

  
384 384
                    matched = names.FirstOrDefault(param => param == PSN_TRANSFORMKEYWORD_SETTING);
385 385
                    dicColCheck.Clear();
386
                    dicColCheck.Add("[INDEX]", "INTEGER");
387
                    dicColCheck.Add("[NAME]", "TEXT");
388
                    dicColCheck.Add("[KEYWORD]", "TEXT");
386
                    dicColCheck.Add("INDEX", "INTEGER");
387
                    dicColCheck.Add("NAME", "TEXT");
388
                    dicColCheck.Add("KEYWORD", "TEXT");
389 389
                    if (matched == null)
390 390
                    {
391 391
                        var query = $"CREATE TABLE {PSN_TRANSFORMKEYWORD_SETTING} ([INDEX] INTEGER, [NAME] TEXT, [KEYWORD] TEXT)";
......
486 486

  
487 487
                    matched = names.FirstOrDefault(param => param == PSN_NOPOCKETSETTING);
488 488
                    dicColCheck.Clear();
489
                    dicColCheck.Add("[INDEX]", "INTEGER");
490
                    dicColCheck.Add("[TYPE]", "TEXT");
491
                    dicColCheck.Add("[NAME]", "TEXT");
489
                    dicColCheck.Add("INDEX", "INTEGER");
490
                    dicColCheck.Add("TYPE", "TEXT");
491
                    dicColCheck.Add("NAME", "TEXT");
492 492
                    if (matched == null)
493 493
                    {
494 494
                        var query = $"CREATE TABLE {PSN_NOPOCKETSETTING} ([INDEX] INTEGER, [TYPE] TEXT, [NAME] TEXT)";
......
503 503
                    }
504 504

  
505 505
                    matched = names.FirstOrDefault(param => param == PSN_AIRFINCOOLERSETTING);
506

  
506 507
                    dicColCheck.Clear();
507
                    dicColCheck.Add("[INDEX]", "INTEGER");
508
                    dicColCheck.Add("[TYPE]", "TEXT");
509
                    dicColCheck.Add("[NAME]", "TEXT");
508
                    dicColCheck.Add("INDEX", "INTEGER");
509
                    dicColCheck.Add("TYPE", "TEXT");
510
                    dicColCheck.Add("TagIdentifier", "TEXT");
511
                    dicColCheck.Add("AttributeName", "TEXT");
512
                    dicColCheck.Add("NAME", "TEXT");
513

  
510 514
                    if (matched == null)
511 515
                    {
512
                        var query = $"CREATE TABLE {PSN_AIRFINCOOLERSETTING} ([INDEX] INTEGER, [TYPE] TEXT, [NAME] TEXT)";
516
                        var query = $"CREATE TABLE {PSN_AIRFINCOOLERSETTING} ([INDEX] INTEGER, [TYPE] TEXT, [TagIdentifier] TEXT, [AttributeName] TEXT, [NAME] TEXT)";
513 517
                        using (var cmd = connection.GetSqlStringCommand(query))
514 518
                        {
515 519
                            cmd.ExecuteNonQuery();
......
1173 1177
            {
1174 1178
                try
1175 1179
                {
1176
                    var query = $@"SELECT [INDEX], [TYPE], [NAME] FROM {PSN_AIRFINCOOLERSETTING};";
1180
                    var query = $@"SELECT [INDEX], [TYPE], [TagIdentifier], [AttributeName], [NAME] FROM {PSN_AIRFINCOOLERSETTING};";
1177 1181
                    using (var ds = connection.ExecuteDataSet(connection.GetSqlStringCommand(query)))
1178 1182
                    {
1179 1183
                        dt = ds.Tables[0].Copy();
......
1387 1391

  
1388 1392
                        foreach (EquipmentAirFinCoolerItem item in keywordItems)
1389 1393
                        {
1390
                            query = $"INSERT INTO {PSN_AIRFINCOOLERSETTING} ([INDEX], [TYPE], [NAME]) VALUES (@INDEX, @TYPE, @NAME)";
1394
                            query = $"INSERT INTO {PSN_AIRFINCOOLERSETTING} ([INDEX], [TYPE], [TagIdentifier], [AttributeName], [NAME]) VALUES (@INDEX, @TYPE, @TagIdentifier, @AttributeName, @NAME)";
1391 1395
                            var cmd = connection.GetSqlStringCommand(query);
1392 1396
                            AddWithValue(cmd, "@INDEX", item.Index);
1393 1397
                            AddWithValue(cmd, "@TYPE", item.Type);
1398
                            AddWithValue(cmd, "@TagIdentifier", item.TagIdentifier);
1399
                            AddWithValue(cmd, "@AttributeName", item.AttributeName);
1394 1400
                            AddWithValue(cmd, "@NAME", item.Name);
1395 1401
                            connection.ExecuteNonQuery(cmd, txn);
1402

  
1396 1403
                        }
1397 1404

  
1398 1405
                        txn.Commit();
......
2989 2996

  
2990 2997
                    matched = names.FirstOrDefault(param => param == PSN_NOPOCKETSETTING);
2991 2998
                    dicColCheck.Clear();
2992
                    dicColCheck.Add("[INDEX]", "INTEGER");
2993
                    dicColCheck.Add("[TYPE]", "TEXT");
2994
                    dicColCheck.Add("[NAME]", "TEXT");
2999
                    dicColCheck.Add("INDEX", "INTEGER");
3000
                    dicColCheck.Add("TYPE", "TEXT");
3001
                    dicColCheck.Add("NAME", "TEXT");
2995 3002
                    if (matched == null)
2996 3003
                    {
2997 3004
                        var query = $"CREATE TABLE {PSN_NOPOCKETSETTING} ([INDEX] INTEGER, [TYPE] TEXT, [NAME] TEXT)";
......
3007 3014

  
3008 3015
                    matched = names.FirstOrDefault(param => param == PSN_AIRFINCOOLERSETTING);
3009 3016
                    dicColCheck.Clear();
3010
                    dicColCheck.Add("[INDEX]", "INTEGER");
3011
                    dicColCheck.Add("[TYPE]", "TEXT");
3012
                    dicColCheck.Add("[NAME]", "TEXT");
3017
                    dicColCheck.Add("INDEX", "INTEGER");
3018
                    dicColCheck.Add("TYPE", "TEXT");
3019
                    dicColCheck.Add("TagIdentifier", "NVARCHAR(50)");
3020
                    dicColCheck.Add("AttributeName", "NVARCHAR(255)");
3021
                    dicColCheck.Add("NAME", "TEXT");
3022

  
3013 3023
                    if (matched == null)
3014 3024
                    {
3015
                        var query = $"CREATE TABLE {PSN_AIRFINCOOLERSETTING}  ([INDEX] INTEGER, [TYPE] TEXT, [NAME] TEXT)";
3025
                        var query = $"CREATE TABLE {PSN_AIRFINCOOLERSETTING} ([INDEX] INTEGER, [TYPE] TEXT, [TagIdentifier] TEXT, [AttributeName] TEXT, [NAME] TEXT)";
3026
                       
3016 3027
                        using (var cmd = connection.GetSqlStringCommand(query))
3017 3028
                        {
3018 3029
                            cmd.ExecuteNonQuery();
......
3276 3287
        }
3277 3288

  
3278 3289
        public static bool SaveAnotherPSNData(PSN item, List<HeaderInfo> headerInfos, List<VentDrainInfo> ventDrainInfos,
3279
          List<KeywordItem> keywordItems, DataTable dtTopologyRule, DataTable dtFluidCode, DataTable dtPMC, DataTable dtInsulation, DataTable dtvalvegrouping, DataTable dtnopocket)
3290
          List<KeywordItem> keywordItems, DataTable dtTopologyRule, DataTable dtFluidCode, DataTable dtPMC, DataTable dtInsulation, DataTable dtvalvegrouping, DataTable dtnopocket, DataTable dtafc)
3280 3291
        {
3281 3292
            AnotherID2Info id2Info = AnotherID2Info.GetInstance();
3282 3293

  
......
3751 3762
                            //air fin cooler Setting
3752 3763
                            query = $"DELETE FROM {PSN_AIRFINCOOLERSETTING}";
3753 3764
                            connection.ExecuteNonQuery(connection.GetSqlStringCommand(query), txn);
3754

  
3755
                            foreach (DataRow row in dtnopocket.Rows)
3765
                             
3766
                            foreach (DataRow row in dtafc.Rows)
3756 3767
                            {
3757
                                query = $"INSERT INTO {PSN_AIRFINCOOLERSETTING} ([INDEX], [TYPE], [NAME]) VALUES (@INDEX, @TYPE, @NAME)";
3768
                                query = $"INSERT INTO {PSN_AIRFINCOOLERSETTING} ([INDEX], [TYPE], [TagIdentifier], [AttributeName], [NAME]) VALUES (@INDEX, @TYPE, @TagIdentifier, @AttributeName, @NAME)";
3758 3769
                                var cmd = connection.GetSqlStringCommand(query);
3759 3770
                                AddWithValue(cmd, "@INDEX", row["INDEX"].ToString());
3760 3771
                                AddWithValue(cmd, "@TYPE", row["TYPE"].ToString());
3772
                                AddWithValue(cmd, "@TagIdentifier", row["TagIdentifier"].ToString());
3773
                                AddWithValue(cmd, "@AttributeName", row["AttributeName"].ToString());
3761 3774
                                AddWithValue(cmd, "@NAME", row["NAME"].ToString());
3762 3775
                                connection.ExecuteNonQuery(cmd, txn);
3763 3776
                            }
DTI_PID/ID2PSN/Form/DBSettingForm.cs
171 171

  
172 172
                DataTable PSNVALVALVEGROUPINGDT = DB.SelectValveGroupItemsSetting();
173 173
                DataTable PSNNOPOCKETDT = DB.SelectEquipmentNoPocketSetting();
174
                DataTable PSNAFC = DB.SelectAirFinCoolerSetting();
175
                
174 176
                //DB check
175 177
                DB.ConnTestAndCreateAnotherTable();
176 178

  
177 179
                //Save
178
                if (DB.SaveAnotherPSNData(_currentPSN, HeaderInfos, VentDrainInfos, KeywordInfos.KeywordItems, dtTopologyRule, PSNFluidDT, PSNPMCDT, PSNINSULATIONDT, PSNVALVALVEGROUPINGDT, PSNNOPOCKETDT))
180
                if (DB.SaveAnotherPSNData(_currentPSN, HeaderInfos, VentDrainInfos, KeywordInfos.KeywordItems, dtTopologyRule, PSNFluidDT, PSNPMCDT, PSNINSULATIONDT, PSNVALVALVEGROUPINGDT, PSNNOPOCKETDT, PSNAFC))
179 181
                {
180 182
                    if (rgDbSetting.SelectedIndex == 1)
181 183
                    {
DTI_PID/ID2PSN/Form/EquipmentSetting.cs
27 27
        EquipmentAirFinCoolerInfo currentEquipmentAirFinCoolerInfo = null;
28 28
        private RepositoryItemComboBox repositoryGroupType2 = new RepositoryItemComboBox();
29 29

  
30
        private RepositoryItemComboBox repositoryAttributeItem = new RepositoryItemComboBox();
31
        private DataTable SymbolList = new DataTable();
30 32
        public EquipmentSetting()
31 33
        {
32 34
            InitializeComponent();
......
34 36
            InitGridEquipmentNoPocket();
35 37
            InitGridEquipmentAirFinCooler();
36 38

  
39
            gridViewAirFinCooler.CellValueChanging += new DevExpress.XtraGrid.Views.Base.CellValueChangedEventHandler(gridViewSymbol_CellValueChanged);
40

  
37 41
            EquipmentNoPocketInfos = new List<EquipmentNoPocketInfo>();
38 42
            currentEquipmentNoPocketInfo = new EquipmentNoPocketInfo();
39 43

  
......
44 48
            InitAirFinCoolerData();
45 49
        }
46 50

  
47
        //const string FluidPriorityType = "FLUIDCODE";
48
        //const string PipingMaterialsPriorityType = "PIPINGMATERIALSCLASS";
51
        private void gridViewSymbol_CellValueChanged(object sender, DevExpress.XtraGrid.Views.Base.CellValueChangedEventArgs e)
52
        {
53
            if (e.Column.FieldName == "Type")
54
            {
55
                DevExpress.XtraGrid.Views.Base.ColumnView columnView = sender as DevExpress.XtraGrid.Views.Base.ColumnView;
56
                if (!string.IsNullOrEmpty(e.Value.ToString()))
57
                {
58
                    string selectItem = e.Value.ToString();
59
                    DataTable dt = gridControlAirFinCooler.DataSource as DataTable;
60
                    if (selectItem.Contains("Air Fin Cooler"))
61
                    {
62
                        dt.Rows[columnView.FocusedRowHandle]["TagIdentifier"] = "AFC";
63
                    }
64
                    else if (selectItem.Contains("Pump"))
65
                    {
66
                        dt.Rows[columnView.FocusedRowHandle]["TagIdentifier"] = "P";
67
                    }
68
                }
69
            }
70

  
71
        }
72

  
49 73
        public void InitGridEquipmentNoPocket()
50 74
        {
51 75
            RepositoryItemButtonEdit btnRemove = new RepositoryItemButtonEdit();
......
120 144
            DataTable dtType = new DataTable();
121 145
            dtType.Columns.Add("Index");
122 146
            dtType.Columns.Add("Type");
147
            dtType.Columns.Add("TagIdentifier");
148
            dtType.Columns.Add("AttributeName");
123 149
            dtType.Columns.Add("SppidSymbolName");
124 150
            dtType.Columns.Add(" ");
125 151
            gridControlAirFinCooler.DataSource = dtType;
126 152

  
127 153
            GridColumn gridColumn = gridViewAirFinCooler.Columns[0];
128 154

  
129

  
130 155
            gridColumn.Name = "Index";
131 156
            gridColumn.Caption = "Index";
132 157
            gridColumn.OptionsColumn.AllowEdit = false;
......
146 171
            gridViewAirFinCooler.Columns["Type"].ColumnEdit = repositoryGroupType2;
147 172

  
148 173
            gridColumn = gridViewAirFinCooler.Columns[2];
174
            gridColumn.Name = "TagIdentifier";
175
            gridColumn.Caption = "Prefix";
176
            gridColumn.OptionsColumn.AllowSort = DevExpress.Utils.DefaultBoolean.False;
177
            gridColumn.VisibleIndex = 2;
178

  
179
            repositoryAttributeItem.TextEditStyle = DevExpress.XtraEditors.Controls.TextEditStyles.DisableTextEditor;
180
            repositoryAttributeItem.AppearanceDropDown.Font = Font;
181
            gridControlAirFinCooler.RepositoryItems.Add(repositoryAttributeItem);
182

  
183
            gridColumn = gridViewAirFinCooler.Columns[3];
184
            gridColumn.Name = "AttributeName";
185
            gridColumn.Caption = "ID2 Attribute Name";
186
            gridColumn.OptionsColumn.AllowSort = DevExpress.Utils.DefaultBoolean.False;
187
            gridColumn.VisibleIndex = 3;
188
            gridViewAirFinCooler.Columns["AttributeName"].ColumnEdit = repositoryAttributeItem;
189

  
190
            gridColumn = gridViewAirFinCooler.Columns[4];
149 191
            gridColumn.Name = "SppidSymbolName";
150 192
            gridColumn.Caption = "ID2 Symbol Name";
151 193
            gridColumn.OptionsColumn.AllowSort = DevExpress.Utils.DefaultBoolean.False;
152
            gridColumn.VisibleIndex = 2;
194
            gridColumn.VisibleIndex = 4;
195

  
196
            SymbolList = DB.SelectAllSymbolAttribute();
153 197

  
154 198
            RepositoryItemTreeListLookUpEdit treeListLookUpEdit = new RepositoryItemTreeListLookUpEdit();
155 199
            gridControlAirFinCooler.RepositoryItems.Add(treeListLookUpEdit);
......
157 201

  
158 202
            gridViewAirFinCooler.Columns["SppidSymbolName"].ColumnEdit = treeListLookUpEdit;
159 203

  
160
            gridColumn = gridViewAirFinCooler.Columns[3];
204
            gridColumn = gridViewAirFinCooler.Columns[5];
161 205
            gridColumn.Name = "Remove";
162 206
            gridColumn.Caption = "";
163 207
            gridColumn.OptionsColumn.AllowSort = DevExpress.Utils.DefaultBoolean.False;
164
            gridColumn.VisibleIndex = 3;
208
            gridColumn.VisibleIndex = 5;
165 209
            gridColumn.MaxWidth = 16;
166 210

  
167 211
            gridColumn.ColumnEdit = btnRemove;
168 212
            gridColumn.ShowButtonMode = DevExpress.XtraGrid.Views.Base.ShowButtonModeEnum.ShowAlways;
213
            gridViewAirFinCooler.CustomRowCellEditForEditing += GridViewAirFinCooler_CustomRowCellEditForEditing;
214
        }
215

  
216
        private void GridViewAirFinCooler_CustomRowCellEditForEditing(object sender, CustomRowCellEditEventArgs e)
217
        {
218
            if (e.Column == (sender as GridView).Columns["AttributeName"])
219
            {
220
                DevExpress.XtraGrid.Views.Base.ColumnView columnView = sender as DevExpress.XtraGrid.Views.Base.ColumnView;
221
                DataTable dt = gridControlAirFinCooler.DataSource as DataTable;
222
                string SppidSymbolName = dt.Rows[columnView.FocusedRowHandle]["SppidSymbolName"].ToString();
223

  
224
                if (string.IsNullOrEmpty(SppidSymbolName))
225
                {
226
                    MessageBox.Show("Choose a symbol !", "ID2 " + ID2Info.ProgramName, MessageBoxButtons.OK, MessageBoxIcon.Information);
227
                    return;
228
                }
229

  
230
                repositoryAttributeItem.Items.Clear();
231
                repositoryAttributeItem.Items.Add("");
232
              //  repositoryAttributeItem.Items.Add("NoSelection");
233
                foreach (DataRow dr in SymbolList.Rows)
234
                {
235
                    if (dr["SymbolName"].ToString().ToUpper().Equals(SppidSymbolName.ToUpper()))
236
                    {
237
                        repositoryAttributeItem.Items.Add(dr["SymbolAttribute"].ToString());
238
                    }
239
                }
240
            }
169 241
        }
170 242

  
171 243
        private void GridViewKeyword_CustomDrawColumnHeader(object sender, ColumnHeaderCustomDrawEventArgs e)
......
222 294
            {
223 295
                int index = Convert.ToInt32(row["INDEX"]);
224 296
                string Type = row["TYPE"].ToString();
297
                string TagIdentifier = row["TagIdentifier"].ToString();
298
                string AttributeName = row["AttributeName"].ToString();
225 299
                string SppidSymbolName = row["NAME"].ToString();
226 300

  
227
                typeDT.Rows.Add(index, Type, SppidSymbolName, null);
301
                typeDT.Rows.Add(index, Type, TagIdentifier, AttributeName, SppidSymbolName, null);
228 302
            }
229 303

  
230 304
        }
......
327 401
            }
328 402

  
329 403
            DataTable dt = gridControlAirFinCooler.DataSource as DataTable;
330
            dt.Rows.Add(dt.Rows.Count + 1, null, null, null);
404
            dt.Rows.Add(dt.Rows.Count + 1, null, null, null, null, null);
331 405
            gridViewAirFinCooler.Columns["Index"].BestFit();
332 406
        }
333 407

  
......
360 434
                {
361 435
                    Index = i + 1,
362 436
                    Type = row["Type"].ToString(),
437
                    TagIdentifier = row["TagIdentifier"].ToString(),
438
                    AttributeName = row["AttributeName"].ToString(),
363 439
                    Name = row["SppidSymbolName"].ToString()
364 440
                });
365 441
            }
......
399 475
                return;
400 476
            }
401 477

  
478
            if (currentEquipmentAirFinCoolerInfo.EquipmentAirFinCoolerItem.Find(x => x.TagIdentifier == string.Empty || x.AttributeName == string.Empty || x.Name == string.Empty) != null)
479
            {
480
                IEnumerable<EquipmentAirFinCoolerItem> lstafc = currentEquipmentAirFinCoolerInfo.EquipmentAirFinCoolerItem.Where(x => x.TagIdentifier == string.Empty || x.AttributeName == string.Empty || x.Name == string.Empty);
481
                //Scope Break
482
                foreach (EquipmentAirFinCoolerItem vg in lstafc)
483
                {
484
                    if(vg.Type == string.Empty || vg.Name == string.Empty)
485
                    {
486
                        MessageBox.Show("Please save after entering data.", "ID2 " + ID2Info.ProgramName, MessageBoxButtons.OK, MessageBoxIcon.Warning);
487
                        return;
488
                    }
489
                }
490
            }
491
            
402 492
            if (DB.SaveEquipmentNopocketSetting(currentEquipmentNoPocketInfo.EquipmentNoPocketItem) &&
403 493
                DB.SaveAirFinCoolerSetting(currentEquipmentAirFinCoolerInfo.EquipmentAirFinCoolerItem))
404 494
                MessageBox.Show("Save was successful", "ID2 " + ID2Info.ProgramName, MessageBoxButtons.OK, MessageBoxIcon.Information);
DTI_PID/ID2PSN/Form/HistoryForm.Designer.cs
62 62
            this.ribbonControl.ShowDisplayOptionsMenuButton = DevExpress.Utils.DefaultBoolean.False;
63 63
            this.ribbonControl.ShowPageHeadersMode = DevExpress.XtraBars.Ribbon.ShowPageHeadersMode.ShowOnMultiplePages;
64 64
            this.ribbonControl.ShowToolbarCustomizeItem = false;
65
            this.ribbonControl.Size = new System.Drawing.Size(1599, 32);
65
            this.ribbonControl.Size = new System.Drawing.Size(1607, 32);
66 66
            this.ribbonControl.Toolbar.ShowCustomizeItem = false;
67 67
            // 
68 68
            // layoutControl1
......
74 74
            this.layoutControl1.Name = "layoutControl1";
75 75
            this.layoutControl1.OptionsCustomizationForm.DesignTimeCustomizationFormPositionAndSize = new System.Drawing.Rectangle(488, 408, 650, 400);
76 76
            this.layoutControl1.Root = this.Root;
77
            this.layoutControl1.Size = new System.Drawing.Size(1599, 861);
77
            this.layoutControl1.Size = new System.Drawing.Size(1607, 865);
78 78
            this.layoutControl1.TabIndex = 1;
79 79
            this.layoutControl1.Text = "layoutControl1";
80 80
            // 
......
84 84
            this.gridHistory.MainView = this.gridViewHistory;
85 85
            this.gridHistory.MenuManager = this.ribbonControl;
86 86
            this.gridHistory.Name = "gridHistory";
87
            this.gridHistory.Size = new System.Drawing.Size(1575, 797);
87
            this.gridHistory.Size = new System.Drawing.Size(1583, 801);
88 88
            this.gridHistory.TabIndex = 6;
89 89
            this.gridHistory.ViewCollection.AddRange(new DevExpress.XtraGrid.Views.Base.BaseView[] {
90 90
            this.gridViewHistory});
......
98 98
            // btnClose
99 99
            // 
100 100
            this.btnClose.ImageOptions.Image = ((System.Drawing.Image)(resources.GetObject("btnClose.ImageOptions.Image")));
101
            this.btnClose.Location = new System.Drawing.Point(1517, 813);
101
            this.btnClose.Location = new System.Drawing.Point(1525, 817);
102 102
            this.btnClose.Name = "btnClose";
103 103
            this.btnClose.Size = new System.Drawing.Size(70, 36);
104 104
            this.btnClose.StyleController = this.layoutControl1;
......
115 115
            this.layoutControlItem5,
116 116
            this.layoutControlItem1});
117 117
            this.Root.Name = "Root";
118
            this.Root.Size = new System.Drawing.Size(1599, 861);
118
            this.Root.Size = new System.Drawing.Size(1607, 865);
119 119
            this.Root.TextVisible = false;
120 120
            // 
121 121
            // emptySpaceItem3
122 122
            // 
123 123
            this.emptySpaceItem3.AllowHotTrack = false;
124
            this.emptySpaceItem3.Location = new System.Drawing.Point(0, 801);
124
            this.emptySpaceItem3.Location = new System.Drawing.Point(0, 805);
125 125
            this.emptySpaceItem3.Name = "emptySpaceItem3";
126
            this.emptySpaceItem3.Size = new System.Drawing.Size(1505, 40);
126
            this.emptySpaceItem3.Size = new System.Drawing.Size(1513, 40);
127 127
            this.emptySpaceItem3.TextSize = new System.Drawing.Size(0, 0);
128 128
            // 
129 129
            // layoutControlItem5
130 130
            // 
131 131
            this.layoutControlItem5.Control = this.btnClose;
132
            this.layoutControlItem5.Location = new System.Drawing.Point(1505, 801);
132
            this.layoutControlItem5.Location = new System.Drawing.Point(1513, 805);
133 133
            this.layoutControlItem5.MaxSize = new System.Drawing.Size(74, 40);
134 134
            this.layoutControlItem5.MinSize = new System.Drawing.Size(74, 40);
135 135
            this.layoutControlItem5.Name = "layoutControlItem5";
......
143 143
            this.layoutControlItem1.Control = this.gridHistory;
144 144
            this.layoutControlItem1.Location = new System.Drawing.Point(0, 0);
145 145
            this.layoutControlItem1.Name = "layoutControlItem1";
146
            this.layoutControlItem1.Size = new System.Drawing.Size(1579, 801);
146
            this.layoutControlItem1.Size = new System.Drawing.Size(1587, 805);
147 147
            this.layoutControlItem1.TextSize = new System.Drawing.Size(0, 0);
148 148
            this.layoutControlItem1.TextVisible = false;
149 149
            // 
......
151 151
            // 
152 152
            this.AutoScaleDimensions = new System.Drawing.SizeF(7F, 14F);
153 153
            this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
154
            this.ClientSize = new System.Drawing.Size(1599, 893);
154
            this.ClientSize = new System.Drawing.Size(1607, 897);
155 155
            this.Controls.Add(this.layoutControl1);
156 156
            this.Controls.Add(this.ribbonControl);
157 157
            this.Name = "HistoryForm";
DTI_PID/ID2PSN/Form/MainForm.resx
118 118
    <value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
119 119
  </resheader>
120 120
  <metadata name="defaultLookAndFeel.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
121
    <value>197, 17</value>
121
    <value>17, 56</value>
122 122
  </metadata>
123 123
  <assembly alias="System.Drawing" name="System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" />
124 124
  <data name="btnSaveAs.ImageOptions.Image" type="System.Drawing.Bitmap, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
......
344 344
</value>
345 345
  </data>
346 346
  <metadata name="contextMenuPSN.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
347
    <value>359, 17</value>
347
    <value>17, 95</value>
348 348
  </metadata>
349 349
  <metadata name="sqLiteCommandBuilder1.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
350
    <value>507, 17</value>
350
    <value>17, 134</value>
351 351
  </metadata>
352 352
  <metadata name="$this.TrayHeight" type="System.Int32, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
353 353
    <value>25</value>
DTI_PID/ID2PSN/Form/PBSSetting.Designer.cs
83 83
            this.ribbonControl.ShowDisplayOptionsMenuButton = DevExpress.Utils.DefaultBoolean.False;
84 84
            this.ribbonControl.ShowPageHeadersMode = DevExpress.XtraBars.Ribbon.ShowPageHeadersMode.ShowOnMultiplePages;
85 85
            this.ribbonControl.ShowToolbarCustomizeItem = false;
86
            this.ribbonControl.Size = new System.Drawing.Size(302, 32);
86
            this.ribbonControl.Size = new System.Drawing.Size(310, 32);
87 87
            this.ribbonControl.Toolbar.ShowCustomizeItem = false;
88 88
            // 
89 89
            // layoutControl1
......
99 99
            this.layoutControl1.Name = "layoutControl1";
100 100
            this.layoutControl1.OptionsCustomizationForm.DesignTimeCustomizationFormPositionAndSize = new System.Drawing.Rectangle(488, 408, 650, 400);
101 101
            this.layoutControl1.Root = this.Root;
102
            this.layoutControl1.Size = new System.Drawing.Size(302, 244);
102
            this.layoutControl1.Size = new System.Drawing.Size(310, 248);
103 103
            this.layoutControl1.TabIndex = 1;
104 104
            this.layoutControl1.Text = "layoutControl1";
105 105
            // 
......
117 117
            new DevExpress.XtraEditors.Controls.RadioGroupItem("Drawing No", "Drawing No"),
118 118
            new DevExpress.XtraEditors.Controls.RadioGroupItem("Unit Area", "Unit Area"),
119 119
            new DevExpress.XtraEditors.Controls.RadioGroupItem("No selection (Empty PBS)", "No selection (Empty PBS)")});
120
            this.radioGroupPBS1.Size = new System.Drawing.Size(254, 85);
120
            this.radioGroupPBS1.Size = new System.Drawing.Size(262, 85);
121 121
            this.radioGroupPBS1.StyleController = this.layoutControl1;
122 122
            this.radioGroupPBS1.TabIndex = 19;
123 123
            this.radioGroupPBS1.SelectedIndexChanged += new System.EventHandler(this.radioGroupPBS_SelectedIndexChanged);
......
125 125
            // btnClose
126 126
            // 
127 127
            this.btnClose.ImageOptions.Image = ((System.Drawing.Image)(resources.GetObject("btnClose.ImageOptions.Image")));
128
            this.btnClose.Location = new System.Drawing.Point(220, 192);
128
            this.btnClose.Location = new System.Drawing.Point(228, 192);
129 129
            this.btnClose.Name = "btnClose";
130 130
            this.btnClose.Size = new System.Drawing.Size(70, 36);
131 131
            this.btnClose.StyleController = this.layoutControl1;
......
136 136
            // btnSave
137 137
            // 
138 138
            this.btnSave.ImageOptions.Image = ((System.Drawing.Image)(resources.GetObject("btnSave.ImageOptions.Image")));
139
            this.btnSave.Location = new System.Drawing.Point(128, 192);
139
            this.btnSave.Location = new System.Drawing.Point(136, 192);
140 140
            this.btnSave.Name = "btnSave";
141 141
            this.btnSave.Size = new System.Drawing.Size(68, 36);
142 142
            this.btnSave.StyleController = this.layoutControl1;
......
150 150
            this.comboBoxEditPBSAttr.Name = "comboBoxEditPBSAttr";
151 151
            this.comboBoxEditPBSAttr.Properties.Buttons.AddRange(new DevExpress.XtraEditors.Controls.EditorButton[] {
152 152
            new DevExpress.XtraEditors.Controls.EditorButton(DevExpress.XtraEditors.Controls.ButtonPredefines.Combo)});
153
            this.comboBoxEditPBSAttr.Size = new System.Drawing.Size(194, 20);
153
            this.comboBoxEditPBSAttr.Size = new System.Drawing.Size(202, 20);
154 154
            this.comboBoxEditPBSAttr.StyleController = this.layoutControl1;
155 155
            this.comboBoxEditPBSAttr.TabIndex = 14;
156 156
            // 
......
175 175
            0,
176 176
            0,
177 177
            0});
178
            this.spinEditStart.Size = new System.Drawing.Size(76, 20);
178
            this.spinEditStart.Size = new System.Drawing.Size(80, 20);
179 179
            this.spinEditStart.StyleController = this.layoutControl1;
180 180
            this.spinEditStart.TabIndex = 17;
181 181
            // 
......
186 186
            0,
187 187
            0,
188 188
            0});
189
            this.spinEditEnd.Location = new System.Drawing.Point(224, 156);
189
            this.spinEditEnd.Location = new System.Drawing.Point(228, 156);
190 190
            this.spinEditEnd.Name = "spinEditEnd";
191 191
            this.spinEditEnd.Properties.Buttons.AddRange(new DevExpress.XtraEditors.Controls.EditorButton[] {
192 192
            new DevExpress.XtraEditors.Controls.EditorButton(DevExpress.XtraEditors.Controls.ButtonPredefines.Combo)});
......
200 200
            0,
201 201
            0,
202 202
            0});
203
            this.spinEditEnd.Size = new System.Drawing.Size(54, 20);
203
            this.spinEditEnd.Size = new System.Drawing.Size(58, 20);
204 204
            this.spinEditEnd.StyleController = this.layoutControl1;
205 205
            this.spinEditEnd.TabIndex = 18;
206 206
            // 
......
215 215
            this.emptySpaceItem2,
216 216
            this.layoutControlGroup2});
217 217
            this.Root.Name = "Root";
218
            this.Root.Size = new System.Drawing.Size(302, 244);
218
            this.Root.Size = new System.Drawing.Size(310, 248);
219 219
            this.Root.TextVisible = false;
220 220
            // 
221 221
            // emptySpaceItem3
......
223 223
            this.emptySpaceItem3.AllowHotTrack = false;
224 224
            this.emptySpaceItem3.Location = new System.Drawing.Point(0, 180);
225 225
            this.emptySpaceItem3.Name = "emptySpaceItem3";
226
            this.emptySpaceItem3.Size = new System.Drawing.Size(116, 44);
226
            this.emptySpaceItem3.Size = new System.Drawing.Size(124, 48);
227 227
            this.emptySpaceItem3.TextSize = new System.Drawing.Size(0, 0);
228 228
            // 
229 229
            // layoutControlItem4
230 230
            // 
231 231
            this.layoutControlItem4.Control = this.btnSave;
232
            this.layoutControlItem4.Location = new System.Drawing.Point(116, 180);
232
            this.layoutControlItem4.Location = new System.Drawing.Point(124, 180);
233 233
            this.layoutControlItem4.MaxSize = new System.Drawing.Size(72, 40);
234 234
            this.layoutControlItem4.MinSize = new System.Drawing.Size(72, 40);
235 235
            this.layoutControlItem4.Name = "layoutControlItem4";
236
            this.layoutControlItem4.Size = new System.Drawing.Size(72, 44);
236
            this.layoutControlItem4.Size = new System.Drawing.Size(72, 48);
237 237
            this.layoutControlItem4.SizeConstraintsType = DevExpress.XtraLayout.SizeConstraintsType.Custom;
238 238
            this.layoutControlItem4.TextSize = new System.Drawing.Size(0, 0);
239 239
            this.layoutControlItem4.TextVisible = false;
......
241 241
            // layoutControlItem5
242 242
            // 
243 243
            this.layoutControlItem5.Control = this.btnClose;
244
            this.layoutControlItem5.Location = new System.Drawing.Point(208, 180);
244
            this.layoutControlItem5.Location = new System.Drawing.Point(216, 180);
245 245
            this.layoutControlItem5.MaxSize = new System.Drawing.Size(74, 40);
246 246
            this.layoutControlItem5.MinSize = new System.Drawing.Size(74, 40);
247 247
            this.layoutControlItem5.Name = "layoutControlItem5";
248
            this.layoutControlItem5.Size = new System.Drawing.Size(74, 44);
248
            this.layoutControlItem5.Size = new System.Drawing.Size(74, 48);
249 249
            this.layoutControlItem5.SizeConstraintsType = DevExpress.XtraLayout.SizeConstraintsType.Custom;
250 250
            this.layoutControlItem5.TextSize = new System.Drawing.Size(0, 0);
251 251
            this.layoutControlItem5.TextVisible = false;
......
253 253
            // emptySpaceItem2
254 254
            // 
255 255
            this.emptySpaceItem2.AllowHotTrack = false;
256
            this.emptySpaceItem2.Location = new System.Drawing.Point(188, 180);
256
            this.emptySpaceItem2.Location = new System.Drawing.Point(196, 180);
257 257
            this.emptySpaceItem2.MaxSize = new System.Drawing.Size(20, 40);
258 258
            this.emptySpaceItem2.MinSize = new System.Drawing.Size(20, 40);
259 259
            this.emptySpaceItem2.Name = "emptySpaceItem2";
260
            this.emptySpaceItem2.Size = new System.Drawing.Size(20, 44);
260
            this.emptySpaceItem2.Size = new System.Drawing.Size(20, 48);
261 261
            this.emptySpaceItem2.SizeConstraintsType = DevExpress.XtraLayout.SizeConstraintsType.Custom;
262 262
            this.emptySpaceItem2.TextSize = new System.Drawing.Size(0, 0);
263 263
            // 
......
271 271
            this.layoutControlItem1});
272 272
            this.layoutControlGroup2.Location = new System.Drawing.Point(0, 0);
273 273
            this.layoutControlGroup2.Name = "layoutControlGroup2";
274
            this.layoutControlGroup2.Size = new System.Drawing.Size(282, 180);
274
            this.layoutControlGroup2.Size = new System.Drawing.Size(290, 180);
275 275
            this.layoutControlGroup2.Text = "PBS ";
276 276
            // 
277 277
            // layoutControlItemPBSAttribute
......
280 280
            this.layoutControlItemPBSAttribute.CustomizationFormText = "Attr Name";
281 281
            this.layoutControlItemPBSAttribute.Location = new System.Drawing.Point(0, 89);
282 282
            this.layoutControlItemPBSAttribute.Name = "layoutControlItemPBSAttribute";
283
            this.layoutControlItemPBSAttribute.Size = new System.Drawing.Size(258, 24);
283
            this.layoutControlItemPBSAttribute.Size = new System.Drawing.Size(266, 24);
284 284
            this.layoutControlItemPBSAttribute.Text = "Attr Name";
285 285
            this.layoutControlItemPBSAttribute.TextSize = new System.Drawing.Size(57, 14);
286 286
            // 
......
290 290
            this.layoutControlItemStart.CustomizationFormText = "From";
291 291
            this.layoutControlItemStart.Location = new System.Drawing.Point(0, 113);
292 292
            this.layoutControlItemStart.Name = "layoutControlItemStart";
293
            this.layoutControlItemStart.Size = new System.Drawing.Size(140, 24);
293
            this.layoutControlItemStart.Size = new System.Drawing.Size(144, 24);
294 294
            this.layoutControlItemStart.Text = "From";
295 295
            this.layoutControlItemStart.TextSize = new System.Drawing.Size(57, 14);
296 296
            // 
......
298 298
            // 
299 299
            this.layoutControlItemEnd.Control = this.spinEditEnd;
300 300
            this.layoutControlItemEnd.CustomizationFormText = "To";
301
            this.layoutControlItemEnd.Location = new System.Drawing.Point(140, 113);
301
            this.layoutControlItemEnd.Location = new System.Drawing.Point(144, 113);
302 302
            this.layoutControlItemEnd.Name = "layoutControlItemEnd";
303
            this.layoutControlItemEnd.Size = new System.Drawing.Size(118, 24);
303
            this.layoutControlItemEnd.Size = new System.Drawing.Size(122, 24);
304 304
            this.layoutControlItemEnd.Text = "To";
305 305
            this.layoutControlItemEnd.TextSize = new System.Drawing.Size(57, 14);
306 306
            // 
......
309 309
            this.layoutControlItem1.Control = this.radioGroupPBS1;
310 310
            this.layoutControlItem1.Location = new System.Drawing.Point(0, 0);
311 311
            this.layoutControlItem1.Name = "layoutControlItem1";
312
            this.layoutControlItem1.Size = new System.Drawing.Size(258, 89);
312
            this.layoutControlItem1.Size = new System.Drawing.Size(266, 89);
313 313
            this.layoutControlItem1.TextSize = new System.Drawing.Size(0, 0);
314 314
            this.layoutControlItem1.TextVisible = false;
315 315
            // 
......
341 341
            // 
342 342
            this.AutoScaleDimensions = new System.Drawing.SizeF(7F, 14F);
343 343
            this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
344
            this.ClientSize = new System.Drawing.Size(302, 276);
344
            this.ClientSize = new System.Drawing.Size(310, 280);
345 345
            this.Controls.Add(this.layoutControl1);
346 346
            this.Controls.Add(this.ribbonControl);
347 347
            this.Name = "PBSSetting";
DTI_PID/ID2PSN/Form/ValveGroupingSetting.Designer.cs
74 74
            this.ribbonControl.ShowDisplayOptionsMenuButton = DevExpress.Utils.DefaultBoolean.False;
75 75
            this.ribbonControl.ShowPageHeadersMode = DevExpress.XtraBars.Ribbon.ShowPageHeadersMode.ShowOnMultiplePages;
76 76
            this.ribbonControl.ShowToolbarCustomizeItem = false;
77
            this.ribbonControl.Size = new System.Drawing.Size(623, 32);
77
            this.ribbonControl.Size = new System.Drawing.Size(631, 32);
78 78
            this.ribbonControl.Toolbar.ShowCustomizeItem = false;
79 79
            // 
80 80
            // layoutControl1
......
88 88
            this.layoutControl1.Name = "layoutControl1";
89 89
            this.layoutControl1.OptionsCustomizationForm.DesignTimeCustomizationFormPositionAndSize = new System.Drawing.Rectangle(488, 408, 650, 400);
90 90
            this.layoutControl1.Root = this.Root;
91
            this.layoutControl1.Size = new System.Drawing.Size(623, 639);
91
            this.layoutControl1.Size = new System.Drawing.Size(631, 643);
92 92
            this.layoutControl1.TabIndex = 1;
93 93
            this.layoutControl1.Text = "layoutControl1";
94 94
            // 
......
98 98
            this.gridValveGroup.MainView = this.gridViewValveGroup;
99 99
            this.gridValveGroup.MenuManager = this.ribbonControl;
100 100
            this.gridValveGroup.Name = "gridValveGroup";
101
            this.gridValveGroup.Size = new System.Drawing.Size(575, 506);
101
            this.gridValveGroup.Size = new System.Drawing.Size(583, 510);
102 102
            this.gridValveGroup.TabIndex = 4;
103 103
            this.gridValveGroup.ViewCollection.AddRange(new DevExpress.XtraGrid.Views.Base.BaseView[] {
104 104
            this.gridViewValveGroup});
......
112 112
            // btnClose
113 113
            // 
114 114
            this.btnClose.ImageOptions.Image = ((System.Drawing.Image)(resources.GetObject("btnClose.ImageOptions.Image")));
115
            this.btnClose.Location = new System.Drawing.Point(541, 591);
115
            this.btnClose.Location = new System.Drawing.Point(549, 595);
116 116
            this.btnClose.Name = "btnClose";
117 117
            this.btnClose.Size = new System.Drawing.Size(70, 36);
118 118
            this.btnClose.StyleController = this.layoutControl1;
......
123 123
            // btnSave
124 124
            // 
125 125
            this.btnSave.ImageOptions.Image = ((System.Drawing.Image)(resources.GetObject("btnSave.ImageOptions.Image")));
126
            this.btnSave.Location = new System.Drawing.Point(449, 591);
126
            this.btnSave.Location = new System.Drawing.Point(457, 595);
127 127
            this.btnSave.Name = "btnSave";
128 128
            this.btnSave.Size = new System.Drawing.Size(68, 36);
129 129
            this.btnSave.StyleController = this.layoutControl1;
......
133 133
            // 
134 134
            // btnAddValveGroup
135 135
            // 
136
            this.btnAddValveGroup.Location = new System.Drawing.Point(458, 43);
136
            this.btnAddValveGroup.Location = new System.Drawing.Point(464, 43);
137 137
            this.btnAddValveGroup.Name = "btnAddValveGroup";
138
            this.btnAddValveGroup.Size = new System.Drawing.Size(141, 22);
138
            this.btnAddValveGroup.Size = new System.Drawing.Size(143, 22);
139 139
            this.btnAddValveGroup.StyleController = this.layoutControl1;
140 140
            this.btnAddValveGroup.TabIndex = 2;
141 141
            this.btnAddValveGroup.Text = " Add Valve Group";
......
152 152
            this.emptySpaceItem2,
153 153
            this.layoutControlGroup2});
154 154
            this.Root.Name = "Root";
155
            this.Root.Size = new System.Drawing.Size(623, 639);
155
            this.Root.Size = new System.Drawing.Size(631, 643);
156 156
            this.Root.TextVisible = false;
157 157
            // 
158 158
            // emptySpaceItem3
159 159
            // 
160 160
            this.emptySpaceItem3.AllowHotTrack = false;
161
            this.emptySpaceItem3.Location = new System.Drawing.Point(0, 579);
161
            this.emptySpaceItem3.Location = new System.Drawing.Point(0, 583);
162 162
            this.emptySpaceItem3.Name = "emptySpaceItem3";
163
            this.emptySpaceItem3.Size = new System.Drawing.Size(437, 40);
163
            this.emptySpaceItem3.Size = new System.Drawing.Size(445, 40);
164 164
            this.emptySpaceItem3.TextSize = new System.Drawing.Size(0, 0);
165 165
            // 
166 166
            // layoutControlItem4
167 167
            // 
168 168
            this.layoutControlItem4.Control = this.btnSave;
169
            this.layoutControlItem4.Location = new System.Drawing.Point(437, 579);
169
            this.layoutControlItem4.Location = new System.Drawing.Point(445, 583);
170 170
            this.layoutControlItem4.MaxSize = new System.Drawing.Size(72, 40);
171 171
            this.layoutControlItem4.MinSize = new System.Drawing.Size(72, 40);
172 172
            this.layoutControlItem4.Name = "layoutControlItem4";
......
178 178
            // layoutControlItem5
179 179
            // 
180 180
            this.layoutControlItem5.Control = this.btnClose;
181
            this.layoutControlItem5.Location = new System.Drawing.Point(529, 579);
181
            this.layoutControlItem5.Location = new System.Drawing.Point(537, 583);
182 182
            this.layoutControlItem5.MaxSize = new System.Drawing.Size(74, 40);
183 183
            this.layoutControlItem5.MinSize = new System.Drawing.Size(74, 40);
184 184
            this.layoutControlItem5.Name = "layoutControlItem5";
......
190 190
            // emptySpaceItem2
191 191
            // 
192 192
            this.emptySpaceItem2.AllowHotTrack = false;
193
            this.emptySpaceItem2.Location = new System.Drawing.Point(509, 579);
193
            this.emptySpaceItem2.Location = new System.Drawing.Point(517, 583);
194 194
            this.emptySpaceItem2.MaxSize = new System.Drawing.Size(20, 40);
195 195
            this.emptySpaceItem2.MinSize = new System.Drawing.Size(20, 40);
196 196
            this.emptySpaceItem2.Name = "emptySpaceItem2";
......
207 207
            this.emptySpaceItem1});
208 208
            this.layoutControlGroup2.Location = new System.Drawing.Point(0, 0);
209 209
            this.layoutControlGroup2.Name = "layoutControlGroup2";
210
            this.layoutControlGroup2.Size = new System.Drawing.Size(603, 579);
210
            this.layoutControlGroup2.Size = new System.Drawing.Size(611, 583);
211 211
            this.layoutControlGroup2.Text = "Valve Group Items";
212 212
            // 
213 213
            // layoutControlItem6
......
215 215
            this.layoutControlItem6.Control = this.gridValveGroup;
216 216
            this.layoutControlItem6.Location = new System.Drawing.Point(0, 26);
217 217
            this.layoutControlItem6.Name = "layoutControlItem6";
218
            this.layoutControlItem6.Size = new System.Drawing.Size(579, 510);
218
            this.layoutControlItem6.Size = new System.Drawing.Size(587, 514);
219 219
            this.layoutControlItem6.TextSize = new System.Drawing.Size(0, 0);
220 220
            this.layoutControlItem6.TextVisible = false;
221 221
            // 
222 222
            // layoutControlItem3
223 223
            // 
224 224
            this.layoutControlItem3.Control = this.btnAddValveGroup;
225
            this.layoutControlItem3.Location = new System.Drawing.Point(434, 0);
225
            this.layoutControlItem3.Location = new System.Drawing.Point(440, 0);
226 226
            this.layoutControlItem3.Name = "layoutControlItem3";
227
            this.layoutControlItem3.Size = new System.Drawing.Size(145, 26);
227
            this.layoutControlItem3.Size = new System.Drawing.Size(147, 26);
228 228
            this.layoutControlItem3.TextSize = new System.Drawing.Size(0, 0);
229 229
            this.layoutControlItem3.TextVisible = false;
230 230
            // 
......
233 233
            this.emptySpaceItem1.AllowHotTrack = false;
234 234
            this.emptySpaceItem1.Location = new System.Drawing.Point(0, 0);
235 235
            this.emptySpaceItem1.Name = "emptySpaceItem1";
236
            this.emptySpaceItem1.Size = new System.Drawing.Size(434, 26);
236
            this.emptySpaceItem1.Size = new System.Drawing.Size(440, 26);
237 237
            this.emptySpaceItem1.TextSize = new System.Drawing.Size(0, 0);
238 238
            // 
239 239
            // ValveGroupingSetting
240 240
            // 
241 241
            this.AutoScaleDimensions = new System.Drawing.SizeF(7F, 14F);
242 242
            this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
243
            this.ClientSize = new System.Drawing.Size(623, 671);
243
            this.ClientSize = new System.Drawing.Size(631, 675);
244 244
            this.Controls.Add(this.layoutControl1);
245 245
            this.Controls.Add(this.ribbonControl);
246 246
            this.Name = "ValveGroupingSetting";
DTI_PID/ID2PSN/Form/VentDrainSettingForm.Designer.cs
94 94
            this.ribbonControl.ShowDisplayOptionsMenuButton = DevExpress.Utils.DefaultBoolean.False;
95 95
            this.ribbonControl.ShowPageHeadersMode = DevExpress.XtraBars.Ribbon.ShowPageHeadersMode.ShowOnMultiplePages;
96 96
            this.ribbonControl.ShowToolbarCustomizeItem = false;
97
            this.ribbonControl.Size = new System.Drawing.Size(904, 32);
97
            this.ribbonControl.Size = new System.Drawing.Size(912, 32);
98 98
            this.ribbonControl.Toolbar.ShowCustomizeItem = false;
99 99
            // 
100 100
            // layoutControl1
......
110 110
            this.layoutControl1.Location = new System.Drawing.Point(0, 32);
111 111
            this.layoutControl1.Name = "layoutControl1";
112 112
            this.layoutControl1.Root = this.Root;
113
            this.layoutControl1.Size = new System.Drawing.Size(904, 623);
113
            this.layoutControl1.Size = new System.Drawing.Size(912, 627);
114 114
            this.layoutControl1.TabIndex = 1;
115 115
            this.layoutControl1.Text = "layoutControl1";
116 116
            // 
......
120 120
            this.labelControlToolTip.ImageAlignToText = DevExpress.XtraEditors.ImageAlignToText.RightCenter;
121 121
            this.labelControlToolTip.ImageOptions.Alignment = System.Drawing.ContentAlignment.MiddleLeft;
122 122
            this.labelControlToolTip.ImageOptions.Image = ((System.Drawing.Image)(resources.GetObject("labelControlToolTip.ImageOptions.Image")));
123
            this.labelControlToolTip.Location = new System.Drawing.Point(822, 12);
123
            this.labelControlToolTip.Location = new System.Drawing.Point(830, 12);
124 124
            this.labelControlToolTip.Name = "labelControlToolTip";
125 125
            this.labelControlToolTip.Size = new System.Drawing.Size(70, 16);
126 126
            this.labelControlToolTip.StyleController = this.layoutControl1;
......
129 129
            // 
130 130
            // btnAddType
131 131
            // 
132
            this.btnAddType.Location = new System.Drawing.Point(354, 63);
132
            this.btnAddType.Location = new System.Drawing.Point(357, 63);
133 133
            this.btnAddType.Name = "btnAddType";
134
            this.btnAddType.Size = new System.Drawing.Size(77, 22);
134
            this.btnAddType.Size = new System.Drawing.Size(78, 22);
135 135
            this.btnAddType.StyleController = this.layoutControl1;
136 136
            this.btnAddType.TabIndex = 0;
137 137
            this.btnAddType.Text = "Add Type";
......
139 139
            // 
140 140
            // gridControlSymbol
141 141
            // 
142
            this.gridControlSymbol.Location = new System.Drawing.Point(471, 89);
142
            this.gridControlSymbol.Location = new System.Drawing.Point(475, 89);
143 143
            this.gridControlSymbol.MainView = this.gridViewSymbol;
144 144
            this.gridControlSymbol.MenuManager = this.ribbonControl;
145 145
            this.gridControlSymbol.Name = "gridControlSymbol";
146
            this.gridControlSymbol.Size = new System.Drawing.Size(409, 470);
146
            this.gridControlSymbol.Size = new System.Drawing.Size(413, 474);
147 147
            this.gridControlSymbol.TabIndex = 4;
148 148
            this.gridControlSymbol.ViewCollection.AddRange(new DevExpress.XtraGrid.Views.Base.BaseView[] {
149 149
            this.gridViewSymbol});
......
160 160
            this.gridControlType.MainView = this.gridViewType;
161 161
            this.gridControlType.MenuManager = this.ribbonControl;
162 162
            this.gridControlType.Name = "gridControlType";
163
            this.gridControlType.Size = new System.Drawing.Size(407, 470);
163
            this.gridControlType.Size = new System.Drawing.Size(411, 474);
164 164
            this.gridControlType.TabIndex = 3;
165 165
            this.gridControlType.ViewCollection.AddRange(new DevExpress.XtraGrid.Views.Base.BaseView[] {
166 166
            this.gridViewType});
......
176 176
            // btnClose
177 177
            // 
178 178
            this.btnClose.ImageOptions.Image = ((System.Drawing.Image)(resources.GetObject("btnClose.ImageOptions.Image")));
179
            this.btnClose.Location = new System.Drawing.Point(822, 575);
179
            this.btnClose.Location = new System.Drawing.Point(830, 579);
180 180
            this.btnClose.Name = "btnClose";
181 181
            this.btnClose.Size = new System.Drawing.Size(70, 36);
182 182
            this.btnClose.StyleController = this.layoutControl1;
......
187 187
            // btnSave
188 188
            // 
189 189
            this.btnSave.ImageOptions.Image = ((System.Drawing.Image)(resources.GetObject("btnSave.ImageOptions.Image")));
190
            this.btnSave.Location = new System.Drawing.Point(730, 575);
190
            this.btnSave.Location = new System.Drawing.Point(738, 579);
191 191
            this.btnSave.Name = "btnSave";
192 192
            this.btnSave.Size = new System.Drawing.Size(68, 36);
193 193
            this.btnSave.StyleController = this.layoutControl1;
......
197 197
            // 
198 198
            // btnAddSymbol
199 199
            // 
200
            this.btnAddSymbol.Location = new System.Drawing.Point(791, 63);
200
            this.btnAddSymbol.Location = new System.Drawing.Point(798, 63);
201 201
            this.btnAddSymbol.Name = "btnAddSymbol";
202
            this.btnAddSymbol.Size = new System.Drawing.Size(89, 22);
202
            this.btnAddSymbol.Size = new System.Drawing.Size(90, 22);
203 203
            this.btnAddSymbol.StyleController = this.layoutControl1;
204 204
            this.btnAddSymbol.TabIndex = 2;
205 205
            this.btnAddSymbol.Text = " Add Symbol";
......
220 220
            this.layoutControlItem7,
221 221
            this.emptySpaceItem5});
222 222
            this.Root.Name = "Root";
223
            this.Root.Size = new System.Drawing.Size(904, 623);
223
            this.Root.Size = new System.Drawing.Size(912, 627);
224 224
            this.Root.TextVisible = false;
225 225
            // 
226 226
            // splitterItem1
227 227
            // 
228 228
            this.splitterItem1.AllowHotTrack = true;
229
            this.splitterItem1.Location = new System.Drawing.Point(435, 20);
229
            this.splitterItem1.Location = new System.Drawing.Point(439, 20);
230 230
            this.splitterItem1.Name = "splitterItem1";
231
            this.splitterItem1.Size = new System.Drawing.Size(12, 543);
231
            this.splitterItem1.Size = new System.Drawing.Size(12, 547);
232 232
            // 
233 233
            // emptySpaceItem3
234 234
            // 
235 235
            this.emptySpaceItem3.AllowHotTrack = false;
236
            this.emptySpaceItem3.Location = new System.Drawing.Point(0, 563);
236
            this.emptySpaceItem3.Location = new System.Drawing.Point(0, 567);
237 237
            this.emptySpaceItem3.Name = "emptySpaceItem3";
238
            this.emptySpaceItem3.Size = new System.Drawing.Size(718, 40);
238
            this.emptySpaceItem3.Size = new System.Drawing.Size(726, 40);
239 239
            this.emptySpaceItem3.TextSize = new System.Drawing.Size(0, 0);
240 240
            // 
241 241
            // layoutControlItem4
242 242
            // 
243 243
            this.layoutControlItem4.Control = this.btnSave;
244
            this.layoutControlItem4.Location = new System.Drawing.Point(718, 563);
244
            this.layoutControlItem4.Location = new System.Drawing.Point(726, 567);
245 245
            this.layoutControlItem4.MaxSize = new System.Drawing.Size(72, 40);
246 246
            this.layoutControlItem4.MinSize = new System.Drawing.Size(72, 40);
247 247
            this.layoutControlItem4.Name = "layoutControlItem4";
......
253 253
            // layoutControlItem5
254 254
            // 
255 255
            this.layoutControlItem5.Control = this.btnClose;
256
            this.layoutControlItem5.Location = new System.Drawing.Point(810, 563);
256
            this.layoutControlItem5.Location = new System.Drawing.Point(818, 567);
257 257
            this.layoutControlItem5.MaxSize = new System.Drawing.Size(74, 40);
258 258
            this.layoutControlItem5.MinSize = new System.Drawing.Size(74, 40);
259 259
            this.layoutControlItem5.Name = "layoutControlItem5";
......
265 265
            // emptySpaceItem2
266 266
            // 
267 267
            this.emptySpaceItem2.AllowHotTrack = false;
268
            this.emptySpaceItem2.Location = new System.Drawing.Point(790, 563);
268
            this.emptySpaceItem2.Location = new System.Drawing.Point(798, 567);
269 269
            this.emptySpaceItem2.MaxSize = new System.Drawing.Size(20, 40);
270 270
            this.emptySpaceItem2.MinSize = new System.Drawing.Size(20, 40);
271 271
            this.emptySpaceItem2.Name = "emptySpaceItem2";
......
281 281
            this.emptySpaceItem4});
282 282
            this.layoutControlGroup1.Location = new System.Drawing.Point(0, 20);
283 283
            this.layoutControlGroup1.Name = "layoutControlGroup1";
284
            this.layoutControlGroup1.Size = new System.Drawing.Size(435, 543);
284
            this.layoutControlGroup1.Size = new System.Drawing.Size(439, 547);
285 285
            this.layoutControlGroup1.Text = "Vent/Drain Type";
286 286
            // 
287 287
            // layoutControlItem2
......
289 289
            this.layoutControlItem2.Control = this.gridControlType;
290 290
            this.layoutControlItem2.Location = new System.Drawing.Point(0, 26);
291 291
            this.layoutControlItem2.Name = "layoutControlItem2";
292
            this.layoutControlItem2.Size = new System.Drawing.Size(411, 474);
292
            this.layoutControlItem2.Size = new System.Drawing.Size(415, 478);
293 293
            this.layoutControlItem2.TextSize = new System.Drawing.Size(0, 0);
294 294
            this.layoutControlItem2.TextVisible = false;
295 295
            // 
296 296
            // layoutControlItem1
297 297
            // 
298 298
            this.layoutControlItem1.Control = this.btnAddType;
299
            this.layoutControlItem1.Location = new System.Drawing.Point(330, 0);
299
            this.layoutControlItem1.Location = new System.Drawing.Point(333, 0);
300 300
            this.layoutControlItem1.Name = "layoutControlItem1";
301
            this.layoutControlItem1.Size = new System.Drawing.Size(81, 26);
301
            this.layoutControlItem1.Size = new System.Drawing.Size(82, 26);
302 302
            this.layoutControlItem1.TextSize = new System.Drawing.Size(0, 0);
303 303
            this.layoutControlItem1.TextVisible = false;
304 304
            // 
......
307 307
            this.emptySpaceItem4.AllowHotTrack = false;
308 308
            this.emptySpaceItem4.Location = new System.Drawing.Point(0, 0);
309 309
            this.emptySpaceItem4.Name = "emptySpaceItem4";
310
            this.emptySpaceItem4.Size = new System.Drawing.Size(330, 26);
310
            this.emptySpaceItem4.Size = new System.Drawing.Size(333, 26);
311 311
            this.emptySpaceItem4.TextSize = new System.Drawing.Size(0, 0);
312 312
            // 
313 313
            // layoutControlGroup2
......
316 316
            this.layoutControlItem6,
317 317
            this.layoutControlItem3,
318 318
            this.emptySpaceItem1});
319
            this.layoutControlGroup2.Location = new System.Drawing.Point(447, 20);
319
            this.layoutControlGroup2.Location = new System.Drawing.Point(451, 20);
320 320
            this.layoutControlGroup2.Name = "layoutControlGroup2";
321
            this.layoutControlGroup2.Size = new System.Drawing.Size(437, 543);
321
            this.layoutControlGroup2.Size = new System.Drawing.Size(441, 547);
322 322
            this.layoutControlGroup2.Text = "Type Items";
323 323
            // 
324 324
            // layoutControlItem6
......
326 326
            this.layoutControlItem6.Control = this.gridControlSymbol;
327 327
            this.layoutControlItem6.Location = new System.Drawing.Point(0, 26);
328 328
            this.layoutControlItem6.Name = "layoutControlItem6";
329
            this.layoutControlItem6.Size = new System.Drawing.Size(413, 474);
329
            this.layoutControlItem6.Size = new System.Drawing.Size(417, 478);
330 330
            this.layoutControlItem6.TextSize = new System.Drawing.Size(0, 0);
331 331
            this.layoutControlItem6.TextVisible = false;
332 332
            // 
333 333
            // layoutControlItem3
334 334
            // 
335 335
            this.layoutControlItem3.Control = this.btnAddSymbol;
336
            this.layoutControlItem3.Location = new System.Drawing.Point(320, 0);
336
            this.layoutControlItem3.Location = new System.Drawing.Point(323, 0);
337 337
            this.layoutControlItem3.Name = "layoutControlItem3";
338
            this.layoutControlItem3.Size = new System.Drawing.Size(93, 26);
338
            this.layoutControlItem3.Size = new System.Drawing.Size(94, 26);
339 339
            this.layoutControlItem3.TextSize = new System.Drawing.Size(0, 0);
340 340
            this.layoutControlItem3.TextVisible = false;
341 341
            // 
......
344 344
            this.emptySpaceItem1.AllowHotTrack = false;
345 345
            this.emptySpaceItem1.Location = new System.Drawing.Point(0, 0);
346 346
            this.emptySpaceItem1.Name = "emptySpaceItem1";
347
            this.emptySpaceItem1.Size = new System.Drawing.Size(320, 26);
347
            this.emptySpaceItem1.Size = new System.Drawing.Size(323, 26);
348 348
            this.emptySpaceItem1.TextSize = new System.Drawing.Size(0, 0);
349 349
            // 
350 350
            // layoutControlItem7
351 351
            // 
352 352
            this.layoutControlItem7.Control = this.labelControlToolTip;
353
            this.layoutControlItem7.Location = new System.Drawing.Point(810, 0);
353
            this.layoutControlItem7.Location = new System.Drawing.Point(818, 0);
354 354
            this.layoutControlItem7.MaxSize = new System.Drawing.Size(74, 20);
355 355
            this.layoutControlItem7.MinSize = new System.Drawing.Size(74, 20);
356 356
            this.layoutControlItem7.Name = "layoutControlItem7";
......
364 364
            this.emptySpaceItem5.AllowHotTrack = false;
365 365
            this.emptySpaceItem5.Location = new System.Drawing.Point(0, 0);
366 366
            this.emptySpaceItem5.Name = "emptySpaceItem5";
367
            this.emptySpaceItem5.Size = new System.Drawing.Size(810, 20);
367
            this.emptySpaceItem5.Size = new System.Drawing.Size(818, 20);
368 368
            this.emptySpaceItem5.TextSize = new System.Drawing.Size(0, 0);
369 369
            // 
370 370
            // VentDrainSettingForm
371 371
            // 
372 372
            this.AutoScaleDimensions = new System.Drawing.SizeF(7F, 14F);
373 373
            this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
374
            this.ClientSize = new System.Drawing.Size(904, 655);
374
            this.ClientSize = new System.Drawing.Size(912, 659);
375 375
            this.Controls.Add(this.layoutControl1);
376 376
            this.Controls.Add(this.ribbonControl);
377 377
            this.Name = "VentDrainSettingForm";
DTI_PID/ID2PSN/Object/EquipmentAirFinCoolerInfo.cs
16 16
    {
17 17
        public int Index { get; set; }
18 18
        public string Type { get; set; }
19

  
20
        public string TagIdentifier { get; set; }
21
        public string AttributeName { get; set; }
19 22
        public string Name { get; set; }
20 23
    }
21 24
}
DTI_PID/ID2PSN/PSN.cs
667 667
                }
668 668
                
669 669
                int afcTagNum = 0;
670
                DataRow[] airFinCoolerRows = PipeSystemNetwork.Select("AFC = 'P1'");
670
                DataRow[] airFinCoolerRows = PipeSystemNetwork.Select("AFC Like 'P1%'");
671
                Dictionary<string, string> keyValuePairs = new Dictionary<string, string>();
671 672
                foreach (DataRow dataRow in airFinCoolerRows)
672 673
                {
673
                    afcTagNum++;
674
                    DataRow[] pathItemRows = PathItems.Select(string.Format("PipeSystemNetwork_OID = '{0}'", dataRow["OID"].ToString()));
675
                    foreach (DataRow dr in pathItemRows)
676
                    {
677
                        dr["EqpGroupTag"] = "AFC" + string.Format("-{0}", string.Format("{0:D3}", afcTagNum));
678
                    }
674
                    string[] afcTag = dataRow.Field<string>("AFC").Split(new string[] { "\\" }, StringSplitOptions.None);
675
                    if (afcTag.Length > 1)
676
                    {                        
677
                        string afc = string.Empty;
678
                        if(!keyValuePairs.ContainsKey(afcTag[1]))
679
                        {
680
                            afcTagNum++;
681
                            afc = "AFC" + string.Format("-{0}", string.Format("{0:D3}", afcTagNum));
682
                            keyValuePairs.Add(afcTag[1], afc);                            
683
                        }
684
                        else
685
                        {
686
                            afc = keyValuePairs[afcTag[1]];
687
                        }
688

  
689
                        DataRow[] pathItemRows = PathItems.Select(string.Format("PipeSystemNetwork_OID = '{0}'", dataRow["OID"].ToString()));
690
                        foreach (DataRow dr in pathItemRows)
691
                        {
692
                            dr["EqpGroupTag"] = afc;
693
                        }
694
                    }                    
679 695
                }
680 696
                
681 697
                foreach (DataRow dataRow in airFinCoolerRows)
......
711 727
                    }
712 728
                    else if (dataRow["Type"].ToString() == "E2B" || dataRow["Type"].ToString() == "B2E")
713 729
                    {
714
                        int bCount = 0;
715 730
                        foreach (string viewOID in lstViewPipeSystemNetwork_OID)
716 731
                        {
717 732
                            if (viewOID == dataRow["OID"].ToString())
718 733
                                continue;
719 734

  
720 735
                            DataRow dr = PipeSystemNetwork.Select(string.Format("OID = '{0}'", viewOID)).First();
721
                            if (dr.Field<string>("AFC") != "P1")
736
                            if (!dr.Field<string>("AFC").Contains("P1"))
722 737
                            {
723 738
                                if (lstViewPipeSystemNetwork_OID.Where(x => x.Equals(viewOID)).Count() == 1)
724 739
                                {
......
735 750

  
736 751
                                    DataRow[] viewpathItemRows = PathItems.Select(string.Format("PipeSystemNetwork_OID = '{0}'", viewOID));
737 752

  
738
                                    if(viewpathItemRows.Where(x => !string.IsNullOrEmpty(x.Field<string>("EqpGroupTag"))).Count() > 0)
739
                                        AFCTag = viewpathItemRows.Where(x => !string.IsNullOrEmpty(x.Field<string>("EqpGroupTag"))).First().Field<string>("EqpGroupTag");                                    
740

  
753
                                    //if(viewpathItemRows.Where(x => !string.IsNullOrEmpty(x.Field<string>("EqpGroupTag"))).Count() > 0)
754
                                    //    AFCTag = viewpathItemRows.Where(x => !string.IsNullOrEmpty(x.Field<string>("EqpGroupTag"))).First().Field<string>("EqpGroupTag");                                    
755
                                    afcTagNum++;
756
                                    AFCTag = "AFC" + string.Format("-{0}", string.Format("{0:D3}", afcTagNum));
741 757
                                    foreach (DataRow viewdr in viewpathItemRows)
742 758
                                    {
743
                                       // viewdr["EqpGroupTag"] = AFCTag;
759
                                        viewdr["EqpGroupTag"] = AFCTag;
744 760
                                        viewdr["MainLineTag"] = "M";
745 761
                                    }
746 762
                                }
......
755 771
                        dr["EGFlowDirection"] = EGFlowDirection; 
756 772
                    }
757 773
                }
758
                
774

  
775
                //P3을 제외한 P1
776
                airFinCoolerRows = PipeSystemNetwork.Select("AFC Like 'P1%'");
759 777
                foreach (DataRow dataRow in airFinCoolerRows)
760 778
                {
779
                    //ML이 공란
761 780
                    DataRow[] pathItemRows = PathItems.Select(string.Format("PipeSystemNetwork_OID = '{0}' AND MainLineTag = ''", dataRow["OID"].ToString()));
762
                    //ML이 공란인 PSN - P1이 있다면 해당 Pathitem에 P3인 psn이 있는지 확인 : 해당 값은 전부 돌린후 확인 가능하기 때문에 다시 조회
781
                 
763 782
                    if (pathItemRows.Count() > 0)
764 783
                    {
765 784
                        List<string> lstViewPipeSystemNetwork_OID = pathItemRows.Select(x => x.Field<string>("ViewPipeSystemNetwork_OID")).Distinct().ToList();
......
769 788
                        foreach (string viewOID in lstViewPipeSystemNetwork_OID)
770 789
                        {
771 790
                            if (dataRow["OID"].ToString() == viewOID)
772
                            {
773
                                //lstViewPipeSystemNetwork_OID.Remove(viewOID);
774 791
                                continue;
775
                            }
792

  
793
                            //P3이면
776 794
                            DataRow viewPSN = null;
777 795
                            if (PipeSystemNetwork.Select(string.Format("OID = '{0}' AND AFC = 'P3'", viewOID)).Count() > 0)
778 796
                                viewPSN = PipeSystemNetwork.Select(string.Format("OID = '{0}' AND AFC = 'P3'", viewOID)).First();
779 797
                            
780 798
                            if (viewPSN != null)
781 799
                            {
800
                                //P3의 AGT를 가져와 P1에 입력
782 801
                                EqpGroupTag = PathItems.Select(string.Format("PipeSystemNetwork_OID = '{0}'", viewOID)).First().Field<string>("EqpGroupTag");
783 802
                                foreach (DataRow dr in pathItemRows)
784 803
                                {
785 804
                                    dr["EqpGroupTag"] = EqpGroupTag;
786 805

  
806
                                    //P1의 AGT와 같은 모든 AGT를 P3의 AGT로 변경하기위해 
787 807
                                    if (!string.IsNullOrEmpty(dr.Field<string>("ViewPipeSystemNetwork_OID")) && !lstpsn.Contains(dr.Field<string>("ViewPipeSystemNetwork_OID")))
788 808
                                    {
789 809
                                        lstpsn.Add(dr.Field<string>("ViewPipeSystemNetwork_OID"));
......
799 819
                            int lstCount = lstpsn.Count;
800 820
                            for (int i = 0; i < lstpsn.Count(); i++) //string psn in lstpsn
801 821
                            {
802
                                
822

  
803 823
                                DataRow[] rule4pathItems = PathItems.Select(string.Format("PipeSystemNetwork_OID = '{0}'", lstpsn[i]));
804 824
                                foreach (DataRow dr in rule4pathItems)
805 825
                                {
806 826
                                    if (!string.IsNullOrEmpty(dr.Field<string>("ViewPipeSystemNetwork_OID")) && !lstAll.Contains(dr.Field<string>("ViewPipeSystemNetwork_OID")))
807 827
                                    {
808
                                        lstpsn.Add(dr.Field<string>("ViewPipeSystemNetwork_OID"));
809
                                        lstAll.Add(dr.Field<string>("ViewPipeSystemNetwork_OID"));
828
                                        DataRow viewPSN = null;
829
                                        //연결된 PathItem-Tee (P3인것만) 의 PathItem-Tee에 또 P3가 있다면 해당 PSN도 Tag변경 만약 P3가 아닌 모든 OID면 해당 로직 삭제 (위에로직도 변경필요)
830
                                        if (PipeSystemNetwork.Select(string.Format("OID = '{0}' AND AFC = 'P3'", dr.Field<string>("ViewPipeSystemNetwork_OID"))).Count() > 0)
831
                                            viewPSN = PipeSystemNetwork.Select(string.Format("OID = '{0}' AND AFC = 'P3'", dr.Field<string>("ViewPipeSystemNetwork_OID"))).First();
832
                                        if(viewPSN != null)
833
                                        {
834
                                            lstpsn.Add(dr.Field<string>("ViewPipeSystemNetwork_OID"));
835
                                            lstAll.Add(dr.Field<string>("ViewPipeSystemNetwork_OID"));
836
                                        }
810 837
                                    }
811 838

  
812 839
                                    if (dr["EqpGroupTag"].Equals(EqpGroupTag))
813 840
                                        continue;
814 841

  
815
                                    dr["EqpGroupTag"] = EqpGroupTag;                                  
842
                                    dr["EqpGroupTag"] = EqpGroupTag;
816 843
                                }
817 844

  
818 845
                                lstpsn.Remove(lstpsn[i]);
819
                            }                        
846
                            }
820 847

  
821 848
                        }
822 849
                    }
823 850
                    
824 851
                }
825 852

  
826
                //DataRow[]  = PipeSystemNetwork.Select("AFC = 'P1'");
827 853
                foreach(DataRow dr in PipeSystemNetwork.Rows)
828 854
                {
829 855
                    DataRow[] pathItemRows = PathItems.Select(string.Format("PipeSystemNetwork_OID = '{0}' AND MainLineTag = 'M'", dr["OID"].ToString()));
......
852 878
                                if (viewpsn == dr["OID"].ToString())
853 879
                                    continue;
854 880

  
855
                                if (PipeSystemNetwork.Select(string.Format("OID = '{0}' AND AFC = 'P1'", viewpsn)).Length == 0)
881
                                if (PipeSystemNetwork.Select(string.Format("OID = '{0}' AND AFC Like 'P1%'", viewpsn)).Length == 0)
856 882
                                    continue;
857 883

  
858
                                DataRow rows = PipeSystemNetwork.Select(string.Format("OID = '{0}' AND AFC = 'P1'", viewpsn)).First();
884
                                DataRow rows = PipeSystemNetwork.Select(string.Format("OID = '{0}' AND AFC Like 'P1%'", viewpsn)).First();
859 885
                                if(rows != null)
860 886
                                {
861 887
                                    lastP1 = viewpsn;
......
2454 2480
                                        if(PSNItem.StartType == PSNType.Equipment && From_item.Equipment != null)
2455 2481
                                        {
2456 2482
                                            if (EquipmentAirFinCooler.EquipmentAirFinCoolerItem.Where(x => x.Type != "Pump" && x.Name.Equals(From_item.Equipment.Name)).Count() > 0)
2457
                                                AFC = "P1";
2483
                                                AFC = "P1\\" + From_item.Equipment.Name;
2458 2484
                                            else if (EquipmentAirFinCooler.EquipmentAirFinCoolerItem.Where(x => x.Type == "Pump" && x.Name.Equals(From_item.Equipment.Name)).Count() > 0)
2459 2485
                                                newRow["PUMP"] = "PUMP";
2460 2486
                                        }
......
2462 2488
                                        if (PSNItem.EndType == PSNType.Equipment && To_item.Equipment != null)
2463 2489
                                        {
2464 2490
                                            if (EquipmentAirFinCooler.EquipmentAirFinCoolerItem.Where(x => x.Type != "Pump" && x.Name.Equals(To_item.Equipment.Name)).Count() > 0)
2465
                                                AFC = "P1";
2491
                                                AFC = "P1\\" + To_item.Equipment.Name;
2466 2492
                                            else if (EquipmentAirFinCooler.EquipmentAirFinCoolerItem.Where(x => x.Type == "Pump" && x.Name.Equals(To_item.Equipment.Name)).Count() > 0)
2467 2493
                                                newRow["PUMP"] = "PUMP";
2468 2494
                                        }

내보내기 Unified diff

클립보드 이미지 추가 (최대 크기: 500 MB)