Skip to content
Toggle navigation
P
Projects
G
Groups
S
Snippets
Help
zhangzhonghua
/
BoneHouse_Business_APP
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
0
Merge Requests
0
Pipelines
Wiki
Snippets
Settings
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Commit
96a5af79
authored
Mar 09, 2021
by
wong.peiyi
Browse files
Options
_('Browse Files')
Download
Email Patches
Plain Diff
ios状态栏高度修改
parent
10012595
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
19 additions
and
18 deletions
app/containers/common/StatusBarView.js
app/containers/login/LoginPage.js
app/utils/Utils.js
app/containers/common/StatusBarView.js
View file @
96a5af79
...
...
@@ -4,7 +4,7 @@ import {isIphoneX} from '../../utils/Utils'
import
{
connect
}
from
"react-redux"
;
const
iosStatusBarHeight
=
20
;
const
iosStatusBarXHeight
=
4
4
;
const
iosStatusBarXHeight
=
4
8
;
const
PropTypes
=
require
(
'prop-types'
);
class
StatusBarView
extends
Component
{
...
...
@@ -23,7 +23,6 @@ class StatusBarView extends Component {
render
()
{
let
height
=
0
if
(
Platform
.
OS
==
'ios'
)
{
if
(
this
.
props
.
isReactStackNavigator
)
{
height
=
isIphoneX
()
?
iosStatusBarXHeight
:
iosStatusBarHeight
...
...
@@ -53,4 +52,4 @@ const mapDispatchToProps = (dispatch) => ({
})
export
default
connect
(
mapStateToProps
,
mapDispatchToProps
)(
StatusBarView
)
\ No newline at end of file
export
default
connect
(
mapStateToProps
,
mapDispatchToProps
)(
StatusBarView
)
app/containers/login/LoginPage.js
View file @
96a5af79
...
...
@@ -161,7 +161,7 @@ class LoginPage extends Component{
// this.enterHomePage()
let
{
username
,
password
,
isSubLoding
}
=
this
.
state
// let {global_domain_config} = this.props
// if(global_domain_config.includes("obs.uat.guke.tech")) {
// show('请修改正确域名')
...
...
@@ -300,7 +300,7 @@ class LoginPage extends Component{
activeOpacity
=
{
isSubLoding
?
1
:
.
8
}
>
<
Text
style
=
{
styles
.
btn_text
}
>
{
subTit
}
<
/Text
>
<
/TouchableOpacity
>
<
TouchableOpacity
<
TouchableOpacity
activeOpacity
=
{.
8
}
style
=
{
styles
.
fo_domain_box
}
onPress
=
{()
=>
this
.
handleOpenDomain
()}
...
...
@@ -317,7 +317,7 @@ class LoginPage extends Component{
<
/View
>
<
LodingModel
title
=
{
subTit
}
show
=
{
isSubLoding
}
/
>
<
FillDomainModel
show
=
{
isShowDomain
}
show
=
{
isShowDomain
}
closeModal
=
{()
=>
this
.
handleCloseDomain
()}
callback
=
{(
domainVal
)
=>
this
.
fillDomainCallBack
(
domainVal
)}
domainValue
=
{
tempGlobalDomain
}
...
...
app/utils/Utils.js
View file @
96a5af79
...
...
@@ -50,8 +50,11 @@ export const isEmpty = (data) => {
const
X_WIDTH
=
375
;
const
X_HEIGHT
=
812
;
const
XS_MAX_WIDTH
=
414
;
const
XS_MAX_HEIGHT
=
896
;
const
X_MAX_WIDTH
=
414
;
const
X_MAX_HEIGHT
=
896
;
const
XS_MAX_WIDTH
=
428
;
const
XS_MAX_HEIGHT
=
926
;
const
screenW
=
Dimensions
.
get
(
'window'
).
width
;
const
screenH
=
Dimensions
.
get
(
'window'
).
height
;
...
...
@@ -60,6 +63,7 @@ export const isIphoneX = () => {
return
(
Platform
.
OS
===
'ios'
&&
((
screenH
===
X_HEIGHT
&&
screenW
===
X_WIDTH
)
||
(
screenH
===
X_MAX_HEIGHT
&&
screenW
===
X_MAX_WIDTH
)
||
(
screenH
===
XS_MAX_HEIGHT
&&
screenW
===
XS_MAX_WIDTH
))
)
};
...
...
@@ -182,7 +186,7 @@ export function ascArray(arr, typeName) {
/**
* 引用数组降序排序
* @param {Array} arr 原数组
* @param {String} typeName 排序字段名
* @param {String} typeName 排序字段名
*/
export
function
descArray
(
arr
,
typeName
)
{
if
(
!
arr
.
length
)
{
...
...
@@ -222,7 +226,7 @@ export function referenceArrSort(arr, speciField, typeName, sortType) {
/**
* 调用安卓下载
* @param {String} path
* @param {String} path
*/
export
const
openInstallActivity
=
(
path
)
=>
{
if
(
path
==
null
||
path
.
length
==
0
)
return
;
...
...
@@ -232,7 +236,7 @@ export const openInstallActivity = (path) => {
/**
* 判断数据类型
* @param {any} data
* @param {any} data
*/
export
const
_typeof
=
function
(
data
)
{
try
{
...
...
@@ -247,8 +251,8 @@ export const _typeof = function (data) {
/**
* 接口常见错误提示
* @param {function} dispatch
* @param {object} res
* @param {function} dispatch
* @param {object} res
* @param {function} exitCallback 退出回调
* @param {function} errCallback 错误回调
*/
...
...
@@ -295,8 +299,8 @@ export const showWarnErrorMessage = (dispatch, res, exitCallback, errCallback) =
/**
* 接口异常提示
* @param {function} dispatch
* @param {object} err
* @param {function} dispatch
* @param {object} err
* @param {function} errorCallback 错误回调
* @param {string} logTit 错误打印标题
*/
...
...
@@ -314,4 +318,4 @@ export const showErrorMessage = (dispatch, err, errorCallback, logTit) => {
let
error_msg
=
err
.
error
||
'请求接口错误,请联系管理员!'
show
(
error_msg
);
dispatch
(
errorCallback
());
}
\ No newline at end of file
}
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