home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Chip 2007 January, February, March & April
/
Chip-Cover-CD-2007-02.iso
/
boot
/
i386
/
root
/
usr
/
share
/
YaST2
/
clients
/
vm_autoyast_proposal.ycp
< prev
next >
Wrap
Text File
|
2006-11-29
|
1KB
|
71 lines
/**
* Module: vm_autoyast_proposal.ycp
*
* Authors: Ladislav Slezak <lslezak@suse.cz>
*
* Purpose: Proposal for AutoYaST profile
*
* $Id: vm_autoyast_proposal.ycp 31352 2006-06-06 23:53:13Z mgfritch $
*
*/
{
textdomain "vm";
import "VM";
import "VM_Common";
import "HTML";
import "Mode";
import "Report";
Report::DisplayErrors(true, 0);
string func = (string) WFM::Args (0);
map param = (map) WFM::Args (1);
map ret = $[];
if ( func == "MakeProposal" )
{
boolean force_reset = param["force_reset" ]:false;
boolean language_changed = param["language_changed"]:false;
if (force_reset)
{
VM::ResetAutoYastProfile();
}
ret = $[ "preformatted_proposal" : VM::GetAutoYastProposal() ];
map warn = VM::GetAutoYastProposalWarning();
if (warn != nil && size(warn) > 0)
{
ret = union(ret, warn);
}
}
else if ( func == "AskUser" )
{
boolean has_next = param["has_next"]:false;
symbol result = (symbol) WFM::CallFunction ("inst_vm_autoyast",
[true, has_next]);
ret = $[ "workflow_sequence" : result ];
}
else if ( func == "Description" )
{
if (VM::GetVirtualizationType() == "para" && VM_Common::proposal_type == "install") {
ret = (Mode::config()) ? $[] :
$[
// this is a heading
"rich_text_title" : _("AutoYaST"),
// this is a menu entry
"menu_title" : _("AutoYaST"),
"id" : "vm_autoyast"
];
}
else return $[];
}
return ret;
}