ホテル管理システム
ogi
yesterday 1a1c8e71fcd14858f595029f089b2d4a00202b32
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
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
using System;
using System.Collections.Generic;
using System.Text;
using System.IO;
using System.Reflection;
using System.Windows.Forms;
 
namespace HotelPms.Share.Windows.Util
{
    [Serializable()]
    public class InputItem
    {
        private bool lbIsChkData = false;
        private bool lbNotNull = false;
        private int liMaxKeta = 0;
        private int liSeparatorLen = 0;
        private numInputType liInputType = 0;
        private bool lbIsDate = false;
        private string lsIn_Range = "";  // '”͈́F "'A','E','F'" OR "'1','2','21'" OR "[1,10]" OR "(1,10)" OR "[1,10)" OR "(1,10]"  ‹ó”’‚ÌŽž‚µ‚È‚¢
        private string lsDBFieldName = "";
        private string lsCtrName = "";
        private bool lbIsPrimaryKey = false;
        private int liIndex = 0;
        private int liCtrIdx = 0;
        private string lsText = "";
        private string lsTag = "";
        private numShowStyle showStyle = 0;
        private bool enableUpDownKey = false;  //ª‚Ɓ«ƒL[‚Łuenterv‚Ɓuescv“¯‚¶—l‚É‚·‚é
        private ImeMode imeMode = ImeMode.On;
        private string mstNameCtrl = string.Empty;
 
        public ImeMode ImeMode
        {
            get { return imeMode; }
            set { imeMode = value; }
        }
 
        public int CtrIdx
        {
            get{return liCtrIdx;}
            set{liCtrIdx = value;}
        }
 
        public int Index{
            get{return liIndex;}
            set{liIndex = value;}
        }
 
        public bool EnableUpDownKey
        {
            get { return enableUpDownKey; }
            set { enableUpDownKey = value; }
        }
 
        public bool IsChkData
        {
            get{return lbIsChkData;}
            set{lbIsChkData = value;}
        }
 
        public numShowStyle ShowStyle
        {
            get { return showStyle; }
            set { showStyle = value; }
        }
 
        public bool NotNull
        {
            get{return lbNotNull;}
            set{lbNotNull = value;}
        }
 
        public int MaxKeta
        {
            get{return liMaxKeta;}
            set
            {
                liMaxKeta = value;
                int len = liMaxKeta / 3;
                liSeparatorLen =liMaxKeta + len + (liMaxKeta % 3 == 0 ? (len == 0 ? 0 : -1) : 0);
            }
        }
 
        public int SeparatorLen
        {
            get { return liSeparatorLen; }
        }
 
 
        public numInputType InputType
        {
            get{return liInputType;}
            set{liInputType = value;}
        }
 
        public bool IsDate
        {
            get{return lbIsDate;}
            set{lbIsDate = value;}
        }
 
        public string In_Range
        {
            get{return lsIn_Range;}
            set{lsIn_Range = value;}
        }
 
        public string DBFieldName
        {
            get{return lsDBFieldName;}
            set{lsDBFieldName = value;}
        }
 
        public string CtrName
        {
            get{return lsCtrName;}
            set{lsCtrName = value;}
        }
 
        public bool IsPrimaryKey
        {
            get{return lbIsPrimaryKey;}
            set{lbIsPrimaryKey = value;}
        }
 
        public string Text
        {
            get{return lsText;}
            set{lsText = value;}
        }
 
        public string MstNameCtrl
        {
            get { return mstNameCtrl; }
            set { mstNameCtrl = value; }
        }        
 
        public string Tag
        {
            get{return lsTag;}
            set{lsTag = value;}
        }
 
        public string ShowAllInfo()
        {
            try
            {
                string wsRet = "";
                string wvValue = "";
                Type woType = System.Type.GetType("Oat.Library.CommonClass.WinForm.InputItem");
                FieldInfo[] woFields = woType.GetFields(BindingFlags.Instance | BindingFlags.NonPublic | BindingFlags.Static);
 
                for (int i = 0; i < woFields.Length; i++)
                {
                    try
                    {
                        wvValue = woFields[i].GetValue(this).ToString();
                    }
                    catch
                    {
                        wvValue = "";
                    }
                    wsRet = wsRet + woFields[i].Name + " = " + wvValue + "\n";
                }
 
                return wsRet;
 
            }
            catch
            {
                return "";
            }
        }
 
        public InputItem Clone()
        {
            return MemberwiseClone() as InputItem;
        }
    }
}