Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
S
supplier
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
王宇航
supplier
Commits
f142c320
Commit
f142c320
authored
Oct 13, 2020
by
宁斌
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
1、修改餐廳擴展類
parent
a5b63f95
Hide whitespace changes
Inline
Side-by-side
Showing
14 changed files
with
251 additions
and
304 deletions
+251
-304
base-module/src/main/java/com/gingersoft/gsa/cloud/base/application/GsaCloudApplication.java
+3
-3
base-module/src/main/java/com/gingersoft/gsa/cloud/base/common/bean/expand/UIStyleConfiguration.java
+7
-0
base-module/src/main/java/com/gingersoft/gsa/cloud/base/utils/CommonConfiguration.java
+1
-2
base-module/src/main/java/com/gingersoft/gsa/cloud/base/utils/ReflectionUtils.java
+83
-0
base-module/src/main/java/com/gingersoft/gsa/cloud/base/utils/RestaurantExpandInfoUtils.java
+40
-0
base-module/src/main/java/com/gingersoft/gsa/cloud/bean/RestaurantExpandInfo.java
+109
-0
base-module/src/main/java/com/gingersoft/gsa/cloud/constans/ExpandConstant.java
+4
-1
base-module/src/main/java/com/gingersoft/gsa/cloud/database/bean/ExpandInfo.java
+1
-1
base-module/src/main/java/com/gingersoft/gsa/cloud/function/FunctionStyleUtils.java
+0
-242
login-module/src/main/java/com/gingersoft/gsa/cloud/login/mvp/contract/LoginInterfaceImpl.java
+2
-1
login-module/src/main/java/com/gingersoft/gsa/cloud/login/mvp/ui/activity/mvp/ui/activity/LoginActivity.java
+0
-20
table-module/src/main/java/com/gingersoft/gsa/cloud/bean/mvp/presenter/TablePresenter.java
+0
-5
table-module/src/main/java/com/gingersoft/gsa/cloud/bean/mvp/ui/activity/TableActivity.java
+1
-0
table-module/src/main/java/com/gingersoft/gsa/cloud/bean/mvp/ui/adapter/CurrentSlodoutFoodAdapter.java
+0
-29
No files found.
base-module/src/main/java/com/gingersoft/gsa/cloud/base/application/GsaCloudApplication.java
View file @
f142c320
...
...
@@ -36,7 +36,7 @@ import com.gingersoft.gsa.cloud.constans.UserConstans;
import
com.gingersoft.gsa.cloud.database.DaoManager
;
import
com.gingersoft.gsa.cloud.database.bean.ExpandInfo
;
import
com.gingersoft.gsa.cloud.database.utils.ExpandInfoDaoUtils
;
import
com.gingersoft.gsa.cloud.bean.
StyleSettingUtils
;
import
com.gingersoft.gsa.cloud.bean.
RestaurantExpandInfo
;
import
com.hyweb.n5.lib.exception.NoInitPrinterException
;
import
com.hyweb.n5.lib.util.PrinterUtil
;
import
com.jess.arms.base.BaseApplication
;
...
...
@@ -67,7 +67,7 @@ public class GsaCloudApplication extends BaseApplication {
private
static
GsaCloudApplication
mAppContext
;
private
Activity
mCurrentActivity
;
public
static
StyleSettingUtils
androidSetting
;
public
static
RestaurantExpandInfo
androidSetting
;
/**
* 是否開啟皮膚切換
*/
...
...
@@ -127,7 +127,7 @@ public class GsaCloudApplication extends BaseApplication {
//初始化crash記錄
AppCrashHandler
.
getInstance
().
init
(
this
);
androidSetting
=
new
StyleSettingUtils
();
androidSetting
=
new
RestaurantExpandInfo
();
isLogin
=
(
boolean
)
SPUtils
.
get
(
this
,
PrintConstans
.
IS_LOGIN
,
false
);
initExpandInfo
();
...
...
base-module/src/main/java/com/gingersoft/gsa/cloud/base/common/bean/expand/UIStyleConfiguration.java
0 → 100644
View file @
f142c320
package
com
.
gingersoft
.
gsa
.
cloud
.
base
.
common
.
bean
.
expand
;
public
class
UIStyleConfiguration
{
}
base-module/src/main/java/com/gingersoft/gsa/cloud/base/utils/CommonConfiguration.java
View file @
f142c320
...
...
@@ -25,8 +25,7 @@ public class CommonConfiguration {
public
static
CommonConfiguration
getInstance
()
{
if
(
commonConfiguration
==
null
)
{
commonConfiguration
=
new
CommonConfiguration
();
}
commonConfiguration
=
new
CommonConfiguration
();
}
return
commonConfiguration
;
}
...
...
base-module/src/main/java/com/gingersoft/gsa/cloud/base/utils/ReflectionUtils.java
0 → 100644
View file @
f142c320
package
com
.
gingersoft
.
gsa
.
cloud
.
base
.
utils
;
import
android.util.Log
;
import
java.lang.reflect.Field
;
import
java.lang.reflect.Method
;
import
java.util.ArrayList
;
import
java.util.HashMap
;
import
java.util.List
;
import
java.util.Map
;
/**
* 反射工具类
*/
public
class
ReflectionUtils
{
private
static
final
String
TAG
=
"ReflectionUtils"
;
/**
* 根据属性名获取属性值
*/
public
static
Object
getFieldValueByName
(
String
fieldName
,
Object
o
)
{
try
{
String
firstLetter
=
fieldName
.
substring
(
0
,
1
).
toUpperCase
();
String
getter
=
"get"
+
firstLetter
+
fieldName
.
substring
(
1
);
Method
method
=
o
.
getClass
().
getMethod
(
getter
,
new
Class
[]{});
Object
value
=
method
.
invoke
(
o
,
new
Object
[]{});
return
value
;
}
catch
(
Exception
e
)
{
Log
.
d
(
TAG
,
"getFieldValueByName: "
+
e
.
getMessage
());
return
null
;
}
}
/**
* 获取属性名数组
*/
public
static
String
[]
getFiledName
(
Object
o
)
{
Field
[]
fields
=
o
.
getClass
().
getDeclaredFields
();
String
[]
fieldNames
=
new
String
[
fields
.
length
];
for
(
int
i
=
0
;
i
<
fields
.
length
;
i
++)
{
System
.
out
.
println
(
"类型"
+
fields
[
i
].
getType
());
System
.
out
.
println
(
"名称="
+
fields
[
i
].
getName
());
fieldNames
[
i
]
=
fields
[
i
].
getName
();
}
return
fieldNames
;
}
/**
* 获取属性类型(type),属性名(name),属性值(value)的map组成的list
*/
public
static
List
getFiledsInfo
(
Object
o
)
{
Field
[]
fields
=
o
.
getClass
().
getDeclaredFields
();
String
[]
fieldNames
=
new
String
[
fields
.
length
];
List
list
=
new
ArrayList
();
Map
infoMap
=
null
;
for
(
int
i
=
0
;
i
<
fields
.
length
;
i
++)
{
infoMap
=
new
HashMap
();
infoMap
.
put
(
"field"
,
fields
[
i
]);
infoMap
.
put
(
"type"
,
fields
[
i
].
getType
().
toString
());
infoMap
.
put
(
"name"
,
fields
[
i
].
getName
());
infoMap
.
put
(
"value"
,
getFieldValueByName
(
fields
[
i
].
getName
(),
o
));
list
.
add
(
infoMap
);
}
return
list
;
}
/**
* 获取对象的所有属性值,返回一个对象数组
*/
public
static
Object
[]
getFiledValues
(
Object
o
)
{
String
[]
fieldNames
=
getFiledName
(
o
);
Object
[]
value
=
new
Object
[
fieldNames
.
length
];
for
(
int
i
=
0
;
i
<
fieldNames
.
length
;
i
++)
{
value
[
i
]
=
getFieldValueByName
(
fieldNames
[
i
],
o
);
}
return
value
;
}
}
base-module/src/main/java/com/gingersoft/gsa/cloud/base/utils/RestaurantExpandInfoUtils.java
View file @
f142c320
package
com
.
gingersoft
.
gsa
.
cloud
.
base
.
utils
;
import
com.gingersoft.gsa.cloud.base.application.GsaCloudApplication
;
import
com.gingersoft.gsa.cloud.bean.RestaurantExpandInfo
;
import
com.gingersoft.gsa.cloud.constans.ExpandConstant
;
import
com.gingersoft.gsa.cloud.database.bean.ExpandInfo
;
import
java.lang.reflect.Field
;
import
java.util.HashMap
;
import
java.util.List
;
import
java.util.Map
;
...
...
@@ -64,6 +67,43 @@ public class RestaurantExpandInfoUtils {
break
;
}
}
// for (ExpandInfo expandInfo : expandInfoList) {
// if (expandInfo.getValueInt() != null) {
// map.put(expandInfo.getSettingName(), expandInfo.getValueInt());
// } else {
// map.put(expandInfo.getSettingName(), expandInfo.getValueChar());
// }
// }
//
// List<Map> uiFields = ReflectionUtils.getFiledsInfo(RestaurantExpandInfo.UIStyleConfiguration.class);
// List<Map> functionFields = ReflectionUtils.getFiledsInfo(RestaurantExpandInfo.FunctionConfiguration.class);
// for (Map fields : uiFields) {
// String expandinfoName = (String) fields.get("name");
// if (map.containsKey(expandinfoName)) {
// Field field = (Field) fields.get("field");
// Object value = map.get(expandinfoName);
// try {
// field.set(expandinfoName,value);
// } catch (IllegalAccessException e) {
// e.printStackTrace();
// }
// }
// }
// for (Map field : functionFields) {
// if (map.containsKey(field)) {
// String expandinfoName = (String) field.get("name");
// if (map.containsKey(expandinfoName)) {
// Field curField = (Field) field.get("field");
// Object value = map.get(expandinfoName);
// try {
// curField.set(expandinfoName,value);
// } catch (IllegalAccessException e) {
// e.printStackTrace();
// }
// }
// }
// }
}
public
static
<
T
>
T
getValue
(
String
name
,
Object
defaultValue
)
{
...
...
base-module/src/main/java/com/gingersoft/gsa/cloud/bean/RestaurantExpandInfo.java
0 → 100644
View file @
f142c320
package
com
.
gingersoft
.
gsa
.
cloud
.
bean
;
import
lombok.Data
;
/**
* 作者:ELEGANT_BIN
* 版本:1.6.0
* 创建日期:2018/8/11
* 修订历史:2018/8/11
* 描述:保存餐廳UI配置信息
*/
@Data
public
class
RestaurantExpandInfo
{
private
int
TableDirection
;
private
int
RefreshTime
=
1
;
private
int
ItemDecimals
;
private
int
RoundingDecimal
=
1
;
private
int
Rounding
;
private
int
SystemLanguage
=
2
;
private
int
nowLanguageIndex
=
1
;
private
String
orderlanguage
=
"1,2,3"
;
private
String
LanageName
=
"中文,粵語,英文"
;
private
int
DataLanguage
=
2
;
private
boolean
MemberLoginCover
=
true
;
private
boolean
BillTextScroll
=
true
;
private
boolean
EnableErrorLog
=
true
;
private
int
AutoQuitTime
=
600
;
/**
* UI配置相關
*/
private
int
FoodTypeCol
=
4
;
private
int
FoodTypeRow
=
1
;
private
int
FoodCol
=
4
;
private
int
ModCol
=
5
;
private
int
DiscountCol
=
5
;
private
int
LayoutFoodTypeHeight
=
100
;
private
int
FoodBtnHeight
=
120
;
private
int
LayoutQtyHeight
=
40
;
private
int
LayoutQuitHeight
=
40
;
private
int
ModBtnHeight
=
75
;
private
int
FoodTypeFontSize
=
12
;
private
int
FoodFontSize
=
12
;
private
int
ModFontSize
=
14
;
private
int
BillListFontSize
=
12
;
private
int
BillTotalFontSize
=
12
;
private
int
FoodlListFontSize
=
18
;
private
int
ReportFontSize
=
15
;
private
int
orderInfoFontSize
=
16
;
private
int
OrderNumberShowSize
=
20
;
private
int
OrderNumberFontSize
=
7
;
private
int
OrderNumberChildShowSize
=
20
;
private
int
OrderNumberChildFontSize
=
10
;
public
static
final
class
UIStyleConfiguration
{
private
int
foodGroupRow
=
5
;
private
int
foodGroupColumn
=
2
;
private
int
foodRow
=
4
;
private
int
comboRow
=
4
;
private
int
modRow
=
4
;
private
int
discountRow
=
4
;
private
int
foodGroupBtnHeight
=
100
;
private
int
foodBtnHeight
=
120
;
private
int
modBtnHeight
=
80
;
private
int
comboHeight
=
90
;
private
int
foodGroupFontSize
=
12
;
private
int
foodFontSize
=
12
;
private
int
comboFontSize
=
12
;
private
int
modFontSize
=
14
;
private
int
discountFontSize
=
14
;
}
public
static
final
class
FunctionConfiguration
{
private
int
Rounding
;
private
int
RoundingDecimal
;
private
int
ItemDecimals
;
private
String
DeliveryPrintCount
;
//外送印單打印次數
private
String
DeliveryClosingPC
;
//外送結賬打印次數
private
String
TableModePrintCount
;
//餐檯印單打印次數
private
String
TableModeClosingPC
;
//餐檯模式結賬單打印次數
private
String
OrderReceivingTimeout
;
//外送接單超時時間
private
String
PrintMemberInfo
;
//是否打印會員信息
private
String
PrintPage
;
//是否打印頁數
private
String
PrintMergerFood
;
//是否合併食品
private
String
PrintStatisticsAmount
;
//是否顯示統計打印數
private
String
PrintFirstOrder
;
//是否打印"頭單"文字
private
String
FrozenChainAutoOrder
;
//是否自動接單 為0true
private
String
MergeSendFood
;
/**
* 送單自動打印上菜紙
*/
private
String
AutoPrinterPaper
;
/**
* 結賬是否打印積分二維碼
*/
private
String
ToPrintQRCode
;
}
}
base-module/src/main/java/com/gingersoft/gsa/cloud/constans/ExpandConstant.java
View file @
f142c320
...
...
@@ -23,7 +23,10 @@ public class ExpandConstant {
public
final
static
String
MergeSendFood
=
"MergeSendFood"
;
/**送單自動打印上菜紙*/
public
final
static
String
AutoPrinterPaper
=
"AutoPrinterParper"
;
/**結賬是否打印積分二維碼*/
public
final
static
String
ToPrintQRCode
=
"ToPrintQRCode"
;
}
base-module/src/main/java/com/gingersoft/gsa/cloud/database/bean/ExpandInfo.java
View file @
f142c320
...
...
@@ -30,6 +30,7 @@ public class ExpandInfo {
*/
private
Integer
valueInt
;
private
String
valueChar
;
private
int
valueBoolean
;
private
String
valueDatetime
;
/**
* 功能说明
...
...
@@ -38,7 +39,6 @@ public class ExpandInfo {
private
int
dataType
;
//配置的數據類型 1:整形,2:字符型,3:布爾型,4:日期類型
private
String
sort
;
//排序
private
int
valueBoolean
;
//是否在雲端GSA上配置:0 否,1 是
@Transient
private
boolean
isUpdate
=
false
;
//是否被編輯了
...
...
base-module/src/main/java/com/gingersoft/gsa/cloud/function/FunctionStyleUtils.java
deleted
100644 → 0
View file @
a5b63f95
package
com
.
gingersoft
.
gsa
.
cloud
.
function
;
import
android.content.Context
;
import
android.util.DisplayMetrics
;
import
android.util.Log
;
import
com.jess.arms.utils.DeviceUtils
;
import
java.util.HashSet
;
import
java.util.Set
;
import
lombok.Data
;
/**
* 作者:ELEGANT_BIN
* 版本:1.6.0
* 创建日期:2018/8/11
* 修订历史:2018/8/11
* 描述:
*/
@Data
public
class
FunctionStyleUtils
{
private
int
ID
;
private
String
TableNumPadChar
;
private
String
PLUNumPadChar
;
private
int
FoodTypeFontSize
=
12
;
private
int
FoodFontSize
=
12
;
private
String
TableExt
=
""
;
private
int
BaseDpi
=
480
;
private
int
BaseHeight
=
1920
;
private
int
BaseWidth
=
1080
;
private
int
ModFontSize
=
14
;
private
int
BillListFontSize
=
12
;
private
int
BillTotalFontSize
=
12
;
private
int
FoodlListFontSize
=
18
;
private
int
LayoutBillListHeight
=
40
;
private
int
LayoutQtyHeight
=
40
;
private
int
LayoutQuitHeight
=
40
;
private
int
LayoutFoodTypeHeight
=
100
;
private
int
FoodBtnHeight
=
120
;
private
int
ModBtnHeight
=
75
;
private
int
FoodTypeCol
=
4
;
private
int
FoodTypeRow
=
1
;
private
int
FoodCol
=
4
;
private
int
ModCol
=
5
;
private
int
DiscountCol
=
5
;
private
int
TableDirection
;
private
int
RefreshTime
=
1
;
private
String
ShowTableType
=
"1,2,3,5"
;
private
int
servicecharge_tablemode
;
private
int
servicecharge_tablemode_setting
;
private
int
servicecharge_takeoutmode
;
private
int
servicecharge_deliverymode
;
private
int
servicecharge_pickupmode
;
private
int
tableType
=
1
;
private
boolean
ServiceChargeIncludeItemDiscount
;
private
boolean
BillDiscountIncludeServiceCharge
;
private
boolean
Edit_Send
;
private
int
ItemDecimals
;
private
int
RoundingDecimal
=
1
;
private
int
Rounding
;
private
int
SystemLanguage
=
2
;
private
int
OpenTableVipFrontColor
=
1
;
private
int
OpenTableVipBackColor
=
2
;
private
int
nowLanguageIndex
=
1
;
private
String
orderlanguage
=
"1,2,3"
;
private
boolean
MemberLoginCover
=
true
;
private
String
LanageName
=
"中文,粵語,英文"
;
private
int
DataLanguage
=
2
;
private
int
AutoQuitTime
=
600
;
private
int
ModFunctionBarHeight
=
60
;
private
int
BottomBarHeight
=
160
;
private
int
ReportFontSize
=
15
;
private
String
ShopId
=
""
;
private
boolean
OrderFunction_Discount
;
private
boolean
OrderFunction_Transfer
;
private
boolean
OrderFunction_Print
;
private
boolean
MainFunction_Report
;
private
int
printerServerReadTime
=
10
;
private
boolean
OrderFunction_VoidSentItem
=
false
;
private
boolean
OrderFunction_ItemDiscount
=
false
;
private
boolean
OrderFunction_ItemFoodMerge
=
false
;
private
boolean
OrderFunction_FoodTableMode
=
true
;
private
boolean
OrderFunction_FoodTemporay
=
true
;
private
boolean
Order_InputPax
=
true
;
private
boolean
Order_GetTables
=
true
;
private
int
OrderOperButtonHeight
=
40
;
private
int
orderInfoHeight
=
40
;
private
int
orderInfoFontSize
=
16
;
private
int
OrderDataOperBtnWidth
=
50
;
private
int
OrderDataOperBtnHeight
=
50
;
private
boolean
BillTextScroll
=
true
;
private
int
TableFunctionTopHeight
=
100
;
private
int
TableFunctionBottomHeight
=
100
;
private
int
TableFunctionFontSize
=
20
;
private
int
TableFunctionTopFontSize
=
20
;
private
int
TableFunctionBottomFontSize
=
20
;
private
String
Memberinfo
=
"MEM_MemberNo,MEM_Phone,MEM_NAME,MEM_Points"
;
private
String
MemberHttp
=
"http://m.ricepon.com:9090/member-web"
;
private
boolean
EnableErrorLog
=
true
;
private
boolean
TableFunction_SplitTable
=
true
;
private
boolean
TableFunction_FoodList
=
true
;
private
boolean
TableFunction_OfflineOrder
=
true
;
private
boolean
MainFunction_TableMode
=
true
;
private
boolean
TableFunction_ScanBarcode
=
true
;
private
boolean
OrderFunction_send
=
true
;
private
boolean
TableFunction_PayBill
=
true
;
private
boolean
OrderFunction_PrePay
=
true
;
private
int
AutoOpen
=
0
;
private
int
OrderNumberShowSize
=
20
;
private
int
OrderNumberFontSize
=
7
;
private
int
OrderNumberChildShowSize
=
20
;
private
int
OrderNumberChildFontSize
=
10
;
/**
* 送單是否自動合併未送食品(只處理未有細項的食品)
*/
private
boolean
MergeSendFood
=
true
;
/**
* 送單是否自動打印上菜纸
*/
private
boolean
AutoPrinterParper
=
true
;
private
Set
<
String
>
customizeSetting
=
new
HashSet
<>();
private
int
screen_w
=
1080
;
private
int
screen_h
=
1920
;
private
int
screen_density_dpi
;
public
void
adjustSize
(
Context
context
,
FunctionStyleUtils
setting
)
{
DisplayMetrics
metrics
=
DeviceUtils
.
getDisplayMetrics
(
context
);
screen_w
=
metrics
.
widthPixels
;
screen_h
=
metrics
.
heightPixels
;
screen_density_dpi
=
metrics
.
densityDpi
;
if
(!
setting
.
customizeSetting
.
contains
(
"TableFunctionBottomHeight"
))
{
//计算高度/
setting
.
TableFunctionBottomHeight
=
(
int
)
Math
.
ceil
((
float
)
setting
.
TableFunctionBottomHeight
/
(
float
)
setting
.
BaseHeight
*
(
float
)
setting
.
screen_h
);
}
if
(!
setting
.
customizeSetting
.
contains
(
"TableFunctionTopHeight"
))
{
//计算高度/
setting
.
TableFunctionTopHeight
=
(
int
)
Math
.
ceil
((
float
)
setting
.
TableFunctionTopHeight
/
(
float
)
setting
.
BaseHeight
*
(
float
)
setting
.
screen_h
);
}
if
(!
setting
.
customizeSetting
.
contains
(
"OrderOperButtonHeight"
))
{
//计算高度/
setting
.
OrderOperButtonHeight
=
(
int
)
Math
.
ceil
((
float
)
setting
.
OrderOperButtonHeight
/
(
float
)
setting
.
BaseHeight
*
(
float
)
setting
.
screen_h
);
}
if
(!
setting
.
customizeSetting
.
contains
(
"LayoutBillListHeight"
))
{
//计算高度/
setting
.
LayoutBillListHeight
=
(
int
)
Math
.
ceil
((
float
)
setting
.
LayoutBillListHeight
/
(
float
)
setting
.
BaseHeight
*
(
float
)
setting
.
screen_h
);
}
if
(!
setting
.
customizeSetting
.
contains
(
"LayoutQtyHeight"
))
{
//计算高度/
setting
.
LayoutQtyHeight
=
(
int
)
Math
.
ceil
((
float
)
setting
.
LayoutQtyHeight
/
(
float
)
setting
.
BaseHeight
*
(
float
)
setting
.
screen_h
);
}
if
(!
setting
.
customizeSetting
.
contains
(
"LayoutQuitHeight"
))
{
//计算高度/
setting
.
LayoutQuitHeight
=
(
int
)
Math
.
ceil
((
float
)
setting
.
LayoutQuitHeight
/
(
float
)
setting
.
BaseHeight
*
(
float
)
setting
.
screen_h
);
}
if
(!
setting
.
customizeSetting
.
contains
(
"LayoutFoodTypeHeight"
))
{
//计算高度/
setting
.
LayoutFoodTypeHeight
=
(
int
)
Math
.
ceil
((
float
)
setting
.
LayoutFoodTypeHeight
/
(
float
)
setting
.
BaseHeight
*
(
float
)
setting
.
screen_h
);
}
if
(!
setting
.
customizeSetting
.
contains
(
"FoodBtnHeight"
))
{
//计算高度/
Log
.
e
(
"初始FoodBtnHeight"
,
FoodBtnHeight
+
""
);
setting
.
FoodBtnHeight
=
(
int
)
Math
.
ceil
((
float
)
setting
.
FoodBtnHeight
/
(
float
)
setting
.
BaseHeight
*
(
float
)
setting
.
screen_h
);
Log
.
e
(
"最后得出的FoodBtnHeight"
,
setting
.
FoodBtnHeight
+
""
);
}
if
(!
setting
.
customizeSetting
.
contains
(
"ModBtnHeight"
))
{
//计算高度/
setting
.
ModBtnHeight
=
(
int
)
Math
.
ceil
((
float
)
setting
.
ModBtnHeight
/
(
float
)
setting
.
BaseHeight
*
(
float
)
setting
.
screen_h
);
}
if
(!
setting
.
customizeSetting
.
contains
(
"ModFunctionBarHeight"
))
{
//计算高度/
setting
.
ModFunctionBarHeight
=
(
int
)
Math
.
ceil
((
float
)
setting
.
ModFunctionBarHeight
/
(
float
)
setting
.
BaseHeight
*
(
float
)
setting
.
screen_h
);
}
if
(!
setting
.
customizeSetting
.
contains
(
"BottomBarHeight"
))
{
//计算高度/
setting
.
BottomBarHeight
=
(
int
)
Math
.
ceil
((
float
)
setting
.
BottomBarHeight
/
(
float
)
setting
.
BaseHeight
*
(
float
)
setting
.
screen_h
);
}
if
(!
setting
.
customizeSetting
.
contains
(
"OrderDataOperBtnWidth"
))
{
//计算高度/
OrderDataOperBtnWidth
=
(
int
)
Math
.
ceil
((
float
)
OrderDataOperBtnWidth
/
(
float
)
BaseWidth
*
(
float
)
screen_w
);
}
if
(!
customizeSetting
.
contains
(
"OrderDataOperBtnHeight"
))
{
//计算高度/
setting
.
OrderDataOperBtnHeight
=
(
int
)
Math
.
ceil
((
float
)
setting
.
OrderDataOperBtnHeight
/
(
float
)
setting
.
BaseHeight
*
(
float
)
setting
.
screen_h
);
}
float
screen_scaledDensity
=
(
float
)
setting
.
screen_density_dpi
/
160
;
float
base_scaledDensity
=
(
float
)
setting
.
BaseDpi
/
160
;
float
rate
=
(
float
)
(
base_scaledDensity
/
screen_scaledDensity
);
if
(!
setting
.
customizeSetting
.
contains
(
"TableFunctionTopFontSize"
))
{
setting
.
TableFunctionTopFontSize
=
(
int
)
Math
.
ceil
((
float
)
setting
.
TableFunctionTopFontSize
/
(
float
)
setting
.
BaseWidth
*
(
float
)
setting
.
screen_w
*
rate
);
///base_scaledDensity*(float)privateClass.screen_scaledDensity);
}
if
(!
setting
.
customizeSetting
.
contains
(
"TableFunctionBottomFontSize"
))
{
setting
.
TableFunctionBottomFontSize
=
(
int
)
Math
.
ceil
((
float
)
setting
.
TableFunctionBottomFontSize
/
(
float
)
setting
.
BaseWidth
*
(
float
)
setting
.
screen_w
*
rate
);
}
if
(!
setting
.
customizeSetting
.
contains
(
"FoodTypeFontSize"
))
{
setting
.
FoodTypeFontSize
=
(
int
)
Math
.
ceil
((
float
)
setting
.
FoodTypeFontSize
/
(
float
)
setting
.
BaseWidth
*
(
float
)
setting
.
screen_w
*
rate
);
}
if
(!
setting
.
customizeSetting
.
contains
(
"FoodFontSize"
))
{
setting
.
FoodFontSize
=
(
int
)
Math
.
ceil
((
float
)
setting
.
FoodFontSize
/
(
float
)
setting
.
BaseWidth
*
(
float
)
setting
.
screen_w
*
rate
);
}
if
(!
setting
.
customizeSetting
.
contains
(
"ModFontSize"
))
{
setting
.
ModFontSize
=
(
int
)
Math
.
ceil
((
float
)
setting
.
ModFontSize
/
(
float
)
setting
.
BaseWidth
*
(
float
)
setting
.
screen_w
*
rate
);
}
if
(!
setting
.
customizeSetting
.
contains
(
"BillTotalFontSize"
))
{
setting
.
BillTotalFontSize
=
(
int
)
Math
.
ceil
((
float
)
setting
.
BillTotalFontSize
/
(
float
)
setting
.
BaseWidth
*
(
float
)
setting
.
screen_w
*
rate
);
}
if
(!
setting
.
customizeSetting
.
contains
(
"BillListFontSize"
))
{
Log
.
e
(
"初始BillListFontSize"
,
setting
.
BillListFontSize
+
""
);
setting
.
BillListFontSize
=
(
int
)
Math
.
ceil
((
float
)
setting
.
BillListFontSize
/
(
float
)
setting
.
BaseWidth
*
(
float
)
setting
.
screen_w
*
rate
);
Log
.
e
(
"最后得出的BillListFontSize"
,
BillListFontSize
+
""
);
}
if
(!
setting
.
customizeSetting
.
contains
(
"FoodlListFontSize"
))
{
setting
.
FoodlListFontSize
=
(
int
)
Math
.
ceil
((
float
)
setting
.
FoodlListFontSize
/
(
float
)
setting
.
BaseWidth
*
(
float
)
setting
.
screen_w
*
rate
);
}
if
(!
setting
.
customizeSetting
.
contains
(
"orderInfoFontSize"
))
{
Log
.
e
(
"初始orderInfoFontSize"
,
setting
.
orderInfoFontSize
+
""
);
setting
.
orderInfoFontSize
=
(
int
)
Math
.
ceil
((
float
)
setting
.
orderInfoFontSize
/
(
float
)
setting
.
BaseWidth
*
(
float
)
setting
.
screen_w
*
rate
);
Log
.
e
(
"最后得出的orderInfoFontSize"
,
setting
.
orderInfoFontSize
+
""
);
}
if
(!
setting
.
customizeSetting
.
contains
(
"TableFunctionFontSize"
))
{
setting
.
TableFunctionFontSize
=
(
int
)
Math
.
ceil
((
float
)
setting
.
TableFunctionFontSize
/
(
float
)
setting
.
BaseWidth
*
(
float
)
setting
.
screen_w
*
rate
);
}
if
(!
setting
.
customizeSetting
.
contains
(
"OrderNumberFontSize"
))
{
setting
.
OrderNumberFontSize
=
(
int
)
Math
.
ceil
((
float
)
setting
.
OrderNumberFontSize
/
(
float
)
setting
.
BaseWidth
*
(
float
)
setting
.
screen_w
*
rate
);
}
if
(!
setting
.
customizeSetting
.
contains
(
"OrderNumberChildFontSize"
))
{
setting
.
OrderNumberChildFontSize
=
(
int
)
Math
.
ceil
((
float
)
setting
.
OrderNumberChildFontSize
/
(
float
)
setting
.
BaseWidth
*
(
float
)
setting
.
screen_w
*
rate
);
}
}
}
login-module/src/main/java/com/gingersoft/gsa/cloud/login/mvp/contract/LoginInterfaceImpl.java
View file @
f142c320
...
...
@@ -94,7 +94,8 @@ public abstract class LoginInterfaceImpl<P extends BaseLoginPresenter> extends B
if
(
restaurantId
!=
0
)
{
//上一次進入app有選擇餐廳,通過餐廳ID獲取允許的最大登陸數
// mPresenter.getLoginLimit(restaurantId, false);
jumpMainActivity
();
// jumpMainActivity();
jumpDownloadActivity
();
return
;
}
}
...
...
login-module/src/main/java/com/gingersoft/gsa/cloud/login/mvp/ui/activity/mvp/ui/activity/LoginActivity.java
View file @
f142c320
...
...
@@ -80,26 +80,6 @@ public class LoginActivity extends LoginInterfaceImpl<LoginPresenter> implements
private
boolean
passwrodVisibility
=
false
;
/**
* 轉台操作后需要重算的點:
* 合計(食品總金額)
* 服務費
* 折扣
* 賬單小數
*/
/**
* 服務費:
* 1、A 轉 B,服務費不用轉過去 用目標檯的即可
*/
/**
* 折扣:
* A 轉 B
* 1、A B都有折扣不用轉過去
* 2、A有折扣B沒有 需要轉過去
* 3、B有折扣A沒有 不用管
*/
@Override
public
void
setupActivityComponent
(
@NonNull
AppComponent
appComponent
)
{
...
...
table-module/src/main/java/com/gingersoft/gsa/cloud/bean/mvp/presenter/TablePresenter.java
View file @
f142c320
...
...
@@ -148,11 +148,6 @@ public class TablePresenter extends BasePresenter<TableContract.Model, TableCont
mTableActions
.
add
(
new
PrintSkyOrderAction
(
context
));
}
}
// mTableActions.add(new ResetTableAction(context));
// mTableActions.add(new MoveTableAction(context));
// mTableActions.add(new SplitTableAction(context));
// mTableActions.add(new PrintServingPaperAction(context));
// mTableActions.add(new PrintSkyOrderAction(context));
}
@Override
...
...
table-module/src/main/java/com/gingersoft/gsa/cloud/bean/mvp/ui/activity/TableActivity.java
View file @
f142c320
package
com
.
gingersoft
.
gsa
.
cloud
.
bean
.
mvp
.
ui
.
activity
;
import
android.app.Activity
;
import
android.content.Intent
;
import
android.os.Bundle
;
import
android.os.Message
;
...
...
table-module/src/main/java/com/gingersoft/gsa/cloud/bean/mvp/ui/adapter/CurrentSlodoutFoodAdapter.java
View file @
f142c320
...
...
@@ -39,35 +39,6 @@ public class CurrentSlodoutFoodAdapter extends DefaultAdapter<SoldoutCtrFood> {
super
(
infos
);
this
.
mContext
=
context
;
this
.
mFoodlListFontSize
=
GsaCloudApplication
.
androidSetting
.
getFoodlListFontSize
();
// Object mInstanceProxy = Proxy.newProxyInstance(Thread.currentThread().getContextClassLoader(), new Class[]{QMUIActivity.class}, new InvocationHandler() {
//
// @Override
// public Object invoke(Object proxy, Method method, Object[] args) throws Throwable {
// // 当执行的方法是 startActivity 时作处理
// if ("startActivity".equals(method.getName())) {
// int index = 0;
// // 获取 Intent 参数在 args 数组中的index值
// for (int i = 0; i < args.length; i++) {
// if (args[i] instanceof Intent) {
// index = i;
// break;
// }
// }
// // 得到原始的 Intent 对象 -- 唐僧(插件)的Intent
// Intent intent = (Intent) args[index];
//
// // 生成代理proxyIntent -- 孙悟空(代理)的Intent
// Intent proxyIntent = new Intent();
// proxyIntent.setClassName("com.enjoy.pluginactivity", ProxyActivity.class.getName());
// // 保存原始的Intent对象
// proxyIntent.putExtra(TARGET_INTENT, intent);
// // 使用proxyIntent替换数组中的Intent
// args[index] = proxyIntent;
// }
// return method.invoke(mInstance, args);
// }
// });
}
public
void
setSelectPosition
(
int
select_position
)
{
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment