zhangyk-c
2024-07-31 f0e02d57957827a48013c0291b89371839788075
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
using Autodesk.Revit.DB;
using HStation.RevitDev.Model.ModelEnum;
using System.Collections.Generic;
using System.IO;
using System.Reflection;
 
namespace HStation.RevitDev.RevitDataExport.Common
{
    public static class GlobalResource
    {
        public static readonly string PluginName = "泵系统分析";
 
        public static readonly string PanelName = "族库";
 
        public static AddInId CurrentAddinId = null;
 
        public static string UpdaterGuid = "345C723B-2244-46EE-B976-360FC14A543E";
 
        public static List<string> ElementIds = new List<string>();
 
        public static string LastFilePath = string.Empty;
 
        public static Dictionary<RevitType, List<string>> RevitModels = new Dictionary<RevitType, List<string>>();
 
        public static RevitType RevitFamilyType = RevitType.RFT_Unknown;
 
        public static int ThumbnailSize = 150;
 
        public static string CurrentRevitVersion = string.Empty;
 
        public static bool InstancePlacing = false;
 
        public static bool PipePlacing = false;
 
 
 
        public static Dictionary<RevitType, string> DockablePanelDict => new Dictionary<RevitType, string>
        {          
            {RevitType.RFT_Pump, "8AF8DA72-120F-44A0-81DD-5DD24EDAB919"},
            {RevitType.RFT_Valve, "1A2728E3-51FF-4084-B0B6-F6DAD26A56FB"},
            {RevitType.RFT_Pipe, "CB879681-B8E8-4FE2-BF57-4C86068D2C89"},
 
            {RevitType.RFT_FourJoint, "AAB55EEE-8450-4848-9C89-0322BBE94F5A"},
            {RevitType.RFT_Elbow, "C357EC81-09FF-41C5-8E32-FE71E30EA394"},
            {RevitType.RFT_Blocker, "0250FA8F-56C3-4355-817D-60B515CAD90E"},
            {RevitType.RFT_FireHydrant, "34E2EAD1-3D49-46C9-9942-451DD0192229"},
            {RevitType.RFT_HeatExchanger, "056EAACD-ED75-4854-8F3C-A4A43007BF31"},
            {RevitType.RFT_Reducing, "51F22122-04D5-4C28-9E68-1ADED0EABD04"},
 
            {RevitType.RFT_Shower, "D4AA8261-406E-44FF-A1EE-531153FA9709"},
            {RevitType.RFT_ThreeJoint, "1BAA114A-E355-402C-B91D-569882D12987"},
            {RevitType.RFT_WaterBox, "44951F67-0C2F-4B02-B988-8B5F06295A18"},
            {RevitType.RFT_WaterMeter, "28354DCD-C11F-4EE8-89F8-72B9A93FD9E6"},
            {RevitType.RFT_WaterPool, "2DFB190E-1FD9-4CC6-8F85-AD3B19745ACF"},
        };
 
        public static string BinDirectory
        {
            get
            {
                string result = Path.GetDirectoryName(Assembly.GetExecutingAssembly().Location);
                return result;
            }
        }
 
        public static string DataDirectory
        {
            get
            {
                string result = Path.Combine(Path.GetDirectoryName(BinDirectory), "Data");
                return result;
            }
        }
 
        public static string ExportFilePath
        {
            get
            {
                string result = Path.Combine(DataDirectory, "Export", "export.json");
                return result;
            }
        }
 
        public static string ConfigFilePath
        {
            get
            {
                string result = Path.Combine(DataDirectory, "Config", "config.json");
                return result;
            }
        }
 
        public static string FamilysDirectory
        {
            get
            {
                string result = Path.Combine(DataDirectory, "Familys");
                return result;
            }
        }
 
        public static string ImageDirectory
        {
            get
            {
                string result = Path.Combine(DataDirectory, "Image");
                return result;
            }
        }
    }
}