Ejemplo n.º 1
0
        private void CopyFromFieldConfigItem(FieldConfigItem field, IPageStyle style)
        {
            PlaceHolder = field.PlaceHolder;
            Hint        = FieldConfigItem.ToString(field.Hint, null);
            if (field.Hint != null)
            {
                HintPosition = field.Hint.Position;
            }

            SetFieldControl(field, style);
            Extension   = field.Extension;
            Upload      = field.Upload;
            Constraints = field.Constraints;
            SetPageProperties(field.Edit, field.ListDetail, style);
            SetDisplay(style);
        }
Ejemplo n.º 2
0
        internal Tk5FieldInfoEx(AddFieldConfig field, IPageStyle style)
        {
            FieldName   = field.FieldName;
            NickName    = field.NickName;
            DataType    = field.DataType;
            Length      = field.Length;
            IsEmpty     = field.IsEmpty;
            PlaceHolder = field.PlaceHolder;
            Kind        = field.Kind;
            Hint        = FieldConfigItem.ToString(field.Hint, null);
            if (field.Hint != null)
            {
                HintPosition = field.Hint.Position;
            }
            DisplayName     = FieldConfigItem.ToString(field.DisplayName, string.Empty);
            InternalControl = new SimpleFieldControl(field.Control, field.Order, style.Style);
            if (field.CodeTable != null)
            {
                Decoder = new SimpleFieldDecoder(field.CodeTable, DecoderType.CodeTable);
            }
            else if (field.EasySearch != null)
            {
                Decoder = new SimpleFieldDecoder(field.EasySearch, DecoderType.EasySearch);
            }
            else
            {
                Decoder = new SimpleFieldDecoder();
            }

            Extension = field.Extension;
            Layout    = field.Layout;
            ResetExpression();
            SetPageProperties(field.Edit, field.ListDetail, style);
            if (ListDetail != null)
            {
                ListDetail.TextHead = true;
            }
            else
            {
                ListDetail = new Tk5ListDetailConfig {
                    TextHead = true
                }
            };
            SetDisplay(style);
        }
Ejemplo n.º 3
0
        internal Tk5FieldInfoEx(FieldConfigItem field, IPageStyle style)
        {
            CopyFieldInfo(field);

            CopyFromFieldConfigItem(field, style);
        }