1
This commit is contained in:
@@ -30,12 +30,12 @@ const (
|
|||||||
VendorIDDada = 101 // 达达配送
|
VendorIDDada = 101 // 达达配送
|
||||||
VendorIDMTPS = 102 // 美团配送
|
VendorIDMTPS = 102 // 美团配送
|
||||||
VendorIDFengNiao = 103 // 蜂鸟配送
|
VendorIDFengNiao = 103 // 蜂鸟配送
|
||||||
VendorIDDYPS = 104 // 抖音配送
|
//VendorIDDYPS = 104 // 抖音配送
|
||||||
VendorIDUUPT = 105 //uu跑腿
|
VendorIDUUPT = 105 //uu跑腿
|
||||||
VendorJXFakeWL = 300 // 京西假物流
|
VendorJXFakeWL = 300 // 京西假物流
|
||||||
VendorIDJDWL = 401 // 京东物流
|
VendorIDJDWL = 401 // 京东物流
|
||||||
VendorIDTotalWl = 402 // (综合物流[京东,圆通,申通....])
|
VendorIDTotalWl = 402 // (综合物流[京东,圆通,申通....])
|
||||||
VendorIDDeliveryEnd = 500
|
VendorIDDeliveryEnd = 500
|
||||||
|
|
||||||
VendorIDPrinterBegin = 201
|
VendorIDPrinterBegin = 201
|
||||||
VendorIDFeiE = 201 // 飞鹅打印机
|
VendorIDFeiE = 201 // 飞鹅打印机
|
||||||
@@ -102,8 +102,8 @@ var (
|
|||||||
VendorIDDada: "Dada",
|
VendorIDDada: "Dada",
|
||||||
VendorIDMTPS: "Mtps",
|
VendorIDMTPS: "Mtps",
|
||||||
VendorIDFengNiao: "Fn",
|
VendorIDFengNiao: "Fn",
|
||||||
VendorIDDYPS: "DYPS",
|
//VendorIDDYPS: "DYPS",
|
||||||
VendorIDUUPT: "UUPT",
|
VendorIDUUPT: "UUPT",
|
||||||
|
|
||||||
VendorIDFeiE: "Feie",
|
VendorIDFeiE: "Feie",
|
||||||
VendorIDXiaoWM: "XiaoWM",
|
VendorIDXiaoWM: "XiaoWM",
|
||||||
@@ -136,8 +136,8 @@ var (
|
|||||||
VendorIDMTPS: "美团配送",
|
VendorIDMTPS: "美团配送",
|
||||||
VendorIDJDWL: "京东物流",
|
VendorIDJDWL: "京东物流",
|
||||||
VendorIDFengNiao: "蜂鸟配送",
|
VendorIDFengNiao: "蜂鸟配送",
|
||||||
VendorIDDYPS: "抖音配送",
|
//VendorIDDYPS: "抖音配送",
|
||||||
VendorIDUUPT: "UU跑腿",
|
VendorIDUUPT: "UU跑腿",
|
||||||
|
|
||||||
VendorIDFeiE: "飞鹅",
|
VendorIDFeiE: "飞鹅",
|
||||||
VendorIDXiaoWM: "外卖管家",
|
VendorIDXiaoWM: "外卖管家",
|
||||||
|
|||||||
@@ -525,9 +525,10 @@ func WaybillVendorID2Mask(vendorID int) (mask int8) {
|
|||||||
mask = OrderDeliveryFlagMaskDada
|
mask = OrderDeliveryFlagMaskDada
|
||||||
} else if vendorID == VendorIDMTPS {
|
} else if vendorID == VendorIDMTPS {
|
||||||
mask = OrderDeliveryFlagMaskMtps
|
mask = OrderDeliveryFlagMaskMtps
|
||||||
} else if vendorID == VendorIDDYPS {
|
|
||||||
mask = OrderDeliveryFlagMaskDYPS
|
|
||||||
}
|
}
|
||||||
|
//else if vendorID == VendorIDDYPS {
|
||||||
|
// mask = OrderDeliveryFlagMaskDYPS
|
||||||
|
//}
|
||||||
return mask
|
return mask
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -299,8 +299,8 @@ var (
|
|||||||
VendorIDMTPS: BrandOpenMTPS,
|
VendorIDMTPS: BrandOpenMTPS,
|
||||||
VendorIDDada: BrandOpenDaDa,
|
VendorIDDada: BrandOpenDaDa,
|
||||||
VendorIDFengNiao: BrandOpenFN,
|
VendorIDFengNiao: BrandOpenFN,
|
||||||
VendorIDDYPS: BrandOpenDYPS,
|
//VendorIDDYPS: BrandOpenDYPS,
|
||||||
VendorIDUUPT: BrandOpenUUPT,
|
VendorIDUUPT: BrandOpenUUPT,
|
||||||
}
|
}
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|||||||
@@ -57,7 +57,7 @@ func (c *PurchaseHandler) callbackMsg2Waybill(tag, orderId string, data interfac
|
|||||||
VendorOrderID: utils.Int64ToStr(req.ShopOrderID),
|
VendorOrderID: utils.Int64ToStr(req.ShopOrderID),
|
||||||
OrderVendorID: model.VendorIDDD,
|
OrderVendorID: model.VendorIDDD,
|
||||||
VendorWaybillID: req.TrackNo,
|
VendorWaybillID: req.TrackNo,
|
||||||
WaybillVendorID: model.VendorIDDYPS,
|
WaybillVendorID: model.VendorIDDD,
|
||||||
CourierName: req.RiderName,
|
CourierName: req.RiderName,
|
||||||
CourierMobile: req.RiderPhone,
|
CourierMobile: req.RiderPhone,
|
||||||
VendorStatus: utils.Int64ToStr(req.ShipmentStatus),
|
VendorStatus: utils.Int64ToStr(req.ShipmentStatus),
|
||||||
|
|||||||
@@ -6,24 +6,25 @@ import (
|
|||||||
"git.rosy.net.cn/jx-callback/business/model/legacymodel"
|
"git.rosy.net.cn/jx-callback/business/model/legacymodel"
|
||||||
"git.rosy.net.cn/jx-callback/globals"
|
"git.rosy.net.cn/jx-callback/globals"
|
||||||
"github.com/astaxie/beego/client/orm"
|
"github.com/astaxie/beego/client/orm"
|
||||||
|
"github.com/astaxie/beego/server/web"
|
||||||
)
|
)
|
||||||
|
|
||||||
func Init() {
|
func Init() {
|
||||||
// set default database
|
// set default database
|
||||||
// orm.RegisterDataBase(aliasName, driverName, dataSource, params)
|
// orm.RegisterDataBase(aliasName, driverName, dataSource, params)
|
||||||
//正式服务器
|
//正式服务器
|
||||||
//orm.RegisterDataBase("default", "mysql", web.AppConfig.DefaultString("dbConnectStr", ""))
|
orm.RegisterDataBase("default", "mysql", web.AppConfig.DefaultString("dbConnectStr", ""))
|
||||||
//orm.RegisterDataBase("c4beta", "mysql", "ubuntu:WebServer@1@tcp(111.231.218.230:3306)/jxd_dev_0?charset=utf8mb4&loc=Local&parseTime=true")
|
orm.RegisterDataBase("c4beta", "mysql", "ubuntu:WebServer@1@tcp(111.231.218.230:3306)/jxd_dev_0?charset=utf8mb4&loc=Local&parseTime=true")
|
||||||
//orm.RegisterDataBase("api", "mysql", "root:WebServer@1@tcp(127.0.0.1:3306)/api?charset=utf8mb4&loc=Local&parseTime=true")
|
orm.RegisterDataBase("api", "mysql", "root:WebServer@1@tcp(127.0.0.1:3306)/api?charset=utf8mb4&loc=Local&parseTime=true")
|
||||||
// 本地测试服调试
|
// 本地测试服调试
|
||||||
// orm.RegisterDataBase("default", "mysql", web.AppConfig.DefaultString("dbConnectStr", ""))
|
// orm.RegisterDataBase("default", "mysql", web.AppConfig.DefaultString("dbConnectStr", ""))
|
||||||
//orm.RegisterDataBase("api", "mysql", "root:WebServer@1@tcp(127.0.0.1:3306)/api?charset=utf8mb4&loc=Local&parseTime=true")
|
//orm.RegisterDataBase("api", "mysql", "root:WebServer@1@tcp(127.0.0.1:3306)/api?charset=utf8mb4&loc=Local&parseTime=true")
|
||||||
//orm.RegisterDataBase("c4beta", "mysql", "ubuntu:WebServer@1@tcp(127.0.0.1:3306)/jxd_dev_0?charset=utf8mb4&loc=Local&parseTime=true")
|
//orm.RegisterDataBase("c4beta", "mysql", "ubuntu:WebServer@1@tcp(127.0.0.1:3306)/jxd_dev_0?charset=utf8mb4&loc=Local&parseTime=true")
|
||||||
|
|
||||||
//本地服务器测试用 -ysq
|
//本地服务器测试用 -ysq
|
||||||
orm.RegisterDataBase("default", "mysql", "root:123456@tcp(127.0.0.1:3306)/jxd_dev_0?charset=utf8mb4&loc=Local&parseTime=true")
|
//orm.RegisterDataBase("default", "mysql", "root:123456@tcp(127.0.0.1:3306)/jxd_dev_0?charset=utf8mb4&loc=Local&parseTime=true")
|
||||||
orm.RegisterDataBase("c4beta", "mysql", "root:123456@tcp(127.0.0.1:3306)/jxd_dev_0?charset=utf8mb4&loc=Local&parseTime=true")
|
//orm.RegisterDataBase("c4beta", "mysql", "root:123456@tcp(127.0.0.1:3306)/jxd_dev_0?charset=utf8mb4&loc=Local&parseTime=true")
|
||||||
orm.RegisterDataBase("api", "mysql", "root:123456@tcp(127.0.0.1:3306)/api?charset=utf8mb4&loc=Local&parseTime=true")
|
//orm.RegisterDataBase("api", "mysql", "root:123456@tcp(127.0.0.1:3306)/api?charset=utf8mb4&loc=Local&parseTime=true")
|
||||||
|
|
||||||
// 开启sql打印
|
// 开启sql打印
|
||||||
//orm.Debug = true
|
//orm.Debug = true
|
||||||
|
|||||||
@@ -101,8 +101,8 @@ func Init() {
|
|||||||
}
|
}
|
||||||
|
|
||||||
SugarLogger.Infof("globals RunMode=%s", web.BConfig.RunMode)
|
SugarLogger.Infof("globals RunMode=%s", web.BConfig.RunMode)
|
||||||
//ReallyCallPlatformAPI = (web.BConfig.RunMode != "dev" && web.BConfig.RunMode != "test")
|
ReallyCallPlatformAPI = (web.BConfig.RunMode != "dev" && web.BConfig.RunMode != "test")
|
||||||
ReallyCallPlatformAPI = true //本地测试用-ysq
|
//ReallyCallPlatformAPI = true //本地测试用-ysq
|
||||||
ReallySendWeixinMsg = ReallyCallPlatformAPI && IsProductEnv()
|
ReallySendWeixinMsg = ReallyCallPlatformAPI && IsProductEnv()
|
||||||
|
|
||||||
AliKey = web.AppConfig.DefaultString("aliKey", "")
|
AliKey = web.AppConfig.DefaultString("aliKey", "")
|
||||||
|
|||||||
Reference in New Issue
Block a user