예제 #1
0
        public ProxyTreeGridRenderer ConvertObject(TreeGridViewRenderer obj)
        {
            ProxyTreeGridRenderer proxy = null;

            if (obj != null)
            {
                proxy = new ProxyTreeGridRenderer
                {
                    DisplayFieldName = obj.DisplayFieldName,
                    fieldName        = obj.FieldName,
                    ObjectId         = obj.ObjectId,
                    QualifiedName    = obj.QualifiedName,
                    fieldValue       = obj.FieldValue,
                    fieldType        = obj.FieldType
                };

                proxy.ObjectId       = obj.ObjectId;
                proxy.readOnlyStatus = obj.ReadOnlyStatus;
                proxy.subObject      = obj.SubObject;
                proxy.hasSubNode     = obj.HasSubNode;

                if (obj.ObjectType != null)
                {
                    proxy.ObjectType = new ProxyType().CovertITypeToProxyType(obj.ObjectType);
                }
            }
            return(proxy);
        }
예제 #2
0
        public ProxyTreeGridRenderer GetTreeGridViewDetails(bool readOnly, long selectedObj, string classname)
        {
            TreeGridViewRenderer  item  = new RenderHierarcyDetails(readOnly).GetRootObject(selectedObj, classname);
            ProxyTreeGridRenderer proxy = new ProxyTreeGridRenderer().ConvertObject(item);

            return(proxy);
        }
예제 #3
0
		private void PopulateNode(TreeGridNode rootNode, ProxyTreeGridRenderer item)
		{
		    rootNode.Cells[0].Value = item.DisplayFieldName;
            rootNode.Cells[0].Tag  = item.QualifiedName ;
			rootNode.Cells[1].Value = item.FieldValue;
            rootNode.Cells[1].Tag = item.FieldName ;
			rootNode.Cells[2].Value = item.FieldType;
			rootNode.Cells[2].Tag = item.ObjectType;
			rootNode.Tag = item.ObjectId;
			rootNode.Cells[1].ReadOnly = item.ReadOnlyStatus;
		}
예제 #4
0
		private List<ProxyTreeGridRenderer> ConvertToProxyTreeGridRendererList(List<TreeGridViewRenderer> list)
		{
            if (list == null)
                return null;
            List<ProxyTreeGridRenderer> proxylist = new List<ProxyTreeGridRenderer>();

			foreach (TreeGridViewRenderer item in list)
			{
				ProxyTreeGridRenderer proxy = new ProxyTreeGridRenderer().ConvertObject(item);
				proxylist.Add(proxy);
			}
			return proxylist;
		}
예제 #5
0
        private List <ProxyTreeGridRenderer> ConvertToProxyTreeGridRendererList(List <TreeGridViewRenderer> list)
        {
            if (list == null)
            {
                return(null);
            }
            List <ProxyTreeGridRenderer> proxylist = new List <ProxyTreeGridRenderer>();

            foreach (TreeGridViewRenderer item in list)
            {
                ProxyTreeGridRenderer proxy = new ProxyTreeGridRenderer().ConvertObject(item);
                proxylist.Add(proxy);
            }
            return(proxylist);
        }
예제 #6
0
		private void PopulateTreeGridNode(TreeGridNode rootNode, ProxyTreeGridRenderer NodeDetails)
		{
			TreeGridNode node = new TreeGridNode();
			rootNode.Nodes.Add(node);
			PopulateNode(node, NodeDetails);
			node.ImageIndex = 0;
			node.Collapse();
			if (NodeDetails.HasSubNode || NodeDetails.ObjectId != 0)
			{
				TreeGridNode treenodeDummyChildNode = new TreeGridNode();
				node.Nodes.Add(treenodeDummyChildNode);
				treenodeDummyChildNode.Cells[0].Value = BusinessConstants.DB4OBJECTS_DUMMY;
				if (NodeDetails.HasSubNode && NodeDetails.ObjectId == 0)
					node.Tag = NodeDetails.SubObject;
			}
		}
예제 #7
0
		public ProxyTreeGridRenderer GetTreeGridViewDetails(bool readOnly, long selectedObj, string classname)
		{
			TreeGridViewRenderer item = new RenderHierarcyDetails(readOnly).GetRootObject(selectedObj, classname);
			ProxyTreeGridRenderer proxy = new ProxyTreeGridRenderer().ConvertObject(item );
			return proxy;
		}
예제 #8
0
		public ProxyTreeGridRenderer ConvertObject(TreeGridViewRenderer obj)
		{
			ProxyTreeGridRenderer proxy = null;
			if (obj != null)
			{
			    proxy = new ProxyTreeGridRenderer
			                {
			                    DisplayFieldName = obj.DisplayFieldName,
			                    fieldName = obj.FieldName,
			                    ObjectId = obj.ObjectId,
			                    QualifiedName = obj.QualifiedName,
			                    fieldValue = obj.FieldValue,
			                    fieldType = obj.FieldType
			                };

			    proxy.ObjectId = obj.ObjectId;
				proxy.readOnlyStatus = obj.ReadOnlyStatus;
				proxy.subObject = obj.SubObject;
				proxy.hasSubNode = obj.HasSubNode;
              
				if (obj.ObjectType != null)
					proxy.ObjectType = new ProxyType().CovertITypeToProxyType(obj.ObjectType  );
			}
			return proxy;
		}