Exemple #1
0
        private void frmHelp_LeftLayoutItemClick(object sender, MobileFormLayoutItemEventArgs e)
        {
            switch (e.CellItem.Name)
            {
            case "imgbz":
            case "btnbz":
                this.CloseSlider();
                break;

            case "imgtc":
            case "btnExit":
                MessageBox.Show("是否确定退出系统?", MessageBoxButtons.YesNo, (Object s, MessageBoxHandlerArgs args) =>
                {
                    if (args.Result == Smobiler.Core.ShowResult.Yes)
                    {
                        this.Close();
                    }
                }
                                );
                break;

            default:
                this.LeftLayoutAction = e.CellItem.Name;
                this.Close();
                break;
            }
        }
        /// <summary>
        /// FooterBarDialog点击事件
        /// </summary>
        /// <param name="sender"></param>
        /// <param name="e"></param>
        private void frmCostCenter_FooterBarDialogLayoutItemClick(object sender, MobileFormLayoutItemEventArgs e)
        {
            try
            {
                switch (e.CellItem.Name)
                {
                case "btnchoice":
                    DataTable cctable = new DataTable();
                    cctable.Columns.Add("USER_ID", typeof(System.String));
                    cctable.Rows.Add("MobilerUser");
                    cctable.Rows.Add("MUser");
                    PopListGroup poli = new PopListGroup();
                    PopList1.Groups.Add(poli);
                    int liindex = 0;
                    //设置PopListTitle
                    poli.Text = "成本中心责任人筛选";
                    //显示样式
                    foreach (DataRow rowli in cctable.Rows)
                    {
                        poli.Items.Add(rowli["USER_ID"].ToString(), liindex.ToString());
                        liindex += 1;
                    }

                    PopList1.ShowDialog();
                    break;

                case "btnsearch":
                    string confirmUser = this.FooterBarDialogData.Items["txtCCUser"].Text;
                    string CCNAME      = this.FooterBarDialogData.Items["txtCCName"].Text;
                    Bind(confirmUser, CCNAME);
                    this.CloseFooterBar();
                    //隐藏FooterBarLayout
                    break;

                case "btncurrentUser":
                    this.FooterBarDialogData.Items["txtCCUser"].Text = "Demo";
                    break;
                }
            }
            catch (Exception ex)
            {
                MessageBox.Show(ex.Message);
            }
        }
        private void frmAddContent_FooterBarLayoutItemClick(object sender, MobileFormLayoutItemEventArgs e)
        {
            try
            {
                if (txtGroup.Text.Trim().Length <= 0)
                {
                    throw new Exception("请输入群组名称");
                }
                if (groupuserCount < 0)
                {
                    throw new Exception("请选择群组成员");
                }
                string[] users = new string[groupuserCount + 1];
                string   guser = "";
                int      n     = 0;
                foreach (GridViewRow ROW in GridView1.Rows)
                {
                    if (Convert.ToBoolean(ROW.Cell.Items["Check"].DefaultValue) == true)
                    {
                        if (string.IsNullOrWhiteSpace(guser) == false)
                        {
                            guser += "," + ROW.Cell.Items["lblUSER_ID"].DefaultValue;
                        }
                        else
                        {
                            guser = ROW.Cell.Items["lblUSER_ID"].DefaultValue.ToString();
                        }

                        users[n] = ROW.Cell.Items["lblUSER_ID"].DefaultValue.ToString();
                        n       += 1;
                    }
                }
                //添加群组到数据库
                //....
                //
                im.CreateGroup(users, "G0001", txtGroup.Text.Trim());
                MessageBox.Show("群组已添加", (Object s, MessageBoxHandlerArgs args) => Close());
            }
            catch (Exception ex)
            {
                Toast(ex.Message, ToastLength.SHORT);
            }
        }
Exemple #4
0
        private void frmInfo_FooterBarLayoutItemClick(object sender, MobileFormLayoutItemEventArgs e)
        {
            frmInfoEdit frm = new frmInfoEdit();

            this.Redirect(frm);
        }
 private void frmMune_LeftLayoutItemClick(object sender, MobileFormLayoutItemEventArgs e)
 {
     ProcessLeftMenuFormName(e.CellItem.Name);
 }
Exemple #6
0
 /// <summary>
 /// FooterBar点击事件
 /// </summary>
 /// <param name="sender"></param>
 /// <param name="e"></param>
 private void frmRBCreate_FooterBarLayoutItemClick(object sender, MobileFormLayoutItemEventArgs e)
 {
     getcheckall();
 }