Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
S
safetcut-app
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Registry
Registry
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
1
Merge Requests
1
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
atichat
safetcut-app
Commits
50ce3fdc
Commit
50ce3fdc
authored
Oct 04, 2019
by
Tonk
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
update
parent
435cb1a6
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
40 additions
and
7 deletions
+40
-7
components/MeterCard.js
+31
-7
screens/Private/SmartMeterScreen/McbLinkScreen.js
+9
-0
No files found.
components/MeterCard.js
View file @
50ce3fdc
...
...
@@ -40,27 +40,51 @@ const MeterCard = ({ item, onPressEachCard, data, isFocused, ...rest }) => {
]}
/> */
}
{
/* <View style={[styles.meterOnInner, { backgroundColor: breakerStatus === 1 ? 'rgba(65, 204, 0, 0.2)' : 'rgba(223, 0, 0, 0.2)'}]} /> */
}
<
View
style
=
{[
theme
.
centerContainer
,
{
padding
Left
:
1
0
}]}
>
{
item
.
img
?
(
<
View
style
=
{[
theme
.
centerContainer
,
{
padding
:
2
0
}]}
>
{
/* {
item.img ? (
<Image source={{ uri: item.img }} style={styles.meterImgStyle} />
) : (
<View style={[styles.meterImgStyle, { flex: 1, justifyContent: 'center', alignContent: 'center' }]}>
<Text style={{ fontSize: 10 }}>No Img</Text>
</View>
)}
)} */
}
<
View
style
=
{{
backgroundColor
:
color
.
lightGrey
,
flex
:
1
,
aspectRatio
:
1
,
borderRadius
:
8
}}
>
<
View
style
=
{{
width
:
15
,
height
:
15
,
borderRadius
:
100
,
backgroundColor
:
color
.
lightGrey
,
position
:
'absolute'
,
top
:
-
8
,
right
:
-
8
,
alignItems
:
'center'
,
justifyContent
:
'center'
,
}}
>
<
View
style
=
{{
backgroundColor
:
breakerStatus
===
1
?
'#10ca88'
:
'#d8d8d8'
,
width
:
10
,
height
:
10
,
borderRadius
:
100
,
}}
/
>
<
/View
>
<
/View
>
<
/View
>
<
View
style
=
{[
theme
.
containerWithPadding
,
{
flex
:
2
}]}
>
<
View
style
=
{[
theme
.
containerWithPadding
,
{
flex
:
2
,
paddingLeft
:
0
}]}
>
<
Text
style
=
{[
theme
.
smallTitle
]}
>
{
item
.
name
}
<
/Text
>
<
Text
style
=
{[
theme
.
description
,
theme
.
mt1
]}
numberOfLines
=
{
2
}
>
{
item
.
description
||
'No description'
}
<
/Text
>
<
/View
>
<
View
style
=
{[
theme
.
rowContainer
,
{
position
:
'absolute'
,
top
:
10
,
right
:
5
}]}
>
<
View
{
/*
<View
style={[styles.online, { backgroundColor: item.onlineStatus === 1 ? '#10ca88' : color.primary }]}
/
>
/>
*/
}
<
Icon
name
=
{
item
.
isSharing
?
'users'
:
'user'
}
type
=
"FontAwesome"
style
=
{
styles
.
iconStyle
}
/
>
<
Icon
name
=
"wifi"
type
=
"FontAwesome
"
style
=
{
styles
.
iconStyle
}
/
>
<
Icon
name
=
{
item
.
onlineStatus
===
1
?
'wifi'
:
'wifi-off'
}
type
=
"Feather
"
style
=
{
styles
.
iconStyle
}
/
>
<
/View
>
<
/
>
);
...
...
screens/Private/SmartMeterScreen/McbLinkScreen.js
View file @
50ce3fdc
...
...
@@ -460,6 +460,15 @@ class McbLinkScreen extends Component {
borderRadius
:
100
,
marginVertical
:
10
,
marginHorizontal
:
5
,
shadowColor
:
'#000'
,
shadowOffset
:
{
width
:
0
,
height
:
1
,
},
shadowOpacity
:
0.18
,
shadowRadius
:
1.0
,
elevation
:
1
,
},
style
:
{
backgroundColor
:
color
.
defaultBg
},
};
...
...
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