wsp-10256 Importing Exchange mailboxes

This commit is contained in:
dev_amdtel 2014-12-04 18:10:38 +04:00
parent 8d616552fe
commit 5bebce9e60
6 changed files with 414 additions and 344 deletions

View file

@ -28,296 +28,319 @@ namespace WebsitePanel.Import.Enterprise
/// </summary> /// </summary>
private void InitializeComponent() private void InitializeComponent()
{ {
this.components = new System.ComponentModel.Container(); this.components = new System.ComponentModel.Container();
System.ComponentModel.ComponentResourceManager resources = new System.ComponentModel.ComponentResourceManager(typeof(ApplicationForm)); System.ComponentModel.ComponentResourceManager resources = new System.ComponentModel.ComponentResourceManager(typeof(ApplicationForm));
this.lblSpace = new System.Windows.Forms.Label(); this.lblSpace = new System.Windows.Forms.Label();
this.txtSpace = new System.Windows.Forms.TextBox(); this.txtSpace = new System.Windows.Forms.TextBox();
this.btnBrowseSpace = new System.Windows.Forms.Button(); this.btnBrowseSpace = new System.Windows.Forms.Button();
this.btnBrowseOU = new System.Windows.Forms.Button(); this.btnBrowseOU = new System.Windows.Forms.Button();
this.txtOU = new System.Windows.Forms.TextBox(); this.txtOU = new System.Windows.Forms.TextBox();
this.lblOU = new System.Windows.Forms.Label(); this.lblOU = new System.Windows.Forms.Label();
this.grpOrganization = new System.Windows.Forms.GroupBox(); this.grpOrganization = new System.Windows.Forms.GroupBox();
this.btnSelectAll = new System.Windows.Forms.Button(); this.cbMailboxPlan = new System.Windows.Forms.ComboBox();
this.btnDeselectAll = new System.Windows.Forms.Button(); this.lblMailnoxPlan = new System.Windows.Forms.Label();
this.rbCreateAndImport = new System.Windows.Forms.RadioButton(); this.btnSelectAll = new System.Windows.Forms.Button();
this.rbImport = new System.Windows.Forms.RadioButton(); this.btnDeselectAll = new System.Windows.Forms.Button();
this.lvUsers = new System.Windows.Forms.ListView(); this.rbCreateAndImport = new System.Windows.Forms.RadioButton();
this.columnHeader1 = new System.Windows.Forms.ColumnHeader(); this.rbImport = new System.Windows.Forms.RadioButton();
this.columnHeader2 = new System.Windows.Forms.ColumnHeader(); this.lvUsers = new System.Windows.Forms.ListView();
this.columnHeader3 = new System.Windows.Forms.ColumnHeader(); this.columnHeader1 = ((System.Windows.Forms.ColumnHeader)(new System.Windows.Forms.ColumnHeader()));
this.images = new System.Windows.Forms.ImageList(this.components); this.columnHeader2 = ((System.Windows.Forms.ColumnHeader)(new System.Windows.Forms.ColumnHeader()));
this.txtOrgName = new System.Windows.Forms.TextBox(); this.columnHeader3 = ((System.Windows.Forms.ColumnHeader)(new System.Windows.Forms.ColumnHeader()));
this.lblOrgName = new System.Windows.Forms.Label(); this.images = new System.Windows.Forms.ImageList(this.components);
this.txtOrgId = new System.Windows.Forms.TextBox(); this.txtOrgName = new System.Windows.Forms.TextBox();
this.lblOrgId = new System.Windows.Forms.Label(); this.lblOrgName = new System.Windows.Forms.Label();
this.btnStart = new System.Windows.Forms.Button(); this.txtOrgId = new System.Windows.Forms.TextBox();
this.progressBar = new System.Windows.Forms.ProgressBar(); this.lblOrgId = new System.Windows.Forms.Label();
this.lblMessage = new System.Windows.Forms.Label(); this.btnStart = new System.Windows.Forms.Button();
this.grpOrganization.SuspendLayout(); this.progressBar = new System.Windows.Forms.ProgressBar();
this.SuspendLayout(); this.lblMessage = new System.Windows.Forms.Label();
// this.grpOrganization.SuspendLayout();
// lblSpace this.SuspendLayout();
// //
this.lblSpace.Location = new System.Drawing.Point(15, 15); // lblSpace
this.lblSpace.Name = "lblSpace"; //
this.lblSpace.Size = new System.Drawing.Size(125, 23); this.lblSpace.Location = new System.Drawing.Point(15, 15);
this.lblSpace.TabIndex = 0; this.lblSpace.Name = "lblSpace";
this.lblSpace.Text = "Target Hosting Space:"; this.lblSpace.Size = new System.Drawing.Size(125, 23);
// this.lblSpace.TabIndex = 0;
// txtSpace this.lblSpace.Text = "Target Hosting Space:";
// //
this.txtSpace.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left) // txtSpace
| System.Windows.Forms.AnchorStyles.Right))); //
this.txtSpace.Location = new System.Drawing.Point(146, 12); this.txtSpace.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left)
this.txtSpace.Name = "txtSpace"; | System.Windows.Forms.AnchorStyles.Right)));
this.txtSpace.ReadOnly = true; this.txtSpace.Location = new System.Drawing.Point(146, 12);
this.txtSpace.Size = new System.Drawing.Size(429, 20); this.txtSpace.Name = "txtSpace";
this.txtSpace.TabIndex = 1; this.txtSpace.ReadOnly = true;
this.txtSpace.TextChanged += new System.EventHandler(this.OnDataChanged); this.txtSpace.Size = new System.Drawing.Size(426, 20);
// this.txtSpace.TabIndex = 1;
// btnBrowseSpace this.txtSpace.TextChanged += new System.EventHandler(this.OnDataChanged);
// //
this.btnBrowseSpace.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right))); // btnBrowseSpace
this.btnBrowseSpace.Location = new System.Drawing.Point(581, 10); //
this.btnBrowseSpace.Name = "btnBrowseSpace"; this.btnBrowseSpace.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right)));
this.btnBrowseSpace.Size = new System.Drawing.Size(24, 22); this.btnBrowseSpace.Location = new System.Drawing.Point(578, 10);
this.btnBrowseSpace.TabIndex = 2; this.btnBrowseSpace.Name = "btnBrowseSpace";
this.btnBrowseSpace.Text = "..."; this.btnBrowseSpace.Size = new System.Drawing.Size(24, 22);
this.btnBrowseSpace.UseVisualStyleBackColor = true; this.btnBrowseSpace.TabIndex = 2;
this.btnBrowseSpace.Click += new System.EventHandler(this.OnBrowseSpace); this.btnBrowseSpace.Text = "...";
// this.btnBrowseSpace.UseVisualStyleBackColor = true;
// btnBrowseOU this.btnBrowseSpace.Click += new System.EventHandler(this.OnBrowseSpace);
// //
this.btnBrowseOU.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right))); // btnBrowseOU
this.btnBrowseOU.Location = new System.Drawing.Point(581, 36); //
this.btnBrowseOU.Name = "btnBrowseOU"; this.btnBrowseOU.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right)));
this.btnBrowseOU.Size = new System.Drawing.Size(24, 22); this.btnBrowseOU.Location = new System.Drawing.Point(578, 36);
this.btnBrowseOU.TabIndex = 5; this.btnBrowseOU.Name = "btnBrowseOU";
this.btnBrowseOU.Text = "..."; this.btnBrowseOU.Size = new System.Drawing.Size(24, 22);
this.btnBrowseOU.UseVisualStyleBackColor = true; this.btnBrowseOU.TabIndex = 5;
this.btnBrowseOU.Click += new System.EventHandler(this.OnBrowseOU); this.btnBrowseOU.Text = "...";
// this.btnBrowseOU.UseVisualStyleBackColor = true;
// txtOU this.btnBrowseOU.Click += new System.EventHandler(this.OnBrowseOU);
// //
this.txtOU.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left) // txtOU
| System.Windows.Forms.AnchorStyles.Right))); //
this.txtOU.Location = new System.Drawing.Point(146, 38); this.txtOU.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left)
this.txtOU.Name = "txtOU"; | System.Windows.Forms.AnchorStyles.Right)));
this.txtOU.ReadOnly = true; this.txtOU.Location = new System.Drawing.Point(146, 38);
this.txtOU.Size = new System.Drawing.Size(429, 20); this.txtOU.Name = "txtOU";
this.txtOU.TabIndex = 4; this.txtOU.ReadOnly = true;
this.txtOU.TextChanged += new System.EventHandler(this.OnDataChanged); this.txtOU.Size = new System.Drawing.Size(426, 20);
// this.txtOU.TabIndex = 4;
// lblOU this.txtOU.TextChanged += new System.EventHandler(this.OnDataChanged);
// //
this.lblOU.Location = new System.Drawing.Point(15, 41); // lblOU
this.lblOU.Name = "lblOU"; //
this.lblOU.Size = new System.Drawing.Size(125, 23); this.lblOU.Location = new System.Drawing.Point(15, 41);
this.lblOU.TabIndex = 3; this.lblOU.Name = "lblOU";
this.lblOU.Text = "Organizational Unit:"; this.lblOU.Size = new System.Drawing.Size(125, 23);
// this.lblOU.TabIndex = 3;
// grpOrganization this.lblOU.Text = "Organizational Unit:";
// //
this.grpOrganization.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom) // grpOrganization
| System.Windows.Forms.AnchorStyles.Left) //
| System.Windows.Forms.AnchorStyles.Right))); this.grpOrganization.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
this.grpOrganization.Controls.Add(this.btnSelectAll); | System.Windows.Forms.AnchorStyles.Left)
this.grpOrganization.Controls.Add(this.btnDeselectAll); | System.Windows.Forms.AnchorStyles.Right)));
this.grpOrganization.Controls.Add(this.rbCreateAndImport); this.grpOrganization.Controls.Add(this.cbMailboxPlan);
this.grpOrganization.Controls.Add(this.rbImport); this.grpOrganization.Controls.Add(this.lblMailnoxPlan);
this.grpOrganization.Controls.Add(this.lvUsers); this.grpOrganization.Controls.Add(this.btnSelectAll);
this.grpOrganization.Controls.Add(this.txtOrgName); this.grpOrganization.Controls.Add(this.btnDeselectAll);
this.grpOrganization.Controls.Add(this.lblOrgName); this.grpOrganization.Controls.Add(this.rbCreateAndImport);
this.grpOrganization.Controls.Add(this.txtOrgId); this.grpOrganization.Controls.Add(this.rbImport);
this.grpOrganization.Controls.Add(this.lblOrgId); this.grpOrganization.Controls.Add(this.lvUsers);
this.grpOrganization.Location = new System.Drawing.Point(15, 67); this.grpOrganization.Controls.Add(this.txtOrgName);
this.grpOrganization.Name = "grpOrganization"; this.grpOrganization.Controls.Add(this.lblOrgName);
this.grpOrganization.Size = new System.Drawing.Size(590, 328); this.grpOrganization.Controls.Add(this.txtOrgId);
this.grpOrganization.TabIndex = 6; this.grpOrganization.Controls.Add(this.lblOrgId);
this.grpOrganization.TabStop = false; this.grpOrganization.Location = new System.Drawing.Point(15, 67);
// this.grpOrganization.Name = "grpOrganization";
// btnSelectAll this.grpOrganization.Size = new System.Drawing.Size(587, 328);
// this.grpOrganization.TabIndex = 6;
this.btnSelectAll.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right))); this.grpOrganization.TabStop = false;
this.btnSelectAll.Location = new System.Drawing.Point(417, 282); //
this.btnSelectAll.Name = "btnSelectAll"; // cbMailboxPlan
this.btnSelectAll.Size = new System.Drawing.Size(75, 23); //
this.btnSelectAll.TabIndex = 7; this.cbMailboxPlan.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left)
this.btnSelectAll.Text = "Select All"; | System.Windows.Forms.AnchorStyles.Right)));
this.btnSelectAll.UseVisualStyleBackColor = true; this.cbMailboxPlan.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList;
this.btnSelectAll.Click += new System.EventHandler(this.OnSelectAllClick); this.cbMailboxPlan.FormattingEnabled = true;
// this.cbMailboxPlan.Location = new System.Drawing.Point(155, 74);
// btnDeselectAll this.cbMailboxPlan.Name = "cbMailboxPlan";
// this.cbMailboxPlan.Size = new System.Drawing.Size(415, 21);
this.btnDeselectAll.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right))); this.cbMailboxPlan.TabIndex = 10;
this.btnDeselectAll.Location = new System.Drawing.Point(498, 282); //
this.btnDeselectAll.Name = "btnDeselectAll"; // lblMailnoxPlan
this.btnDeselectAll.Size = new System.Drawing.Size(75, 23); //
this.btnDeselectAll.TabIndex = 8; this.lblMailnoxPlan.Location = new System.Drawing.Point(19, 74);
this.btnDeselectAll.Text = "Unselect All"; this.lblMailnoxPlan.Name = "lblMailnoxPlan";
this.btnDeselectAll.UseVisualStyleBackColor = true; this.lblMailnoxPlan.Size = new System.Drawing.Size(130, 23);
this.btnDeselectAll.Click += new System.EventHandler(this.OnDeselectAllClick); this.lblMailnoxPlan.TabIndex = 9;
// this.lblMailnoxPlan.Text = "Default mailbox plan :";
// rbCreateAndImport //
// // btnSelectAll
this.rbCreateAndImport.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Left))); //
this.rbCreateAndImport.AutoSize = true; this.btnSelectAll.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right)));
this.rbCreateAndImport.Checked = true; this.btnSelectAll.Location = new System.Drawing.Point(414, 282);
this.rbCreateAndImport.Enabled = false; this.btnSelectAll.Name = "btnSelectAll";
this.rbCreateAndImport.Location = new System.Drawing.Point(19, 282); this.btnSelectAll.Size = new System.Drawing.Size(75, 23);
this.rbCreateAndImport.Name = "rbCreateAndImport"; this.btnSelectAll.TabIndex = 7;
this.rbCreateAndImport.Size = new System.Drawing.Size(261, 17); this.btnSelectAll.Text = "Select All";
this.rbCreateAndImport.TabIndex = 5; this.btnSelectAll.UseVisualStyleBackColor = true;
this.rbCreateAndImport.TabStop = true; this.btnSelectAll.Click += new System.EventHandler(this.OnSelectAllClick);
this.rbCreateAndImport.Text = "Create new organization and import selected items"; //
this.rbCreateAndImport.UseVisualStyleBackColor = true; // btnDeselectAll
this.rbCreateAndImport.CheckedChanged += new System.EventHandler(this.OnCheckedChanged); //
// this.btnDeselectAll.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right)));
// rbImport this.btnDeselectAll.Location = new System.Drawing.Point(495, 282);
// this.btnDeselectAll.Name = "btnDeselectAll";
this.rbImport.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Left))); this.btnDeselectAll.Size = new System.Drawing.Size(75, 23);
this.rbImport.AutoSize = true; this.btnDeselectAll.TabIndex = 8;
this.rbImport.Enabled = false; this.btnDeselectAll.Text = "Unselect All";
this.rbImport.Location = new System.Drawing.Point(19, 305); this.btnDeselectAll.UseVisualStyleBackColor = true;
this.rbImport.Name = "rbImport"; this.btnDeselectAll.Click += new System.EventHandler(this.OnDeselectAllClick);
this.rbImport.Size = new System.Drawing.Size(237, 17); //
this.rbImport.TabIndex = 6; // rbCreateAndImport
this.rbImport.Text = "Import selected items for existing organization"; //
this.rbImport.UseVisualStyleBackColor = true; this.rbCreateAndImport.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Left)));
// this.rbCreateAndImport.AutoSize = true;
// lvUsers this.rbCreateAndImport.Checked = true;
// this.rbCreateAndImport.Enabled = false;
this.lvUsers.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom) this.rbCreateAndImport.Location = new System.Drawing.Point(19, 282);
| System.Windows.Forms.AnchorStyles.Left) this.rbCreateAndImport.Name = "rbCreateAndImport";
| System.Windows.Forms.AnchorStyles.Right))); this.rbCreateAndImport.Size = new System.Drawing.Size(261, 17);
this.lvUsers.CheckBoxes = true; this.rbCreateAndImport.TabIndex = 5;
this.lvUsers.Columns.AddRange(new System.Windows.Forms.ColumnHeader[] { this.rbCreateAndImport.TabStop = true;
this.rbCreateAndImport.Text = "Create new organization and import selected items";
this.rbCreateAndImport.UseVisualStyleBackColor = true;
this.rbCreateAndImport.CheckedChanged += new System.EventHandler(this.OnCheckedChanged);
//
// rbImport
//
this.rbImport.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Left)));
this.rbImport.AutoSize = true;
this.rbImport.Enabled = false;
this.rbImport.Location = new System.Drawing.Point(19, 305);
this.rbImport.Name = "rbImport";
this.rbImport.Size = new System.Drawing.Size(237, 17);
this.rbImport.TabIndex = 6;
this.rbImport.Text = "Import selected items for existing organization";
this.rbImport.UseVisualStyleBackColor = true;
//
// lvUsers
//
this.lvUsers.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
| System.Windows.Forms.AnchorStyles.Left)
| System.Windows.Forms.AnchorStyles.Right)));
this.lvUsers.CheckBoxes = true;
this.lvUsers.Columns.AddRange(new System.Windows.Forms.ColumnHeader[] {
this.columnHeader1, this.columnHeader1,
this.columnHeader2, this.columnHeader2,
this.columnHeader3}); this.columnHeader3});
this.lvUsers.FullRowSelect = true; this.lvUsers.FullRowSelect = true;
this.lvUsers.HeaderStyle = System.Windows.Forms.ColumnHeaderStyle.Nonclickable; this.lvUsers.HeaderStyle = System.Windows.Forms.ColumnHeaderStyle.Nonclickable;
this.lvUsers.Location = new System.Drawing.Point(19, 74); this.lvUsers.Location = new System.Drawing.Point(19, 108);
this.lvUsers.MultiSelect = false; this.lvUsers.MultiSelect = false;
this.lvUsers.Name = "lvUsers"; this.lvUsers.Name = "lvUsers";
this.lvUsers.Size = new System.Drawing.Size(554, 202); this.lvUsers.Size = new System.Drawing.Size(551, 167);
this.lvUsers.SmallImageList = this.images; this.lvUsers.SmallImageList = this.images;
this.lvUsers.TabIndex = 4; this.lvUsers.TabIndex = 4;
this.lvUsers.UseCompatibleStateImageBehavior = false; this.lvUsers.UseCompatibleStateImageBehavior = false;
this.lvUsers.View = System.Windows.Forms.View.Details; this.lvUsers.View = System.Windows.Forms.View.Details;
// //
// columnHeader1 // columnHeader1
// //
this.columnHeader1.Text = "Name"; this.columnHeader1.Text = "Name";
this.columnHeader1.Width = 229; this.columnHeader1.Width = 238;
// //
// columnHeader2 // columnHeader2
// //
this.columnHeader2.Text = "Email"; this.columnHeader2.Text = "Email";
this.columnHeader2.Width = 163; this.columnHeader2.Width = 166;
// //
// columnHeader3 // columnHeader3
// //
this.columnHeader3.Text = "Type"; this.columnHeader3.Text = "Type";
this.columnHeader3.Width = 152; this.columnHeader3.Width = 124;
// //
// images // images
// //
this.images.ImageStream = ((System.Windows.Forms.ImageListStreamer)(resources.GetObject("images.ImageStream"))); this.images.ImageStream = ((System.Windows.Forms.ImageListStreamer)(resources.GetObject("images.ImageStream")));
this.images.TransparentColor = System.Drawing.Color.Transparent; this.images.TransparentColor = System.Drawing.Color.Transparent;
this.images.Images.SetKeyName(0, "UserSmallIcon.ico"); this.images.Images.SetKeyName(0, "UserSmallIcon.ico");
this.images.Images.SetKeyName(1, "contact.ico"); this.images.Images.SetKeyName(1, "contact.ico");
this.images.Images.SetKeyName(2, "DL.ico"); this.images.Images.SetKeyName(2, "DL.ico");
// //
// txtOrgName // txtOrgName
// //
this.txtOrgName.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left) this.txtOrgName.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left)
| System.Windows.Forms.AnchorStyles.Right))); | System.Windows.Forms.AnchorStyles.Right)));
this.txtOrgName.Location = new System.Drawing.Point(155, 45); this.txtOrgName.Location = new System.Drawing.Point(155, 45);
this.txtOrgName.Name = "txtOrgName"; this.txtOrgName.Name = "txtOrgName";
this.txtOrgName.Size = new System.Drawing.Size(418, 20); this.txtOrgName.Size = new System.Drawing.Size(415, 20);
this.txtOrgName.TabIndex = 3; this.txtOrgName.TabIndex = 3;
// //
// lblOrgName // lblOrgName
// //
this.lblOrgName.Location = new System.Drawing.Point(19, 48); this.lblOrgName.Location = new System.Drawing.Point(19, 48);
this.lblOrgName.Name = "lblOrgName"; this.lblOrgName.Name = "lblOrgName";
this.lblOrgName.Size = new System.Drawing.Size(130, 23); this.lblOrgName.Size = new System.Drawing.Size(130, 23);
this.lblOrgName.TabIndex = 2; this.lblOrgName.TabIndex = 2;
this.lblOrgName.Text = "Organization Name:"; this.lblOrgName.Text = "Organization Name:";
// //
// txtOrgId // txtOrgId
// //
this.txtOrgId.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left) this.txtOrgId.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left)
| System.Windows.Forms.AnchorStyles.Right))); | System.Windows.Forms.AnchorStyles.Right)));
this.txtOrgId.Location = new System.Drawing.Point(155, 19); this.txtOrgId.Location = new System.Drawing.Point(155, 19);
this.txtOrgId.Name = "txtOrgId"; this.txtOrgId.Name = "txtOrgId";
this.txtOrgId.ReadOnly = true; this.txtOrgId.ReadOnly = true;
this.txtOrgId.Size = new System.Drawing.Size(418, 20); this.txtOrgId.Size = new System.Drawing.Size(415, 20);
this.txtOrgId.TabIndex = 1; this.txtOrgId.TabIndex = 1;
// //
// lblOrgId // lblOrgId
// //
this.lblOrgId.Location = new System.Drawing.Point(19, 22); this.lblOrgId.Location = new System.Drawing.Point(19, 22);
this.lblOrgId.Name = "lblOrgId"; this.lblOrgId.Name = "lblOrgId";
this.lblOrgId.Size = new System.Drawing.Size(130, 23); this.lblOrgId.Size = new System.Drawing.Size(130, 23);
this.lblOrgId.TabIndex = 0; this.lblOrgId.TabIndex = 0;
this.lblOrgId.Text = "Organization Id:"; this.lblOrgId.Text = "Organization Id:";
// //
// btnStart // btnStart
// //
this.btnStart.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right))); this.btnStart.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right)));
this.btnStart.Location = new System.Drawing.Point(527, 461); this.btnStart.Location = new System.Drawing.Point(524, 461);
this.btnStart.Name = "btnStart"; this.btnStart.Name = "btnStart";
this.btnStart.Size = new System.Drawing.Size(75, 23); this.btnStart.Size = new System.Drawing.Size(75, 23);
this.btnStart.TabIndex = 9; this.btnStart.TabIndex = 9;
this.btnStart.Text = "Start"; this.btnStart.Text = "Start";
this.btnStart.UseVisualStyleBackColor = true; this.btnStart.UseVisualStyleBackColor = true;
this.btnStart.Click += new System.EventHandler(this.OnImportClick); this.btnStart.Click += new System.EventHandler(this.OnImportClick);
// //
// progressBar // progressBar
// //
this.progressBar.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Left) this.progressBar.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Left)
| System.Windows.Forms.AnchorStyles.Right))); | System.Windows.Forms.AnchorStyles.Right)));
this.progressBar.Location = new System.Drawing.Point(15, 427); this.progressBar.Location = new System.Drawing.Point(15, 427);
this.progressBar.Name = "progressBar"; this.progressBar.Name = "progressBar";
this.progressBar.Size = new System.Drawing.Size(587, 23); this.progressBar.Size = new System.Drawing.Size(584, 23);
this.progressBar.TabIndex = 8; this.progressBar.TabIndex = 8;
// //
// lblMessage // lblMessage
// //
this.lblMessage.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Left) this.lblMessage.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Left)
| System.Windows.Forms.AnchorStyles.Right))); | System.Windows.Forms.AnchorStyles.Right)));
this.lblMessage.Location = new System.Drawing.Point(12, 401); this.lblMessage.Location = new System.Drawing.Point(12, 401);
this.lblMessage.Name = "lblMessage"; this.lblMessage.Name = "lblMessage";
this.lblMessage.Size = new System.Drawing.Size(593, 23); this.lblMessage.Size = new System.Drawing.Size(590, 23);
this.lblMessage.TabIndex = 7; this.lblMessage.TabIndex = 7;
// //
// ApplicationForm // ApplicationForm
// //
this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F); this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F);
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font; this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
this.ClientSize = new System.Drawing.Size(617, 496); this.ClientSize = new System.Drawing.Size(614, 496);
this.Controls.Add(this.lblMessage); this.Controls.Add(this.lblMessage);
this.Controls.Add(this.progressBar); this.Controls.Add(this.progressBar);
this.Controls.Add(this.btnStart); this.Controls.Add(this.btnStart);
this.Controls.Add(this.grpOrganization); this.Controls.Add(this.grpOrganization);
this.Controls.Add(this.btnBrowseOU); this.Controls.Add(this.btnBrowseOU);
this.Controls.Add(this.txtOU); this.Controls.Add(this.txtOU);
this.Controls.Add(this.lblOU); this.Controls.Add(this.lblOU);
this.Controls.Add(this.btnBrowseSpace); this.Controls.Add(this.btnBrowseSpace);
this.Controls.Add(this.txtSpace); this.Controls.Add(this.txtSpace);
this.Controls.Add(this.lblSpace); this.Controls.Add(this.lblSpace);
this.Icon = ((System.Drawing.Icon)(resources.GetObject("$this.Icon"))); this.Icon = ((System.Drawing.Icon)(resources.GetObject("$this.Icon")));
this.MinimumSize = new System.Drawing.Size(630, 500); this.MinimumSize = new System.Drawing.Size(630, 500);
this.Name = "ApplicationForm"; this.Name = "ApplicationForm";
this.StartPosition = System.Windows.Forms.FormStartPosition.CenterScreen; this.StartPosition = System.Windows.Forms.FormStartPosition.CenterScreen;
this.Text = "WebsitePanel Enterprise Import Tool"; this.Text = "WebsitePanel Enterprise Import Tool";
this.FormClosing += new System.Windows.Forms.FormClosingEventHandler(this.OnFormClosing); this.FormClosing += new System.Windows.Forms.FormClosingEventHandler(this.OnFormClosing);
this.grpOrganization.ResumeLayout(false); this.grpOrganization.ResumeLayout(false);
this.grpOrganization.PerformLayout(); this.grpOrganization.PerformLayout();
this.ResumeLayout(false); this.ResumeLayout(false);
this.PerformLayout(); this.PerformLayout();
} }
@ -346,6 +369,8 @@ namespace WebsitePanel.Import.Enterprise
private System.Windows.Forms.RadioButton rbImport; private System.Windows.Forms.RadioButton rbImport;
internal System.Windows.Forms.Button btnSelectAll; internal System.Windows.Forms.Button btnSelectAll;
internal System.Windows.Forms.Button btnDeselectAll; internal System.Windows.Forms.Button btnDeselectAll;
private System.Windows.Forms.ComboBox cbMailboxPlan;
private System.Windows.Forms.Label lblMailnoxPlan;
} }
} }

View file

@ -1,4 +1,4 @@
// Copyright (c) 2011, Outercurve Foundation. // Copyright (c) 2014, Outercurve Foundation.
// All rights reserved. // All rights reserved.
// //
// Redistribution and use in source and binary forms, with or without modification, // Redistribution and use in source and binary forms, with or without modification,
@ -129,6 +129,30 @@ namespace WebsitePanel.Import.Enterprise
} }
} }
private void BindMailboxPlans(string orgId)
{
cbMailboxPlan.Items.Clear();
cbMailboxPlan.Items.Add("<not set>");
cbMailboxPlan.SelectedIndex = 0;
Organization org = OrganizationController.GetOrganizationById(orgId);
if (org == null)
{
List<Organization> orgs = ExchangeServerController.GetExchangeOrganizations(1, false);
if (orgs.Count > 0)
org = orgs[0];
}
if (org != null)
{
int itemId = org.Id;
List<ExchangeMailboxPlan> plans = ExchangeServerController.GetExchangeMailboxPlans(itemId, false);
cbMailboxPlan.Items.AddRange(plans.ToArray());
}
}
private void LoadOrganizationData(DirectoryEntry parent) private void LoadOrganizationData(DirectoryEntry parent)
{ {
string orgId = (string)parent.Properties["name"].Value; string orgId = (string)parent.Properties["name"].Value;
@ -147,6 +171,9 @@ namespace WebsitePanel.Import.Enterprise
rbImport.Checked = false; rbImport.Checked = false;
txtOrgName.Text = orgId; txtOrgName.Text = orgId;
} }
BindMailboxPlans(orgId);
LoadOrganizationAccounts(parent); LoadOrganizationAccounts(parent);
} }
@ -326,6 +353,16 @@ namespace WebsitePanel.Import.Enterprise
Global.OrganizationName = txtOrgName.Text; Global.OrganizationName = txtOrgName.Text;
Global.ImportAccountsOnly = rbImport.Checked; Global.ImportAccountsOnly = rbImport.Checked;
Global.HasErrors = false; Global.HasErrors = false;
Global.defaultMailboxPlanId = 0;
if (cbMailboxPlan.SelectedItem!=null)
{
ExchangeMailboxPlan plan = cbMailboxPlan.SelectedItem as ExchangeMailboxPlan;
if (plan != null)
Global.defaultMailboxPlanId = plan.MailboxPlanId;
}
importer.Initialize(this.username, this); importer.Initialize(this.username, this);
importer.Start(); importer.Start();

View file

@ -112,79 +112,79 @@
<value>2.0</value> <value>2.0</value>
</resheader> </resheader>
<resheader name="reader"> <resheader name="reader">
<value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value> <value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader> </resheader>
<resheader name="writer"> <resheader name="writer">
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value> <value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader> </resheader>
<metadata name="images.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a"> <metadata name="images.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
<value>17, 17</value> <value>17, 17</value>
</metadata> </metadata>
<data name="images.ImageStream" mimetype="application/x-microsoft.net.object.binary.base64"> <data name="images.ImageStream" mimetype="application/x-microsoft.net.object.binary.base64">
<value> <value>
AAEAAAD/////AQAAAAAAAAAMAgAAAFdTeXN0ZW0uV2luZG93cy5Gb3JtcywgVmVyc2lvbj0yLjAuMC4w AAEAAAD/////AQAAAAAAAAAMAgAAAFd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ABHwIA AgABwAEvAgABwAEPAgABwAE/AgAB4AEPAgAB0AEfAgABwAEHAgABwAEfAgABwAEHAgABwAEfAgABwAEH
AcABBwIAAdgBHwIAAcEBDwIAAegBHwIAAcEB/wIAAdQBfwEAAX8B4QH/AgAG/wIACw== AgAB2AEfAgABwQEPAgAB6AEfAgABwQH/AgAB1AF/AQABfwHhAf8CAAb/AgAL
</value> </value>
</data> </data>
<assembly alias="System.Drawing" name="System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" /> <assembly alias="System.Drawing" name="System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" />
<data name="$this.Icon" type="System.Drawing.Icon, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64"> <data name="$this.Icon" type="System.Drawing.Icon, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
<value> <value>
AAABAAoAAAAAAAEACADKTwAApgAAADAwAAABAAgAqA4AAHBQAAAgIAAAAQAIAKgIAAAYXwAAGBgAAAEA AAABAAoAAAAAAAEACADKTwAApgAAADAwAAABAAgAqA4AAHBQAAAgIAAAAQAIAKgIAAAYXwAAGBgAAAEA

View file

@ -81,6 +81,7 @@ namespace WebsitePanel.Import.Enterprise
public static string ErrorMessage; public static string ErrorMessage;
public static bool ImportAccountsOnly; public static bool ImportAccountsOnly;
public static bool HasErrors; public static bool HasErrors;
public static int defaultMailboxPlanId;
} }
} }

View file

@ -51,7 +51,6 @@ namespace WebsitePanel.Import.Enterprise
private ProgressBar progressBar; private ProgressBar progressBar;
private ApplicationForm appForm; private ApplicationForm appForm;
private Button btnImport; private Button btnImport;
private Thread thread; private Thread thread;
@ -826,7 +825,7 @@ namespace WebsitePanel.Import.Enterprise
} }
} }
UpdateExchangeAccount(userId, accountName, accountType, displayName, email, false, string.Empty, samName, string.Empty); UpdateExchangeAccount(userId, accountName, accountType, displayName, email, false, string.Empty, samName, string.Empty, Global.defaultMailboxPlanId);
string defaultEmail = (string)entry.Properties["extensionAttribute3"].Value; string defaultEmail = (string)entry.Properties["extensionAttribute3"].Value;
@ -987,7 +986,7 @@ namespace WebsitePanel.Import.Enterprise
private static void UpdateExchangeAccount(int accountId, string accountName, ExchangeAccountType accountType, private static void UpdateExchangeAccount(int accountId, string accountName, ExchangeAccountType accountType,
string displayName, string primaryEmailAddress, bool mailEnabledPublicFolder, string displayName, string primaryEmailAddress, bool mailEnabledPublicFolder,
string mailboxManagerActions, string samAccountName, string accountPassword) string mailboxManagerActions, string samAccountName, string accountPassword, int mailboxPlanId)
{ {
DataProvider.UpdateExchangeAccount(accountId, DataProvider.UpdateExchangeAccount(accountId,
accountName, accountName,
@ -997,7 +996,7 @@ namespace WebsitePanel.Import.Enterprise
mailEnabledPublicFolder, mailEnabledPublicFolder,
mailboxManagerActions, mailboxManagerActions,
samAccountName, samAccountName,
CryptoUtils.Encrypt(accountPassword), 0, -1, string.Empty, false); CryptoUtils.Encrypt(accountPassword), mailboxPlanId , -1, string.Empty, false);
} }
} }
} }

View file

@ -38,6 +38,15 @@ namespace WebsitePanel.Providers.HostedSolution
int itemId; int itemId;
int mailboxPlanId; int mailboxPlanId;
string mailboxPlan; string mailboxPlan;
public override string ToString()
{
if (mailboxPlan != null)
return mailboxPlan;
return base.ToString();
}
int mailboxSizeMB; int mailboxSizeMB;
int maxRecipients; int maxRecipients;
int maxSendMessageSizeKB; int maxSendMessageSizeKB;
@ -63,7 +72,6 @@ namespace WebsitePanel.Providers.HostedSolution
string litigationHoldUrl; string litigationHoldUrl;
string litigationHoldMsg; string litigationHoldMsg;
public int ItemId public int ItemId
{ {
get { return this.itemId; } get { return this.itemId; }