package main

import (
	log "github.com/donnie4w/go-logger/logger"
	qu "qfw/util"
)

func SaveRegionCode() {
	datas, _ := Source_Mgo.Find("zktest_mysql_area", map[string]interface{}{}, map[string]interface{}{
		"_id": 1,
	}, nil)
	for _, v := range datas {
		info := map[string]interface{}{}
		name := qu.ObjToString(v["name"])
		code := qu.ObjToString(v["code"])
		pcode := qu.ObjToString(v["pcode"])
		level := qu.IntAll(v["level"])
		info["name"] = name
		info["code"] = code
		info["pcode"] = pcode
		info["level"] = level
		InsertMysqlDevData("seo_area_copy", info, "")
	}
	log.Debug("is over ~")
}
