public FormReaderInfo(AccessDataBase.Model.ReaderInfo modelReaderInfo, OpenMode openMode)
        {
            InitializeComponent();
            this.CenterToScreen();
            this.MaximizeBox     = false;
            this.MinimizeBox     = false;
            this.FormBorderStyle = System.Windows.Forms.FormBorderStyle.FixedSingle;
            this.Icon            = GetResourcesFile.getSystemIco();

            this.modelReaderInfo = modelReaderInfo;
            this.openMode        = openMode;
            for (int i = 0; i < 7; i++)
            {
                arrarymodelReaderTimeZone[i] = new AccessDataBase.Model.ReaderTimeZone();
            }

            if (openMode == OpenMode.Add)
            {
                showAddPara();
            }
            else if (openMode == OpenMode.Update)
            {
                this.modelReaderInfo = bllReaderInfo.GetModel(modelReaderInfo.ReaderID);
                showUpdatePara();
            }
        }
        public FormCompany(AccessDataBase.Model.CompanyInfo companyInfo, OpenMode openMode)
        {
            InitializeComponent();

            this.CenterToScreen();
            this.MaximizeBox     = false;
            this.MinimizeBox     = false;
            this.FormBorderStyle = System.Windows.Forms.FormBorderStyle.FixedSingle;
            this.Icon            = GetResourcesFile.getSystemIco();

            this.modelCompanyInfo = companyInfo;
            this.openMode         = openMode;

            if (openMode == OpenMode.Add)
            {
                kryptonTextBoxCompanyID.Text = companyInfo.CompanyID.ToString();
            }
            else if (openMode == OpenMode.Update)
            {
                kryptonTextBoxCompanyID.Text   = companyInfo.CompanyID.ToString();
                kryptonTextBoxCompanyName.Text = companyInfo.CompanyName.ToString();
                kryptonTextBoxCompanyDes.Text  = companyInfo.CompanyDes.ToString();
                kryptonTextBoxCompanyAddr.Text = companyInfo.CompanyAddress.ToString();
                kryptonTextBoxTelPhone1.Text   = companyInfo.CompanyTel1.ToString();
                kryptonTextBoxTelPhone2.Text   = companyInfo.CompanyTel2.ToString();
            }
        }
Esempio n. 3
0
        public FormElectronicMap(AccessDataBase.Model.ElectronicMap modelElectronicMap, OpenMode openMode)
        {
            InitializeComponent();

            this.StartPosition   = FormStartPosition.CenterParent;
            this.FormBorderStyle = System.Windows.Forms.FormBorderStyle.FixedSingle;
            this.MaximizeBox     = false;
            this.MinimizeBox     = false;
            this.Icon            = GetResourcesFile.getSystemIco();

            this.openMode = openMode;
            if (modelElectronicMap != null)
            {
                this.modelElectronicMap = modelElectronicMap;
            }
            initUI();
            if (this.openMode == OpenMode.Add)
            {
            }
            else if (this.openMode == OpenMode.Update)
            {
                textBoxElectronicMapName.Text    = modelElectronicMap.ElectronicMapName;
                textBoxElectronicMapName.Enabled = false;
                List <KryptonAccessController.AccessDataBase.Model.ElectronicMap> listElectronicMap = bllElectronicMap.GetModelList("ElectronicMapName = '" + modelElectronicMap.ElectronicMapName + "'");
                textBoxElectronicMapDes.Text = listElectronicMap[0].ElectronicMapDes;
            }
        }
Esempio n. 4
0
        private void FormDataBaseLogin_Load(object sender, EventArgs e)
        {
            kryptonTextBoxDataSource.Text   = IniFile.getDataSource();
            kryptonTextBoxDataBaseName.Text = IniFile.getDataBaseName();
            kryptonTextBoxUserName.Text     = IniFile.getUserID();
            kryptonTextBoxPassword.Text     = IniFile.getPassword();
            this.Icon = GetResourcesFile.getSystemIco();

            if (string.IsNullOrEmpty(kryptonTextBoxDataSource.Text))
            {
                IniFile.setHide("false");
            }
            else if (string.IsNullOrEmpty(kryptonTextBoxDataBaseName.Text))
            {
                IniFile.setHide("false");
            }
            else if (string.IsNullOrEmpty(kryptonTextBoxUserName.Text))
            {
                IniFile.setHide("false");
            }
            else if (string.IsNullOrEmpty(kryptonTextBoxPassword.Text))
            {
                IniFile.setHide("false");
            }

            if (IniFile.getHide() == "true")
            {
                kryptonButtonOk_Click(sender, e);
            }
        }
        public FormDepartment(AccessDataBase.Model.DepartmentInfo modelDepartmentInfo, OpenMode openMode)
        {
            InitializeComponent();
            InitComboBoxCompany();

            this.CenterToScreen();
            this.MaximizeBox     = false;
            this.MinimizeBox     = false;
            this.FormBorderStyle = System.Windows.Forms.FormBorderStyle.FixedSingle;
            this.Icon            = GetResourcesFile.getSystemIco();

            this.modelDepartmentInfo = modelDepartmentInfo;
            this.openMode            = openMode;

            if (openMode == OpenMode.Add)
            {
                kryptonTextBoxDepartmentID.Text = modelDepartmentInfo.DepartmentID.ToString();
            }
            else if (openMode == OpenMode.Update)
            {
                string companyName = modelDepartmentInfo.CompanyName;//.CompanyID.HasValue?modelDepartmentInfo.CompanyID.Value:0;
                modelCompanyInfo = bllCompanyInfo.GetModelList("CompanyName = '" + companyName + "'")[0];

                kryptonTextBoxDepartmentID.Text   = modelDepartmentInfo.DepartmentID.ToString();
                kryptonComboBoxCompany.Text       = modelCompanyInfo.CompanyName.ToString();
                kryptonTextBoxDepartmentName.Text = modelDepartmentInfo.DepartmentName.ToString();
                kryptonTextBoxDepartmentTel1.Text = modelDepartmentInfo.DepartmentTel1.ToString();
                kryptonTextBoxDepartmentTel2.Text = modelDepartmentInfo.DepartmentTel2.ToString();
                kryptonTextBoxDepartmentDes.Text  = modelDepartmentInfo.DepartmentDes.ToString();
            }
        }
Esempio n. 6
0
 public FormChangePassword()
 {
     InitializeComponent();
     this.CenterToScreen();
     this.MaximizeBox     = false;
     this.MinimizeBox     = false;
     this.Icon            = GetResourcesFile.getSystemIco();
     this.FormBorderStyle = System.Windows.Forms.FormBorderStyle.FixedSingle;
 }
Esempio n. 7
0
        public FormAboutUs()
        {
            InitializeComponent();

            this.FormBorderStyle = System.Windows.Forms.FormBorderStyle.FixedSingle;
            this.MaximizeBox     = false;
            this.MinimizeBox     = false;
            this.StartPosition   = FormStartPosition.CenterParent;
            this.Icon            = GetResourcesFile.getSystemIco();
        }
        private void Ktypton1_Load(object sender, EventArgs e)
        {
            this.CenterToScreen();
            //this.FormBorderStyle = FormBorderStyle.None;
            this.MaximizeBox = false;
            this.MinimizeBox = false;

            this.Icon = GetResourcesFile.getSystemIco();
            initComboBoxUserName(comboBoxUserName);
            labelFailInfo.Text = "";
        }
Esempio n. 9
0
        public FormController(AccessDataBase.Model.ControllerInfo ModelControllerInfo, OpenMode openMode)
        {
            InitializeComponent();

            doorUnit1.KryptonButtonReaderAdd1.Click         += KryptonButtonReaderAddClick1;
            doorUnit1.KryptonButtonReaderAdd2.Click         += KryptonButtonReaderAddClick1;
            doorUnit1.KryptonButtonReaderUpdate1.Click      += KryptonButtonReaderUpdateClick1;
            doorUnit1.KryptonButtonReaderUpdate2.Click      += KryptonButtonReaderUpdateClick1;
            doorUnit1.KryptonCheckBoxReader1.CheckedChanged += KryptonCheckBoxReaderCheckedChanged1;
            doorUnit1.KryptonCheckBoxReader2.CheckedChanged += KryptonCheckBoxReaderCheckedChanged1;

            doorUnit2.KryptonButtonReaderAdd1.Click         += KryptonButtonReaderAddClick1;
            doorUnit2.KryptonButtonReaderAdd2.Click         += KryptonButtonReaderAddClick1;
            doorUnit2.KryptonButtonReaderUpdate1.Click      += KryptonButtonReaderUpdateClick2;
            doorUnit2.KryptonButtonReaderUpdate2.Click      += KryptonButtonReaderUpdateClick2;
            doorUnit2.KryptonCheckBoxReader1.CheckedChanged += KryptonCheckBoxReaderCheckedChanged2;
            doorUnit2.KryptonCheckBoxReader2.CheckedChanged += KryptonCheckBoxReaderCheckedChanged2;

            doorUnit3.KryptonButtonReaderAdd1.Click         += KryptonButtonReaderAddClick1;
            doorUnit3.KryptonButtonReaderAdd2.Click         += KryptonButtonReaderAddClick1;
            doorUnit3.KryptonButtonReaderUpdate1.Click      += KryptonButtonReaderUpdateClick3;
            doorUnit3.KryptonButtonReaderUpdate2.Click      += KryptonButtonReaderUpdateClick3;
            doorUnit3.KryptonCheckBoxReader1.CheckedChanged += KryptonCheckBoxReaderCheckedChanged3;
            doorUnit3.KryptonCheckBoxReader2.CheckedChanged += KryptonCheckBoxReaderCheckedChanged3;

            doorUnit4.KryptonButtonReaderAdd1.Click         += KryptonButtonReaderAddClick4;
            doorUnit4.KryptonButtonReaderAdd2.Click         += KryptonButtonReaderAddClick4;
            doorUnit4.KryptonButtonReaderUpdate1.Click      += KryptonButtonReaderUpdateClick4;
            doorUnit4.KryptonButtonReaderUpdate2.Click      += KryptonButtonReaderUpdateClick4;
            doorUnit4.KryptonCheckBoxReader1.CheckedChanged += KryptonCheckBoxReaderCheckedChanged4;
            doorUnit4.KryptonCheckBoxReader2.CheckedChanged += KryptonCheckBoxReaderCheckedChanged4;

            this.CenterToScreen();
            this.MaximizeBox     = false;
            this.MinimizeBox     = false;
            this.FormBorderStyle = System.Windows.Forms.FormBorderStyle.FixedSingle;
            this.Icon            = GetResourcesFile.getSystemIco();

            this.modelControllerInfo = ModelControllerInfo;
            this.openMode            = openMode;
            for (int i = 0; i < 4; i++)
            {
                arrayDoorUnitInfo[i] = new AccessDataBase.Model.DoorUnitInfo();
            }

            if (openMode == OpenMode.Add)
            {
                showAddPara();
            }
            else if (openMode == OpenMode.Update)
            {
                showUpdatePara();
            }
        }
        private void FormDeviceManage_Load(object sender, EventArgs e)
        {
            this.FormBorderStyle = System.Windows.Forms.FormBorderStyle.FixedSingle;
            this.CenterToScreen();
            this.MaximizeBox = false;
            this.MinimizeBox = false;

            this.Icon = GetResourcesFile.getSystemIco();

            readIpAddrToTextFile();
        }
Esempio n. 11
0
        public FormDataBase()
        {
            InitializeComponent();

            this.CenterToScreen();
            this.MaximizeBox     = false;
            this.MinimizeBox     = false;
            this.FormBorderStyle = System.Windows.Forms.FormBorderStyle.FixedSingle;
            this.Icon            = GetResourcesFile.getSystemIco();

            initUserInterface();
        }
        private ManagerInfo()
        {
            InitializeComponent();

            this.CenterToScreen();
            this.MaximizeBox = false;
            this.MinimizeBox = false;
            this.Icon        = GetResourcesFile.getSystemIco();

            initToolStripMenu();
            refreshDataGridView();
        }
        private TimeAccessInfo()
        {
            InitializeComponent();
            this.CenterToScreen();
            this.MaximizeBox = false;
            this.MinimizeBox = false;
            this.Icon        = GetResourcesFile.getSystemIco();

            kryptonContextMenuItem3.Click += new EventHandler(kryptonContextMenuItem3_Click);
            kryptonContextMenuItem2.Click += new EventHandler(kryptonContextMenuItem2_Click);

            initToolStripMenu();
        }
        private FormRealTimeMoni()
        {
            InitializeComponent();
            initToolStripControlConsole();
            initPictureBoxTitle();

            this.CenterToScreen();
            //this.MaximizeBox = false;
            //this.MinimizeBox = false;
            this.Icon = GetResourcesFile.getSystemIco();

            showlistViewElectronicMap();
            showlistViewAccess();
            displayFormOnPanel1(formPictureMovable);
        }
        public FormManager(AccessDataBase.Model.Manager modelManager, OpenMode openMode)
        {
            InitializeComponent();

            this.CenterToScreen();
            this.MaximizeBox     = false;
            this.MinimizeBox     = false;
            this.Icon            = GetResourcesFile.getSystemIco();
            this.FormBorderStyle = System.Windows.Forms.FormBorderStyle.FixedSingle;

            this.modelManager = modelManager;
            this.openMode     = openMode;
            if (openMode == OpenMode.Update)
            {
                kryptonTextBoxName.Text    = modelManager.ManagerName;
                kryptonTextBoxName.Enabled = false;
            }
        }
        public FormLogin(OpenMode openMode)
        {
            InitializeComponent();

            this.CenterToScreen();
            this.MaximizeBox     = false;
            this.MinimizeBox     = false;
            this.FormBorderStyle = System.Windows.Forms.FormBorderStyle.FixedSingle;
            this.Icon            = GetResourcesFile.getSystemIco();

            initUserInterface();

            if (openMode == OpenMode.Unclock)
            {
                buttonCancel.Visible     = false;
                comboBoxUserName.Enabled = false;

                buttonLogin.Location = new Point((this.Width - buttonLogin.Width) / 2, buttonLogin.Location.Y);
            }
        }
Esempio n. 17
0
        public FormCard(AccessDataBase.Model.CardInfo cardInfo, OpenMode openMode)
        {
            InitializeComponent();
            this.CenterToScreen();
            this.MaximizeBox     = false;
            this.MinimizeBox     = false;
            this.Icon            = GetResourcesFile.getSystemIco();
            this.FormBorderStyle = System.Windows.Forms.FormBorderStyle.FixedSingle;

            this.modelCardInfo = cardInfo;
            this.openMode      = openMode;
            if (openMode == OpenMode.Add)
            {
                showAddPara();
            }
            else if (openMode == OpenMode.Update)
            {
                showUpdatePara();
            }
        }
Esempio n. 18
0
        public FormReaderHoliday(OpenMode openMode, AccessDataBase.Model.ReaderInfo modelReaderInfo, AccessDataBase.Model.ReaderHoliday modelHoliay)
        {
            InitializeComponent();
            this.MaximizeBox     = false;
            this.MinimizeBox     = false;
            this.FormBorderStyle = System.Windows.Forms.FormBorderStyle.FixedSingle;
            this.Icon            = GetResourcesFile.getSystemIco();
            this.CenterToScreen();

            this.openMode        = openMode;
            this.modelReaderInfo = modelReaderInfo;
            this.modelHoliay     = modelHoliay;
            if (openMode == OpenMode.Update)
            {
                kryptonDateTimePickerStartDate.Value = Convert.ToDateTime(modelHoliay.ReaderHolidayStartDate);
                kryptonDateTimePickerEndDate.Value   = Convert.ToDateTime(modelHoliay.ReaderHolidayEndDate);
            }
            else if (openMode == OpenMode.Add)
            {
            }
        }
        public FormMain(AccessDataBase.Model.Manager model)
        {
            InitializeComponent();
            this.model = model;
            this.CenterToScreen();
            this.WindowState      = FormWindowState.Maximized;
            this.Icon             = GetResourcesFile.getSystemIco();
            this.notifyIcon1.Icon = GetResourcesFile.getSystemIco();
            this.notifyIcon1.Text = this.Text;

            this.toolStripStatusLabel2.Text = "";
            this.toolStripStatusLabel3.Text = DateTime.Now.ToString("yyyy-MM-dd hh:mm:ss");
            this.timer1.Interval            = 1000;
            this.timer1.Start();

            initUserInterface();

            //WidgetThread.WidgetThread.displayFormOnPanel(this.splitContainer1.Panel2.Controls, webServer);
            //webServer.BringToFrontAndRefresh();

            toolStripMenuItemController_Click(null, null);
        }
 private void WebServer_Load(object sender, EventArgs e)
 {
     this.Icon       = GetResourcesFile.getSystemIco();
     webBrowser1.Url = new System.Uri(url, System.UriKind.Absolute);
 }