修复postgresql下的行政区划导入
parent
550b90b157
commit
0c642f3b58
|
@ -190,16 +190,32 @@ public interface GroupMapper {
|
||||||
"</script>")
|
"</script>")
|
||||||
Set<Group> queryByChannelList(List<CommonGBChannel> channelList);
|
Set<Group> queryByChannelList(List<CommonGBChannel> channelList);
|
||||||
|
|
||||||
@Update(" <script>" +
|
@Update(value = " <script>" +
|
||||||
" update wvp_common_group w1 " +
|
" update wvp_common_group w1 " +
|
||||||
" inner join (select * from wvp_common_group ) w2 on w1.parent_device_id = w2.device_id " +
|
" inner join (select * from wvp_common_group ) w2 on w1.parent_device_id = w2.device_id " +
|
||||||
" set w1.parent_id = w2.id" +
|
" set w1.parent_id = w2.id" +
|
||||||
" where w1.id in " +
|
" where w1.id in " +
|
||||||
" <foreach collection='groupListForAdd' item='item' open='(' separator=',' close=')' > #{item.id}</foreach>" +
|
" <foreach collection='groupListForAdd' item='item' open='(' separator=',' close=')' > #{item.id}</foreach>" +
|
||||||
" </script>")
|
" </script>", databaseId = "mysql")
|
||||||
|
@Update( value = " <script>" +
|
||||||
|
" update wvp_common_group w1\n" +
|
||||||
|
" set parent_id = w2.id\n" +
|
||||||
|
" from wvp_common_group w2\n" +
|
||||||
|
" where w1.parent_device_id = w2.device_id\n" +
|
||||||
|
" and w1.id in " +
|
||||||
|
" <foreach collection='groupListForAdd' item='item' open='(' separator=',' close=')' > #{item.id}</foreach>" +
|
||||||
|
" </script>", databaseId = "postgresql")
|
||||||
|
@Update( value = " <script>" +
|
||||||
|
" update wvp_common_group w1\n" +
|
||||||
|
" set parent_id = w2.id\n" +
|
||||||
|
" from wvp_common_group w2\n" +
|
||||||
|
" where w1.parent_device_id = w2.device_id\n" +
|
||||||
|
" and w1.id in " +
|
||||||
|
" <foreach collection='groupListForAdd' item='item' open='(' separator=',' close=')' > #{item.id}</foreach>" +
|
||||||
|
" </script>", databaseId = "kingbase")
|
||||||
void updateParentId(List<Group> groupListForAdd);
|
void updateParentId(List<Group> groupListForAdd);
|
||||||
|
|
||||||
@Update(" <script>" +
|
@Update(value = " <script>" +
|
||||||
" update wvp_common_group w1 " +
|
" update wvp_common_group w1 " +
|
||||||
" inner join (select * from wvp_common_group ) w2" +
|
" inner join (select * from wvp_common_group ) w2" +
|
||||||
" on w1.parent_device_id is null" +
|
" on w1.parent_device_id is null" +
|
||||||
|
@ -210,7 +226,31 @@ public interface GroupMapper {
|
||||||
" set w1.parent_id = w2.id" +
|
" set w1.parent_id = w2.id" +
|
||||||
" where w1.id in " +
|
" where w1.id in " +
|
||||||
" <foreach collection='groupListForAdd' item='item' open='(' separator=',' close=')' > #{item.id}</foreach>" +
|
" <foreach collection='groupListForAdd' item='item' open='(' separator=',' close=')' > #{item.id}</foreach>" +
|
||||||
" </script>")
|
" </script>", databaseId = "mysql")
|
||||||
|
@Update( value = " <script>" +
|
||||||
|
" update wvp_common_group w1 " +
|
||||||
|
" set parent_id = w2.id " +
|
||||||
|
" from wvp_common_group w2 " +
|
||||||
|
" where w1.parent_device_id is null " +
|
||||||
|
" and w2.parent_device_id is null " +
|
||||||
|
" and w2.device_id = w2.business_group " +
|
||||||
|
" and w1.business_group = w2.device_id " +
|
||||||
|
" and w1.device_id != w1.business_group " +
|
||||||
|
" and w1.id in " +
|
||||||
|
" <foreach collection='groupListForAdd' item='item' open='(' separator=',' close=')' > #{item.id}</foreach>" +
|
||||||
|
" </script>", databaseId = "kingbase")
|
||||||
|
@Update( value = " <script>" +
|
||||||
|
" update wvp_common_group w1 " +
|
||||||
|
" set parent_id = w2.id " +
|
||||||
|
" from wvp_common_group w2 " +
|
||||||
|
" where w1.parent_device_id is null " +
|
||||||
|
" and w2.parent_device_id is null " +
|
||||||
|
" and w2.device_id = w2.business_group " +
|
||||||
|
" and w1.business_group = w2.device_id " +
|
||||||
|
" and w1.device_id != w1.business_group " +
|
||||||
|
" and w1.id in " +
|
||||||
|
" <foreach collection='groupListForAdd' item='item' open='(' separator=',' close=')' > #{item.id}</foreach>" +
|
||||||
|
" </script>", databaseId = "postgresql")
|
||||||
void updateParentIdWithBusinessGroup(List<Group> groupListForAdd);
|
void updateParentIdWithBusinessGroup(List<Group> groupListForAdd);
|
||||||
|
|
||||||
@Select(" <script>" +
|
@Select(" <script>" +
|
||||||
|
|
|
@ -106,13 +106,29 @@ public interface RegionMapper {
|
||||||
List<CommonGBChannel> queryByPlatform(@Param("platformId") Integer platformId);
|
List<CommonGBChannel> queryByPlatform(@Param("platformId") Integer platformId);
|
||||||
|
|
||||||
|
|
||||||
@Update(" <script>" +
|
@Update(value = " <script>" +
|
||||||
" update wvp_common_region w1 " +
|
" update wvp_common_region w1 " +
|
||||||
" inner join (select * from wvp_common_region ) w2 on w1.parent_device_id = w2.device_id " +
|
" inner join (select * from wvp_common_region ) w2 on w1.parent_device_id = w2.device_id " +
|
||||||
" set w1.parent_id = w2.id" +
|
" set w1.parent_id = w2.id" +
|
||||||
" where w1.id in " +
|
" where w1.id in " +
|
||||||
" <foreach collection='regionListForAdd' item='item' open='(' separator=',' close=')' > #{item.id}</foreach>" +
|
" <foreach collection='regionListForAdd' item='item' open='(' separator=',' close=')' > #{item.id}</foreach>" +
|
||||||
" </script>")
|
" </script>", databaseId = "mysql")
|
||||||
|
@Update( value = " <script>" +
|
||||||
|
" update wvp_common_region w1\n" +
|
||||||
|
" set parent_id = w2.id\n" +
|
||||||
|
" from wvp_common_region w2\n" +
|
||||||
|
" where w1.parent_device_id = w2.device_id\n" +
|
||||||
|
" and w1.id in " +
|
||||||
|
" <foreach collection='regionListForAdd' item='item' open='(' separator=',' close=')' > #{item.id}</foreach>" +
|
||||||
|
" </script>", databaseId = "kingbase")
|
||||||
|
@Update( value = " <script>" +
|
||||||
|
" update wvp_common_region w1\n" +
|
||||||
|
" set parent_id = w2.id\n" +
|
||||||
|
" from wvp_common_region w2\n" +
|
||||||
|
" where w1.parent_device_id = w2.device_id\n" +
|
||||||
|
" and w1.id in " +
|
||||||
|
" <foreach collection='regionListForAdd' item='item' open='(' separator=',' close=')' > #{item.id}</foreach>" +
|
||||||
|
" </script>", databaseId = "postgresql")
|
||||||
void updateParentId(List<Region> regionListForAdd);
|
void updateParentId(List<Region> regionListForAdd);
|
||||||
|
|
||||||
@Update(" <script>" +
|
@Update(" <script>" +
|
||||||
|
|
|
@ -40,8 +40,6 @@
|
||||||
</el-select>
|
</el-select>
|
||||||
</div>
|
</div>
|
||||||
<el-button icon="el-icon-refresh-right" circle size="mini" @click="refresh()"></el-button>
|
<el-button icon="el-icon-refresh-right" circle size="mini" @click="refresh()"></el-button>
|
||||||
<el-button v-if="showTree" icon="iconfont icon-list" circle size="mini" @click="switchList()"></el-button>
|
|
||||||
<el-button v-if="!showTree" icon="iconfont icon-tree" circle size="mini" @click="switchTree()"></el-button>
|
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<devicePlayer ref="devicePlayer"></devicePlayer>
|
<devicePlayer ref="devicePlayer"></devicePlayer>
|
||||||
|
|
|
@ -4,26 +4,13 @@
|
||||||
<el-dialog title="通道共享" v-loading="loading" v-if="showDialog" top="2rem" width="80%" :close-on-click-modal="false" :visible.sync="showDialog" :destroy-on-close="true" @close="close()">
|
<el-dialog title="通道共享" v-loading="loading" v-if="showDialog" top="2rem" width="80%" :close-on-click-modal="false" :visible.sync="showDialog" :destroy-on-close="true" @close="close()">
|
||||||
<el-row>
|
<el-row>
|
||||||
<el-col :span="24">
|
<el-col :span="24">
|
||||||
<el-tabs v-model="catalogTabActiveName" >
|
<el-container>
|
||||||
<el-tab-pane label="共享通道" name="addShare">
|
<el-main v-bind:style="{backgroundColor: '#FFF', maxHeight: winHeight + 'px'}">
|
||||||
<el-container>
|
<shareChannelAdd ref="shareChannelAdd" :platformId="platformId"></shareChannelAdd>
|
||||||
<el-main v-bind:style="{backgroundColor: '#FFF', maxHeight: winHeight + 'px'}">
|
</el-main>
|
||||||
<shareChannelAdd ref="shareChannelAdd" :platformId="platformId"></shareChannelAdd>
|
</el-container>
|
||||||
</el-main>
|
|
||||||
</el-container>
|
|
||||||
</el-tab-pane>
|
|
||||||
<el-tab-pane label="共享通道信息展示" name="showShare">
|
|
||||||
|
|
||||||
</el-tab-pane>
|
|
||||||
<el-tab-pane label="共享通道信息自定义" name="customShare">
|
|
||||||
|
|
||||||
</el-tab-pane>
|
|
||||||
</el-tabs>
|
|
||||||
|
|
||||||
</el-col>
|
</el-col>
|
||||||
|
|
||||||
</el-row>
|
</el-row>
|
||||||
|
|
||||||
</el-dialog>
|
</el-dialog>
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
|
|
Loading…
Reference in New Issue