Quintiq file version 2.0
|
#parent: #root
|
StaticMethod CanImportFromDataManager (
|
output String feedback_o,
|
ScenarioManager scenariomanager,
|
Boolean hassalesdemand,
|
String salesdemandselection,
|
Boolean ismpscdef,
|
Boolean hasscmpparams,
|
String scmpparams,
|
Boolean hasscplan,
|
String scplan,
|
Boolean invalidexcelpath
|
) declarative remote as Boolean
|
{
|
Description: 'Check whether we can import from data manager.'
|
TextBody:
|
[*
|
// Adhi Nov-27-2015 (created)
|
|
canImport := true
|
feedback_o := '';
|
|
isSDValid := hassalesdemand and not salesdemandselection = '';
|
isSCMPValid := hasscmpparams and not scmpparams = '';
|
isSCPlanValid := hasscplan and not scplan = '';
|
eitherPlan := hasscmpparams or hasscplan
|
|
if( ismpscdef )
|
{
|
canImport := isSDValid or isSCMPValid or isSCPlanValid;
|
if( not canImport )
|
{
|
feedback_o := Translations::MP_GlobalParameters_MP_CanImportFromDataManager_InvalidImport();
|
}
|
}
|
else
|
{
|
canImport := eitherPlan and not invalidexcelpath or isSDValid;
|
if( invalidexcelpath )
|
{
|
feedback_o := Translations::MPSync_ImportProfile_ValidateInput_IsInvalidExcelPath();
|
}
|
else
|
{
|
feedback_o := Translations::MP_GlobalParameters_MP_CanImportFromDataManager_InvalidImport();
|
}
|
}
|
return canImport;
|
*]
|
}
|