Exemplo n.º 1
0
 private void ClearProj_Click(object sender, RoutedEventArgs args)
 {
     if (MyMessageBox.ShowOKCancel("确定要清除?", "提示") == MessageBoxResult.OK)
     {
         CSystem.ClearViews();
     }
 }
Exemplo n.º 2
0
        /// <summary>
        /// 绑定当前对象数据
        /// </summary>
        public void Bind()
        {
            if (m_CurrentCustom == null)
            {
                this.textEdit2.Text = System.DateTime.Now.ToString();
                string jmLock = APP.GoldSoftClient.CurrentCustom.JMLOCK;
                //调用远程方法 获取积分
                string wb_web = CSystem.GetAppConfig("wb");
                this.textEdit4.Text = CustomBAL.getJF(wb_web, jmLock);
                CustomBAL.BDsuoManagerExtendInfo(wb_web, jmLock);
                //BDsuoManagerExtendInfo(wb_web, jmLock);
                this.rd_y_yhcl.Checked = APP.GXKG;
                this.rd_y_zjfa.Checked = APP.ZGFAKG;
                this.rd_y_bcde.Checked = APP.BCQDKG;
                if (APP.GoldSoftClient.CurrentCustom.SOFT_USE == "个人")
                {
                    this.rdo_use_person.Checked = true;
                }
                else
                {
                    this.rdo_use_unit.Checked = true;
                }
                if (APP.GoldSoftClient.CurrentCustom.SEX == "男")
                {
                    this.rdo_nan.Checked = true;
                }
                else
                {
                    this.rdo_nu.Checked = true;
                }

                this.cEntitySuomanagerBindingSource.DataSource = APP.GoldSoftClient.CurrentCustom;
            }
        }
Exemplo n.º 3
0
        private void ImportProjs_Click(object sender, RoutedEventArgs args)
        {
            var dlg = new OpenFileDialog();

            dlg.CheckFileExists = true;
            dlg.Title           = "导入技能";
            dlg.Filter          = "json文件|*.json";
            dlg.FileName        = "Skill.json";
            dlg.DefaultExt      = ".json";
            dlg.AddExtension    = true;
            dlg.Multiselect     = false;
            if (dlg.ShowDialog() == true)
            {
                try
                {
                    var text = File.ReadAllText(dlg.FileName);
                    currentSkill = JsonConvert.DeserializeObject <SkillData>(text);
                    CSystem.ImportDatas(currentSkill.ProjDatas);
                }
                catch
                {
                    MyMessageBox.Show("导入失败", "提示");
                }
            }
        }
Exemplo n.º 4
0
        /// #NAME#: #DESCRIPTION#
        public void f_7536ce3d_08b4_4489_84ea_5a48752c7a83()
        {
            //INI CODE PRCGUID: 7536ce3d-08b4-4489-84ea-5a48752c7a83

            ARQODE_UI.GestorProgramas.CVentanaProgramas CVentanaProgramas = new ARQODE_UI.GestorProgramas.CVentanaProgramas(vm);

            CSystem _system = null;

            if (App_globals.ActiveAppName == dGLOBALS.SYSTEM_APP)
            {
                _system = sys;
            }
            else if (Input("Aplicación activa") != null)
            {
                _system = ((ACORE)Input("Aplicación activa"))._system;
            }
            if (_system != null)
            {
                if (_system.errors.hasErrors())
                {
                    ARQODE_UI.ARQODE_UI.CVisorTexto CVisorTexto = new ARQODE_UI.ARQODE_UI.CVisorTexto(vm);
                    CVisorTexto.RB_Texto.Text =
                        _system.errors.getErrors().ToString();
                    CVisorTexto.VisorTexto.Show();
                }
                else
                {
                    MessageBox.Show("No hay errores en la UI");
                }
            }
            //END CODE PRCGUID: 7536ce3d-08b4-4489-84ea-5a48752c7a83
        }
Exemplo n.º 5
0
        private void Record(int cost, string reason)
        {
            if (!string.IsNullOrEmpty(reason))
            {
                var wb_web = CSystem.GetAppConfig("wb");

                //WebServiceHelper.InvokeMethod<bool>(wb_web, "TBRecord", new Object[] {
                //    pInfo.Current.StructSource.ModelProject.Rows[0]["Name"].ToString(),
                //    APP.GoldSoftClient.CurrentCustom.JMLOCK,"",
                //    APP.GoldSoftClient.PBBF.ToString(),
                //    APP.GoldSoftClient.ZZJ.ToString(),
                //    APP.GoldSoftClient.CSXMHJ.ToString(),
                //    APP.GoldSoftClient.FBFXHJ.ToString(),
                //    APP.GoldSoftClient.SXKZHJ.ToString(),
                //    APP.GoldSoftClient.CSXMHJ.ToString(),
                //    APP.GoldSoftClient.My_Count.ToString(),
                //    APP.GoldSoftClient.Other_Count.ToString(),
                //    APP.GoldSoftClient.QuGaoQuDi.ToString(),
                //    "",
                //    cost.ToString(),
                //    APP.GoldSoftClient.KCJF.ToString(),
                //    reason,
                //    DateTime.Now.ToString()});
                //MsgBox.Alert(reason);
                MessageBox.Show(reason);
            }
        }
Exemplo n.º 6
0
 public TProcess(CSystem csystem, ref Dictionary <String, Object> program_vars, JObject prc)
 {
     sys        = csystem;
     vars       = program_vars;
     pActivePrc = new JSonFile(prc);
     loadBaseProcess();
 }
Exemplo n.º 7
0
        private float CalculateValue(Vector2 left, Vector2 right, Vector2 valuer)
        {
            Vector2 max   = right - left;
            Vector2 value = valuer - left;

            return(CSystem.ToPositive(value.x / max.x));
        }
Exemplo n.º 8
0
        /// <summary>
        /// 提交数据到服务器
        /// </summary>
        /// <param name="sender"></param>
        /// <param name="e"></param>
        private void btnOK_Click(object sender, EventArgs e)
        {
            if (string.IsNullOrEmpty(this.txtContents.Text.Trim()))
            {
                MessageBox.Show("您没有填写任何错误信息!");
                return;
            }

            string             wb_web      = CSystem.GetAppConfig("wb");
            CEntityGCXXErrData GCXXErrData = new CEntityGCXXErrData();

            GCXXErrData.AddTime      = DateTime.Now.ToString();
            GCXXErrData.ColContrnts  = this._strColNameVal;
            GCXXErrData.Contents     = this.txtContents.Text.Trim();
            GCXXErrData.IsLOCK       = 0;
            GCXXErrData.JDName       = _strFormName;
            GCXXErrData.Results      = "";
            GCXXErrData.ResultsState = 0;
            GCXXErrData.InterLock    = APP.GoldSoftClient.GlodSoftDiscern.CurrNo;
            bool sige = GCXXErrDataBLL.insertGCXXErr(wb_web, GCXXErrData);

            if (sige)
            {
                this.Close();
            }
            else
            {
                MessageBox.Show("提交失败,稍后尝试!");
            }
        }
Exemplo n.º 9
0
        /// #NAME#: #DESCRIPTION#
        public void f_0fc207e4_213a_4321_a167_214072c7de6e()
        {
            //INI CODE PRCGUID: 0fc207e4-213a-4321-a167-214072c7de6e

            CSystem _system = null;

            if (App_globals.ActiveAppName == dGLOBALS.SYSTEM_APP)
            {
                _system = sys;
            }
            else if (Input("Aplicación activa") != null)
            {
                _system = ((ACORE)Input("Aplicación activa"))._system;
            }
            if (_system != null)
            {
                ARQODE_UI.GestorProgramas.CVentanaProgramas CVentanaProgramas = new ARQODE_UI.GestorProgramas.CVentanaProgramas(vm);
                ARQODE_UI.ARQODE_UI.CVisorTexto             CVisorTexto       = new ARQODE_UI.ARQODE_UI.CVisorTexto(vm);
                String trace_info =
                    String.Format("Estado global: " + _system.ProgramTracer.GlobalStatus.ToString()) + "\r\n" +
                    _system.ProgramTracer.Program_traces.ToString();
                trace_info += (_system.ProgramErrors.hasErrors()) ? "\r\n\r\nErrores:\r\n\r\n" +
                              _system.ProgramErrors.getErrors().ToString() : "";
                CVisorTexto.RB_Texto.Text = trace_info;
                CVisorTexto.VisorTexto.Show();
            }
            //END CODE PRCGUID: 0fc207e4-213a-4321-a167-214072c7de6e
        }
Exemplo n.º 10
0
        public event RunProcess ExecuteProcess;             // Execute process event

        public CProgram(CSystem csystem, String program)
        {
            sys = csystem;
            // Remove program queued flag
            program = (program.StartsWith("&")) ? program.Substring(1) : program;

            // Read program
            progInfo = new JSonFile(csystem.Globals.debug, csystem.Globals.AppData_path(dPATH.PROGRAM), program, true);

            if (!progInfo.hasErrors())
            {
                // Init csystem.ProgramErrors and debug for program execution
                csystem.NewProgram(program);
                csystem.ProgramErrors.Error = "";
                debug = csystem.ProgramDebug;

                csystem.ProgramErrors.Name        = Name;
                csystem.ProgramErrors.Description = Description;
                debug.Name        = Name;
                debug.Description = Description;

                // Init vars
                vars = new Dictionary <string, object>();
            }
            else
            {
                csystem.ProgramErrors.addError(progInfo.jErrors);
            }
        }
Exemplo n.º 11
0
 /// <summary>
 /// Simple use for access to util functions
 /// </summary>
 public CView(CSystem csystem)
 {
     Globals   = csystem.Globals;
     errors    = csystem.errors;
     debug     = csystem.debug;
     View_name = "";
 }
Exemplo n.º 12
0
        void LoadSubSystem(TreeNode pNode)
        {
            pNode.Nodes.Clear();
            List <CBaseObject> lstObj = Program.Ctx.SystemMgr.GetList();

            foreach (CBaseObject obj in lstObj)
            {
                CSystem  system = (CSystem)obj;
                TreeNode node   = new TreeNode();
                node.Text               = system.Name;
                node.ImageIndex         = 6;
                node.SelectedImageIndex = 6;
                TreeNodeTag tag = new TreeNodeTag();
                tag.NodeType = TreeNodeType.SubSystem;
                tag.Data     = system;
                node.Tag     = tag;

                TreeNode nodeSub = new TreeNode();
                nodeSub.Text               = "子关系图";
                nodeSub.ImageIndex         = 7;
                nodeSub.SelectedImageIndex = 7;
                TreeNodeTag tagSub = new TreeNodeTag();
                tagSub.NodeType = TreeNodeType.SubDiagram;
                nodeSub.Tag     = tagSub;
                node.Nodes.Add(nodeSub);

                pNode.Nodes.Add(node);
            }
        }
Exemplo n.º 13
0
        private void simpleButton1_Click(object sender, EventArgs e)
        {
            var mineCost = 0;

            this.lblName.Text = APP.GoldSoftClient.CurrentCustom.CUSTOMERNAME;
            string wb_web = CSystem.GetAppConfig("wb");

            try
            {
                mineCost = WebServiceHelper.InvokeMethod <int>(wb_web, "getJiFenJL", APP.GoldSoftClient.CurrentCustom.JMLOCK);
            }
            catch (Exception)
            {
                MsgBox.Alert("获取积分失败,请重试");
                return;
            }

            if (mineCost < APP.GoldSoftClient.KCJF)
            {
                //MsgBox.Alert("您的积分不够,不能进行调标操作!请购买积分后,再试!");
                MessageBox.Show("您的积分不够,不能进行调标操作!请购买积分后,再试!");
                this.Close();
                return;
            }

            BeginAnalyze2 begin2 = new BeginAnalyze2();

            begin2.MdiParent  = this.MdiParent;
            begin2.pInfo      = this.pInfo;
            begin2.DataSource = this.DataSource;
            begin2._sender    = this._sender;
            begin2.ShowDialog();
            this.Close();
        }
Exemplo n.º 14
0
        /// <summary>
        /// 每次打开软件的时候调用(首次调用)
        /// 返回可用的功能号信息
        /// 返回结果函数
        /// </summary>
        /// <returns></returns>
        public void FirstLogin()
        {
            //网络验证
            int netStatus = this.m_GlodSoftNetWork.Completed();

            string serverIp = CSystem.GetAppConfig("serverip");

            if (string.IsNullOrEmpty(serverIp))
            {
                //加密锁验证
                this.GlodSoftDiscern.Completed();

                //if (this.ClientResult.IsUseNet)
                //{
                //    string wb_web = CSystem.GetAppConfig("wb");
                //    DataTable dtsuoManager = WebServiceHelper.InvokeMethod<DataTable>(wb_web, "getSuoManagerInfoByJmLock", APP.GoldSoftClient.GlodSoftDiscern.CurrNo);
                //    if (dtsuoManager.Rows.Count <= 0)
                //        this.Can_Use_System = false;
                //}
            }
            else
            {
                if (this.GlodSoftDiscern.Completed(serverIp, 1086) != 0)
                {
                    throw new Exception("服务器不可用!");
                }
            }

            //功能性验证
            this.StandCompleted();
            //加密狗验证
            //this.GlodSoftDiscern.Completed();
        }
Exemplo n.º 15
0
    void OnTriggerStay2D(Collider2D col)
    {
        if (controller.dragging == this.gameObject && controller.startDragging && GetComponent <CardInformation>().inOrder)
        {
            if (col && col.gameObject && col.tag == "DCTrigger")
            {
                for (int i = 0; i < controller.order.Count; i++)
                {
                    card_g = controller.order[i];
                    cardBC = card_g.GetComponent <BoxCollider2D>();
                    if (cardBC && (CSystem.ValueBetween(cardBC.bounds.max.y, bc.bounds.min.y, bc.bounds.max.y) ||
                                   CSystem.ValueBetween(cardBC.bounds.min.y, bc.bounds.min.y, bc.bounds.max.y)))
                    {
                        int ext = 0;
                        if (CSystem.ValueBetween(cardBC.bounds.max.y, bc.bounds.min.y, bc.bounds.max.y))
                        {
                            ext++;
                        }

                        if (!controller.order.Contains(controller.emptySpace))
                        {
                            controller.order.Insert(controller.order.IndexOf(card_g) + ext, controller.emptySpace);
                        }
                        else if (controller.order.IndexOf(controller.emptySpace) != controller.order.IndexOf(card_g) + ext)
                        {
                            controller.order.Remove(controller.emptySpace);
                            controller.order.Insert(controller.order.IndexOf(card_g) + ext, controller.emptySpace);
                        }
                    }
                }
            }
        }
    }
Exemplo n.º 16
0
        public CProgram(CSystem csystem, Programs ePrograms, String program)
        {
            sys = csystem;
            // Remove program queued flag
            program_name = (program.StartsWith("&")) ? program.Substring(1) : program;
            // Read program
            progInfo = new JSonFile(ePrograms.getProgram(program));

            if (!progInfo.hasErrors())
            {
                // Init csystem.ProgramErrors and debug for program execution
                csystem.NewProgram(program_name);
                debug = csystem.ProgramDebug;

                csystem.ProgramErrors.Name        = Name;
                csystem.ProgramErrors.Description = Description;
                debug.Name        = Name;
                debug.Description = Description;

                // Init vars
                vars = new Dictionary <string, object>();
                foreach (JValue var in Variables)
                {
                    if (!vars.ContainsKey(var.Value.ToString()))
                    {
                        vars.Add(var.Value.ToString(), null);
                    }
                }
            }
            else
            {
                csystem.ProgramErrors.invalidJSON = progInfo.jErrors;
            }
        }
Exemplo n.º 17
0
 public CStructModifications(CSystem system, CGlobals app_globals)
 {
     sys        = system;
     Globals    = app_globals;
     cVistas    = Globals.AppDataSection(dPATH.VIEWS);
     cProgramas = Globals.AppDataSection(dPATH.PROGRAM);
     cProcesos  = Globals.AppDataSection(dPATH.PROCESSES);
 }
Exemplo n.º 18
0
 /// <summary>
 /// Constructor for runner
 /// </summary>
 /// <param name="views_manager"></param>
 public CRunner(CSystem csystem, CViewsManager views_manager)
 {
     sys         = csystem;
     vm          = views_manager;
     tasks       = new Dictionary <string, Task>();
     slogic      = new Stack();
     sevent_desc = new Stack();
     sprogram    = new Stack();
 }
Exemplo n.º 19
0
 /// <summary>
 /// 绑定当前对象数据
 /// </summary>
 public void Bind()
 {
     if (m_CurrentCustom == null)
     {
         this.textEdit2.Text = System.DateTime.Now.ToString();
         string jmLock = APP.GoldSoftClient.CurrentCustom.JMLOCK;
         //调用远程方法 获取积分
         string wb_web = CSystem.GetAppConfig("wb");
         this.textEdit4.Text = CustomBAL.getJF(wb_web, jmLock);
         this.cEntitySuomanagerBindingSource.DataSource = APP.GoldSoftClient.CurrentCustom;
     }
 }
Exemplo n.º 20
0
        /// <summary>
        /// 绑定当前对象数据
        /// </summary>
        public void Bind()
        {
            if (m_CurrentCustom == null)
            {
                string jmLock = APP.GoldSoftClient.CurrentCustom.JMLOCK;

                string wb_web = CSystem.GetAppConfig("wb");
                //调用远程方法 获取积分
                this.textEdit4.Text = CustomBAL.getJF(wb_web, jmLock);

                CustomBAL.BDsuoManagerExtendInfo(wb_web, jmLock);
                //BDsuoManagerExtendInfo(wb_web, jmLock);
                this.rd_y_yhcl.Checked = APP.GXKG;
                this.rd_y_zjfa.Checked = APP.ZGFAKG;
                this.rd_y_bcde.Checked = APP.BCQDKG;


                if (APP.GoldSoftClient.CurrentCustom.SOFT_USE == "个人")
                {
                    this.rdo_use_person.Checked = true;
                }
                else
                {
                    this.rdo_use_unit.Checked = true;
                }
                if (APP.GoldSoftClient.CurrentCustom.SEX == "男")
                {
                    this.rd_man.Checked = true;
                }
                else
                {
                    this.rd_wman.Checked = true;
                }
                this.cEntitySuomanagerBindingSource.DataSource = APP.GoldSoftClient.CurrentCustom;

                this.rdo_use_unit.Enabled   = false;
                this.rdo_use_person.Enabled = false;



                if (this.rdo_use_unit.Checked)
                {
                    this.txt_ZCDWNAME.Enabled = false;
                }
                if (this.rdo_use_person.Checked)
                {
                    this.txt_CUSTOMERNAME.Enabled = false;
                    this.txtIdCard.Enabled        = false;
                }
            }
        }
Exemplo n.º 21
0
 public TProcess(CSystem csystem, ref Dictionary <String, Object> program_vars, JObject prc)
 {
     sys        = csystem;
     vars       = program_vars;
     pActivePrc = new JSonFile(prc);
     if (!loadBaseProcess(sys.Globals))
     {
         csystem.ProgramErrors.invalidJSON =
             String.Format("Error loading json: file not found {0}.{1}.json containing process guid: {2}",
                           dPATH.PROCESSES,
                           Namespace,
                           Guid);
     }
 }
Exemplo n.º 22
0
 public TProcess(CSystem csystem, CSystem csystem_app, JObject prc)
 {
     pActivePrc = new JSonFile(prc);
     if (!loadBaseProcess(csystem))
     {
         if (!loadBaseProcess(csystem_app))
         {
             csystem.ProgramErrors.invalidJSON =
                 String.Format("Error loading json: file not found {0}.{1}. ",
                               dPATH.PROCESSES,
                               Namespace);
         }
     }
 }
Exemplo n.º 23
0
        public TProcess(CSystem csystem, ref Dictionary <String, Object> program_vars, JObject prc)
        {
            vars       = program_vars;
            pActivePrc = new JSonFile(prc);

            #region get base process from string
            Type tobj = typeof(CLogic);

            String var_base_process             = "BP_" + TLogic.Utils.escape_sc(prc[dPROCESS.GUID].ToString());
            System.Reflection.PropertyInfo JSON = tobj.GetProperty(var_base_process);
            String json_value = JSON.GetValue(null).ToString();
            pBasePrc = new JSonFile(JObject.Parse(System.Text.UTF8Encoding.UTF8.GetString(Convert.FromBase64String(json_value))));
            #endregion
        }
Exemplo n.º 24
0
        /// <summary>
        /// Constructor
        /// </summary>
        /// <param name="base_errors"></param>
        /// <param name="base_debug"></param>
        /// <param name="MainView"></param>
        public CViewsManager(CSystem csystem)
        {
            cs      = csystem;
            globals = csystem.Globals;
            errors  = csystem.errors;
            debug   = csystem.debug;

            listViews = new List <CView>();

            String MainView_name = Globals.get(dGLOBALS.MAIN_VIEW).ToString();

            if (MainView_name != "")
            {
                AddView(MainView_name);
            }
        }
Exemplo n.º 25
0
        /// <summary>
        /// Primary constructor to call from view manager
        /// </summary>
        /// <param name="base_errors"></param>
        /// <param name="base_debug"></param>
        /// <param name="view_name"></param>
        public CView(CSystem csystem, String view_name)
        {
            Globals   = csystem.Globals;
            errors    = csystem.errors;
            debug     = csystem.debug;
            vars      = new Dictionary <string, object>();
            View_name = view_name;
            View_guid = Guid.NewGuid().ToString();
            ctrls     = new Dictionary <String, CtrlStruct>();
            objects   = new Dictionary <String, ObjStruct>();

            // Create main control and descendants
            CreateControl(view_name);

            // Create other objects
            CreateObjects(view_name);
        }
Exemplo n.º 26
0
        /// <summary>
        /// 提交数据到服务器
        /// </summary>
        /// <param name="sender"></param>
        /// <param name="e"></param>
        private void simpleButton1_Click2(object sender, EventArgs e)
        {
            //建立表结构
            createTable();
            //调用借口方法
            //ServiceReference1.WebSuoSoapClient my_webservice = new GOLDSOFT.QDJJ.UI.ServiceReference1.WebSuoSoapClient();
            //获取DataTable信息
            DataTable dt = getTable();

            if (dt != null)
            {
                string wb_web = CSystem.GetAppConfig("wb");

                bool sige = CustomBAL.updateBDsuoManager(wb_web, dt);
                if (sige)
                {
                    MessageBox.Show("修改成功");
                }
                else
                {
                    MessageBox.Show("修改不成功");
                }
            }
            else
            {
                MessageBox.Show("表为空");
            }



            /////获取输入信息
            //CEntitySuomanager info = this.cEntitySuomanagerBindingSource.Current as CEntitySuomanager;
            //info.ISFIRST = "1";
            //int result = APP.GoldSoftClient.TryUpdateCustomer(info);
            //if (result == ResultConst.SERVER_SUCCESS)
            //{
            //    //成功
            //    MsgBox.Alert("资料已经提交成功等待审核");
            //}
            //else
            //{
            //    MsgBox.Alert("提交失败,稍后尝试!");
            //}
        }
Exemplo n.º 27
0
        public CProgram(CSystem csystem, CGlobals Globals, String program, object program_vars = null)
        {
            sys = csystem;
            // Remove program queued flag
            program_name = (program.StartsWith("&")) ? program.Substring(1) : program;
            // Read program
            progInfo = new JSonFile(Globals.AppDataSection(dPATH.PROGRAM), program_name, true);

            if (!progInfo.hasErrors())
            {
                // Init csystem.ProgramErrors and debug for program execution
                csystem.ProgramErrors = new TErrors(Globals, program);
                csystem.ProgramDebug  = new TDebug(Globals, program);
                debug = csystem.ProgramDebug;

                csystem.ProgramErrors.Name        = Name;
                csystem.ProgramErrors.Description = Description;
                debug.Name        = Name;
                debug.Description = Description;

                // Init vars
                if (program_vars == null)
                {
                    vars = new Dictionary <string, object>();
                }
                else
                {
                    vars = (Dictionary <string, object>)program_vars;
                }
                foreach (JValue var in Variables)
                {
                    if (!vars.ContainsKey(var.Value.ToString()))
                    {
                        vars.Add(var.Value.ToString(), null);
                    }
                }
            }
            else
            {
                csystem.ProgramErrors             = new TErrors(Globals, program);
                csystem.ProgramErrors.invalidJSON = progInfo.jErrors;
            }
        }
Exemplo n.º 28
0
        private void MenuItemSetSystemDiagram_Click(object sender, EventArgs e)
        {
            if (treeLeft.SelectedNode == null)
            {
                return;
            }
            TreeNode       pNode  = treeLeft.SelectedNode.Parent;
            CSystem        system = (CSystem)pNode.Tag;
            SelDiagramForm frm    = new SelDiagramForm();

            if (frm.ShowDialog() != DialogResult.OK)
            {
                return;
            }
            system.FW_Diagram_id = frm.m_SelDiagram.Id;
            if (!Program.Ctx.SystemMgr.Update(system))
            {
                MessageBox.Show("修改失败!", "错误", MessageBoxButtons.OK, MessageBoxIcon.Asterisk);
            }
        }
Exemplo n.º 29
0
        CView.CtrlStruct fireCtrl_str; // Controls struct who fire the event
        #endregion

        #region initialize

        /// <summary>
        /// Load all information from UI to work with
        /// </summary>
        /// <param name="viewManager"></param>
        /// <param name="eventDesc"></param>
        public CLogic(CSystem csystem, CViewsManager views_manager, CEventDesc eventDesc)
        {
            sys        = csystem;
            vm         = views_manager;
            Globals    = sys.Globals;
            errors     = sys.ProgramErrors;
            debug      = sys.ProgramDebug;
            event_desc = eventDesc;
            if (event_desc != null)
            {
                view = (event_desc.View_Guid != "") ? vm.getFirstView_byGuid(event_desc.View_Guid) : null;
                if (view != null)
                {
                    mainCtrl     = view.mainControl();
                    fireCtrl_str = view.getCtrlStruct(eventDesc.Control_Name);
                }
                fireCtrl = (Control)event_desc.fireCtrl;
                args     = event_desc.args;
            }
            MainView = ((view != null) && (Globals.get_str(dGLOBALS.MAIN_VIEW) == view.Name)) ? view : vm.getFirstView(Globals.get_str(dGLOBALS.MAIN_VIEW));
        }
Exemplo n.º 30
0
        private void simpleButton1_Click(object sender, EventArgs e)
        {
            string wb_web = CSystem.GetAppConfig("wb");

            APP.GoldSoftClient.PBBF = this.rdoZH.Checked ? "综合评估法" : "合理低价法";

            int cost = 0;

            try
            {
                cost = WebServiceHelper.InvokeMethod <int>(wb_web, "getJiFenJL", APP.GoldSoftClient.CurrentCustom.JMLOCK);
            }
            catch
            {
                MsgBox.Alert("获取积分时出现错误,请重试");
                return;
            }

            Dictionary <string, object> result = null;

            if (Validate(cost, out result))
            {
                BeginAnalyze1 begin1 = new BeginAnalyze1(result);
                begin1.MdiParent  = this.MdiParent;
                begin1.pInfo      = this.pInfo;
                begin1.DataSource = this.DataSource;
                begin1._sender    = this._sender;
                begin1.ShowDialog();
                if (this.rdoZH.Checked)
                {
                    APP.GoldSoftClient.TBMethod = false;
                }
                else
                {
                    APP.GoldSoftClient.TBMethod = true;
                }

                this.Close();
            }
        }