From 50c3437ec2e1874df6468bb83a9d5acf40482e6a Mon Sep 17 00:00:00 2001
From: liuxiaolong <liuxiaolong@aiotlink.com>
Date: 星期二, 08 九月 2020 11:08:29 +0800
Subject: [PATCH] rm push msg title and nightMsg for manger

---
 main.go |   12 ++++++++++++
 1 files changed, 12 insertions(+), 0 deletions(-)

diff --git a/main.go b/main.go
index 6bb3d29..1af406e 100644
--- a/main.go
+++ b/main.go
@@ -1,8 +1,12 @@
 package main
 
 import (
+	"car-service/controllers"
+	"car-service/models"
 	_ "car-service/routers"
+	"car-service/service"
 	"github.com/astaxie/beego"
+	"github.com/robfig/cron"
 )
 
 func main() {
@@ -10,5 +14,13 @@
 		beego.BConfig.WebConfig.DirectoryIndex = true
 		beego.BConfig.WebConfig.StaticDir["/swagger"] = "swagger"
 	}
+	models.InitDb()
+	go controllers.ComputeSpaceLeftRealTime()
+	//姣忓ぉ鍚屾娴峰悍鏁版嵁锛岀湅浜哄憳id鏄惁鏈夊彂鐢熷彉鍖�
+	c := cron.New()
+	c.AddFunc("@daily", func() {
+		service.SyncHikPerson()
+	})
+	c.Start()
 	beego.Run()
 }

--
Gitblit v1.8.0