Merge remote-tracking branch 'origin/dev' into dev
This commit is contained in:
@@ -0,0 +1,84 @@
|
||||
<template>
|
||||
<ai-list class="AppGridMemberScore">
|
||||
<template slot="title">
|
||||
<ai-title title="网格员积分" :isShowBottomBorder="false" :instance="instance" >
|
||||
|
||||
</ai-title>
|
||||
</template>
|
||||
<template slot="tabs">
|
||||
<el-tabs v-model="currIndex">
|
||||
<el-tab-pane v-for="(tab,i) in tabs" :key="i" :label="tab.label">
|
||||
<component :is="tab.comp" v-if="currIndex === String(i)" :ref="tab.name"
|
||||
:areaId="areaId" :instance="instance" :dict="dict" :permissions="permissions"/>
|
||||
</el-tab-pane>
|
||||
</el-tabs>
|
||||
</template>
|
||||
</ai-list>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import girdScoreManage from "./components/girdScoreManage"
|
||||
import gridScoreRules from "./components/gridScoreRules"
|
||||
import gridScoreStatistics from './components/gridScoreStatistics'
|
||||
import {mapState} from 'vuex'
|
||||
|
||||
export default {
|
||||
name: 'AppGridMemberScore',
|
||||
label: "网格员积分",
|
||||
components: {girdScoreManage, gridScoreRules, gridScoreStatistics},
|
||||
props: {
|
||||
instance: Function,
|
||||
dict: Object,
|
||||
permissions: Function
|
||||
},
|
||||
|
||||
data() {
|
||||
return {
|
||||
activeName: "girdScoreManage",
|
||||
currIndex: "2",
|
||||
areaId: '',
|
||||
oldActiveName: '',
|
||||
}
|
||||
},
|
||||
|
||||
computed: {
|
||||
...mapState(['user']),
|
||||
tabs() {
|
||||
return [
|
||||
{
|
||||
label: "积分管理",
|
||||
name: "girdScoreManage",
|
||||
comp: girdScoreManage,
|
||||
permission: "",
|
||||
},
|
||||
{
|
||||
label: "积分规则",
|
||||
name: "gridScoreRules",
|
||||
comp: gridScoreRules,
|
||||
permission: "",
|
||||
},
|
||||
{
|
||||
label: "积分统计",
|
||||
name: "gridScoreStatistics",
|
||||
comp: gridScoreStatistics,
|
||||
permission: "",
|
||||
},
|
||||
]
|
||||
}
|
||||
},
|
||||
created() {
|
||||
this.areaId = this.user.info.areaId
|
||||
// this.$dict.load("")
|
||||
},
|
||||
methods: {
|
||||
|
||||
},
|
||||
|
||||
}
|
||||
</script>
|
||||
|
||||
<style lang="scss" scoped>
|
||||
.AppGridMemberScore {
|
||||
height: 100%;
|
||||
}
|
||||
</style>
|
||||
@@ -0,0 +1,96 @@
|
||||
<template>
|
||||
<section class="girdScoreManage">
|
||||
<ai-list>
|
||||
<template #content>
|
||||
<ai-search-bar>
|
||||
<template #left>
|
||||
<el-button type="primary" size="small" icon="iconfont iconAdd">批量调整积分</el-button>
|
||||
<el-select size="small" style="width: 200px;margin-left: 16px;" v-model="search.girdId" placeholder="所属网格" clearable
|
||||
@change="getListInit()">
|
||||
<el-option
|
||||
v-for="(item,i) in girdList"
|
||||
:key="i"
|
||||
:label="item.girdName"
|
||||
:value="item.id"
|
||||
>
|
||||
</el-option>
|
||||
</el-select>
|
||||
</template>
|
||||
<template #right>
|
||||
<el-input size="small" placeholder="请输入居民名称或真实姓名" v-model="search.name" clearable
|
||||
@clear="page.current = 1, search.name = '', getTableData()" suffix-icon="iconfont iconSearch"
|
||||
v-throttle="() => {(page.current = 1), getTableData();}" style="margin-right: 16px;"/>
|
||||
<ai-download :instance="instance" url="" :params="search" fileName="网格员积分"
|
||||
:disabled="tableData.length == 0">
|
||||
<el-button size="small">导出</el-button>
|
||||
</ai-download>
|
||||
</template>
|
||||
</ai-search-bar>
|
||||
<ai-table :tableData="tableData" :total="page.total" :current.sync="page.current" :size.sync="page.size"
|
||||
@getList="getTableData" :col-configs="colConfigs" :dict="dict">
|
||||
<el-table-column slot="options" label="操作" align="center">
|
||||
<template slot-scope="{ row }">
|
||||
<el-button type="text" @click="handleDelete(row.id)">调整积分</el-button>
|
||||
<el-button type="text" @click="toAdd(row.id)">详情</el-button>
|
||||
|
||||
</template>
|
||||
</el-table-column>
|
||||
</ai-table>
|
||||
</template>
|
||||
</ai-list>
|
||||
</section>
|
||||
|
||||
</template>
|
||||
|
||||
<script>
|
||||
export default {
|
||||
name: "girdScoreManage",
|
||||
label: "积分管理",
|
||||
props: {
|
||||
instance: Function,
|
||||
dict: Object,
|
||||
permissions: Function
|
||||
},
|
||||
data() {
|
||||
return {
|
||||
search: {
|
||||
current: 1,
|
||||
name: '',
|
||||
girdId: '',
|
||||
},
|
||||
tableData: [],
|
||||
page: {current: 1, size: 10, total: 0},
|
||||
girdList: [],
|
||||
}
|
||||
},
|
||||
computed: {
|
||||
colConfigs() {
|
||||
return [
|
||||
{ prop: "", label: '姓名', align: "left", },
|
||||
{ prop: "", label: '所属网格', align: "center", },
|
||||
{ prop: "", label: '积分余额', align: "center", },
|
||||
{ prop: "", label: '累计积分', align: "center", },
|
||||
{ slot: "options" },
|
||||
]
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
getTableData() {},
|
||||
getListInit() {
|
||||
this.search.current = 1
|
||||
this.getList()
|
||||
},
|
||||
},
|
||||
|
||||
}
|
||||
</script>
|
||||
|
||||
<style lang="scss" scoped>
|
||||
.girdScoreManage {
|
||||
height: 100%;
|
||||
// ::v-deep .searchLeftZone,
|
||||
// ::v-deep .searchRightZone {
|
||||
// display: flex;
|
||||
// }
|
||||
}
|
||||
</style>
|
||||
@@ -0,0 +1,26 @@
|
||||
<template>
|
||||
<section class="gridScoreDetail">
|
||||
<!-- <ai-detail>
|
||||
<template #title>
|
||||
<ai-title title="网格员积分详情" isShowBottomBorder isShowBack @onBackClick="cancel(true)"></ai-title>
|
||||
</template>
|
||||
</ai-detail> -->
|
||||
</section>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
export default {
|
||||
name: "gridScoreDetail",
|
||||
label: "网格员积分详情",
|
||||
data() {
|
||||
return {
|
||||
|
||||
}
|
||||
},
|
||||
methods: {},
|
||||
}
|
||||
</script>
|
||||
|
||||
<style lang="scss" scoped>
|
||||
.gridScoreDetail {}
|
||||
</style>
|
||||
@@ -0,0 +1,304 @@
|
||||
|
||||
<template>
|
||||
<section class="gridScoreRules">
|
||||
<!-- v-if="permissions('app_appvillagerintegralrule_detail')" -->
|
||||
<ai-list>
|
||||
<template slot="content">
|
||||
<ai-search-bar>
|
||||
<template #left>
|
||||
<el-button type="primary" icon="iconfont iconAdd" @click="dialog=true">添加</el-button>
|
||||
</template>
|
||||
<template slot="right">
|
||||
<el-cascader size="small" v-model="search.eventType" placeholder="请选择事件/类型" clearable style="margin-right: 16px;"
|
||||
:props="{...etOps,checkStrictly:true}" @change="handleTypeSearch" ref="eventTypeSearch" />
|
||||
<ai-select
|
||||
v-model="search.status"
|
||||
@change="page.current = 1, getList()"
|
||||
placeholder="请选择状态"
|
||||
:selectList="$dict.getDict('integralRuleStatus')">
|
||||
</ai-select>
|
||||
</template>
|
||||
|
||||
</ai-search-bar>
|
||||
<ai-table
|
||||
:tableData="tableData"
|
||||
:col-configs="colConfigs"
|
||||
:total="page.total" :dict="dict"
|
||||
:current.sync="page.current"
|
||||
:size.sync="page.size"
|
||||
@getList="getList">
|
||||
<el-table-column slot="integral" label="分值" align="center">
|
||||
<template slot-scope="{ row }">
|
||||
<span
|
||||
v-if="row.integralValueType == 1">
|
||||
{{ row.integralStart > 0 ? '+' + row.integralStart : row.integralStart }} ~ {{ row.integralEnd > 0 ? '+' + row.integralEnd : row.integralEnd }}
|
||||
</span>
|
||||
<span v-else>{{ row.integral > 0 ? '+' : '' }}{{ row.integral }}</span>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column slot="options" label="操作" align="center" fixed="right" width="200">
|
||||
<template slot-scope="{ row }">
|
||||
<div class="table-options">
|
||||
<el-button type="text" :disabled="!permissions('app_appvillagerintegralrule_edit')" @click="changeStatus(row.id, 0)" v-if="row.status == 1">
|
||||
停用
|
||||
</el-button>
|
||||
<el-button type="text" :disabled="!permissions('app_appvillagerintegralrule_edit')" @click="changeStatus(row.id, 1)" v-else>启用</el-button>
|
||||
<el-button type="text" :disabled="!permissions('app_appvillagerintegralrule_edit')" @click="toEdit(row)">编辑</el-button>
|
||||
<el-button type="text" :disabled="!permissions('app_appvillagerintegralrule_del')" @click="remove(row.id)">删除</el-button>
|
||||
</div>
|
||||
</template>
|
||||
</el-table-column>
|
||||
</ai-table>
|
||||
</template>
|
||||
</ai-list>
|
||||
<!-- <ai-empty v-else>暂无应用权限</ai-empty> -->
|
||||
<ai-dialog :title="dialogTitle" :visible.sync="dialog" @onConfirm="onConfirm" @closed="form={ladderRule: []}" width="700px">
|
||||
<div class="form_div">
|
||||
<el-form ref="DialogForm" :model="form" :rules="formRules" size="small" label-suffix=":" label-width="100px">
|
||||
<el-form-item label="事件/类型" prop="eventType">
|
||||
<el-cascader v-model="form.eventType" :props="etOps" clearable placeholder="请选择" @change="handleTypeForm"
|
||||
:options="cacheOps"/>
|
||||
</el-form-item>
|
||||
<el-form-item label="规则" prop="ruleType" v-if="form.ruleType>-1" required>
|
||||
<el-row type="flex" justify="space-between">
|
||||
<div v-text="$dict.getLabel('integralRuleRuleType',form.ruleType)"/>
|
||||
<el-button v-if="form.ruleType==1" type="text" icon="iconfont iconAdd"
|
||||
@click="form.ladderRule.push({viewCount:null,integral:null})">添加
|
||||
</el-button>
|
||||
</el-row>
|
||||
<el-table v-if="form.ruleType==1" :data="form.ladderRule" size="mini" border stripe>
|
||||
<el-table-column label="查看人数(人)" align="center">
|
||||
<template slot-scope="{row}">
|
||||
<el-input class="tableInput" v-model.number="row.viewCount" clearable placeholder="请输入"/>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="获得积分(分)" align="center">
|
||||
<template slot-scope="{row}">
|
||||
<el-input class="tableInput" v-model="row.integral" clearable placeholder="请输入" type="number"
|
||||
@keyup.native="row.integral=checkIntegral(row.integral)"/>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="操作" align="center">
|
||||
<template slot-scope="{$index}">
|
||||
<el-button type="text" @click="handleDelete($index)">删除</el-button>
|
||||
</template>
|
||||
</el-table-column>
|
||||
</el-table>
|
||||
</el-form-item>
|
||||
<el-form-item label="周期范围" prop="scoringCycle">
|
||||
<ai-select v-model="form.scoringCycle" :selectList="$dict.getDict('integralRuleScoringCycle')"/>
|
||||
</el-form-item>
|
||||
<template v-if="form.ruleType==0">
|
||||
<el-form-item label="奖励次数" prop="numberLimit">
|
||||
<el-input placeholder="请输入,周期范围内,不填写表示不限制" v-model.number="form.numberLimit" clearable/>
|
||||
</el-form-item>
|
||||
<el-form-item label="积分分值" prop="integral">
|
||||
<el-input placeholder="请输入" v-model="form.integral" clearable/>
|
||||
</el-form-item>
|
||||
</template>
|
||||
</el-form>
|
||||
</div>
|
||||
</ai-dialog>
|
||||
</section>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
export default {
|
||||
name: "gridScoreRules",
|
||||
label: "积分规则",
|
||||
props: {
|
||||
instance: Function,
|
||||
dict: Object,
|
||||
permissions: Function
|
||||
},
|
||||
data() {
|
||||
return {
|
||||
search: {status: "", eventType: null},
|
||||
page: {current: 1, size: 10, total: 0},
|
||||
colConfigs: [
|
||||
{prop: "event", label: "事件", dict: "integralRuleEvent"},
|
||||
{prop: "type", label: "类型", dict: "integralRuleEventType"},
|
||||
{prop: "ruleType", label: "规则", dict: "integralRuleRuleType"},
|
||||
{prop: "scoringCycle", label: "周期范围", dict: "integralRuleScoringCycle"},
|
||||
{prop: "status", label: "状态", align: "center", width: 96, dict: "integralRuleStatus"},
|
||||
{slot: "options", label: "操作", align: "center"},
|
||||
],
|
||||
tableData: [],
|
||||
dialog: false,
|
||||
form: {ladderRule: []},
|
||||
formRules: {
|
||||
eventType: [{required: true, message: "请选择事件/类型", trigger: "change"}],
|
||||
scoringCycle: [{required: true, message: "请选择周期范围", trigger: "change"}],
|
||||
integral: [{required: true, pattern: /^\d*[.\d]\d?$/, message: "请输入积分分值,最多保留一位小数"}],
|
||||
numberLimit: [{pattern: /^\d*$/, message: "请输入正整数"}]
|
||||
},
|
||||
cacheOps: []
|
||||
};
|
||||
},
|
||||
created() {
|
||||
this.$dict.load("integralRuleStatus", "integralRuleRuleType", 'integralRuleScoringCycle', 'integralRuleEvent', 'integralRuleEventType').then(() => {
|
||||
this.getList();
|
||||
});
|
||||
},
|
||||
methods: {
|
||||
getList() {
|
||||
this.instance.post(`/app/appvillagerintegralrule/list`, null, {
|
||||
params: {...this.search, ...this.page},
|
||||
}).then(res => {
|
||||
if (res?.data) {
|
||||
this.tableData = res.data.records;
|
||||
this.page.total = res.data.total;
|
||||
}
|
||||
});
|
||||
},
|
||||
toEdit(row) {
|
||||
this.form = this.$copy(row)
|
||||
let {ladderRule, event, type} = this.form,
|
||||
dict = 'integralRuleEvent' + event
|
||||
this.$dict.load(dict).then(() => {
|
||||
this.form.eventType = [event, type]
|
||||
this.form.ladderRule = JSON.parse(ladderRule || "[]")
|
||||
this.cacheOps = this.$dict.getDict('integralRuleEvent').map(e => {
|
||||
if (e.dictValue == event) {
|
||||
e.children = this.$dict.getDict(dict).map(d => ({...d, leaf: true}))
|
||||
}
|
||||
return e
|
||||
})
|
||||
this.$nextTick(() => {
|
||||
this.dialog = true
|
||||
})
|
||||
})
|
||||
},
|
||||
remove(id) {
|
||||
this.$confirm("删除后不可恢复,是否要删除该事项?", {
|
||||
type: 'error'
|
||||
}).then(() => {
|
||||
this.instance
|
||||
.post(`/app/appvillagerintegralrule/delete?ids=${id}`)
|
||||
.then((res) => {
|
||||
if (res.code == 0) {
|
||||
this.$message.success("删除成功!");
|
||||
this.getList();
|
||||
}
|
||||
});
|
||||
});
|
||||
},
|
||||
changeStatus(id, status) {
|
||||
let text = status == 1 ? '启用' : '停用'
|
||||
this.$confirm(`确定${text}该条规则?`).then(() => {
|
||||
this.instance.post(`/app/appvillagerintegralrule/enableOrDisable?id=${id}`).then((res) => {
|
||||
if (res.code == 0) {
|
||||
this.$message.success(`${text}成功!`)
|
||||
this.getList();
|
||||
}
|
||||
});
|
||||
});
|
||||
},
|
||||
onReset() {
|
||||
this.page.current = 1
|
||||
this.search.classification = ""
|
||||
this.search.integralType = ""
|
||||
this.search.ruleStatus = ""
|
||||
this.getList();
|
||||
},
|
||||
onConfirm() {
|
||||
if(this.form.ruleType==1 && !this.form.ladderRule.length) {
|
||||
return this.$message.error('请添加规则')
|
||||
}
|
||||
this.$refs.DialogForm.validate((valid) => {
|
||||
if (valid) {
|
||||
let formData = this.$copy(this.form)
|
||||
formData.ladderRule = JSON.stringify(formData.ladderRule)
|
||||
formData.integral = formData.integral || 0
|
||||
this.instance.post(`/app/appvillagerintegralrule/addOrUpdate`, formData).then((res) => {
|
||||
if (res.code == 0) {
|
||||
this.$message.success(`${this.isEdit ? '编辑成功' : '添加成功'}`)
|
||||
this.onReset()
|
||||
this.dialog = false;
|
||||
}
|
||||
});
|
||||
} else {
|
||||
return false;
|
||||
}
|
||||
});
|
||||
},
|
||||
handleTypeSearch(v) {
|
||||
this.search.event = v?.[0]
|
||||
this.search.type = v?.[1]
|
||||
this.page.current = 1
|
||||
this.$refs.eventTypeSearch.dropDownVisible = false
|
||||
this.getList()
|
||||
},
|
||||
handleTypeForm(v) {
|
||||
if (this.dialog) {
|
||||
this.form.event = v?.[0]
|
||||
this.form.type = v?.[1]
|
||||
this.form.ruleType = !this.form.event ? null : this.form.event == 3 ? 1 : 0
|
||||
}
|
||||
},
|
||||
handleDelete(i) {
|
||||
this.$confirm("是否要删除该规则?").then(() => {
|
||||
this.form.ladderRule.splice(i, 1)
|
||||
}).catch(() => 0)
|
||||
},
|
||||
checkIntegral(v) {
|
||||
return /\.\d{2,}$/.test(v) ? Math.abs(v).toFixed(1) : Math.abs(v)
|
||||
}
|
||||
},
|
||||
computed: {
|
||||
isEdit() {
|
||||
return !!this.form.id
|
||||
},
|
||||
dialogTitle() {
|
||||
return this.isEdit ? "编辑积分规则" : "添加积分规则"
|
||||
},
|
||||
etOps() {
|
||||
return {
|
||||
lazy: true,
|
||||
value: "dictValue",
|
||||
label: "dictName",
|
||||
lazyLoad: (node, resolve) => {
|
||||
if (node.level == 0) resolve(this.$dict.getDict('integralRuleEvent'))
|
||||
else if (node.level == 1) {
|
||||
let dict = 'integralRuleEvent' + node.value
|
||||
this.$dict.load(dict).then(() => {
|
||||
let nodes = this.$dict.getDict(dict).map(e => ({...e, leaf: true}))
|
||||
resolve(nodes)
|
||||
})
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
},
|
||||
|
||||
}
|
||||
</script>
|
||||
|
||||
<style lang="scss" scoped>
|
||||
.gridScoreRules {
|
||||
height: 100%;
|
||||
background: #f3f6f9;
|
||||
|
||||
::v-deep .ai-list__content--right {
|
||||
width: 100%;
|
||||
}
|
||||
|
||||
// ::v-deep .searchRightZone {
|
||||
// display: flex;
|
||||
// }
|
||||
|
||||
::v-deep .ai-dialog {
|
||||
.el-cascader {
|
||||
width: 100%;
|
||||
}
|
||||
|
||||
.tableInput {
|
||||
& > input {
|
||||
text-align: center;
|
||||
border: none;
|
||||
background: transparent;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
</style>
|
||||
@@ -0,0 +1,127 @@
|
||||
<template>
|
||||
<section class="gridScoreStatistics">
|
||||
<el-row>
|
||||
<div class="card_list">
|
||||
<div class="card">
|
||||
<h2>上报事件</h2>
|
||||
<p class="color1">20</p>
|
||||
</div>
|
||||
<div class="card">
|
||||
<h2>办结事件</h2>
|
||||
<p class="color2">5</p>
|
||||
</div>
|
||||
<div class="card">
|
||||
<h2>待办事件</h2>
|
||||
<p class="color3">0</p>
|
||||
</div>
|
||||
</div>
|
||||
</el-row>
|
||||
<el-row class="echertsBox">
|
||||
<h4>事件汇总</h4>
|
||||
<div class="bar_echerts" id="chartDom"></div>
|
||||
</el-row>
|
||||
</section>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import * as echarts from 'echarts';
|
||||
export default {
|
||||
name: "gridScoreStatistics",
|
||||
label: "积分统计",
|
||||
props: {
|
||||
instance: Function,
|
||||
dict: Object,
|
||||
permissions: Function,
|
||||
},
|
||||
data() {
|
||||
return {
|
||||
name: "积分统计"
|
||||
}
|
||||
},
|
||||
created() {},
|
||||
methods: {
|
||||
getColEcherts() {
|
||||
var chartDom = document.getElementById('chartDom');
|
||||
var myChart = echarts.init(chartDom);
|
||||
myChart.setOption({
|
||||
xAxis: {
|
||||
type: 'category',
|
||||
data: ['Mon', 'Tue', 'Wed', 'Thu', 'Fri', 'Sat', 'Sun']
|
||||
},
|
||||
yAxis: {
|
||||
type: 'value'
|
||||
},
|
||||
series: [
|
||||
{
|
||||
data: [120, 200, 150, 80, 70, 110, 130],
|
||||
type: 'bar',
|
||||
showBackground: true,
|
||||
backgroundStyle: {
|
||||
color: 'rgba(180, 180, 180, 0.2)'
|
||||
}
|
||||
}
|
||||
]
|
||||
});
|
||||
}
|
||||
},
|
||||
mounted() {
|
||||
this.getColEcherts()
|
||||
},
|
||||
}
|
||||
</script>
|
||||
|
||||
<style lang="scss" scoped>
|
||||
.gridScoreStatistics {
|
||||
height: 100%;
|
||||
padding: 0 0 20px 0;
|
||||
box-sizing: border-box;
|
||||
.card_list {
|
||||
display: flex;
|
||||
.card {
|
||||
flex: 1;
|
||||
height: 96px;
|
||||
background: #FFFFFF;
|
||||
box-shadow: 0px 4px 6px -2px rgba(15,15,21,0.1500);
|
||||
border-radius: 4px;
|
||||
margin-right: 20px;
|
||||
padding: 16px 24px;
|
||||
box-sizing: border-box;
|
||||
h2 {
|
||||
color: #888888;
|
||||
font-weight: 600;
|
||||
font-size: 16px;
|
||||
}
|
||||
p {
|
||||
margin-top: 8px;
|
||||
font-size: 24px;
|
||||
font-weight: 600;
|
||||
}
|
||||
.color1 {
|
||||
color: #2891FF;
|
||||
}
|
||||
.color2 {
|
||||
color: #22AA99;
|
||||
}
|
||||
.color3 {
|
||||
color: #F8B425;
|
||||
}
|
||||
}
|
||||
.card:last-child {
|
||||
margin-right: 0;
|
||||
}
|
||||
}
|
||||
.echertsBox {
|
||||
margin-top: 20px;
|
||||
background: #FFFFFF;
|
||||
box-shadow: 0px 4px 6px -2px rgba(15,15,21,0.1500);
|
||||
border-radius: 4px;
|
||||
padding: 16px;
|
||||
box-sizing: border-box;
|
||||
h4 {
|
||||
color: #222222;
|
||||
font-style: 16px;
|
||||
font-weight: 600;
|
||||
}
|
||||
}
|
||||
}
|
||||
</style>
|
||||
@@ -21,9 +21,7 @@
|
||||
</template>
|
||||
|
||||
<script>
|
||||
// import { VueOkrTree } from 'vue-okr-tree'
|
||||
import OkrTree from './vue-okr-tree/OkrTree'
|
||||
// import 'vue-okr-tree/dist/vue-okr-tree.css'
|
||||
|
||||
export default {
|
||||
name: 'AiGrid',
|
||||
@@ -74,9 +72,9 @@
|
||||
if (elClass === 'tree' || elClass === 'middle' || (elClass && (elClass.indexOf('chart') > -1 || elClass.indexOf('user') > -1))) {
|
||||
var dir = event.deltaY > 0 ? 'Up' : 'Down'
|
||||
if (dir === 'Up') {
|
||||
this.scale = this.scale - 0.2 <= 0.1 ? 0.1 : this.scale - 0.2
|
||||
this.scale = this.scale - 0.12 <= 0.1 ? 0.1 : this.scale - 0.12
|
||||
} else {
|
||||
this.scale = this.scale + 0.2
|
||||
this.scale = this.scale + 0.12
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -27,7 +27,7 @@
|
||||
<ai-monitor :src="data.src" v-else-if="data.type === 'monitor'" :type="data.monitorType"/>
|
||||
<video style="width: 100%; height: 100%; object-fit: fill;" loop :src="data.src" autoplay v-else-if="data.type === 'video'"/>
|
||||
<AiDvPartyOrg style="width: 100%; height: 100%;" v-else-if="data.type === 'partyOrg'" :instance="instance"/>
|
||||
<ai-sprite v-else-if="/building/.test(data.type)" v-bind="data" is3D @init="mods[data.type]"/>
|
||||
<!-- <ai-sprite v-else-if="/building/.test(data.type)" v-bind="data" is3D @init="mods[data.type]"/> -->
|
||||
</ai-dv-panel>
|
||||
</div>
|
||||
</template>
|
||||
@@ -47,7 +47,7 @@ export default {
|
||||
name: 'AiDvRender',
|
||||
props: ['data', 'index', 'theme', 'instance'],
|
||||
components: {
|
||||
AiSprite,
|
||||
// AiSprite,
|
||||
AiDvSummary,
|
||||
AiDvDisplay,
|
||||
AiDvPanel,
|
||||
@@ -56,7 +56,7 @@ export default {
|
||||
},
|
||||
data() {
|
||||
return {
|
||||
mods,
|
||||
// mods,
|
||||
chartList,
|
||||
map: null,
|
||||
lib: null
|
||||
|
||||
Reference in New Issue
Block a user