Skip to content

Commit

Permalink
update api path
Browse files Browse the repository at this point in the history
  • Loading branch information
RWDai committed Oct 29, 2024
1 parent 4c5d8d3 commit 6f9edca
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion backend/spi/spi-log/src/api/ci/log_ci_item_api.rs
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ impl LogCiItemApi {
}

/// Interface Console Log API V2
#[poem_openapi::OpenApi(prefix_path = "/ci/item/v2", tag = "bios_basic::ApiTag::Interface")]
#[poem_openapi::OpenApi(prefix_path = "/ci/v2/item", tag = "bios_basic::ApiTag::Interface")]
impl LogCiItemApiV2 {
/// Add Item
#[oai(path = "/", method = "post")]
Expand Down
4 changes: 2 additions & 2 deletions frontend/sdks/invoke/src/clients/spi_log_client.rs
Original file line number Diff line number Diff line change
Expand Up @@ -180,7 +180,7 @@ impl SpiLogClient {
}
let log_url: String = BaseSpiClient::module_url(InvokeModuleKind::Log, funs).await?;
let headers = BaseSpiClient::headers(None, funs, ctx).await?;
funs.web_client().post_obj_to_str(&format!("{log_url}/ci/item/v2"), &req, headers.clone()).await?;
funs.web_client().post_obj_to_str(&format!("{log_url}/ci/v2/item"), &req, headers.clone()).await?;
Ok(())
}

Expand All @@ -190,7 +190,7 @@ impl SpiLogClient {
}

pub async fn findv2(find_req: LogItemFindReq, funs: &TardisFunsInst, ctx: &TardisContext) -> TardisResult<Option<TardisPage<LogItemFindResp>>> {
Self::do_find(find_req, "/ci/item/v2/find", funs, ctx).await
Self::do_find(find_req, "/ci/v2/item/find", funs, ctx).await
}

async fn do_find(find_req: LogItemFindReq, path: &str, funs: &TardisFunsInst, ctx: &TardisContext) -> TardisResult<Option<TardisPage<LogItemFindResp>>> {
Expand Down

0 comments on commit 6f9edca

Please sign in to comment.