Commit 1ba5e648 by wuyang.zou

<1> 支持 WSG-MOP 美好咖啡; [OK]

<2> 插件支持获取 o2o-fulfillment(EC-MOP)新履约链路的订单(订单列表) [ok];
<3> 兼容上一版本(未测试发版): Aliy CallBackUrl;
parent c0567f97
...@@ -118,6 +118,7 @@ private: ...@@ -118,6 +118,7 @@ private:
int m_modStoreStatus; int m_modStoreStatus;
bool m_bLastHeartIsError; bool m_bLastHeartIsError;
int m_orderCount; int m_orderCount;
int m_o2ofulfillmentOrderCount;
//订单清除定时器 //订单清除定时器
QTimer *m_clearTimer; QTimer *m_clearTimer;
QTimer *m_heartTimer; QTimer *m_heartTimer;
...@@ -335,7 +336,7 @@ public slots: ...@@ -335,7 +336,7 @@ public slots:
* 参数:[1]订单编号 * 参数:[1]订单编号
* 返回:是否成功 * 返回:是否成功
* */ * */
bool _PullOrderDetail(const QString &orderId, const QString& channel, const QString &callBackUrl); bool _PullOrderDetail(const QString &orderId, const QString& channel, const QString &callBackUrl, const bool &skipErrorDisplay = false );
/* 功能:拉取订单 /* 功能:拉取订单
* 参数:NULL * 参数:NULL
* 返回:是否成功 * 返回:是否成功
...@@ -403,7 +404,7 @@ public slots: ...@@ -403,7 +404,7 @@ public slots:
QString _Penny2Dollar(int penny); QString _Penny2Dollar(int penny);
void _GetIpAddress(); void _GetIpAddress();
void _AddOrderPull(const QString& orderId=0,const QString& channel=0,const int& pageNumber=1,const int& pageSize=30); void _AddOrderPull( const QString& orderId=0, const QString& channel=0, const QString& callBackUrl="", const int& pageNumber=1, const int& pageSize=30 );
// 避免获取较多历史订单的同时,OMS又有推单过来,导致死锁; // 避免获取较多历史订单的同时,OMS又有推单过来,导致死锁;
bool _TryAddOrderPull(const QString &orderId=0, const QString &channel=0, const QString &callBackUrl="", const int &pageNumber=1, const int &pageSize=30); bool _TryAddOrderPull(const QString &orderId=0, const QString &channel=0, const QString &callBackUrl="", const int &pageNumber=1, const int &pageSize=30);
...@@ -591,6 +592,12 @@ public slots: ...@@ -591,6 +592,12 @@ public slots:
**/ **/
bool _ResponseOMS12Request(const QJsonObject &content, QJsonObject &data,QString &error); bool _ResponseOMS12Request(const QJsonObject &content, QJsonObject &data,QString &error);
/**
*功能:FM外卖插件为响应OMS推送 宣导提醒消息 请求[action:13 -> OMS->POS 推送宣导提醒消息]准备返回数据
*参数:1、请求json参数;2、准备返回请求数据的Buff;3、返回错误信息;
*返回:是否准备成功;
**/
bool _ResponseOMS13Request(const QJsonObject &content, QJsonObject &data, QString &error);
/** /**
*功能:FM外卖插件为响应盒马生鲜 推订单请求[action:21]准备返回数据 *功能:FM外卖插件为响应盒马生鲜 推订单请求[action:21]准备返回数据
......
...@@ -52,6 +52,7 @@ PmsOrdersData &PmsOrdersData::getInstance() { ...@@ -52,6 +52,7 @@ PmsOrdersData &PmsOrdersData::getInstance() {
//* App-MOP[18-销售,19-退货] KouBei-MOP[29-销售,30-退货] App-MOD[9-销售,17-退货] 客诉单[12 (无退单)] Wechat-MOD[27-销售, 28-退货 ] //* App-MOP[18-销售,19-退货] KouBei-MOP[29-销售,30-退货] App-MOD[9-销售,17-退货] 客诉单[12 (无退单)] Wechat-MOD[27-销售, 28-退货 ]
//* ELEME[11-销售, 16-退货] ORS[21-实物-销售(实物无退货), 23-配送费-销售, 24-配送费-退货] MOP自测[20-销售(无退单) ] STC[25-未使用] HM[14-已停用]】 //* ELEME[11-销售, 16-退货] ORS[21-实物-销售(实物无退货), 23-配送费-销售, 24-配送费-退货] MOP自测[20-销售(无退单) ] STC[25-未使用] HM[14-已停用]】
//* 无需转换 ServiceType , 已经被其他字段替代;
int PmsOrdersData::convertPosServiceTypeId( const OrderObject* orderObj, const int &OrderStatus ) { int PmsOrdersData::convertPosServiceTypeId( const OrderObject* orderObj, const int &OrderStatus ) {
int tempOrderTypeId = 0; int tempOrderTypeId = 0;
...@@ -219,6 +220,7 @@ bool PmsOrdersData::insertOrderData(OrderObject* orderObj,QString& pmsOrderRef) ...@@ -219,6 +220,7 @@ bool PmsOrdersData::insertOrderData(OrderObject* orderObj,QString& pmsOrderRef)
query.addBindValue(updateTimeString); // --订单更新时间 query.addBindValue(updateTimeString); // --订单更新时间
QString tempChannel = ("WSG-MOD"==orderObj->channel) ? "MOD" : orderObj->channel; QString tempChannel = ("WSG-MOD"==orderObj->channel) ? "MOD" : orderObj->channel;
tempChannel = ("WSG-MOP" == tempChannel ) ? "MOP" : tempChannel;
query.addBindValue(tempChannel); // --订单渠道 query.addBindValue(tempChannel); // --订单渠道
query.addBindValue(orderObj->orderType); // --订单类型 query.addBindValue(orderObj->orderType); // --订单类型
...@@ -281,7 +283,7 @@ bool PmsOrdersData::insertOrderData(OrderObject* orderObj,QString& pmsOrderRef) ...@@ -281,7 +283,7 @@ bool PmsOrdersData::insertOrderData(OrderObject* orderObj,QString& pmsOrderRef)
// 与 oms协定此块业务出现 歧异 故在此处转换; 【与PMS协定: businessType -> 10: 预约; 20: WSG-用星说: 21: WSG-美好咖啡; 30: 拼团】 // 与 oms协定此块业务出现 歧异 故在此处转换; 【与PMS协定: businessType -> 10: 预约; 20: WSG-用星说: 21: WSG-美好咖啡; 30: 拼团】
int tempBusinessType = orderObj->businessType.toInt(); int tempBusinessType = orderObj->businessType.toInt();
if ( "WSG-MOD" == orderObj->channel && "4" == orderObj->platformSource) { if ( ( "WSG-MOD" == orderObj->channel || "WSG-MOP" == orderObj->channel ) && "4" == orderObj->platformSource) {
if ( 1 == orderObj->isGiftitForward ) if ( 1 == orderObj->isGiftitForward )
tempBusinessType = 21; tempBusinessType = 21;
else else
...@@ -338,7 +340,7 @@ bool PmsOrdersData::insertOrderData(OrderObject* orderObj,QString& pmsOrderRef) ...@@ -338,7 +340,7 @@ bool PmsOrdersData::insertOrderData(OrderObject* orderObj,QString& pmsOrderRef)
pmsOrderRef = query.lastInsertId().toString(); pmsOrderRef = query.lastInsertId().toString();
QString ProInIdRef; QString ProInIdRef;
if ( "WSG-MOD" == orderObj->channel && "4" == orderObj->platformSource ) { if ( ( "WSG-MOD" == orderObj->channel || "WSG-MOP" == orderObj->channel ) && "4" == orderObj->platformSource ) {
result = insertConponData(orderObj->coupList, orderObj->id, ProInIdRef); result = insertConponData(orderObj->coupList, orderObj->id, ProInIdRef);
}else { }else {
result = insertProductData(orderObj->proList, orderObj->id, ProInIdRef); result = insertProductData(orderObj->proList, orderObj->id, ProInIdRef);
......
...@@ -155,10 +155,21 @@ QString OrderObject::getChannelName() ...@@ -155,10 +155,21 @@ QString OrderObject::getChannelName()
return QString::fromLocal8Bit("美团-MOD"); return QString::fromLocal8Bit("美团-MOD");
} }
} else if("WSG-MOD" == channel ) { // 兼容渠道名称不统一问题 } else if ("WSG-MOD" == channel ) { // 兼容渠道名称不统一问题
return QString::fromLocal8Bit("微信用星说"); if ( 1 == isGiftitForward ) {
return QString::fromLocal8Bit("美好咖啡");
} else {
return QString::fromLocal8Bit("用星说");
}
}else if("ELE" == channel){ } else if ("WSG-MOP" == channel) {
if ( 1 == isGiftitForward ) {
return QString::fromLocal8Bit("美好咖啡");
} else {
return QString::fromLocal8Bit("WSG-MOP");
}
} else if ("ELE" == channel) {
if ( 7 == orderType ) { if ( 7 == orderType ) {
return QString::fromLocal8Bit("预-饿了么-当日"); return QString::fromLocal8Bit("预-饿了么-当日");
} else if ( 11 == orderType ) { } else if ( 11 == orderType ) {
...@@ -167,7 +178,7 @@ QString OrderObject::getChannelName() ...@@ -167,7 +178,7 @@ QString OrderObject::getChannelName()
return QString::fromLocal8Bit("饿了么"); return QString::fromLocal8Bit("饿了么");
} }
}else if( "MOP" == channel ){ } else if( "MOP" == channel ) {
if (4 == orderType ) { if (4 == orderType ) {
return QString::fromLocal8Bit("星-自测"); return QString::fromLocal8Bit("星-自测");
} else if ( 7 == orderType ) { } else if ( 7 == orderType ) {
...@@ -190,6 +201,15 @@ QString OrderObject::getChannelName() ...@@ -190,6 +201,15 @@ QString OrderObject::getChannelName()
} }
} }
} else if ( "MT-MOP" == channel ) {
if ( 7 == orderType ) {
return QString::fromLocal8Bit("预-美团-当日");
} else if ( 11 == orderType ) {
return QString::fromLocal8Bit("预-美团-隔日");
} else {
return QString::fromLocal8Bit("美团-MOP");
}
} else if ( "EC-MOP" == channel ){ } else if ( "EC-MOP" == channel ){
return QString::fromLocal8Bit("电商MOP"); return QString::fromLocal8Bit("电商MOP");
......
...@@ -7,8 +7,8 @@ IDI_ICON ICON DISCARDABLE "logo.ico" ...@@ -7,8 +7,8 @@ IDI_ICON ICON DISCARDABLE "logo.ico"
#endif #endif
VS_VERSION_INFO VERSIONINFO VS_VERSION_INFO VERSIONINFO
//***每次修改后编译发版必须变更版本号(preDefine.h中APP_VERSION 需要一致)***// //***每次修改后编译发版必须变更版本号(preDefine.h中APP_VERSION 需要一致)***//
FILEVERSION 4,2022,1,18 FILEVERSION 4,2022,3,3
PRODUCTVERSION 4,2022,1,18 PRODUCTVERSION 4,2022,3,3
//*************************************************************************// //*************************************************************************//
FILEFLAGSMASK 0x3fL FILEFLAGSMASK 0x3fL
#ifdef _DEBUG #ifdef _DEBUG
...@@ -31,8 +31,8 @@ VS_VERSION_INFO VERSIONINFO ...@@ -31,8 +31,8 @@ VS_VERSION_INFO VERSIONINFO
VALUE "OriginalFilename", "PmsPlugin.exe" VALUE "OriginalFilename", "PmsPlugin.exe"
VALUE "ProductName", "PMS Plugin" VALUE "ProductName", "PMS Plugin"
//***每次修改后编译发版必须变更版本号(preDefine.h中APP_VERSION 需要一致)***// //***每次修改后编译发版必须变更版本号(preDefine.h中APP_VERSION 需要一致)***//
VALUE "ProductVersion", "4.2022.1.18" VALUE "ProductVersion", "4.2022.3.3"
VALUE "FileVersion", "4.2022.1.18" VALUE "FileVersion", "4.2022.3.3"
//*************************************************************************// //*************************************************************************//
END END
END END
......
...@@ -16,7 +16,7 @@ ...@@ -16,7 +16,7 @@
//#define APP_VERSION "4.2021.1.8" //#define APP_VERSION "4.2021.1.8"
//#define APP_VERSION "4.2021.5.10" //#define APP_VERSION "4.2021.5.10"
//#define APP_VERSION "4.2021.12.10" //#define APP_VERSION "4.2021.12.10"
#define APP_VERSION "4.2022.1.18" #define APP_VERSION "4.2022.3.3"
//修正版本号时,切记修正 FmTakeout.rc 中的版本号 //修正版本号时,切记修正 FmTakeout.rc 中的版本号
#define SERVER_PASSWORD "posoperator@freemud.cn" #define SERVER_PASSWORD "posoperator@freemud.cn"
...@@ -70,6 +70,10 @@ ...@@ -70,6 +70,10 @@
#define JSON_ELESTORESTS "eleStoreStatus" #define JSON_ELESTORESTS "eleStoreStatus"
#define JSON_MODSTORESTS "modStoreStatus" #define JSON_MODSTORESTS "modStoreStatus"
#define JSON_MOPSTORESTS "mopStoreStatus" #define JSON_MOPSTORESTS "mopStoreStatus"
#define JSON_MTMODSTORESTS "mtModStoreStatus"
#define JSON_NOTICE_TITLE "noticeTitle"
#define JSON_NOTICE_CONTENT "noticeContent"
#define JSON_SKIPRECORDPOS "skipRecord"
#define JSON_PASSWORD "password" #define JSON_PASSWORD "password"
#define JSON_IPADDRESS "iPAddress" #define JSON_IPADDRESS "iPAddress"
#define JSON_IP_ADDRESS "ipAddress" #define JSON_IP_ADDRESS "ipAddress"
...@@ -287,4 +291,11 @@ ...@@ -287,4 +291,11 @@
#define OPENSTORE 1 #define OPENSTORE 1
#define CLOSESTORE 2 #define CLOSESTORE 2
// o2ofulfillment 履约服务 CallBackUrl 地址;
#define GET_O2OFULFILLMENT_STG_CBL "https://o2ofulfillment.stg.starbucks.net/fulfillment/pos"
#define GET_O2OFULFILLMENT_PRO_CBL "https://o2ofulfillment.starbucks.net/fulfillment/pos"
#define GET_O2OFULFILLMENT_UAT_CBL "https://o2ofulfillment.uat.starbucks.net/fulfillment/pos"
#define GET_O2OFULFILLMENT_DEV_CBL "https://o2ofulfillment.dev.starbucks.net/fulfillment/pos"
#define GET_O2OFULFILLMENT_GRAY_CBL "https://o2ofulfillment.gray.starbucks.net/fulfillment/pos"
#endif // PREDEFINE_H #endif // PREDEFINE_H
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment