<template>
  <div>
    <p>创建通告中....</p>
  </div>
</template>

<script>
export default {
  components:{
  },
  data () {
    return {
      defaultData:{},
      folderid:JSON.parse(sessionStorage.getItem('folderid')).appfolderid,
      form:{
        "sat_noticeid":0,
        "sat_notice_classid": 0,
        "title": "",
        "summary": "",
        "content": "",
        "issecret": 1,
        "begdate":(new Date()).toLocaleDateString(),
        "enddate":(new Date()).toLocaleDateString(),
        "isontop":0
      }
    }
  },
  methods:{
    onChecked () {},
    async onSubmit () {
      const res = await this.$api.requested({
        "classname": "webmanage.saletool.notice.notice",
        "method": "insertormodify_notice",
        "content": this.form
      })
      res.code === 1?this.$router.replace({path:'/notice_edit',query:{id:res.data.sat_noticeid}}):''
    },

  },
  mounted () {
    this.onSubmit()
  }
}

</script>
<style>
</style>