我试图关注来自extjs的setup guide。将GPL版本6.2.0下载到我的主文件夹中并执行
sencha app init --ext@6.2.0 --modern MyApp
Sencha Cmd v6.5.3.6
[INF] Using existing workspace at /home/bivol/myapp
[ERR] Cannot satisfy requirements for "ext"!
[INF] The following versions are available:
[INF] 5.0.0.970 ( ... compatible back to 4.0)
[INF] 5.0.1.1255 ( ... compatible back to 4.0)
[INF] 5.1.0.107 ( ... compatible back to 4.0)
[INF] 5.1.1.451 ( ... compatible back to 4.0)
[INF] 6.0.0.640 ( ... compatible back to 6.0.0)
[ERR] The following versions cannot be satisfied:
[ERR] root: ext@6.2.0 (No matches!)
[ERR] Cannot resolve package requirements
但是当我执行init命令时,我收到以下错误:
public class RestInterfaceImp : IRestLogin
{
HttpClient client;
private const string WebServiceUrl = "http://localhost:56207/api/Users/Raju/Password@123";
public async Task<List<User>> RefreshDataAsync()
{
try
{
var httpClient = new HttpClient();
var resp = await httpClient.GetAsync(WebServiceUrl);
if (resp.IsSuccessStatusCode)
{
var respStr = await resp.Content.ReadAsStringAsync();
var listaAtletas = JsonConvert.DeserializeObject<List<User>>(respStr);
}
}
catch (HttpRequestException e)
{
Debug.WriteLine(e.InnerException.Message);
}
return null;
}
}
答案 0 :(得分:1)
似乎cmd道具没有得到妥善保存。因此,您必须在app init期间指定extjs的路径。 我最终使用了这个有效的命令:
sencha app init -e /home/username/sencha-sdks/ext-6.2.0 --modern MyApp
Sencha Cmd v6.5.3.6
[INF] Using existing workspace at /home/bivol/myapp
[INF] Copying framework to /home/bivol/myapp/ext
[INF] Added framework ext to workspace.json
[INF] Loading framework from /home/bivol/myapp/ext