프로젝트

일반

사용자정보

개정판 16a422d1

ID16a422d1f5c6d66a5842aaa7d994d56b7a6f5916
상위 35a96e24
하위 b9ce7aee

백흠경이(가) 5년 이상 전에 추가함

issue #000: add ConsolidateCommand

Change-Id: Ib75611bb9f4bf3205e7cd2dadac902c382e2492b

차이점 보기:

KCOM/Events/ConsolidateCommand.cs
1
using IKCOM;
2
using KCOM.Common;
3
using KCOMDataModel.Common;
4
using KCOMDataModel.DataModel;
5
using MarkupToPDF.Common;
6
using MarkupToPDF.Controls.Parsing;
7
using System;
8
using System.Collections.Generic;
9
using System.Linq;
10
using System.Text;
11
using System.Windows.Controls;
12

  
13
namespace KCOM.Events
14
{
15
    public class ConsolidateCommand
16
    {
17
        private static readonly ConsolidateCommand _instance = new ConsolidateCommand();
18

  
19
        // Explicit static constructor to tell C# compiler
20
        // not to mark type as beforefieldinit
21
        static ConsolidateCommand()
22
        {
23
        }
24

  
25
        private ConsolidateCommand()
26
        {
27
        }
28

  
29
        public static ConsolidateCommand Instance
30
        {
31
            get
32
            {
33
                return _instance;
34
            }
35
        }
36

  
37
        /// <summary>
38
        /// save comments related to given markup information
39
        /// </summary>
40
        /// <param name="UserState"></param>
41
        /// <param name="iPageNo"></param>
42
        public void Execute(List<MarkupInfoItem> InfoList, int iPageNo)
43
        {
44
            try
45
            {
46
                string sDocID = Common.ViewerDataModel.Instance.SystemMain.dzMainMenu._DocInfo.ID;
47
                Common.ViewerDataModel.Instance.SystemMain.dzTopMenu.SaveEvent(null, null);
48
                
49
                Logger.sendReqLog("Consolidate", App.ViewInfo.ProjectNO + "," + App.ViewInfo.UserID + "," + sDocID + "," + InfoList, 1);
50
                Logger.sendResLog("Consolidate", Common.ViewerDataModel.Instance.SystemMain.dzMainMenu.BaseClient.Consolidate(App.ViewInfo.ProjectNO, App.ViewInfo.UserID, sDocID, InfoList).ToString(), 1);
51

  
52
                Logger.sendReqLog("GetMarkupInfoItemsAsync", App.ViewInfo.ProjectNO + "," + sDocID, 1);
53
                Common.ViewerDataModel.Instance.SystemMain.dzMainMenu.BaseClient.GetMarkupInfoItemsAsync(App.ViewInfo.ProjectNO, sDocID);
54
            }
55
            catch (Exception ex)
56
            {
57
                Common.ViewerDataModel.Instance.SystemMain.DialogMessage_Alert(string.Format("{0}", ex.StackTrace), "Alert");
58
                throw ex;
59
            }
60
        }
61
    }
62
}
KCOM/Views/MainMenu.xaml.cs
2321 2321
                                    control.PointSet.RemoveAt(control.PointSet.Count - 1);
2322 2322
                                    control.PointSet.Add(currentCanvasDrawingMouseMovePoint);
2323 2323
                                    control.Paint = ViewerDataModel.Instance.paintSet;
2324
                                    ///control.SetPolyPath();
2324
                                    control.ApplyTemplate();
2325 2325
                                    //강인구 추가
2326 2326
                                    control.DashSize = ViewerDataModel.Instance.DashSize;
2327 2327
                                    control.Paint = ViewerDataModel.Instance.paintSet;
......
4857 4857
                                    currentControl = new PolygonControl
4858 4858
                                    {
4859 4859
                                        PointSet = new List<Point>(),
4860
                                        //PointC = new StylusPointSet()
4861 4860
                                    };
4862 4861

  
4863
                                    //if (IsDrawingEnable(canvasZoomPanningMouseDownPoint))
4864
                                    //{
4865
                                        var polygonControl = (currentControl as PolygonControl);
4866
                                        currentControl.CommentID = Commons.shortGuid();
4867
                                        currentControl.IsNew = true;
4868
                                        currentControl.MarkupInfoID = App.Custom_ViewInfoId;
4869
                                        ViewerDataModel.Instance.MarkupControls_USER.Add(currentControl);
4870
                                        //currentControl.OnApplyTemplate();
4871
                                        polygonControl.PointSet.Add(canvasDrawingMouseDownPoint);
4872
                                        polygonControl.PointSet.Add(canvasDrawingMouseDownPoint);
4873
                                    //}
4862
                                    var polygonControl = (currentControl as PolygonControl);
4863
                                    currentControl.CommentID = Commons.shortGuid();
4864
                                    currentControl.IsNew = true;
4865
                                    currentControl.MarkupInfoID = App.Custom_ViewInfoId;
4866
                                    ViewerDataModel.Instance.MarkupControls_USER.Add(currentControl);
4867
                                    //currentControl.OnApplyTemplate();
4868
                                    polygonControl.PointSet.Add(canvasDrawingMouseDownPoint);
4869
                                    polygonControl.PointSet.Add(canvasDrawingMouseDownPoint);
4870
                                    polygonControl.ApplyTemplate();
4871
                                    polygonControl.Visibility = Visibility.Visible;
4874 4872
                                }
4875 4873
                            }
4876 4874
                        }
MarkupToPDF/Controls/Polygon/PolygonControl.cs
435 435

  
436 436
        private void SetPolyPath()
437 437
        {
438
            this.ApplyTemplate();
439

  
440 438
            if (Base_PolyPath != null)
441 439
            {
442 440
                Base_PolyPath.StrokeDashArray.Clear();

내보내기 Unified diff

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