Commit f324f0d6 by wuyang.zou

fix bug: 1、外卖插件订单详情商品配料 显示不全;后期优化

         2、饿了么 支持 录入MSR卡号信息
         3、插件被悬浮框的坐标系,需要更加严谨 ;插件重启需要实现 坐标系纠正
         4、外卖订单退货类型细分:由 退货订单13 ->  eleme:16 + App:17
parent 88e95e81
......@@ -2363,7 +2363,13 @@ bool FlowControl::_ResponseSimReqFristOrderData(const QJsonObject &content, QJso
}
// 如果是退单,更新订单的来源类型;
if (orderObject->pushOrderType == 0) {
tempOrderType = 13;
if("ELE" == orderObject->channel) {
tempOrderType = 16;
} else if("MOD" == orderObject->channel) {
tempOrderType = 17;
}else{
tempOrderType = 13; // 退货订单类型:13 已经过期; 后期还需要考虑MOP的正向订单类型/退货订单类型;
}
}
cObj.insert("orderOriginType", tempOrderType);
cObj.insert("orderPayType", tempOrderPayType);
......@@ -2396,14 +2402,11 @@ bool FlowControl::_ResponseSimReqFristOrderData(const QJsonObject &content, QJso
cObj.insert("discount_fee", /*orderObject->disPlateformFee*/0); //平台优惠总额
//只有这个字段(discount_fee)传个Simphony(代表平台优惠给POS系统),对应的字段是dis_shop_fee :平台优惠总额 只能通过 dis_shop_fee 字段传递给 POS;
cObj.insert("dis_shop_fee", abs(orderObject->disPlateformFee)); // 商家承担优惠金额(实际传递的是: 平台优惠金额 orderObject->disPlateformFee);
//只有星巴克App 才挂MSR的虚拟卡号;第三方App MSR_NO='-1';
//只有星巴克App 才挂MSR的虚拟卡号;目前饿了么也要挂MSR的虚拟卡号;卡号是空 则 MSR_NO='-1' 卡号不入机;
QString temp_MSR_NO;
if("MOD"==orderObject->channel){
temp_MSR_NO = (orderObject->msr_no.length()==0)?orderObject->customerId:orderObject->msr_no;
temp_MSR_NO = (temp_MSR_NO.length()==0)?QString::fromLocal8Bit("no_MsrNo_no_CustomerId"):temp_MSR_NO;
}else{
temp_MSR_NO = "-1";
}
temp_MSR_NO = (orderObject->msr_no.length()==0)?orderObject->customerId:orderObject->msr_no;
temp_MSR_NO = (temp_MSR_NO.length()==0)?QString::fromLocal8Bit("-1"):temp_MSR_NO;
cObj.insert("msr_card_no", temp_MSR_NO); // MSR卡号
cObj.insert("dis_platform_fee", /*orderObject->dis_platform_fee*/0); // 平台承担优惠金额
cObj.insert("shop_fee", /*orderObject->total_fee-orderObject->send_fee-orderObject->service_fee-orderObject->dis_shop_fee*/0); // 商户能够拿到的钱(去除平台佣金)
......
......@@ -179,6 +179,9 @@ void DetailForm::InitData(OrderObject *orderObject)
pNum = pNum + 1;
}
//设置行高根据文字进行自适应;用来重复显示主商品的配料信息;
ui->detailTable0->resizeRowsToContents();
//TODO
// QString records;
// foreach(QString record, orderObject->records)
......@@ -228,9 +231,9 @@ void DetailForm::_Init()
setGeometry(((QWidget*)parent())->geometry());
int tableWidth = this->width()/2 - 65;
ui->detailTable0->setColumnWidth(0, tableWidth*5/9);
ui->detailTable0->setColumnWidth(1, tableWidth*2/9);
ui->detailTable0->setColumnWidth(2, tableWidth*2/9);
ui->detailTable0->setColumnWidth(0, tableWidth*12/15);
ui->detailTable0->setColumnWidth(1, tableWidth*2/15);
ui->detailTable0->setColumnWidth(2, tableWidth*1/15);
ui->detailTable0->horizontalHeader()->setFixedHeight(25);
ui->detailTable0->horizontalHeader()->setSectionResizeMode(QHeaderView::Fixed);
}
......@@ -244,13 +247,15 @@ QString DetailForm::GetProductName(dishesObject *dish)
if(!propertyTags.isEmpty())
{
name.append(QString("(%1)").arg(propertyTags));
name.append("\r\n");
}
if(!dish->sub_products.isEmpty())
{
foreach(auto value,dish->sub_products)
{
name.append(value->name).append("|");
name.append("| ");
name.append(value->name).append(" |").append("\r\n");
}
}
name.remove((name.length()-1),1);
......
......@@ -95,7 +95,7 @@ void FloatForm::mouseReleaseEvent(QMouseEvent *event)
int nWidth = GetSystemMetrics(SM_CXSCREEN) - 200;
int nHeight = GetSystemMetrics(SM_CYSCREEN) - 220;
QLOG_INFO()<<QString::fromLocal8Bit("floatForm active_Range(x:%1,y:%2)").arg(nWidth).arg(nHeight);
if( (point.x()<nWidth && -80<=point.x() && -50<=point.y()) || (point.y()<nHeight && -80<=point.x() && -50<=point.y()) ){
if( (point.x()<nWidth && -80<point.x()) && (point.y()<nHeight && -50<point.y()) ){
ConfigManger::GetInstance().setFloatInitPostion(this->pos());
}else{
point.setX(nWidth);
......@@ -123,7 +123,7 @@ void FloatForm::_Init()
QLOG_INFO()<<QString::fromLocal8Bit("Float From Init Postion(x:%1,y:%2)").arg(point.x()).arg(point.y());
int nWidth = GetSystemMetrics(SM_CXSCREEN) - 200;
int nHeight = GetSystemMetrics(SM_CYSCREEN) - 220;
if( (point.x()<nWidth && -80<=point.x() && -50<=point.y()) || (point.y()<nHeight && -80<=point.x() && -50<=point.y()) ){
if( (point.x()<nWidth && -80<point.x()) && (point.y()<nHeight && -50<point.y()) ){
ConfigManger::GetInstance().setFloatInitPostion(point);
this->move(point);
}else{
......
......@@ -7,8 +7,8 @@ IDI_ICON ICON DISCARDABLE "logo.ico"
#endif
VS_VERSION_INFO VERSIONINFO
//***每次修改后编译发版必须变更版本号(preDefine.h中APP_VERSION 需要一致)***//
FILEVERSION 2,2018,1210,1
PRODUCTVERSION 2,2018,1210,1
FILEVERSION 2,2019,110,2
PRODUCTVERSION 2,2019,110,2
//*************************************************************************//
FILEFLAGSMASK 0x3fL
#ifdef _DEBUG
......@@ -31,8 +31,8 @@ VS_VERSION_INFO VERSIONINFO
VALUE "OriginalFilename", "fmTakeout.exe"
VALUE "ProductName", "Delivery Order Plugin"
//***每次修改后编译发版必须变更版本号(preDefine.h中APP_VERSION 需要一致)***//
VALUE "ProductVersion", "2.2018.1210.1"
VALUE "FileVersion", "2.2018.1210.1"
VALUE "ProductVersion", "2.2019.110.2"
VALUE "FileVersion", "2.2019.110.2"
//*************************************************************************//
END
END
......
......@@ -12,7 +12,9 @@
//#define APP_VERSION "2.2018913.1"
//#define APP_VERSION "2.2018919.1"
//#define APP_VERSION "2.20181023.1"
#define APP_VERSION "2.20181210.1"
//#define APP_VERSION "2.20181210.1"
//#define APP_VERSION "2.2019110.1"
#define APP_VERSION "2.2019110.2"
//修正版本号时,切记修正 FmTakeout.rc 中的版本号
......
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