| | |
| | | using DevExpress.XtraBars.Customization; |
| | | using Yw.CAL.HttpClient; |
| | | |
| | | namespace HStation.WinFrmUI |
| | | { |
| | |
| | | _isInitialize = true; |
| | | var allFlagList = await _bllFlag.Value.GetBySysType(HStation.Xhs.DataType.XhsProject); |
| | | if (allFlagList == null) |
| | | { |
| | | return; |
| | | } |
| | | this.setFlagsEditCtrl1.SetBindingData(allFlagList.Select(x => x.Name).ToList(), null); |
| | | } |
| | | |
| | |
| | | { |
| | | get |
| | | { |
| | | _vm.ZipFile = this.btnEditSelectModelFile.Text.Trim(); |
| | | /* if (_vm.ZipFile != string.Empty) |
| | | { |
| | | AllowImport = true; |
| | | AutoAddItem.Invoke(); |
| | | } |
| | | else |
| | | { |
| | | AllowImport = false; |
| | | DeleteItem.Invoke(); |
| | | }*/ |
| | | return _isInitialize; |
| | | } |
| | | } |
| | |
| | | /// </summary> |
| | | public bool CanPrev() |
| | | { |
| | | return true; |
| | | return false; |
| | | } |
| | | |
| | | /// <summary> |
| | |
| | | } |
| | | _vm.Name = this.txtName.Text.Trim(); |
| | | _vm.Customer = this.txtCustomer.Text.Trim(); |
| | | // _vm.Address = this.txtAddress.Text.Trim(); |
| | | _vm.Flags = null; |
| | | _vm.Flags = this.setFlagsEditCtrl1.SelectedFlagList; |
| | | _vm.TagName = tagName; |
| | | _vm.Description = this.txtDescription.Text.Trim(); |
| | | return true; |
| | |
| | | |
| | | private void btnEditSelectModelFile_ButtonClick(object sender, DevExpress.XtraEditors.Controls.ButtonPressedEventArgs e) |
| | | { |
| | | var suffix = Settings.XhsParasHelper.Xhs.File.Suffix; |
| | | var dlg = new OpenFileDialog(); |
| | | dlg.Filter = $"模型文件(*{suffix})|*{suffix}"; |
| | | dlg.FilterIndex = 1; |
| | | if (dlg.ShowDialog() == DialogResult.OK) |
| | | if (e.Button.Tag.ToString() == "Local") |
| | | { |
| | | var fileName = dlg.FileName; |
| | | this.btnEditSelectModelFile.EditValue = fileName; |
| | | var suffix = Settings.XhsParasHelper.Xhs.File.Suffix; |
| | | var dlg = new OpenFileDialog(); |
| | | dlg.Filter = $"模型文件(*{suffix})|*{suffix}"; |
| | | dlg.FilterIndex = 1; |
| | | if (dlg.ShowDialog() == DialogResult.OK) |
| | | { |
| | | var fileName = dlg.FileName; |
| | | this.btnEditSelectModelFile.EditValue = fileName; |
| | | _vm.IsLocal = true; |
| | | _vm.LocalZipFile = fileName; |
| | | } |
| | | } |
| | | else |
| | | { |
| | | var dlg = new SelectXhsProjectTransferFileDlg(); |
| | | dlg.SetBindingData(); |
| | | dlg.ReloadDataEvent += async (rhs) => |
| | | { |
| | | this.btnEditSelectModelFile.EditValue = rhs.FileName; |
| | | _vm.IsLocal = false; |
| | | _vm.TransferRevitFile = rhs; |
| | | }; |
| | | dlg.ShowDialog(); |
| | | } |
| | | |
| | | } |
| | | |
| | | |
| | | } |
| | | } |