make all frontend functions works (#466)

This commit is contained in:
Sijie.Sun authored and GitHub committed 2024-11-10 11:06:58 +08:00
1 parent e948dbfcc1
commit 88e6de9d7e
36 files changed
+1039 -483

No files matched your search

+4 -1
View File
@@ -100,7 +100,10 @@ impl WebClientService for Controller {
_: BaseController,
req: RunNetworkInstanceRequest,
) -> Result<RunNetworkInstanceResponse, rpc_types::error::Error> {
let cfg = TomlConfigLoader::new_from_str(&req.config)?;
if req.config.is_none() {
return Err(anyhow::anyhow!("config is required").into());
}
let cfg = req.config.unwrap().gen_config()?;
let id = cfg.get_id();
if let Some(inst_id) = req.inst_id {
cfg.set_id(inst_id.into());