<template>
	<div>
		<div class="content">
			<div @click="up">上传</div>
			
		</div>

	</div>
</template>

<script>
	import {
		autodeploy
	} from '@api/common/list'
	export default {
		data() {
			return {
				inputMsg: '',
				config: {
					historyConfig: {
						tip: '查看更多'
					}
				},
				list: [{
						"date": "2020/04/25 21:19:07",
						"text": {
							"text": "起床不"
						},
						"mine": false,
						"name": "留恋人间不羡仙",
						"img": ""
					},
					{
						"date": "2020/04/25 21:19:07",
						"text": {
							"text": "11"
						},
						"mine": false,
						"name": "只盼流星不盼雨",
						"img": ""
					},
					{
						"date": "2020/04/25 21:19:07",
						"text": {
							"text": "111"
						},
						"mine": false,
						"name": "只盼流星不盼雨",
						"img": ""
					},
					{
						"date": "2020/04/16 21:19:07",
						"text": {
							"text": "222"
						},
						"mine": true,
						"name": "JwChat",
						"img": ""
					},
				],
				tool: {
					show: [''],
					callback: this.toolEvent,
					showEmoji: true,
				},
			}
		},
		methods: {
			bindEnter() {
				const msg = this.inputMsg
				if (!msg) return;
				const msgObj = {
					"date": "2020/05/20 23:19:07",
					"text": {
						"text": msg
					},
					"mine": true,
					"name": "JwChat",
					"img": ""
				}
				this.list.push(msgObj)
			},
			toolEvent(type) {
				console.log('tools', type)
			},
			getfile(val) {
				console.log(val)
			},

			async up() {
				try {
					const {
						data,
						code
					} = await autodeploy()
				} catch (e) {
					console.log(e)
				}
			}
		}

	}
</script>

<style scoped>
