public async Task <ApiResponse <int> > Index(InstallParam param) { var installed = _configuration[ConfigKey.DbInstalled].ToBool(); if (!param.AdminPwd.IsNullOrWhiteSpace() && !installed) { if (await _installService.InitializeDb(param)) { return(ApiResponse <int> .Ok()); } } return(ApiResponse <int> .Fail("安装失败")); }