提交 6cb8a0a8 编写于 作者: 刘英杰's avatar 刘英杰

v20250211保存

上级 57612ca8
<template>
<div>
<!-- <Menu @on-select="onSelectMenu" :active-name="schedule.menu">
<MenuItem name="1-1" class="menuFlex">
今日安排
<div class="aaaxx">{{ schedule.formData.plan_list ? schedule.formData.plan_list.length : 0 }}</div>
</MenuItem>
<MenuItem name="1-2" class="menuFlex">
值班安排
<div class="aaaxx">{{ schedule.formData.duty_list ? schedule.formData.duty_list.length : 0 }}</div>
</MenuItem>
<MenuItem name="1-3" class="menuFlex">
会议安排
<div class="aaaxx">{{ schedule.formData.meet_list ? schedule.formData.meet_list.length : 0 }}</div>
</MenuItem>
</Menu>-->
<Row :gutter="24">
<Col :xl="6" :lg="6" :md="0" :sm="0" :xs="0">
<Card shadow title="通用设置" icon="md-options" :padding="0" style="border: 1px solid #ddd;border-radius:8px;">
<CellGroup class="ivu-pt-8 ivu-pb-8">
<Cell
title="1、开关配置"
name="repairs"
label=""
:selected="true"
/>
<!-- <Cell
title="2、其他"
name="other"
label="其他配置"
:selected="currentType === 'other'"
/> -->
</CellGroup>
</Card>
</Col>
<Col :xl="18" :lg="18" :md="24" :sm="24" :xs="24">
<Card :bordered="false" dis-hover>
<!-- <Row>
<Col :xl="0" :lg="0" :md="24" :sm="24" :xs="24">
<Tabs :value="currentType" @on-click="handleChangeCell">
<TabPane label="报修管理" name="repairs" />
<TabPane label="其他" name="other" />
</Tabs>
</Col>
</Row>-->
<Card style="width: 320px; border-radius: 5px; margin: 10px">
<div style="text-align: left">
<Row>
<Col span="18">
<h3>自动推送</h3>
<!-- <h3 v-if="item.id != 'evaluate_mode'">{{ item.name }}</h3>
<h3 v-else>{{ item.name }}: {{EvaluateType}}</h3> -->
</Col>
<Col span="6">
<Switch @on-change="onChangeSwitch" v-model="config.AutomaticallyPushState" trueValue="1" falseValue="0">
</Switch>
</Col>
</Row>
</div>
</Card>
</Card>
</Col>
</Row>
</div>
</template>
<script>
import * as hooks from '@/hook/index'
import * as scheduleApi from '@/api/scheduleApi/controller/index'
//这里可以导入其他文件(比如:组件,工具js,第三方插件js,json文件,图片文件等等)
//例如:import 《组件名称》 from '《组件路径》';
export default {
//import引入的组件需要注入到对象中才能使用",
components: {},
data() {
//这里存放数据",
return {
config:{
AutomaticallyPushState:'0',
},
};
},
//监听属性 类似于data概念",
computed: {},
//监控data中的数据变化",
watch: {},
//方法集合",
methods: {
//变更自动推送状态
onChangeSwitch(e){
hooks.myEncapsulationFunction(()=>{
return scheduleApi.getApiSysConfigTimingSwitchSave({
"timing_switch": e
}).then((res)=>{
this.getAutomaticallyPush()
return res
})
},false,'正在变更中...')
},
//获取自动推送状态
getAutomaticallyPush() {
scheduleApi.getApiSysConfigTimingSwitchInit().then(res=>{
this.config.AutomaticallyPushState = res.response
})
},
},
//生命周期 - 创建之前",数据模型未加载,方法未加载,html模板未加载
beforeCreate() {
},
//生命周期 - 创建完成(可以访问当前this实例)",数据模型已加载,方法已加载,html模板已加载,html模板未渲染
created() {
},
//生命周期 - 挂载之前",html模板未渲染
beforeMount() {
},
//生命周期 - 挂载完成(可以访问DOM元素)",html模板已渲染
mounted() {
this.getAutomaticallyPush()
},
//生命周期 - 更新之前",数据模型已更新,html模板未更新
beforeUpdate() {
},
//生命周期 - 更新之后",数据模型已更新,html模板已更新
updated() {
},
//生命周期 - 销毁之前",
beforeDestroy() {
},
destroyed() {
},
//生命周期 - 销毁完成",
//如果页面有keep-alive缓存功能,这个函数会触发",
activated() {
},
}
</script>
<style scoped>
</style>
Markdown 格式
0% or
您添加了 0 人 到此讨论。请谨慎行事。
先完成此消息的编辑!
想要评论请 注册 或