diff options
author | 2022-09-22 09:34:52 +0800 | |
---|---|---|
committer | 2022-09-22 02:16:47 +0000 | |
commit | 6788e2dd2bf8f3de3b4efa4d809cd64d4c8781cf (patch) | |
tree | dbcf4d6adf3c5a2771b592bfc5555ebcffab37df /intentanalysis/src/main/resources | |
parent | e9b9b7f526101fbeb8742b8643b750e3ca6d72fd (diff) |
Add intent management registration code.
Issue-ID: USECASEUI-696
Change-Id: I20500eaf08f6f41007478a21ff608071e393b54f
Signed-off-by: hekeguang <hekeguang@chinamobile.com>
Diffstat (limited to 'intentanalysis/src/main/resources')
-rw-r--r-- | intentanalysis/src/main/resources/intent-analysis-init.sql | 2 | ||||
-rw-r--r-- | intentanalysis/src/main/resources/mybatis/sql/IMFRegInfoMapper.xml | 14 |
2 files changed, 12 insertions, 4 deletions
diff --git a/intentanalysis/src/main/resources/intent-analysis-init.sql b/intentanalysis/src/main/resources/intent-analysis-init.sql index d7c513c..e5af890 100644 --- a/intentanalysis/src/main/resources/intent-analysis-init.sql +++ b/intentanalysis/src/main/resources/intent-analysis-init.sql @@ -64,7 +64,9 @@ create table if not exists condition( create table if not exists intent_management_function_reg_info( imfr_info_id varchar(255) primary key, imfr_info_description varchar(255), + support_area text ARRAY, support_model varchar(255), + support_interfaces text ARRAY, handle_name varchar(255), intent_function_type varchar(255) );
\ No newline at end of file diff --git a/intentanalysis/src/main/resources/mybatis/sql/IMFRegInfoMapper.xml b/intentanalysis/src/main/resources/mybatis/sql/IMFRegInfoMapper.xml index 03af60b..fd632b3 100644 --- a/intentanalysis/src/main/resources/mybatis/sql/IMFRegInfoMapper.xml +++ b/intentanalysis/src/main/resources/mybatis/sql/IMFRegInfoMapper.xml @@ -2,16 +2,22 @@ <!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd"> + <mapper namespace="org.onap.usecaseui.intentanalysis.mapper.IMFRegInfoMapper"> + <resultMap id="mapIMFRInfo" type="org.onap.usecaseui.intentanalysis.bean.models.IntentManagementFunctionRegInfo"> + <result column="support_area" property="supportArea" typeHandler="org.onap.usecaseui.intentanalysis.util.ListArrayTypeHandler" jdbcType="ARRAY" javaType="java.util.List"/> + <result column="support_interfaces" property="supportInterfaces" typeHandler="org.onap.usecaseui.intentanalysis.util.ListArrayTypeHandler" jdbcType="ARRAY" javaType="java.util.List"/> + </resultMap> + <insert id="insertIMFRegInfoRegInfo"> - insert into intent_management_function_reg_info(imfr_info_id, imfr_info_description, support_model,handle_name,intent_function_type) + insert into intent_management_function_reg_info(imfr_info_id,imfr_info_description,support_area,support_model,support_interfaces,handle_name,intent_function_type) values - (#{imfregInfo.id}, #{imfregInfo.description}, #{imfregInfo.supportModel},#{imfregInfo.handleName},#{imfregInfo.intentFunctionType}) + (#{imfregInfo.id}, #{imfregInfo.description},#{imfregInfo.supportArea} , #{imfregInfo.supportModel},#{imfregInfo.supportInterfaces},#{imfregInfo.handleName},#{imfregInfo.intentFunctionType}) </insert> - <select id="getImfRegInfoList" resultType="org.onap.usecaseui.intentanalysis.bean.models.IntentManagementFunctionRegInfo"> - select * from intent_management_function_reg_info + <select id="getImfRegInfoList" resultMap="mapIMFRInfo"> + select * from intent_management_function_reg_info </select> </mapper> |