diff --git a/src/components/ec_api/BasicConfig.vue b/src/components/ec_api/BasicConfig.vue index a007e4d..ef74244 100644 --- a/src/components/ec_api/BasicConfig.vue +++ b/src/components/ec_api/BasicConfig.vue @@ -125,6 +125,7 @@ function api_on_change() { function handle_api_data() { // 生成被选择的api的数组 + SelectApi.value = [] SelectApiId.value.forEach(api_id => { Api.value.forEach(api => { if (api.id === api_id) { @@ -138,13 +139,6 @@ function handle_api_data() { SelectApiParams.value[api_id] = ApiParams.value[api_id] } }) - - - console.log('Api.value', Api.value) - console.log('SelectApiId.value', SelectApiId.value) - console.log('SelectApi.value', SelectApi.value) - console.log('ApiParams.value', ApiParams.value) - console.log('SelectApiParams.value', SelectApiParams.value) } // 生成共享数据 @@ -159,8 +153,8 @@ function store_data() { }) console.log('select_data.value', select_data.value) // 写入store - store.commit('ecApiModule/change_ec_select_api', SelectApiId.value) store.commit('ecApiModule/add_ec_api_data', select_data.value) + store.commit('ecApiModule/change_ec_select_api', SelectApi.value) console.log('store.state.ecApiModule.ec_api_data', store.state.ecApiModule.ec_api_data) } diff --git a/src/components/ec_api/TabArea.vue b/src/components/ec_api/TabArea.vue index 3415fcf..925c9dd 100644 --- a/src/components/ec_api/TabArea.vue +++ b/src/components/ec_api/TabArea.vue @@ -1,5 +1,5 @@