C2018-039: Upgrade – User Control of Format

This commit is contained in:
2018-12-12 15:25:53 +00:00
parent dcefdc8754
commit e2392f5fec
20 changed files with 5491 additions and 1203 deletions

View File

@@ -197,6 +197,7 @@ namespace VEPROMS
{
tc.RefreshItem(myItemInfo);
}
private E_UCFImportOptions _UCFImportOptionsFromSettings;
public frmVEPROMS()
{
// The following Try/Catch was added to protect against a problem seen by Kathy and Michelle
@@ -550,7 +551,7 @@ namespace VEPROMS
{
int ownerid = MySessionInfo.CheckOutItem(fi.FolderID, CheckOutType.Session);
//int ownerid = MySessionInfo.CheckOutItem(fi.FolderID, (args.Index == 0) ? CheckOutType.Folder : CheckOutType.Session);
dlgExportImport dlg = new dlgExportImport(args.Index == 0 ? "Export" : "Import", fi, this);//Added frmVEPROMS Parameter
dlgExportImport dlg = new dlgExportImport(args.Index == 0 ? "Export" : "Import", fi, this, (E_UCFImportOptions)Properties.Settings.Default.UCFImportOpt);//Added frmVEPROMS Parameter
dlg.ShowDialog(this);
MySessionInfo.CheckInItem(ownerid);
if (args.Index == 1 && dlg.MyNewFolder != null)
@@ -575,7 +576,7 @@ namespace VEPROMS
return;
}
int ownerid = MySessionInfo.CheckOutItem(dvi.VersionID, CheckOutType.DocVersion);
dlgExportImport dlg = new dlgExportImport("Import", dvi, this);//Added frmVEPROMS Parameter
dlgExportImport dlg = new dlgExportImport("Import", dvi, this, (E_UCFImportOptions)Properties.Settings.Default.UCFImportOpt);//Added frmVEPROMS Parameter
dlg.MyNewProcedure = null;
dlg.ExternalTransitionItem = null;
dlg.ShowDialog(this);
@@ -597,7 +598,7 @@ namespace VEPROMS
else
{
int ownerid = MySessionInfo.CheckOutItem(pi.ItemID, CheckOutType.Procedure);
dlgExportImport dlg = new dlgExportImport("Export", pi, this);//Added frmVEPROMS Parameter
dlgExportImport dlg = new dlgExportImport("Export", pi, this, (E_UCFImportOptions)0);//Added frmVEPROMS Parameter
dlg.ShowDialog(this);
MySessionInfo.CheckInItem(ownerid);
}
@@ -1351,6 +1352,9 @@ namespace VEPROMS
private DevComponents.DotNetBar.ButtonItem btnManageSecurity;
private DevComponents.DotNetBar.ButtonItem btnResetSecurity;
private DevComponents.DotNetBar.ButtonItem btnAdministrativeTools;
private DevComponents.DotNetBar.ButtonItem btnUserControlOfFormats;
private DevComponents.DotNetBar.ButtonItem btnUserControlOfFormatsExport;
private DevComponents.DotNetBar.ButtonItem btnUserControlOfFormatsImport;
private TabItemsToClose _MyCloseTabList = new TabItemsToClose();
public TabItemsToClose MyCloseTabList
{
@@ -1497,6 +1501,16 @@ namespace VEPROMS
{
InitializeSecurity();
UpdateUser();
btnUserControlOfFormats = new ButtonItem("btnUserControlOfFormats", "User Control of Formats");
btnAdmin.SubItems.Add(btnUserControlOfFormats);
btnUserControlOfFormats.Click += new EventHandler(btnUserControlOfFormats_Click);
btnUserControlOfFormatsExport = new ButtonItem("btnUserControlOfFormatsExport", "Export User Control of Formats");
btnAdmin.SubItems.Add(btnUserControlOfFormatsExport);
btnUserControlOfFormatsExport.Click += new EventHandler(btnUserControlOfFormatsExport_Click);
btnUserControlOfFormatsImport = new ButtonItem("btnUserControlOfFormatsImport", "Import User Control of Formats");
btnAdmin.SubItems.Add(btnUserControlOfFormatsImport);
btnUserControlOfFormatsImport.Click += new EventHandler(btnUserControlOfFormatsImport_Click);
btnManageSecurity = new ButtonItem("btnManageSecurity", "Manage Security");
btnAdmin.SubItems.Add(btnManageSecurity);
btnManageSecurity.Click += new EventHandler(btnManageSecurity_Click);
@@ -1513,8 +1527,9 @@ namespace VEPROMS
btnAdmin.SubItems.Add(btnAdministrativeTools);
this.superTooltip1.SetSuperTooltip(btnPrint, new SuperTooltipInfo("Create PDF", null, null, null, null, eTooltipColor.Gray));
this.superTooltip1.SetSuperTooltip(btnExit, new SuperTooltipInfo("Exit", null, null, null, null, eTooltipColor.Gray));
this.superTooltip1.SetSuperTooltip(btnOptions, new SuperTooltipInfo("Options", null, null, null, null, eTooltipColor.Gray));
this.superTooltip1.SetSuperTooltip(btnManageSecurity, new SuperTooltipInfo("Manage Security", null, null, null, null, eTooltipColor.Gray));
this.superTooltip1.SetSuperTooltip(btnOptions, new SuperTooltipInfo("Options", null, null, null, null, eTooltipColor.Gray));
this.superTooltip1.SetSuperTooltip(btnManageSecurity, new SuperTooltipInfo("Manage Security", null, null, null, null, eTooltipColor.Gray));
this.superTooltip1.SetSuperTooltip(btnUserControlOfFormats, new SuperTooltipInfo("User Control Of Formats", null, null, null, null, eTooltipColor.Gray));
this.superTooltip1.SetSuperTooltip(btnResetSecurity, new SuperTooltipInfo("Reset Security",null, null, null, null, eTooltipColor.Gray));
this.superTooltip1.SetSuperTooltip(btnAdministrativeTools, new SuperTooltipInfo("Administrative Tools",null, null, null, null, eTooltipColor.Gray));
this.superTooltip1.SetSuperTooltip(btnUpdateFormats, new SuperTooltipInfo("Update Formats",null, null, null, null, eTooltipColor.Gray));
@@ -1545,6 +1560,9 @@ namespace VEPROMS
StepRTB.MyUserInfo = MyUserInfo; // set the user's security information in the StepRTB
VlnFlexGrid.MyUserInfo = MyUserInfo; // set the user's security information in the VlnFlexGrid
bool isVisible = MyUserInfo.IsAdministrator();
btnUserControlOfFormats.Visible = isVisible;
btnUserControlOfFormatsExport.Visible = isVisible;
btnUserControlOfFormatsImport.Visible = isVisible;
btnManageSecurity.Visible = isVisible;
btnUpdateFormats.Visible = isVisible;
btnResetSecurity.Visible = isVisible;
@@ -2191,6 +2209,27 @@ namespace VEPROMS
proxyUser = ui.UserID;
}
}
void btnUserControlOfFormats_Click(object sender, EventArgs e)
{
frmUCF frmucf = new frmUCF();
DialogResult dr = frmucf.ShowDialog(this);
}
void btnUserControlOfFormatsExport_Click(object sender, EventArgs e)
{
DocVersionInfo dvi = null;
dlgExportImport dlg = new dlgExportImport("Export Formats", dvi, this, (E_UCFImportOptions)0);
dlg.MyNewProcedure = null;
dlg.ExternalTransitionItem = null;
dlg.ShowDialog(this);
}
void btnUserControlOfFormatsImport_Click(object sender, EventArgs e)
{
DocVersionInfo dvi = null;
dlgExportImport dlg = new dlgExportImport("Import Formats", dvi, this, (E_UCFImportOptions)0);
dlg.MyNewProcedure = null;
dlg.ExternalTransitionItem = null;
dlg.ShowDialog(this);
}
void btnManageSecurity_Click(object sender, EventArgs e)
{
dlgManageSecurity dlg = new dlgManageSecurity();
@@ -4022,7 +4061,7 @@ namespace VEPROMS
}
private void btnUpdateFormat_Click(object sender, EventArgs e)
{
UpdateFormats(null);
UpdateFormats(null);
}
private void UpdateFormats(string mypath)