Enhanced tab: if no available docversions to link to from a source, hide ‘new’ button
Caching fix B2016-132 fix: don’t allow double click to insert RO when on enhanced step
This commit is contained in:
parent
c92fee3ab1
commit
2498cd10dc
@ -160,7 +160,7 @@ namespace VEPROMS
|
|||||||
}
|
}
|
||||||
catch (Exception ex)
|
catch (Exception ex)
|
||||||
{
|
{
|
||||||
dved.PdfX = 0;
|
dved.PdfX = 10;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -173,7 +173,7 @@ namespace VEPROMS
|
|||||||
}
|
}
|
||||||
catch (Exception ex)
|
catch (Exception ex)
|
||||||
{
|
{
|
||||||
ipdfx = 0;
|
ipdfx = (emc.PdfToken==null||emc.PdfToken=="")?0:10;
|
||||||
}
|
}
|
||||||
int itype = 0;
|
int itype = 0;
|
||||||
try
|
try
|
||||||
@ -562,7 +562,22 @@ namespace VEPROMS
|
|||||||
if (cbxEnhVersions.Items.Count>0) cbxEnhVersions.SelectedIndex = 0;
|
if (cbxEnhVersions.Items.Count>0) cbxEnhVersions.SelectedIndex = 0;
|
||||||
if (lbEnhanced.Items.Count > 0) lbEnhanced.SelectedIndex = 0;
|
if (lbEnhanced.Items.Count > 0) lbEnhanced.SelectedIndex = 0;
|
||||||
bsMiniEnhanced.DataSource = bsEnhanced.Current as EnhancedMiniConfig;
|
bsMiniEnhanced.DataSource = bsEnhanced.Current as EnhancedMiniConfig;
|
||||||
btnNewEnh.Visible = true;
|
|
||||||
|
// only allow new if there are available non-linked 'enhanced format' docversions.
|
||||||
|
int cntAvailForLinkEnh = 0;
|
||||||
|
DocVersionInfoList nonenhdvs = DocVersionInfoList.GetNonEnhancedDocVersions();
|
||||||
|
foreach (DocVersionInfo nonenhdv in nonenhdvs)
|
||||||
|
{
|
||||||
|
if (nonenhdv.VersionID != _DocVersionConfig.MyDocVersion.VersionID)
|
||||||
|
{
|
||||||
|
if (((nonenhdv.ActiveFormat.PlantFormat.FormatData.PurchaseOptions.Value & E_PurchaseOptions.EnhancedBackgrounds) == E_PurchaseOptions.EnhancedBackgrounds) ||
|
||||||
|
((nonenhdv.ActiveFormat.PlantFormat.FormatData.PurchaseOptions.Value & E_PurchaseOptions.EnhancedDeviations) == E_PurchaseOptions.EnhancedDeviations))
|
||||||
|
{
|
||||||
|
cntAvailForLinkEnh++;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
btnNewEnh.Visible = (cntAvailForLinkEnh > 0);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -578,7 +578,7 @@ namespace VEPROMS.CSLA.Library
|
|||||||
}
|
}
|
||||||
public ConfigDynamicTypeDescriptor MyConfig
|
public ConfigDynamicTypeDescriptor MyConfig
|
||||||
{
|
{
|
||||||
get { return Get().DocVersionConfig; }
|
get { return DocVersionConfig; }
|
||||||
}
|
}
|
||||||
//public bool HasStandardSteps()
|
//public bool HasStandardSteps()
|
||||||
//{ return false; }
|
//{ return false; }
|
||||||
|
@ -247,7 +247,7 @@ namespace VEPROMS.CSLA.Library
|
|||||||
}
|
}
|
||||||
public ConfigDynamicTypeDescriptor MyConfig
|
public ConfigDynamicTypeDescriptor MyConfig
|
||||||
{
|
{
|
||||||
get { return Get().FolderConfig; }
|
get { return FolderConfig; }
|
||||||
}
|
}
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// These settings are set on the user interface side.
|
/// These settings are set on the user interface side.
|
||||||
|
@ -916,6 +916,8 @@ namespace Volian.Controls.Library
|
|||||||
|
|
||||||
private void tvROFST_DoubleClick(object sender, EventArgs e)
|
private void tvROFST_DoubleClick(object sender, EventArgs e)
|
||||||
{
|
{
|
||||||
|
// B2016-132: don't process a double click on an RO if on an enhanced step:
|
||||||
|
if (MyRTB != null && MyRTB.MyItemInfo != null && MyRTB.MyItemInfo.IsEnhancedStep) return;
|
||||||
//if (tvROFST.SelectedNode == null) return;
|
//if (tvROFST.SelectedNode == null) return;
|
||||||
//RunRoEditor();
|
//RunRoEditor();
|
||||||
SaveRO();
|
SaveRO();
|
||||||
|
Loading…
x
Reference in New Issue
Block a user