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
5cf2e2a2
Commit
5cf2e2a2
authored
Feb 04, 2021
by
宁斌
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
添加餐台模式埋点
parent
890979d5
Hide whitespace changes
Inline
Side-by-side
Showing
16 changed files
with
65 additions
and
62 deletions
+65
-62
component-login/src/main/java/com/gingersoft/gsa/cloud/login/mvp/ui/activity/mvp/ui/activity/ChooseRestaurantActivity.java
+5
-6
component-main/src/main/AndroidManifest.xml
+2
-1
component-main/src/main/debug/AndroidManifest.xml
+2
-1
component-main/src/main/java/com/gingersoft/gsa/cloud/main/ComponentMain.java
+7
-1
component-main/src/main/java/com/gingersoft/gsa/cloud/main/mvp/ui/activity/NewMainActivity.java
+14
-3
component-table/src/main/java/com/gingersoft/gsa/cloud/table/mvp/ui/activity/MealStandActivity.java
+13
-5
component-table/src/main/java/com/gingersoft/gsa/cloud/table/mvp/ui/widget/CancelFoodDialog.java
+2
-1
config.gradle
+2
-2
library-common/src/main/java/com/gingersoft/gsa/cloud/app/GsaCloudApplication.java
+3
-3
library-common/src/main/java/com/gingersoft/gsa/cloud/common/config/LoganConfig.java
+1
-0
library-common/src/main/java/com/gingersoft/gsa/cloud/common/config/globalconfig/applyOptions/intercept/HeadersInterceptor.java
+1
-1
library-common/src/main/java/com/gingersoft/gsa/cloud/common/logan/LoganManager.java
+11
-0
library-common/src/main/java/com/gingersoft/gsa/cloud/common/printer/PrinterFileUtils.java
+2
-0
library-common/src/main/java/com/gingersoft/gsa/cloud/common/utils/FileUtils.java
+0
-33
library-common/src/main/java/com/gingersoft/gsa/cloud/common/utils/crash/AppCrashHandler.java
+0
-2
library-print/src/main/java/com/gingersoft/gsa/cloud/print/PrintSocketHolder.java
+0
-3
No files found.
component-login/src/main/java/com/gingersoft/gsa/cloud/login/mvp/ui/activity/mvp/ui/activity/ChooseRestaurantActivity.java
View file @
5cf2e2a2
...
@@ -22,6 +22,7 @@ import com.gingersoft.gsa.cloud.common.core.restaurant.RestaurantInfoManager;
...
@@ -22,6 +22,7 @@ import com.gingersoft.gsa.cloud.common.core.restaurant.RestaurantInfoManager;
import
com.gingersoft.gsa.cloud.common.core.restaurant.bean.BrandsBean
;
import
com.gingersoft.gsa.cloud.common.core.restaurant.bean.BrandsBean
;
import
com.gingersoft.gsa.cloud.common.core.restaurant.utils.RestaurantInfoUtils
;
import
com.gingersoft.gsa.cloud.common.core.restaurant.utils.RestaurantInfoUtils
;
import
com.gingersoft.gsa.cloud.common.core.user.UserContext
;
import
com.gingersoft.gsa.cloud.common.core.user.UserContext
;
import
com.gingersoft.gsa.cloud.common.logan.LoganManager
;
import
com.gingersoft.gsa.cloud.common.utils.JsonUtils
;
import
com.gingersoft.gsa.cloud.common.utils.JsonUtils
;
import
com.gingersoft.gsa.cloud.common.utils.log.LogUtil
;
import
com.gingersoft.gsa.cloud.common.utils.log.LogUtil
;
import
com.gingersoft.gsa.cloud.common.utils.other.TextUtil
;
import
com.gingersoft.gsa.cloud.common.utils.other.TextUtil
;
...
@@ -210,8 +211,8 @@ public class ChooseRestaurantActivity extends BaseActivity<ChooseRestaurantPrese
...
@@ -210,8 +211,8 @@ public class ChooseRestaurantActivity extends BaseActivity<ChooseRestaurantPrese
protected
void
saveBrandAndRestaurantInfo
(
int
brandId
,
String
brandName
,
BrandsBean
.
BrandsData
.
RestaurantsBean
restaurantsBean
)
{
protected
void
saveBrandAndRestaurantInfo
(
int
brandId
,
String
brandName
,
BrandsBean
.
BrandsData
.
RestaurantsBean
restaurantsBean
)
{
RestaurantInfoManager
.
newInstance
().
setBrandInfo
(
new
BrandInfo
(
brandId
,
brandName
));
RestaurantInfoManager
.
newInstance
().
setBrandInfo
(
new
BrandInfo
(
brandId
,
brandName
));
if
(
restaurantsBean
!=
null
)
{
if
(
restaurantsBean
!=
null
)
{
RestaurantInfoManager
.
newInstance
().
setResturantInfo
(
new
RestaurantInfo
(
restaurantsBean
.
getRestaurantId
(),
restaurantsBean
.
getRestaurantName
()
RestaurantInfoManager
.
newInstance
().
setResturantInfo
(
new
RestaurantInfo
(
restaurantsBean
.
getRestaurantId
(),
restaurantsBean
.
getRestaurantName
()
,
restaurantsBean
.
getGsPosShopId
()));
,
restaurantsBean
.
getGsPosShopId
()));
}
}
}
}
...
@@ -266,6 +267,7 @@ public class ChooseRestaurantActivity extends BaseActivity<ChooseRestaurantPrese
...
@@ -266,6 +267,7 @@ public class ChooseRestaurantActivity extends BaseActivity<ChooseRestaurantPrese
.
call
();
.
call
();
BrandsBean
.
BrandsData
brandsBean
=
RestaurantInfoUtils
.
getBrandByRestaurantId
(
brands
,
item
.
getRestaurantId
());
BrandsBean
.
BrandsData
brandsBean
=
RestaurantInfoUtils
.
getBrandByRestaurantId
(
brands
,
item
.
getRestaurantId
());
if
(
brandsBean
!=
null
)
{
if
(
brandsBean
!=
null
)
{
LoganManager
.
w_login
(
TAG
,
LoganManager
.
EVENT_SELECTED
,
"品牌="
+
brandsBean
.
getBrandName
()
+
" 餐廳="
+
item
.
getRestaurantName
());
saveBrandAndRestaurantInfo
(
brandsBean
.
getBrandId
(),
brandsBean
.
getBrandName
(),
item
);
saveBrandAndRestaurantInfo
(
brandsBean
.
getBrandId
(),
brandsBean
.
getBrandName
(),
item
);
mPresenter
.
getLoginLimit
(
item
.
getRestaurantId
(),
true
);
mPresenter
.
getLoginLimit
(
item
.
getRestaurantId
(),
true
);
}
}
...
@@ -301,6 +303,7 @@ public class ChooseRestaurantActivity extends BaseActivity<ChooseRestaurantPrese
...
@@ -301,6 +303,7 @@ public class ChooseRestaurantActivity extends BaseActivity<ChooseRestaurantPrese
}
}
}
}
}
}
@Override
@Override
public
void
jumpActivity
(
Class
activity
)
{
public
void
jumpActivity
(
Class
activity
)
{
startActivity
(
new
Intent
(
this
,
activity
));
startActivity
(
new
Intent
(
this
,
activity
));
...
@@ -352,10 +355,6 @@ public class ChooseRestaurantActivity extends BaseActivity<ChooseRestaurantPrese
...
@@ -352,10 +355,6 @@ public class ChooseRestaurantActivity extends BaseActivity<ChooseRestaurantPrese
}).
setGravity
(
Gravity
.
BOTTOM
).
show
();
}).
setGravity
(
Gravity
.
BOTTOM
).
show
();
}
else
{
}
else
{
showMessage
(
"獲取登陸人數失敗"
);
showMessage
(
"獲取登陸人數失敗"
);
// GsaCloudApplication.logOut();
// UserContext.newInstance().logOut();
// launchActivity(new Intent(mContext, LoginActivity.class));
UserContext
.
newInstance
().
logOut
();
UserContext
.
newInstance
().
logOut
();
}
}
}
}
...
...
component-main/src/main/AndroidManifest.xml
View file @
5cf2e2a2
...
@@ -9,7 +9,8 @@
...
@@ -9,7 +9,8 @@
android:screenOrientation=
"portrait"
/>
android:screenOrientation=
"portrait"
/>
<activity
<activity
android:name=
".mvp.ui.activity.NewMainActivity"
android:name=
".mvp.ui.activity.NewMainActivity"
android:launchMode=
"singleTop"
android:alwaysRetainTaskState=
"true"
android:launchMode=
"singleTask"
android:screenOrientation=
"portrait"
/>
android:screenOrientation=
"portrait"
/>
<activity
<activity
android:name=
".mvp.ui.activity.ExpandListActivity"
android:name=
".mvp.ui.activity.ExpandListActivity"
...
...
component-main/src/main/debug/AndroidManifest.xml
View file @
5cf2e2a2
...
@@ -20,7 +20,8 @@
...
@@ -20,7 +20,8 @@
<activity
android:name=
".mvp.ui.activity.menu.ShellActivity"
/>
<activity
android:name=
".mvp.ui.activity.menu.ShellActivity"
/>
<activity
<activity
android:name=
".mvp.ui.activity.NewMainActivity"
android:name=
".mvp.ui.activity.NewMainActivity"
android:launchMode=
"singleTop"
/>
android:launchMode=
"singleTask"
android:alwaysRetainTaskState=
"true"
/>
<activity
android:name=
".mvp.ui.activity.ExpandListActivity"
/>
<activity
android:name=
".mvp.ui.activity.ExpandListActivity"
/>
<activity
android:name=
".mvp.ui.activity.RestaurantQrCodeActivity"
/>
<activity
android:name=
".mvp.ui.activity.RestaurantQrCodeActivity"
/>
<activity
android:name=
".mvp.ui.activity.LanguageActivity"
/>
<activity
android:name=
".mvp.ui.activity.LanguageActivity"
/>
...
...
component-main/src/main/java/com/gingersoft/gsa/cloud/main/ComponentMain.java
View file @
5cf2e2a2
...
@@ -6,7 +6,9 @@ import android.content.Intent;
...
@@ -6,7 +6,9 @@ import android.content.Intent;
import
com.billy.cc.core.component.CC
;
import
com.billy.cc.core.component.CC
;
import
com.billy.cc.core.component.CCResult
;
import
com.billy.cc.core.component.CCResult
;
import
com.billy.cc.core.component.CCUtil
;
import
com.billy.cc.core.component.IComponent
;
import
com.billy.cc.core.component.IComponent
;
import
com.gingersoft.gsa.cloud.common.logan.LoganManager
;
import
com.gingersoft.gsa.cloud.component.ComponentAction
;
import
com.gingersoft.gsa.cloud.component.ComponentAction
;
import
com.gingersoft.gsa.cloud.component.ComponentName
;
import
com.gingersoft.gsa.cloud.component.ComponentName
;
import
com.gingersoft.gsa.cloud.common.function.FModule
;
import
com.gingersoft.gsa.cloud.common.function.FModule
;
...
@@ -18,6 +20,8 @@ import com.jess.arms.utils.ArmsUtils;
...
@@ -18,6 +20,8 @@ import com.jess.arms.utils.ArmsUtils;
public
class
ComponentMain
implements
IComponent
{
public
class
ComponentMain
implements
IComponent
{
private
final
String
TAG
=
getClass
().
getSimpleName
();
public
static
final
class
main
{
public
static
final
class
main
{
/**
/**
* 首頁- 點餐
* 首頁- 點餐
...
@@ -79,6 +83,7 @@ public class ComponentMain implements IComponent {
...
@@ -79,6 +83,7 @@ public class ComponentMain implements IComponent {
String
actionName
=
cc
.
getActionName
();
String
actionName
=
cc
.
getActionName
();
switch
(
actionName
)
{
switch
(
actionName
)
{
case
"showMainActivity"
:
case
"showMainActivity"
:
LoganManager
.
w_code
(
TAG
,
"onCall showMainActivity"
);
openActivity
(
cc
);
openActivity
(
cc
);
break
;
break
;
case
"foodMenuActivity"
:
case
"foodMenuActivity"
:
...
@@ -129,8 +134,9 @@ public class ComponentMain implements IComponent {
...
@@ -129,8 +134,9 @@ public class ComponentMain implements IComponent {
Intent
intent
=
new
Intent
(
cc
.
getContext
(),
NewMainActivity
.
class
);
Intent
intent
=
new
Intent
(
cc
.
getContext
(),
NewMainActivity
.
class
);
intent
.
addFlags
(
Intent
.
FLAG_ACTIVITY_NEW_TASK
);
intent
.
addFlags
(
Intent
.
FLAG_ACTIVITY_NEW_TASK
);
cc
.
getContext
().
startActivity
(
intent
);
cc
.
getContext
().
startActivity
(
intent
);
// CCUtil.createNavigateIntent(cc, MainActivity.class);
// CCUtil.createNavigateIntent(cc,
New
MainActivity.class);
// CC.sendCCResult(cc.getCallId(), CCResult.success());
// CC.sendCCResult(cc.getCallId(), CCResult.success());
}
}
}
}
component-main/src/main/java/com/gingersoft/gsa/cloud/main/mvp/ui/activity/NewMainActivity.java
View file @
5cf2e2a2
...
@@ -196,6 +196,11 @@ public class NewMainActivity extends BaseFragmentActivity<NewMainPresenter> impl
...
@@ -196,6 +196,11 @@ public class NewMainActivity extends BaseFragmentActivity<NewMainPresenter> impl
}
}
@Override
@Override
protected
void
onNewIntent
(
Intent
intent
)
{
super
.
onNewIntent
(
intent
);
}
@Override
protected
void
onResume
()
{
protected
void
onResume
()
{
super
.
onResume
();
super
.
onResume
();
initFuncationData
();
initFuncationData
();
...
@@ -246,7 +251,12 @@ public class NewMainActivity extends BaseFragmentActivity<NewMainPresenter> impl
...
@@ -246,7 +251,12 @@ public class NewMainActivity extends BaseFragmentActivity<NewMainPresenter> impl
MainSideMenuAdapter
adapter
=
new
MainSideMenuAdapter
(
mainSideMenuBeans
);
MainSideMenuAdapter
adapter
=
new
MainSideMenuAdapter
(
mainSideMenuBeans
);
mRvSideMenu
.
setAdapter
(
adapter
);
mRvSideMenu
.
setAdapter
(
adapter
);
adapter
.
setOnItemClickListener
((
adapter1
,
view
,
position
)
->
{
adapter
.
setOnItemClickListener
((
adapter1
,
view
,
position
)
->
{
switch
(
mainSideMenuBeans
.
get
(
position
).
getFunctionName
())
{
String
functionName
=
mainSideMenuBeans
.
get
(
position
).
getFunctionName
();
LoganManager
.
w_home
(
TAG
,
LoganManager
.
EVENT_CLICK
+
functionName
);
switch
(
functionName
)
{
case
"切換環境"
:
case
"切換環境"
:
//切換環境
//切換環境
CC
.
obtainBuilder
(
ComponentName
.
COMPONENT_LOGIN
)
CC
.
obtainBuilder
(
ComponentName
.
COMPONENT_LOGIN
)
...
@@ -388,6 +398,9 @@ public class NewMainActivity extends BaseFragmentActivity<NewMainPresenter> impl
...
@@ -388,6 +398,9 @@ public class NewMainActivity extends BaseFragmentActivity<NewMainPresenter> impl
}
}
private
void
functionClick
(
String
name
,
int
status
)
{
private
void
functionClick
(
String
name
,
int
status
)
{
LoganManager
.
w_home
(
TAG
,
LoganManager
.
EVENT_CLICK
+
name
);
switch
(
name
)
{
switch
(
name
)
{
case
"餐檯模式"
:
case
"餐檯模式"
:
CC
.
obtainBuilder
(
ComponentName
.
COMPONENT_TABLE
)
CC
.
obtainBuilder
(
ComponentName
.
COMPONENT_TABLE
)
...
@@ -591,9 +604,7 @@ public class NewMainActivity extends BaseFragmentActivity<NewMainPresenter> impl
...
@@ -591,9 +604,7 @@ public class NewMainActivity extends BaseFragmentActivity<NewMainPresenter> impl
showMessage
(
"再按一次退出應用"
);
showMessage
(
"再按一次退出應用"
);
mExitTime
=
System
.
currentTimeMillis
();
mExitTime
=
System
.
currentTimeMillis
();
}
else
{
}
else
{
finish
();
ArmsUtils
.
exitApp
();
ArmsUtils
.
exitApp
();
// System.exit(0);
}
}
}
}
return
true
;
return
true
;
...
...
component-table/src/main/java/com/gingersoft/gsa/cloud/table/mvp/ui/activity/MealStandActivity.java
View file @
5cf2e2a2
...
@@ -525,8 +525,10 @@ public class MealStandActivity extends BaseFragmentActivity<MealStandPresenter>
...
@@ -525,8 +525,10 @@ public class MealStandActivity extends BaseFragmentActivity<MealStandPresenter>
public
void
onPageSelected
(
int
position
)
{
public
void
onPageSelected
(
int
position
)
{
currentFinePage
=
position
;
currentFinePage
=
position
;
if
(
currentFinePage
==
0
)
{
if
(
currentFinePage
==
0
)
{
LoganManager
.
w_tableMode
(
TAG
,
LoganManager
.
EVENT_CLICK
+
"口味"
);
tv_fine_type
.
setText
(
"口味"
);
tv_fine_type
.
setText
(
"口味"
);
}
else
{
}
else
{
LoganManager
.
w_tableMode
(
TAG
,
LoganManager
.
EVENT_CLICK
+
"訊息"
);
tv_fine_type
.
setText
(
"訊息"
);
tv_fine_type
.
setText
(
"訊息"
);
}
}
}
}
...
@@ -589,12 +591,14 @@ public class MealStandActivity extends BaseFragmentActivity<MealStandPresenter>
...
@@ -589,12 +591,14 @@ public class MealStandActivity extends BaseFragmentActivity<MealStandPresenter>
@OnClick
(
R2
.
id
.
btn_meal_discount
)
@OnClick
(
R2
.
id
.
btn_meal_discount
)
void
onClickDiscount
()
{
void
onClickDiscount
()
{
LoganManager
.
w_tableMode
(
TAG
,
LoganManager
.
EVENT_CLICK
+
"食品折扣"
);
OrderDetail
mainOrderDetail
=
mPresenter
.
getSelectMealAdapter
().
getCurrentMainOrderDetail
();
OrderDetail
mainOrderDetail
=
mPresenter
.
getSelectMealAdapter
().
getCurrentMainOrderDetail
();
if
(
mainOrderDetail
!=
null
&&
mainOrderDetail
.
getAblediscount
()
==
0
)
{
if
(
mainOrderDetail
!=
null
&&
mainOrderDetail
.
getAblediscount
()
==
0
)
{
showMessage
(
"此食品不能參與折扣!"
);
showMessage
(
"此食品不能參與折扣!"
);
return
;
return
;
}
}
LoganManager
.
w_tableMode
(
TAG
,
LoganManager
.
EVENT_CLICK
+
"食品折扣"
);
//更新折扣数据
//更新折扣数据
mPresenter
.
loadDiscountData
();
mPresenter
.
loadDiscountData
();
...
@@ -655,7 +659,7 @@ public class MealStandActivity extends BaseFragmentActivity<MealStandPresenter>
...
@@ -655,7 +659,7 @@ public class MealStandActivity extends BaseFragmentActivity<MealStandPresenter>
DoshokuOrder
.
getInstance
().
setMemberInfo
(
null
);
DoshokuOrder
.
getInstance
().
setMemberInfo
(
null
);
DiscountItem
memberDiscountBillItem
=
(
DiscountItem
)
mPresenter
.
findBillItemByClass
(
MemberDiscount
.
class
);
DiscountItem
memberDiscountBillItem
=
(
DiscountItem
)
mPresenter
.
findBillItemByClass
(
MemberDiscount
.
class
);
if
(
memberDiscountBillItem
!=
null
)
{
if
(
memberDiscountBillItem
!=
null
)
{
ShoppingCart
shoppingCart
=
mPresenter
.
getShoppingCart
();
ShoppingCart
shoppingCart
=
mPresenter
.
getShoppingCart
();
shoppingCart
.
delMultyDiscount
(
memberDiscountBillItem
.
getDiscount
());
shoppingCart
.
delMultyDiscount
(
memberDiscountBillItem
.
getDiscount
());
//更新賬單信息
//更新賬單信息
...
@@ -690,6 +694,7 @@ public class MealStandActivity extends BaseFragmentActivity<MealStandPresenter>
...
@@ -690,6 +694,7 @@ public class MealStandActivity extends BaseFragmentActivity<MealStandPresenter>
@OnClick
(
R2
.
id
.
btn_multiple_selection
)
@OnClick
(
R2
.
id
.
btn_multiple_selection
)
void
onClickMultipleSelection
()
{
void
onClickMultipleSelection
()
{
LoganManager
.
w_tableMode
(
TAG
,
LoganManager
.
EVENT_CLICK
,
"多选"
);
currentFinePage
=
0
;
currentFinePage
=
0
;
if
(
mPresenter
.
getSelectMealAdapter
().
getSelectedMode
()
==
SelectMealAdapter
.
MULTIPLE_SELECTED
)
{
if
(
mPresenter
.
getSelectMealAdapter
().
getSelectedMode
()
==
SelectMealAdapter
.
MULTIPLE_SELECTED
)
{
mPresenter
.
getSelectMealAdapter
().
setSelectedMode
(
SelectMealAdapter
.
SINGLE_SELECTED
);
mPresenter
.
getSelectMealAdapter
().
setSelectedMode
(
SelectMealAdapter
.
SINGLE_SELECTED
);
...
@@ -706,13 +711,13 @@ public class MealStandActivity extends BaseFragmentActivity<MealStandPresenter>
...
@@ -706,13 +711,13 @@ public class MealStandActivity extends BaseFragmentActivity<MealStandPresenter>
@OnClick
(
R2
.
id
.
btn_select_all
)
@OnClick
(
R2
.
id
.
btn_select_all
)
void
onClickSelectAll
()
{
void
onClickSelectAll
()
{
LoganManager
.
w_tableMode
(
TAG
,
"全選食品
"
);
LoganManager
.
w_tableMode
(
TAG
,
LoganManager
.
EVENT_CLICK
,
"全選
"
);
mPresenter
.
setSelectAll
();
mPresenter
.
setSelectAll
();
}
}
@OnClick
(
R2
.
id
.
btn_anti_selection
)
@OnClick
(
R2
.
id
.
btn_anti_selection
)
void
onClickAntiSelection
()
{
void
onClickAntiSelection
()
{
LoganManager
.
w_tableMode
(
TAG
,
"反選食品
"
);
LoganManager
.
w_tableMode
(
TAG
,
LoganManager
.
EVENT_CLICK
,
"反選
"
);
mPresenter
.
setAntiSelect
();
mPresenter
.
setAntiSelect
();
}
}
...
@@ -722,7 +727,7 @@ public class MealStandActivity extends BaseFragmentActivity<MealStandPresenter>
...
@@ -722,7 +727,7 @@ public class MealStandActivity extends BaseFragmentActivity<MealStandPresenter>
public
void
onClick
(
View
v
)
{
public
void
onClick
(
View
v
)
{
if
(
Build
.
VERSION
.
SDK_INT
>=
Build
.
VERSION_CODES
.
LOLLIPOP
)
{
if
(
Build
.
VERSION
.
SDK_INT
>=
Build
.
VERSION_CODES
.
LOLLIPOP
)
{
LoganManager
.
w_tableMode
(
TAG
,
LoganManager
.
EVENT_CLICK
,
v
.
getTransitionName
());
LoganManager
.
w_tableMode
(
TAG
,
LoganManager
.
EVENT_CLICK
,
v
.
getTransitionName
());
}
}
recordOperat
(
true
);
recordOperat
(
true
);
...
@@ -1365,6 +1370,9 @@ public class MealStandActivity extends BaseFragmentActivity<MealStandPresenter>
...
@@ -1365,6 +1370,9 @@ public class MealStandActivity extends BaseFragmentActivity<MealStandPresenter>
@Override
@Override
public
void
onPageSelect
(
int
pageIndex
)
{
public
void
onPageSelect
(
int
pageIndex
)
{
mPageIndex
=
pageIndex
;
mPageIndex
=
pageIndex
;
LoganManager
.
w_tableMode
(
TAG
,
LoganManager
.
EVENT_SCOLL
+
"食品組頁="
+
(
pageIndex
+
1
));
for
(
int
i
=
0
;
i
<
totalPage
;
i
++)
{
for
(
int
i
=
0
;
i
<
totalPage
;
i
++)
{
if
(
i
==
pageIndex
)
{
if
(
i
==
pageIndex
)
{
ivPoints
[
i
].
setImageResource
(
R
.
drawable
.
meal_food_group_point_focuese
);
ivPoints
[
i
].
setImageResource
(
R
.
drawable
.
meal_food_group_point_focuese
);
...
...
component-table/src/main/java/com/gingersoft/gsa/cloud/table/mvp/ui/widget/CancelFoodDialog.java
View file @
5cf2e2a2
...
@@ -150,7 +150,8 @@ public class CancelFoodDialog extends BaseRetryDialog implements Slider.OnSlider
...
@@ -150,7 +150,8 @@ public class CancelFoodDialog extends BaseRetryDialog implements Slider.OnSlider
@Override
@Override
public
void
onClick
(
View
v
)
{
public
void
onClick
(
View
v
)
{
mCurrCancelNumber
=
mMaxCancelNumber
;
mCurrCancelNumber
=
mMaxCancelNumber
;
slider_food_count
.
setValue
(
mMaxCancelNumber
);
slider_food_count
.
setValue
(
mCurrCancelNumber
);
tv_number_value
.
setText
(
String
.
valueOf
(
mCurrCancelNumber
));
}
}
});
});
ll_container
.
setRadiusAndShadow
(
mRadius
,
QMUIDisplayHelper
.
dp2px
(
mContext
,
mShadowElevationDp
),
mShadowAlpha
);
ll_container
.
setRadiusAndShadow
(
mRadius
,
QMUIDisplayHelper
.
dp2px
(
mContext
,
mShadowElevationDp
),
mShadowAlpha
);
...
...
config.gradle
View file @
5cf2e2a2
...
@@ -7,8 +7,8 @@ ext {
...
@@ -7,8 +7,8 @@ ext {
targetSdkVersion
:
29
,
targetSdkVersion
:
29
,
//正式版: 1.0.3 3
//正式版: 1.0.3 3
//內部測試版:1.2.0 20
//內部測試版:1.2.0 20
versionCode
:
2
2
,
versionCode
:
2
3
,
versionName
:
"1.2.
2
"
versionName
:
"1.2.
3
"
]
]
version
=
[
version
=
[
...
...
library-common/src/main/java/com/gingersoft/gsa/cloud/app/GsaCloudApplication.java
View file @
5cf2e2a2
...
@@ -348,12 +348,12 @@ public class GsaCloudApplication extends BaseApplication {
...
@@ -348,12 +348,12 @@ public class GsaCloudApplication extends BaseApplication {
@Override
@Override
public
void
onPrinterDataBefore
(
int
orderType
,
int
printType
,
String
printerData
,
String
printerDeviceInfo
)
{
public
void
onPrinterDataBefore
(
int
orderType
,
int
printType
,
String
printerData
,
String
printerDeviceInfo
)
{
LoganManager
.
w_printer
(
TAG
,
"打印前数据-
-
> printerData="
+
printerData
+
" printerDeviceInfo="
+
printerDeviceInfo
);
LoganManager
.
w_printer
(
TAG
,
"打印前数据-> printerData="
+
printerData
+
" printerDeviceInfo="
+
printerDeviceInfo
);
}
}
@Override
@Override
public
void
onPrinterBitmapBefore
(
int
orderType
,
int
printType
,
String
directoryName
,
List
<
Bitmap
>
bitmaps
)
{
public
void
onPrinterBitmapBefore
(
int
orderType
,
int
printType
,
String
directoryName
,
List
<
Bitmap
>
bitmaps
)
{
LoganManager
.
w_printer
(
TAG
,
"生成的打印圖片-
-
>"
);
LoganManager
.
w_printer
(
TAG
,
"生成的打印圖片->"
);
PrinterFileUtils
.
savePrinterBitmapByType
(
orderType
,
printType
,
directoryName
,
bitmaps
);
PrinterFileUtils
.
savePrinterBitmapByType
(
orderType
,
printType
,
directoryName
,
bitmaps
);
}
}
...
@@ -370,7 +370,7 @@ public class GsaCloudApplication extends BaseApplication {
...
@@ -370,7 +370,7 @@ public class GsaCloudApplication extends BaseApplication {
@Override
@Override
public
void
connectionBefore
(
String
deviceName
,
String
ip
,
int
port
,
long
ioTimeout
,
long
printTimeout
)
{
public
void
connectionBefore
(
String
deviceName
,
String
ip
,
int
port
,
long
ioTimeout
,
long
printTimeout
)
{
Object
[]
objs
=
{
deviceName
,
ip
,
port
,
ioTimeout
,
printTimeout
};
Object
[]
objs
=
{
deviceName
,
ip
,
port
,
ioTimeout
,
printTimeout
};
LoganManager
.
w_printer
(
TAG
,
String
.
format
(
"連接打印機前-
-
> deviceName=%s ,IP=%s ,port=%s ,ioTimeout=%s ,printTimeout=%s"
,
objs
));
LoganManager
.
w_printer
(
TAG
,
String
.
format
(
"連接打印機前-> deviceName=%s ,IP=%s ,port=%s ,ioTimeout=%s ,printTimeout=%s"
,
objs
));
}
}
@Override
@Override
...
...
library-common/src/main/java/com/gingersoft/gsa/cloud/common/config/LoganConfig.java
View file @
5cf2e2a2
...
@@ -15,6 +15,7 @@ public class LoganConfig {
...
@@ -15,6 +15,7 @@ public class LoganConfig {
public
static
final
String
EncryptIV16
=
"0123456789012345"
;
public
static
final
String
EncryptIV16
=
"0123456789012345"
;
public
static
final
String
APP_ID
=
"gingersoft1008611"
;
public
static
final
String
APP_ID
=
"gingersoft1008611"
;
public
static
final
String
UPLOAD_LOG_URL
=
HttpsConstans
.
HTTP_ADDRESS_URL_HK
+
"/logan-web/logan/upload.json"
;
public
static
final
String
UPLOAD_LOG_URL
=
HttpsConstans
.
HTTP_ADDRESS_URL_HK
+
"/logan-web/logan/upload.json"
;
// public static final String UPLOAD_LOG_URL = "http://192.168.1.131:8080/logan-web/logan/upload.json";
/**
/**
* 日誌保留天數
* 日誌保留天數
...
...
library-common/src/main/java/com/gingersoft/gsa/cloud/common/config/globalconfig/applyOptions/intercept/HeadersInterceptor.java
View file @
5cf2e2a2
...
@@ -34,7 +34,7 @@ public class HeadersInterceptor implements Interceptor {
...
@@ -34,7 +34,7 @@ public class HeadersInterceptor implements Interceptor {
String
deviceId
=
DeviceID
.
getDeviceId
();
String
deviceId
=
DeviceID
.
getDeviceId
();
if
(
deviceId
!=
null
)
{
if
(
deviceId
!=
null
)
{
builder
.
set
(
"deviceId"
,
DeviceID
.
getDeviceId
()
);
builder
.
set
(
"deviceId"
,
deviceId
);
}
}
Headers
headers
=
originalRequest
.
headers
();
Headers
headers
=
originalRequest
.
headers
();
for
(
int
i
=
0
;
i
<
headers
.
size
();
i
++)
{
for
(
int
i
=
0
;
i
<
headers
.
size
();
i
++)
{
...
...
library-common/src/main/java/com/gingersoft/gsa/cloud/common/logan/LoganManager.java
View file @
5cf2e2a2
...
@@ -62,6 +62,8 @@ public class LoganManager {
...
@@ -62,6 +62,8 @@ public class LoganManager {
/*******************************自定義業務日誌類型**************************************/
/*******************************自定義業務日誌類型**************************************/
private
static
final
String
LOGIN_BUSINESS_TAG
=
"login-> "
;
private
static
final
String
HOME_BUSINESS_TAG
=
"home-> "
;
private
static
final
String
DATABASE_BUSINESS_TAG
=
"database-> "
;
private
static
final
String
DATABASE_BUSINESS_TAG
=
"database-> "
;
private
static
final
String
PRINTER_BUSINESS_TAG
=
"printer-> "
;
private
static
final
String
PRINTER_BUSINESS_TAG
=
"printer-> "
;
private
static
final
String
TABLEMODE_BUSINESS_TAG
=
"tableMode-> "
;
private
static
final
String
TABLEMODE_BUSINESS_TAG
=
"tableMode-> "
;
...
@@ -71,6 +73,7 @@ public class LoganManager {
...
@@ -71,6 +73,7 @@ public class LoganManager {
/*******************************交互事件類型**************************************/
/*******************************交互事件類型**************************************/
public
static
final
String
EVENT_CLICK
=
"點擊->"
;
public
static
final
String
EVENT_CLICK
=
"點擊->"
;
public
static
final
String
EVENT_LONG_CLICK
=
"長按->"
;
public
static
final
String
EVENT_LONG_CLICK
=
"長按->"
;
public
static
final
String
EVENT_SELECTED
=
"選中->"
;
public
static
final
String
EVENT_TOUCH
=
"觸摸->"
;
public
static
final
String
EVENT_TOUCH
=
"觸摸->"
;
public
static
final
String
EVENT_SCOLL
=
"滑動->"
;
public
static
final
String
EVENT_SCOLL
=
"滑動->"
;
public
static
final
String
EVENT_RETRY
=
"重試加載->"
;
public
static
final
String
EVENT_RETRY
=
"重試加載->"
;
...
@@ -84,6 +87,14 @@ public class LoganManager {
...
@@ -84,6 +87,14 @@ public class LoganManager {
public
static
final
String
EVENT_MODIFY
=
"修改->"
;
public
static
final
String
EVENT_MODIFY
=
"修改->"
;
public
static
final
String
EVENT_QUERY
=
"查詢->"
;
public
static
final
String
EVENT_QUERY
=
"查詢->"
;
public
static
void
w_login
(
String
TAG
,
String
...
eventAndLog
)
{
w_business
(
LOGIN_BUSINESS_TAG
,
TAG
,
eventAndLog
);
}
public
static
void
w_home
(
String
TAG
,
String
...
eventAndLog
)
{
w_business
(
HOME_BUSINESS_TAG
,
TAG
,
eventAndLog
);
}
public
static
void
w_database
(
String
TAG
,
String
...
eventAndLog
)
{
public
static
void
w_database
(
String
TAG
,
String
...
eventAndLog
)
{
w_business
(
DATABASE_BUSINESS_TAG
,
TAG
,
eventAndLog
);
w_business
(
DATABASE_BUSINESS_TAG
,
TAG
,
eventAndLog
);
}
}
...
...
library-common/src/main/java/com/gingersoft/gsa/cloud/common/printer/PrinterFileUtils.java
View file @
5cf2e2a2
package
com
.
gingersoft
.
gsa
.
cloud
.
common
.
printer
;
package
com
.
gingersoft
.
gsa
.
cloud
.
common
.
printer
;
import
android.graphics.Bitmap
;
import
android.graphics.Bitmap
;
import
android.os.Environment
;
import
android.text.TextUtils
;
import
android.text.TextUtils
;
import
com.gingersoft.gsa.cloud.app.GsaCloudApplication
;
import
com.gingersoft.gsa.cloud.common.constans.PrintConstans
;
import
com.gingersoft.gsa.cloud.common.constans.PrintConstans
;
import
com.gingersoft.gsa.cloud.common.logan.LoganManager
;
import
com.gingersoft.gsa.cloud.common.logan.LoganManager
;
import
com.gingersoft.gsa.cloud.common.utils.FileUtils
;
import
com.gingersoft.gsa.cloud.common.utils.FileUtils
;
...
...
library-common/src/main/java/com/gingersoft/gsa/cloud/common/utils/FileUtils.java
View file @
5cf2e2a2
...
@@ -63,38 +63,6 @@ public class FileUtils {
...
@@ -63,38 +63,6 @@ public class FileUtils {
public
final
static
String
ERRORLOG_PATH
=
LOG_PATH
+
ErrorLog
+
File
.
separator
;
public
final
static
String
ERRORLOG_PATH
=
LOG_PATH
+
ErrorLog
+
File
.
separator
;
public
final
static
String
APK_PATH
=
Environment
.
getExternalStorageDirectory
()
+
File
.
separator
+
APK
+
File
.
separator
;
public
final
static
String
APK_PATH
=
Environment
.
getExternalStorageDirectory
()
+
File
.
separator
+
APK
+
File
.
separator
;
/**
* 打印前圖片存儲路徑
*/
// public final static class PrinterImagePath {
// //Prj圖片文件最大文件大小不能超過100M
// public static final int PRINTER_MAX_FILE_SIZE = 100 * 1024 * 1024;
// //Prj最少保留文件大小
// public static final int PRINTER_KEEP_FILE_SIZE = 20 * 1024 * 1024;
//
// public static String PrinterImagesRootPath = "PrinterImages";
// public static String KitchenImage = "KitchenImages";
// public static String PrintOrderImage = "PrintOrderImages";
// public static String BillImage = "BillImages";
// public static String ServingPaperImage = "ServingPaperImages";
// public static String DeliveryPrintOrderImage = "DeliveryPrintOrderImages";
// public static String DeliveryBillImage = "DeliveryBillImages";
// public static String QrcodeImage = "QrcodeImages";
// public static String SettlementImage = "SettlementImages";
//
// public final static String ROOT_PATH = ALBUM_PATH + PrinterImagesRootPath + File.separator;
// public final static String KITCHEN_PRJ_IMAGE_PATH = ROOT_PATH + KitchenImage + File.separator;
// public final static String PRINT_ORDER_IMAGE_PATH = ROOT_PATH + PrintOrderImage + File.separator;
// public final static String BILL_IMAGE_PATH = ROOT_PATH + BillImage + File.separator;
// public final static String SERVING_PAPER_IMAGE_PATH = ROOT_PATH + ServingPaperImage + File.separator;
// public final static String DELIVERY_PRINT_ORDER_IMAGE_PATH = ROOT_PATH + DeliveryPrintOrderImage + File.separator;
// public final static String DELIVERY_BILL_IMAGE_PATH = ROOT_PATH + DeliveryBillImage + File.separator;
// public final static String QRCODE_IMAGE_PATH = ROOT_PATH + QrcodeImage + File.separator;
// public final static String SETTLEMENT_IMAGE_PATH = ROOT_PATH + SettlementImage + File.separator;
// }
public
final
static
String
FILE_EXTENSION_SEPARATOR
=
"."
;
//操作日志單最大文件大小
//操作日志單最大文件大小
public
final
static
int
ACTION_MAX_SIZE
=
1024
*
1024
*
5
;
public
final
static
int
ACTION_MAX_SIZE
=
1024
*
1024
*
5
;
//操作日志文件按照時間刪除
//操作日志文件按照時間刪除
...
@@ -246,7 +214,6 @@ public class FileUtils {
...
@@ -246,7 +214,6 @@ public class FileUtils {
inStream
.
close
();
inStream
.
close
();
return
outStream
.
toString
();
return
outStream
.
toString
();
}
catch
(
IOException
e
)
{
}
catch
(
IOException
e
)
{
XLog
.
tag
(
"FileTest"
).
d
(
e
.
getMessage
());
}
}
return
null
;
return
null
;
}
}
...
...
library-common/src/main/java/com/gingersoft/gsa/cloud/common/utils/crash/AppCrashHandler.java
View file @
5cf2e2a2
...
@@ -234,13 +234,11 @@ public class AppCrashHandler implements UncaughtExceptionHandler {
...
@@ -234,13 +234,11 @@ public class AppCrashHandler implements UncaughtExceptionHandler {
LogUtil
.
d
(
TAG
,
"delete result : "
+
delete
);
LogUtil
.
d
(
TAG
,
"delete result : "
+
delete
);
}
}
}
}
XLog
.
d
(
TAG
,
"sendFileMultipart onNext: "
+
data
);
}
}
}
}
@Override
@Override
public
void
onError
(
Throwable
t
)
{
public
void
onError
(
Throwable
t
)
{
XLog
.
d
(
TAG
,
"sendFileMultipart onError: "
+
t
.
getMessage
());
}
}
@Override
@Override
...
...
library-print/src/main/java/com/gingersoft/gsa/cloud/print/PrintSocketHolder.java
View file @
5cf2e2a2
...
@@ -18,13 +18,10 @@ package com.gingersoft.gsa.cloud.print;
...
@@ -18,13 +18,10 @@ package com.gingersoft.gsa.cloud.print;
import
android.bluetooth.BluetoothDevice
;
import
android.bluetooth.BluetoothDevice
;
import
android.bluetooth.BluetoothSocket
;
import
android.bluetooth.BluetoothSocket
;
import
com.elvishew.xlog.XLog
;
import
com.gingersoft.gsa.cloud.common.constans.PrintConstans
;
import
com.gingersoft.gsa.cloud.common.constans.PrintConstans
;
import
com.gingersoft.gsa.cloud.common.logan.LoganManager
;
import
com.gingersoft.gsa.cloud.common.logan.LoganManager
;
import
com.gingersoft.gsa.cloud.common.printer.plugins.PrinterPlugins
;
import
com.gingersoft.gsa.cloud.common.printer.plugins.PrinterPlugins
;
import
com.gingersoft.gsa.cloud.database.bean.PrinterDeviceBean
;
import
com.gingersoft.gsa.cloud.database.bean.PrinterDeviceBean
;
import
java.io.IOException
;
import
java.io.IOException
;
import
java.io.OutputStream
;
import
java.io.OutputStream
;
import
java.lang.ref.WeakReference
;
import
java.lang.ref.WeakReference
;
...
...
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