Exemplo n.º 1
0
        private void EditJob()
        {
            var          job = (SdServiceJobDto)lstJobs.SelectedItem;
            UCServiceJob frm = new UCServiceJob(jobView, job, TransMode.EditRecord);

            ISE.UILibrary.Utils.UIUtils.SetFrmTrans(frm, "اطلاعات ریز خدمت", FormBorderStyle.FixedDialog);
            if (frm.Result == DialogResult.OK)
            {
                jobView.UpdateServiceJob(job);
                lstJobs.SelectedItem = job;
            }
        }
Exemplo n.º 2
0
        private void AddSubJob()
        {
            UCServiceJob frm = new UCServiceJob(jobView);

            ISE.UILibrary.Utils.UIUtils.SetFrmTrans(frm, "ایجاد زیر خدمت", FormBorderStyle.FixedDialog);
            if (frm.Result == DialogResult.OK)
            {
                if (frm.serviceJobList.Count > 0)
                {
                    var node = (TreeView)treeServices;

                    var selected = (SdServiceCategoryDto)node.SelectedNode.Tag;
                    if (selected != null)
                    {
                        lstJobs.Items.AddRange(frm.serviceJobList.ToArray());
                        lstJobs.DisplayMember = AssemblyReflector.GetMemberName((SdServiceJobDto c) => c.Title);
                    }
                }
            }
        }