Exemple #1
0
        protected void Page_Init(object sender, EventArgs e)
        {
            session             = XpoHelper.GetNewSession();
            dsInventory.Session = session;
            dsItemUnit.Session  = session;
            treeInventory.DataBind();
            dsInventory.CriteriaParameters["OrganizationId"].DefaultValue = "7e46b424-e0f5-4583-97f7-32bd2ec97e7e";
            if (!IsPostBack)
            {
                Session["InventorySelected"] = "FA31071D-6010-4788-83B9-9F0CE0C90C5F"; //Khoa mặc định
                string       defaultKey = Guid.Parse(Session["InventorySelected"].ToString()).ToString().Replace("-", string.Empty);
                TreeListNode node       = treeInventory.FindNodeByKeyValue(defaultKey);
                if (node != null)
                {
                    node.Focus();
                }
                ItemUnits = InventoryTransactionBO.getItemUnitsInInventory(session, Guid.Parse(Session["InventorySelected"].ToString()));
            }
            System.Diagnostics.Debug.WriteLine(String.Format("Pageload InventoryId: {0}", Session["InventorySelected"].ToString()));
            this.grdataproduct.DataSource = ItemUnits;
            this.grdataproduct.DataBind();

            //grdBalanceOfItems.DataSource = InventoryJournals;
            //grdBalanceOfItems.DataBind();

            grdBalanceOfInventoryCart.DataSource = InventoryLedgers;
            grdBalanceOfInventoryCart.DataBind();
        }
Exemple #2
0
 protected void Page_Load(object sender, EventArgs e)
 {
     // PAra seleccionar el menu correspondiente segun la páginas
     if (Session[Constantes.SessionMenuSeleccionado] != null)
     {
         TreeListNode trN = trlMenuPrincipal.FindNodeByKeyValue(Session[Constantes.SessionMenuSeleccionado].ToString());
         trN.Focus();
     }
 }
Exemple #3
0
        void FocusByPath(string name)
        {
            string       key  = FileManagerHelper.GetPathKey(name).ToString();
            TreeListNode node = tree.FindNodeByKeyValue(key);

            if (node == null)
            {
                return;
            }
            node.Focus();
        }
 protected void Page_Load(object sender, EventArgs e)
 {
     if (!IsPostBack)
     {
         SectionTreeList.DataBind();
         SectionTreeList.ExpandToLevel(1);
         TreeListNode node = SectionTreeList.FindNodeByFieldValue("code", "21-020101");
         if (node != null)
         {
             node.Focus();
             Session["sec_id"] = node.Key;
         }
         MaterialsGridView.DataBind();
     }
 }
    private void CheckNode(TreeListNode node)
    {
        string s_text = txtSearch.Text.ToLower();
        object node_value = node.GetValue("FirstName");
        if (node_value == null)
            return;
        if (node_value.ToString().ToLower().IndexOf(s_text) >= 0)
        {
            node.MakeVisible();
            node.Focus();
        }

        //DataRowView drChild = node.DataItem as DataRowView;
        //if (drChild == null)
        //    return;
        //if (drChild["PER_FULLNAME"].ToString().ToLower().IndexOf(s_text) >= 0)
        //{
        //    node.MakeVisible();
        //    node.Focus();
        //}
    }