From 6331fc23cbe8321150fbcf0f176a1106e3982aa0 Mon Sep 17 00:00:00 2001 From: zhangfan345 Date: Tue, 30 Aug 2022 10:47:22 +0800 Subject: Update intent module and CRUD APIs Issue-ID: USECASEUI-710 Signed-off-by: zhangfan345 Change-Id: I3e53e952b3554235e324b87adef2a997bae82d2a Signed-off-by: zhangfan345 --- .../main/resources/mybatis/sql/ContextMapper.xml | 45 +++++++++++++++++----- 1 file changed, 35 insertions(+), 10 deletions(-) (limited to 'intentanalysis/src/main/resources/mybatis/sql/ContextMapper.xml') diff --git a/intentanalysis/src/main/resources/mybatis/sql/ContextMapper.xml b/intentanalysis/src/main/resources/mybatis/sql/ContextMapper.xml index 975bd03..ff04551 100644 --- a/intentanalysis/src/main/resources/mybatis/sql/ContextMapper.xml +++ b/intentanalysis/src/main/resources/mybatis/sql/ContextMapper.xml @@ -6,19 +6,44 @@ - - insert into context(context_id, context_name, parent_id) - values - - (#{item.contextId}, #{item.contextName}, #{parentId}) - - + insert into context(context_id, context_name, parent_id) + values + + (#{item.contextId}, #{item.contextName}, #{parentId}) + - + select context_id contextId, context_name contextName from context where parent_id = #{parentId} - \ No newline at end of file + + + + insert into context(context_id, context_name, parent_id) + values + (#{context.contextId}, #{context.contextName}, #{parentId}) + + + + update context + + context_name = #{context.contextName}, + + where context_id = #{context.contextId} + + + + DELETE FROM context WHERE context_id = #{context.contextId} + + + + DELETE FROM context WHERE parent_id = #{parentId} + + -- cgit 1.2.3-korg