Merge remote-tracking branch 'origin/master'

main
liu.shiyi 2 years ago
commit ce98bddb4c

@ -8,9 +8,7 @@ import org.springframework.boot.context.properties.NestedConfigurationProperty;
import org.springframework.context.annotation.Configuration;
/**
*
*
* @Author maoshufeng
* @Author qianxing
* @Date 2020-06-16
* @Version 1.0.0
*/

@ -14,11 +14,17 @@ import org.springframework.context.annotation.Configuration;
import javax.annotation.PostConstruct;
import javax.annotation.Resource;
/**
* Jackson
* @Author hongyang
* @Date 2022/06/19
* @Version 1.0.0
*/
@Slf4j
@Configuration
@ConditionalOnMissingClass(value = "com.gccloud.dashboard.core.config.ObjectMapperConfiguration")
//@ConditionalOnProperty(prefix = "gc.starter.dataroom.component", name = "ObjectMapperConfiguration", havingValue = "ObjectMapperConfiguration", matchIfMissing = true)
public class ObjectMapperConfiguration {
@ConditionalOnProperty(prefix = "gc.starter.dataroom.component", name = "ObjectMapperConfiguration", havingValue = "ObjectMapperConfiguration", matchIfMissing = true)
public class DataRoomObjectMapperConfiguration {
@Resource
private ObjectMapper objectMapper;

@ -101,6 +101,14 @@ public class ScreenFlyMapChart extends Chart{
@ApiModelProperty(notes = "名称")
private String name;
@ApiModelProperty(notes = "图形")
private List<String> graphic;
@ApiModelProperty(notes = "图形字体颜色")
private String fontGraphicColor;
@ApiModelProperty(notes = "图形字体大小")
private String fontSize;
}
}

@ -20,16 +20,6 @@
"to": "河北省",
"type": "move_in",
"value": 10
},
{
"from": "合肥",
"lat1": 32.0581,
"lat2": 25.9222,
"lng1": 117.29,
"lng2": 119.4543,
"to": "福州",
"type": "move_in",
"value": 50
}
],
"columnData": {

@ -345,6 +345,7 @@
</el-dialog>
</template>
<script>
import { displayOption } from 'data-room-ui/js/config'
import { pageMixins } from 'data-room-ui/js/mixins/page'
// import _ from 'lodash'
import isEmpty from 'lodash/isEmpty'
@ -425,14 +426,22 @@ export default {
}
this.$emit('setRemoteComponent', this.focus)
} if (['bizComponent'].includes(this.activeName)) {
let config = {}
let config = {
setting: [],
option: {}
}
if (isEmpty(this.focus)) {
return
}
config.code = this.focus.code
config.name = this.focus.name
config = getRemoteComponentConfig(this.focus.code, this.focus.name)
config = cloneDeep(getRemoteComponentConfig(this.focus.code, this.focus.name))
const settingContent = cloneDeep(this.resolveStrSetting(this.focus.settingContent))
config.setting = settingContent.setting
config.option = settingContent.option
this.$emit('setRemoteComponent', config)
// config = getRemoteComponentConfig(this.focus.code, this.focus.name)
// this.$emit('setRemoteComponent', config)
}
},
getDataList () {
@ -472,6 +481,33 @@ export default {
})
}
},
/**
* 处理当前组件的字符串配置
*/
resolveStrSetting (settingContent) {
// eslint-disable-next-line prefer-const
let option = {}
// eslint-disable-next-line prefer-const
let setting = []
// eslint-disable-next-line prefer-const, no-unused-vars
let title = []
// eslint-disable-next-line prefer-const, no-unused-vars
let data = []
// eslint-disable-next-line prefer-const
settingContent = settingContent.replaceAll('const ', '')
// export default
settingContent = settingContent.replace(/export default[\s\S]*/, '')
eval(settingContent)
option = {
data,
displayOption,
...option
}
return {
option,
setting
}
},
//
getCatalogList () {
const url = this.activeName === 'combination' ? '/bigScreen/type/list/componentCatalog' : '/bigScreen/type/list/bizComponentCatalog'

@ -373,7 +373,7 @@ export default {
this.form.refreshConfig = []
} else {
this.pageInfo.chartList.forEach(chart => {
if (chart.dataSource.businessKey) {
if (chart.dataSource?.businessKey) {
this.chartOptions.push({
code: chart.code,
title: chart.title,
@ -470,7 +470,7 @@ export default {
this.$emit('close')
},
timerEmptyState () {
return this.pageInfo.chartList.every(chart => chart.dataSource.businessKey === '')
return this.pageInfo.chartList.every(chart => chart.dataSource?.businessKey === '')
}
}
}

@ -4,13 +4,13 @@
* @Author: xing.heng
*/
// import _ from 'lodash'
import cloneDeep from 'lodash/cloneDeep'
import { mapMutations, mapState } from 'vuex'
import { EventBus } from 'data-room-ui/js/utils/eventBus'
import { getChatInfo, getUpdateChartInfo } from '../api/bigScreenApi'
import axiosFormatting from '../../js/utils/httpParamsFormatting'
import {settingToTheme} from "data-room-ui/js/utils/themeFormatting";
import _ from "lodash";
import { settingToTheme } from 'data-room-ui/js/utils/themeFormatting'
import cloneDeep from 'lodash/cloneDeep'
export default {
data () {
return {
@ -100,14 +100,14 @@ export default {
const scriptMethod = new Function(scriptAfterReplacement)
_res.data = scriptMethod()
} catch (error) {
console.error('JS数据集脚本执行失败', error)
console.info('JS数据集脚本执行失败', error)
}
}
}
config = this.dataFormatting(config, _res)
this.changeChartConfig(config)
}).catch((err) => {
console.error(err)
console.info(err)
}).finally(() => {
resolve(config)
})
@ -151,7 +151,7 @@ export default {
const scriptMethod = new Function(scriptAfterReplacement)
_res.data = scriptMethod()
} catch (error) {
console.error('JS数据集脚本执行失败', error)
console.info('JS数据集脚本执行失败', error)
}
}
}
@ -165,7 +165,7 @@ export default {
}
}
}).catch(err => {
console.error(err)
console.info(err)
}).finally(() => {
resolve(config)
})
@ -191,7 +191,7 @@ export default {
changeStyle (config) {
config = { ...this.config, ...config }
// 样式改变时更新主题配置
config.theme = settingToTheme(_.cloneDeep(config), this.customTheme)
config.theme = settingToTheme(cloneDeep(config), this.customTheme)
this.changeChartConfig(config)
if (config.code === this.activeCode) {
this.changeActiveItemConfig(config)

@ -32,5 +32,4 @@ export default function speak ({ text, speechRate, lang, volume, pitch }, endEve
startEvent && startEvent()
}
speechSynthesis.speak(speechUtterance)
console.log(2)
}

@ -45,7 +45,7 @@ module.exports = {
outputDir: 'dataRoomUi',
assetsDir: 'static',
lintOnSave: false,
productionSourceMap: false,
productionSourceMap: true,
runtimeCompiler: true,
devServer: {
hot: true,

Loading…
Cancel
Save