Commit 687b9b208bb70cfa52fc97e3be01cdaa0bece373
1 parent
51f0f1dcbf
Exists in
master
and in
2 other branches
首页修改
Showing 7 changed files with 118 additions and 86 deletions
- littleApp_child/app.json
- littleApp_child/pages/articleDetail/articleDetail.wxml
- littleApp_child/pages/articleDetail/articleDetail.wxss
- littleApp_child/pages/articleLists/articleLists.wxml
- littleApp_child/pages/childcare_knowledge/childcare_knowledge.wxml
- littleApp_child/pages/home/home.wxml
- littleApp_child/pages/home/home.wxss
littleApp_child/app.json
View file @
687b9b2
littleApp_child/pages/articleDetail/articleDetail.wxml
View file @
687b9b2
1 | - | |
2 | -<!--顶部红色有头像等信息的栏目--> | |
3 | -<view class="TopBar"> | |
4 | - <!--头像--> | |
5 | - <image class="avatar" bindtap="tapAvatar" src="{{userData.avatar.medium ? userData.avatar.medium : ''}}" background-size="cover"></image> | |
6 | - <!--用户名--> | |
7 | - <text class="userName">{{userData.username}}</text> | |
8 | - <!--下方黑色横条--> | |
9 | - <view class="infoBar"> | |
10 | - <view class="infoView"> | |
11 | - <text class="titleText">体检医院</text> | |
12 | - <text class="timeText">{{userData.checkhospital}}</text> | |
1 | +<view class="backgroundView"> | |
2 | + <!-- <image class="TopBgImage" src=""></image> --> | |
3 | + <!--顶部红色有头像等信息的栏目--> | |
4 | + <view class="TopBar"> | |
5 | + <!--头像--> | |
6 | + <view class="circle_bg"> | |
7 | + <image src="{{userData.avatar.medium ? userData.avatar.medium : ''}}" background-size="cover"></image> | |
8 | + <text>7月1日</text> | |
9 | + <view class="circle_year">2017</view> | |
13 | 10 | </view> |
14 | - <view class="infoView"> | |
15 | - <text class="titleText">月龄</text> | |
16 | - <text class="timeText">{{userData.monthage ? userData.monthage : '-'}}</text> | |
17 | - <view class="lineView"></view> | |
11 | + <!--用户名--> | |
12 | + <text class="userName">{{userData.username}}</text> | |
13 | + <!--下方黑色横条--> | |
14 | + <view class="infoBar"> | |
15 | + <view class="infoView"> | |
16 | + <text class="titleText">出生日期</text> | |
17 | + <text class="timeText">{{userData.checkhospital}}</text> | |
18 | + </view> | |
19 | + <view class="infoView"> | |
20 | + <text class="titleText">月龄</text> | |
21 | + <text class="timeText">{{userData.monthage ? userData.monthage : '0'}}</text> | |
22 | + <view class="lineView"></view> | |
23 | + </view> | |
24 | + <view class="infoView"> | |
25 | + <text class="titleText">健康状况</text> | |
26 | + <text class="timeText">{{userData.hstatus}}</text> | |
27 | + </view> | |
18 | 28 | </view> |
19 | - <view class="infoView"> | |
20 | - <text class="titleText">健康状况</text> | |
21 | - <text class="timeText">{{userData.hstatus}}</text> | |
22 | - </view> | |
29 | + <!--下方黑色横条--> | |
23 | 30 | </view> |
24 | - <!--下方黑色横条--> | |
31 | + <!--医院名称横条--> | |
32 | + <view class="hospitalName" wx:if="{{userData.checkhospital}}">{{userData.checkhospital}}</view> | |
25 | 33 | </view> |
littleApp_child/pages/articleDetail/articleDetail.wxss
View file @
687b9b2
... | ... | @@ -2,6 +2,8 @@ |
2 | 2 | .TopBar { |
3 | 3 | width:100%; |
4 | 4 | height:202px; |
5 | + background: white; | |
6 | + position: relative; | |
5 | 7 | } |
6 | 8 | |
7 | 9 | .promptText { |
8 | 10 | |
9 | 11 | |
10 | 12 | |
... | ... | @@ -12,25 +14,45 @@ |
12 | 14 | color: white; |
13 | 15 | } |
14 | 16 | |
15 | -.TopBgImage { | |
16 | - width:100%; | |
17 | - height:202px; | |
18 | - position: absolute; | |
19 | - background: #48C17B; | |
20 | -} | |
21 | - | |
22 | -.avatar { | |
23 | - width:70px; | |
24 | - height:70px; | |
17 | +.circle_bg { | |
18 | + width:118px; | |
19 | + height:118px; | |
25 | 20 | border-radius: 50%; |
26 | - position: absolute; | |
27 | - top: 15px; | |
28 | - left: 50%; | |
21 | + margin-top: 12px; | |
22 | + margin-left: 50%; | |
29 | 23 | transform: translateX(-50%); |
30 | - border: 3px solid white; | |
31 | - box-shadow: 0 2px 4px 0 rgba(186,70,70,0.50); | |
24 | + border: 1px solid #ededed; | |
25 | + box-shadow: 0 2px 4px 0 rgba(186,70,70,0.5); | |
26 | + | |
27 | + display: flex; | |
28 | + flex-direction: column; | |
29 | + align-items: center; | |
30 | + justify-content: flex-start; | |
31 | + box-sizing: border-box; | |
32 | 32 | } |
33 | 33 | |
34 | +.circle_bg image { | |
35 | + height: 42.6px; | |
36 | + width: 42.6px; | |
37 | + background: rebeccapurple; | |
38 | + margin-top: 13px; | |
39 | +} | |
40 | + | |
41 | +.circle_bg text{ | |
42 | + font-size: 18px; | |
43 | + color: #222222; | |
44 | + letter-spacing: 0; | |
45 | + margin-top: 7.4px; | |
46 | + display: inline-block; | |
47 | + line-height: 18px; | |
48 | + border-bottom: 1px solid #dcdcdc; | |
49 | +} | |
50 | + | |
51 | +.circle_year { | |
52 | + font-size: 13px; | |
53 | + margin-top: 0px; | |
54 | +} | |
55 | + | |
34 | 56 | .userName { |
35 | 57 | font-size: 14px; |
36 | 58 | font-weight: bold; |
37 | 59 | |
38 | 60 | |
39 | 61 | |
40 | 62 | |
41 | 63 | |
42 | 64 | |
43 | 65 | |
44 | 66 | |
45 | 67 | |
46 | 68 | |
47 | 69 | |
... | ... | @@ -40,55 +62,65 @@ |
40 | 62 | /*居中*/ |
41 | 63 | left: 50%; |
42 | 64 | transform: translateX(-50%); |
65 | + color: white; | |
43 | 66 | } |
44 | 67 | |
45 | -.documentView { | |
68 | +/*上方信息条部分*/ | |
69 | +.lineView { | |
70 | + width: 100%; | |
71 | + border-right: solid rgba(255, 255, 255, 0.7) 0.5px; | |
72 | + border-left: solid rgba(255, 255, 255, 0.7) 0.5px; | |
73 | + height: 40px; | |
46 | 74 | position: absolute; |
47 | - top: 0px; | |
48 | - left: 0px; | |
49 | - right: 0px; | |
50 | - bottom: 0px; | |
75 | + top: 10px; | |
51 | 76 | } |
52 | 77 | |
53 | -/*上方信息条部分*/ | |
54 | 78 | .infoBar { |
55 | 79 | width: 100%; |
56 | - height: 60px; | |
57 | - top: 142px; | |
80 | + min-height: 60px; | |
81 | + /* top: 142px; */ | |
82 | + bottom: 0px; | |
58 | 83 | position: absolute; |
84 | + display: flex; | |
85 | + justify-content: space-between; | |
86 | + background: rgba(255, 255, 255, 0.2); | |
59 | 87 | } |
60 | 88 | |
61 | 89 | .infoView { |
62 | 90 | text-align: center; |
63 | 91 | width: 33.3%; |
64 | 92 | height: 100%; |
65 | - display:inline-block; | |
66 | - box-sizing: border-box; | |
67 | 93 | position: relative; |
68 | - background-color: rgba(255, 255, 255, 0.1); | |
69 | 94 | } |
70 | 95 | |
71 | -.lineView { | |
72 | - width: 100%; | |
73 | - border-right: solid rgba(255, 255, 255, 0.7) 0.5px; | |
74 | - border-left: solid rgba(255, 255, 255, 0.7) 0.5px; | |
75 | - height: 40px; | |
76 | - position: absolute; | |
77 | - top: 10px; | |
78 | -} | |
79 | - | |
80 | 96 | .titleText { |
81 | 97 | margin-top: 12px; |
82 | 98 | display:block; |
83 | 99 | font-size: 11px; |
84 | -color: #D8FCE7; | |
100 | + color: #787878; | |
85 | 101 | } |
86 | 102 | |
87 | 103 | .timeText { |
88 | 104 | font-family: PingFangSC-Medium; |
89 | 105 | font-size: 12px; |
90 | - color: #FFFFFF; | |
106 | + color: #4a4a4a; | |
91 | 107 | display:block; |
92 | 108 | margin-top: 2px; |
109 | + overflow: hidden; | |
110 | + text-overflow: ellipsis; | |
111 | + display: -webkit-box; | |
112 | + -webkit-box-orient: vertical; | |
113 | + -webkit-line-clamp: 2; | |
114 | +} | |
115 | + | |
116 | +.hospitalName { | |
117 | + width: 100%; | |
118 | + height: 30px; | |
119 | + background-color: white; | |
120 | + color: #ee7289; | |
121 | + font-size: 11px; | |
122 | + font: medium; | |
123 | + text-align: center; | |
124 | + line-height: 30px; | |
93 | 125 | } |
littleApp_child/pages/articleLists/articleLists.wxml
View file @
687b9b2
... | ... | @@ -16,7 +16,7 @@ |
16 | 16 | </view> |
17 | 17 | <view class="home__list-item__bottom"></view> |
18 | 18 | </navigator> --> |
19 | - <navigator url="../childcare_knowledge_detail/childcare_knowledge_detail?titlle={{'id=' + item.id + '&category=' + category}}" wx:for="{{list}}" wx:key="{{index}}"> | |
19 | + <navigator url="../childcare_knowledge_detail/childcare_knowledge_detail?{{'id=' + item.id + '&category=' + category}}" wx:for="{{list}}" wx:key="{{index}}"> | |
20 | 20 | <view class="content_item"> |
21 | 21 | <view style="margin-left:15px;margin-right:75px;"> |
22 | 22 | <view class="content_title">{{item.title}}</view> |
littleApp_child/pages/childcare_knowledge/childcare_knowledge.wxml
View file @
687b9b2
... | ... | @@ -22,7 +22,7 @@ |
22 | 22 | </swiper> --> |
23 | 23 | <image class="swiper" mode="aspectFill" src="{{images.medium}}"></image> |
24 | 24 | <view> |
25 | - <navigator url="../childcare_knowledge_detail/childcare_knowledge_detail" wx:for="{{list}}" wx:key="{{index}}"> | |
25 | + <navigator url="../childcare_knowledge_detail/childcare_knowledge_detail?{{'id=' + item.id + '&category=' + category}}" wx:for="{{list}}" wx:key="{{index}}"> | |
26 | 26 | <view class="content_item"> |
27 | 27 | <view style="margin-left:15px;margin-right:75px;"> |
28 | 28 | <view class="content_title">{{item.title}}</view> |
littleApp_child/pages/home/home.wxml
View file @
687b9b2
... | ... | @@ -5,7 +5,7 @@ |
5 | 5 | </view> |
6 | 6 | <!--首页模块--> |
7 | 7 | <view class="backgroundView" wx:if="{{pageType == 2}}"> |
8 | - <image class="TopBgImage" src=""></image> | |
8 | + <!-- <image class="TopBgImage" src=""></image> --> | |
9 | 9 | <!--顶部红色有头像等信息的栏目--> |
10 | 10 | <view class="TopBar"> |
11 | 11 | <!--头像--> |
... | ... | @@ -15,7 +15,7 @@ |
15 | 15 | <!--下方黑色横条--> |
16 | 16 | <view class="infoBar"> |
17 | 17 | <view class="infoView"> |
18 | - <text class="titleText">体检医院</text> | |
18 | + <text class="titleText">出生日期</text> | |
19 | 19 | <text class="timeText">{{userData.checkhospital}}</text> |
20 | 20 | </view> |
21 | 21 | <view class="infoView"> |
... | ... | @@ -31,7 +31,7 @@ |
31 | 31 | <!--下方黑色横条--> |
32 | 32 | </view> |
33 | 33 | <!--医院名称横条--> |
34 | - <view class="hospitalName" wx:if="{{hospitalName}}">{{hospitalName}}</view> | |
34 | + <view class="hospitalName" wx:if="{{userData.checkhospital}}">{{userData.checkhospital}}</view> | |
35 | 35 | <!--功能模块--> |
36 | 36 | <view class="foundation_BG" style="{{item_big_height}}"> |
37 | 37 | <!-- <navigator class="foundation_item_small" url="../inspectionReport/inspectionReport"> |
littleApp_child/pages/home/home.wxss
View file @
687b9b2
... | ... | @@ -6,6 +6,8 @@ |
6 | 6 | .TopBar { |
7 | 7 | width:100%; |
8 | 8 | height:202px; |
9 | + background: #48C17B; | |
10 | + position: relative; | |
9 | 11 | } |
10 | 12 | |
11 | 13 | .promptText { |
12 | 14 | |
... | ... | @@ -16,12 +18,12 @@ |
16 | 18 | color: white; |
17 | 19 | } |
18 | 20 | |
19 | -.TopBgImage { | |
21 | +/* .TopBgImage { | |
20 | 22 | width:100%; |
21 | 23 | height:202px; |
22 | 24 | position: absolute; |
23 | 25 | background: #48C17B; |
24 | -} | |
26 | +} */ | |
25 | 27 | |
26 | 28 | .avatar { |
27 | 29 | width:70px; |
... | ... | @@ -47,14 +49,6 @@ |
47 | 49 | color: white; |
48 | 50 | } |
49 | 51 | |
50 | -.documentView { | |
51 | - position: absolute; | |
52 | - top: 0px; | |
53 | - left: 0px; | |
54 | - right: 0px; | |
55 | - bottom: 0px; | |
56 | -} | |
57 | - | |
58 | 52 | /*上方信息条部分*/ |
59 | 53 | |
60 | 54 | .lineView { |
61 | 55 | |
62 | 56 | |
63 | 57 | |
... | ... | @@ -69,20 +63,19 @@ |
69 | 63 | .infoBar { |
70 | 64 | width: 100%; |
71 | 65 | min-height: 60px; |
72 | - /* top: 142px; */ | |
73 | - bottom: 0px; | |
66 | + /* top: 142px; */ | |
67 | + bottom: 0px; | |
74 | 68 | position: absolute; |
69 | + display: flex; | |
70 | + justify-content: space-between; | |
71 | + background: rgba(255, 255, 255, 0.1); | |
75 | 72 | } |
76 | 73 | |
77 | 74 | .infoView { |
78 | 75 | text-align: center; |
79 | 76 | width: 33.3%; |
80 | 77 | height: 100%; |
81 | - display:inline-block; | |
82 | - box-sizing: border-box; | |
83 | 78 | position: relative; |
84 | - background-color: rgba(255, 255, 255, 0.1); | |
85 | - background: green; | |
86 | 79 | } |
87 | 80 | |
88 | 81 | .titleText { |
89 | 82 | |
90 | 83 | |
91 | 84 | |
... | ... | @@ -90,21 +83,19 @@ |
90 | 83 | display:block; |
91 | 84 | font-size: 11px; |
92 | 85 | color: #D8FCE7; |
93 | - background: red; | |
94 | 86 | } |
95 | 87 | |
96 | 88 | .timeText { |
97 | - background: rebeccapurple; | |
98 | 89 | font-family: PingFangSC-Medium; |
99 | 90 | font-size: 12px; |
100 | 91 | color: #FFFFFF; |
101 | 92 | display:block; |
102 | 93 | margin-top: 2px; |
103 | - /* overflow: hidden; | |
94 | + overflow: hidden; | |
104 | 95 | text-overflow: ellipsis; |
105 | 96 | display: -webkit-box; |
106 | 97 | -webkit-box-orient: vertical; |
107 | - -webkit-line-clamp: 1; */ | |
98 | + -webkit-line-clamp: 2; | |
108 | 99 | } |
109 | 100 | |
110 | 101 | .hospitalName { |
... | ... | @@ -116,7 +107,6 @@ |
116 | 107 | font: medium; |
117 | 108 | text-align: center; |
118 | 109 | line-height: 30px; |
119 | - | |
120 | 110 | } |
121 | 111 | |
122 | 112 | /*---------foundation---------*/ |
... | ... | @@ -208,6 +198,7 @@ |
208 | 198 | font-size: 14px; |
209 | 199 | color: #222222; |
210 | 200 | margin-left: 15px; |
201 | + margin-right: 85px; | |
211 | 202 | margin-top: 0px; |
212 | 203 | overflow: hidden; |
213 | 204 | text-overflow: ellipsis; |