| 12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061 |
- <template>
- <div>
- <InfoWindow
- :info-window-no="infoWindowNo" :multiple="true" :is-search-widget="false" :is-new-similar-assets="false"
- @get-select-model-data="getSelectModelData"
- >
- <template #customContent>
- <div>这是自定义内容</div>
- </template>
- </InfoWindow>
- </div>
- </template>
- <script>
- import InfoWindow from '@/info/index.js';
- export default {
- components: {
- InfoWindow,
- },
- props: {
- },
- data: function () {
- return {
- 'infoWindowNo': null,
- };
- },
- watch: {
- '$route': function (to, from) {
- this.getInfoWindowNo();
- },
- },
- mounted: function () {
- this.getInfoWindowNo();
- },
- methods: {
- /**
- * 获取查询窗口的编号
- */
- getInfoWindowNo: function () {
- if (this.$route.params != undefined) {
- var routeInfoWindowNo = this.$route.params.infoWindowNo;
- if (this.infoWindowNo != routeInfoWindowNo) {
- this.infoWindowNo = routeInfoWindowNo;
- console.log('open info window: ' + routeInfoWindowNo);
- }
- }
- },
- getSelectModelData: function (selected) {
- console.log(selected, '---');
- },
- },
- };
- </script>
|