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
e8e904bd
Commit
e8e904bd
authored
May 14, 2021
by
Wyh
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
1、去掉PrjService的wakeDisposable定時 2、修復供應鏈入庫單刷新問題
parent
7b55a06f
Hide whitespace changes
Inline
Side-by-side
Showing
13 changed files
with
189 additions
and
21 deletions
+189
-21
build.gradle
+2
-2
component-login/build.gradle
+15
-1
component-login/proguard.cfg
+3
-0
component-login/src/main/java/com/gingersoft/gsa/cloud/login/mvp/ui/activity/WelcomeActivity.java
+1
-1
component-print/src/main/java/com/joe/print/mvp/print/service/PrjService.java
+12
-8
component-supply-chain/src/main/java/com/gingersoft/supply_chain/mvp/presenter/WarehousingOrderDetailsPresenter.java
+2
-0
component-supply-chain/src/main/java/com/gingersoft/supply_chain/mvp/ui/fragment/FunctionListFragment.java
+12
-0
component-supply-chain/src/main/java/com/gingersoft/supply_chain/mvp/ui/fragment/warehouse/WarehousingOrderListFragment.java
+4
-4
component-supply-chain/src/main/java/com/gingersoft/supply_chain/mvp/ui/widget/UpdateRestaurantInfoPop.java
+36
-0
component-supply-chain/src/main/res/drawable-xxhdpi/ic_setting.png
+0
-0
component-supply-chain/src/main/res/layout/layout_update_restaurant_info.xml
+99
-0
gradle.properties
+3
-2
library-common/src/main/java/com/gingersoft/gsa/cloud/common/utils/inputFilter/InputFilterUtils.java
+0
-3
No files found.
build.gradle
View file @
e8e904bd
...
...
@@ -5,7 +5,7 @@ buildscript {
repositories
{
maven
{
url
'https://maven.google.com'
}
maven
{
url
'https://maven.aliyun.com/repository/gradle-plugin'
}
//gradle 国内镜像仓
//
maven { url 'https://maven.aliyun.com/repository/gradle-plugin' } //gradle 国内镜像仓
maven
{
url
'https://maven.aliyun.com/repository/google'
}
//google 国内镜像仓
maven
{
url
'https://maven.aliyun.com/repository/jcenter'
}
//jcenter 国内镜像仓
// 添加阿里云 maven 地址
...
...
@@ -38,7 +38,7 @@ buildscript {
allprojects
{
repositories
{
maven
{
url
'https://maven.aliyun.com/repository/gradle-plugin'
}
//gradle 国内镜像仓
//
maven { url 'https://maven.aliyun.com/repository/gradle-plugin' } //gradle 国内镜像仓
maven
{
url
'https://maven.aliyun.com/repository/google'
}
//google 国内镜像仓
maven
{
url
'https://maven.aliyun.com/repository/jcenter'
}
//jcenter 国内镜像仓
...
...
component-login/build.gradle
View file @
e8e904bd
...
...
@@ -37,7 +37,21 @@ android {
}
resourcePrefix
"user_login"
bundle
{
density
{
// Different APKs are generated for devices with different screen densities; true by default.
enableSplit
true
}
abi
{
// Different APKs are generated for devices with different CPU architectures; true by default.
enableSplit
true
}
language
{
// This is disabled so that the App Bundle does NOT split the APK for each language.
// We're gonna use the same APK for all languages.
enableSplit
true
}
}
buildTypes
{
debug
{
buildConfigField
"boolean"
,
"LOG_DEBUG"
,
rootProject
.
ext
.
buildType
[
"debugLogDebug"
]
...
...
component-login/proguard.cfg
View file @
e8e904bd
...
...
@@ -121,3 +121,6 @@
#xpopup
-dontwarn com.lxj.xpopup.widget.**
-keep class com.lxj.xpopup.widget.**{*;}
-keep class me.jessyan.autosize.** { *; }
-keep interface me.jessyan.autosize.** { *; }
component-login/src/main/java/com/gingersoft/gsa/cloud/login/mvp/ui/activity/WelcomeActivity.java
View file @
e8e904bd
...
...
@@ -132,7 +132,7 @@ public class WelcomeActivity extends LoginInterfaceImpl<WelcomePresenter> implem
mPresenter
.
getLoginLimit
(
restaurantId
,
true
);
return
;
}
//
调整
选择餐厅页面
//
跳轉到
选择餐厅页面
Intent
intent
=
new
Intent
(
mContext
,
ChooseRestaurantActivity
.
class
);
Class
clazz
=
WelcomeActivity
.
this
.
getClass
();
intent
.
putExtra
(
"form"
,
clazz
.
getName
());
...
...
component-print/src/main/java/com/joe/print/mvp/print/service/PrjService.java
View file @
e8e904bd
...
...
@@ -199,13 +199,6 @@ public class PrjService extends Service implements ReceiveListener {
LoganManager
.
w_printer
(
TAG
,
"獲取Prj數據 onNext: "
+
prjInfo
);
//請求到數據,停止輪詢,開始打印,在打印完之後再重新開始輪詢
newPrint
(
prjInfo
);
//開啟另一個定時,三十秒之後自動請求,避免上面的打印成功或失敗時沒有回調。
cancel
(
wakeDisposable
);
wakeDisposable
=
RxJavaUtils
.
delay
(
30
,
TimeUnit
.
SECONDS
)
.
subscribe
(
aLong
->
{
LoganManager
.
w_printer
(
TAG
,
"輪詢獲取Prj數據-->"
);
startGetPrjInfo
();
});
}
@Override
...
...
@@ -240,7 +233,9 @@ public class PrjService extends Service implements ReceiveListener {
return
;
}
//有數據,取消輪詢,等待打印結束。
cancel
(
pollDisposable
);
// cancel(pollDisposable);
//開啟另一個定時,六十秒之後自動請求,避免上面的打印成功或失敗時沒有回調。
// startBplan();
//第一步:解析PRJ數據,格式為 Map<廚房位置,需要打印的數據>
try
{
JSONObject
jsonObject
=
new
JSONObject
(
GsonUtils
.
GsonString
(
prjBean
.
getData
()));
...
...
@@ -270,6 +265,15 @@ public class PrjService extends Service implements ReceiveListener {
foreachPrint
(
listMap
,
getPrinterDevices
());
}
// private void startBplan() {
// cancel(wakeDisposable);
// wakeDisposable = RxJavaUtils.delay(60, TimeUnit.SECONDS)
// .subscribe(aLong -> {
// LoganManager.w_printer(TAG, "輪詢獲取Prj數據-->");
// startGetPrjInfo();
// });
// }
/**
* 計算出prj總數
*
...
...
component-supply-chain/src/main/java/com/gingersoft/supply_chain/mvp/presenter/WarehousingOrderDetailsPresenter.java
View file @
e8e904bd
...
...
@@ -326,6 +326,8 @@ public class WarehousingOrderDetailsPresenter extends BasePresenter<WarehousingO
public
void
onNext
(
BaseResult
baseResult
)
{
if
(
baseResult
!=
null
&&
baseResult
.
isSuccess
())
{
mRootView
.
showMessage
(
"入庫成功"
);
//清空購物車
SupplyShoppingCart
.
getInstance
().
clear
();
mRootView
.
addOrderSuccess
();
}
else
if
(
baseResult
!=
null
&&
TextUtil
.
isNotEmptyOrNullOrUndefined
(
baseResult
.
getErrMsg
()))
{
mRootView
.
showMessage
(
baseResult
.
getErrMsg
());
...
...
component-supply-chain/src/main/java/com/gingersoft/supply_chain/mvp/ui/fragment/FunctionListFragment.java
View file @
e8e904bd
...
...
@@ -29,6 +29,9 @@ import com.gingersoft.supply_chain.mvp.ui.fragment.warehouse.SnInOutboundRecords
import
com.gingersoft.supply_chain.mvp.ui.fragment.warehouse.WareHouseListFragment
;
import
com.gingersoft.supply_chain.mvp.ui.fragment.warehouse.WarehousingOrderListFragment
;
import
com.jess.arms.di.component.AppComponent
;
import
com.lxj.xpopup.XPopup
;
import
com.lxj.xpopup.impl.ConfirmPopupView
;
import
com.lxj.xpopup.interfaces.OnConfirmListener
;
import
com.qmuiteam.qmui.widget.QMUITopBar
;
import
java.util.ArrayList
;
...
...
@@ -98,6 +101,7 @@ public class FunctionListFragment extends BaseSupplyChainFragment<FunctionListPr
storage
.
add
(
new
Function
(
"SN查詢"
,
R
.
drawable
.
ic_inventory
));
if
(
BuildConfig
.
DEBUG
)
{
storage
.
add
(
new
Function
(
"切換環境"
,
R
.
drawable
.
ic_seekbar_btn
));
storage
.
add
(
new
Function
(
"設置"
,
R
.
drawable
.
ic_setting
));
}
purchaseFunctionBeans
.
add
(
new
PurchaseFunctionBean
(
"庫存管理"
,
storage
));
...
...
@@ -144,6 +148,14 @@ public class FunctionListFragment extends BaseSupplyChainFragment<FunctionListPr
SPUtils
.
put
(
"isFormal"
,
3
);
}
break
;
case
"設置"
:
ConfirmPopupView
po
=
new
XPopup
.
Builder
(
requireContext
()).
asConfirm
(
"修改餐廳信息"
,
null
,
null
,
null
,
new
OnConfirmListener
()
{
@Override
public
void
onConfirm
()
{
}
},
null
,
false
,
R
.
layout
.
layout_update_restaurant_info
);
break
;
default
:
break
;
...
...
component-supply-chain/src/main/java/com/gingersoft/supply_chain/mvp/ui/fragment/warehouse/WarehousingOrderListFragment.java
View file @
e8e904bd
...
...
@@ -131,11 +131,11 @@ public class WarehousingOrderListFragment extends BaseSupplyChainFragment<Wareho
loadService
.
showCallback
(
EmptyCallback
.
class
);
}
else
{
loadService
.
showSuccess
();
warehousingOrderListAdapter
.
setOnItemClickListener
((
adapter
,
view
,
position
)
->
{
start
(
WarehousingOrderDetailsFragment
.
newInstance
(
warehousingOrderListAdapter
.
getItem
(
position
).
getId
(),
warehousingOrderListAdapter
.
getItem
(
position
).
getStorageType
()));
});
rvSecondCategory
.
setAdapter
(
warehousingOrderListAdapter
);
}
warehousingOrderListAdapter
.
setOnItemClickListener
((
adapter
,
view
,
position
)
->
{
start
(
WarehousingOrderDetailsFragment
.
newInstance
(
warehousingOrderListAdapter
.
getItem
(
position
).
getId
(),
warehousingOrderListAdapter
.
getItem
(
position
).
getStorageType
()));
});
rvSecondCategory
.
setAdapter
(
warehousingOrderListAdapter
);
}
@Override
...
...
component-supply-chain/src/main/java/com/gingersoft/supply_chain/mvp/ui/widget/UpdateRestaurantInfoPop.java
0 → 100644
View file @
e8e904bd
package
com
.
gingersoft
.
supply_chain
.
mvp
.
ui
.
widget
;
import
android.content.Context
;
import
android.view.View
;
import
androidx.annotation.NonNull
;
import
com.gingersoft.supply_chain.R
;
import
com.lxj.xpopup.core.CenterPopupView
;
import
com.lxj.xpopup.impl.ConfirmPopupView
;
/**
* @author 宇航. 1239658231@qq.com
* User: admin
* Date: 2021/5/14
* Time: 12:25
* Use:
*/
public
class
UpdateRestaurantInfoPop
extends
ConfirmPopupView
{
public
UpdateRestaurantInfoPop
(
@NonNull
Context
context
)
{
super
(
context
,
R
.
layout
.
layout_update_restaurant_info
);
}
@Override
protected
void
onCreate
()
{
super
.
onCreate
();
findViewById
(
R
.
id
.
tv_confirm
).
setOnClickListener
(
new
OnClickListener
()
{
@Override
public
void
onClick
(
View
v
)
{
}
});
}
}
component-supply-chain/src/main/res/drawable-xxhdpi/ic_setting.png
0 → 100644
View file @
e8e904bd
3.58 KB
component-supply-chain/src/main/res/layout/layout_update_restaurant_info.xml
0 → 100644
View file @
e8e904bd
<?xml version="1.0" encoding="utf-8"?>
<androidx.constraintlayout.widget.ConstraintLayout
xmlns:android=
"http://schemas.android.com/apk/res/android"
xmlns:app=
"http://schemas.android.com/apk/res-auto"
xmlns:tools=
"http://schemas.android.com/tools"
android:layout_width=
"match_parent"
android:layout_height=
"match_parent"
android:background=
"@drawable/shape_white_eight_corners_bg"
android:padding=
"@dimen/dp_20"
>
<TextView
android:id=
"@+id/tv_title"
android:layout_width=
"wrap_content"
android:layout_height=
"wrap_content"
android:textColor=
"@color/theme_333_color"
android:textSize=
"@dimen/dp_16"
app:layout_constraintLeft_toLeftOf=
"parent"
app:layout_constraintRight_toRightOf=
"parent"
app:layout_constraintTop_toTopOf=
"parent"
tools:text=
"標題"
/>
<TextView
android:id=
"@+id/tv_content"
android:layout_width=
"wrap_content"
android:layout_height=
"wrap_content"
android:layout_marginTop=
"@dimen/dp_10"
android:textColor=
"@color/theme_333_color"
android:textSize=
"@dimen/dp_16"
app:layout_constraintLeft_toLeftOf=
"parent"
app:layout_constraintRight_toRightOf=
"parent"
app:layout_constraintTop_toBottomOf=
"@id/tv_title"
tools:text=
"標題"
/>
<com.google.android.material.textfield.TextInputLayout
android:id=
"@+id/layout_brand_input"
android:layout_width=
"match_parent"
android:layout_height=
"wrap_content"
android:layout_marginTop=
"@dimen/dp_5"
app:layout_constraintLeft_toLeftOf=
"parent"
app:layout_constraintRight_toRightOf=
"parent"
app:layout_constraintTop_toBottomOf=
"@id/tv_content"
>
<com.google.android.material.textfield.TextInputEditText
android:layout_width=
"match_parent"
android:layout_height=
"wrap_content"
android:hint=
"請輸入品牌ID"
android:textColor=
"@color/theme_333_color"
android:textSize=
"@dimen/dp_14"
/>
</com.google.android.material.textfield.TextInputLayout>
<com.google.android.material.textfield.TextInputLayout
android:id=
"@+id/layout_restaurant_input"
android:layout_width=
"match_parent"
android:layout_height=
"wrap_content"
android:layout_marginTop=
"@dimen/dp_5"
app:layout_constraintLeft_toLeftOf=
"parent"
app:layout_constraintRight_toRightOf=
"parent"
app:layout_constraintTop_toBottomOf=
"@id/layout_brand_input"
>
<com.google.android.material.textfield.TextInputEditText
android:layout_width=
"match_parent"
android:layout_height=
"wrap_content"
android:hint=
"請輸入餐廳ID"
android:textColor=
"@color/theme_333_color"
android:textSize=
"@dimen/dp_14"
/>
</com.google.android.material.textfield.TextInputLayout>
<com.qmuiteam.qmui.alpha.QMUIAlphaButton
android:id=
"@+id/tv_confirm"
style=
"@style/Save_Btn_Style"
android:layout_width=
"0dp"
android:layout_height=
"wrap_content"
android:layout_marginTop=
"@dimen/dp_5"
android:layout_marginRight=
"@dimen/dp_5"
android:layout_marginBottom=
"@dimen/dp_5"
android:text=
"確定"
android:visibility=
"visible"
app:layout_constraintHorizontal_weight=
"1"
app:layout_constraintLeft_toLeftOf=
"parent"
app:layout_constraintRight_toLeftOf=
"@id/tv_cancel"
app:layout_constraintTop_toBottomOf=
"@id/layout_restaurant_input"
/>
<com.qmuiteam.qmui.alpha.QMUIAlphaButton
android:id=
"@+id/tv_cancel"
style=
"@style/Cancel_Btn_Style"
android:layout_width=
"0dp"
android:layout_height=
"wrap_content"
android:layout_marginLeft=
"@dimen/dp_20"
android:layout_marginTop=
"@dimen/dp_5"
android:layout_marginBottom=
"@dimen/dp_5"
android:layout_weight=
"1"
android:text=
"取消"
android:visibility=
"visible"
app:layout_constraintHorizontal_weight=
"1"
app:layout_constraintLeft_toRightOf=
"@id/tv_confirm"
app:layout_constraintRight_toRightOf=
"parent"
app:layout_constraintTop_toBottomOf=
"@id/layout_restaurant_input"
/>
</androidx.constraintlayout.widget.ConstraintLayout>
\ No newline at end of file
gradle.properties
View file @
e8e904bd
...
...
@@ -51,4 +51,5 @@ kapt.include.compile.classpath=false
org.gradle.daemon
=
true
org.gradle.jvmargs
=
-Xmx4096m -XX:MaxPermSize=4096m -XX:+HeapDumpOnOutOfMemoryError -Dfile.encoding=UTF-8
org.gradle.parallel
=
true
org.gradle.configureondemand
=
true
\ No newline at end of file
org.gradle.configureondemand
=
true
android.enableAapt2
=
false
\ No newline at end of file
library-common/src/main/java/com/gingersoft/gsa/cloud/common/utils/inputFilter/InputFilterUtils.java
View file @
e8e904bd
...
...
@@ -3,7 +3,6 @@ package com.gingersoft.gsa.cloud.common.utils.inputFilter;
import
android.content.Context
;
import
android.text.Editable
;
import
android.text.InputFilter
;
import
android.text.Spanned
;
import
android.text.TextUtils
;
import
android.text.TextWatcher
;
import
android.util.Log
;
...
...
@@ -14,8 +13,6 @@ import com.gingersoft.gsa.cloud.common.utils.toast.ToastUtils;
import
java.util.regex.Matcher
;
import
java.util.regex.Pattern
;
import
me.jessyan.autosize.utils.LogUtils
;
/**
* @author 宇航.
* User: admin
...
...
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