Showing
4 changed files
with
150 additions
and
57 deletions
static/sass/me/_address.scss
0 → 100644
1 | +.my-address-page { | ||
2 | + position: absolute; | ||
3 | + bottom: 0; | ||
4 | + top: pxToRem(90px); | ||
5 | + background: #f0f0f0; | ||
6 | + | ||
7 | + .address-item { | ||
8 | + padding: pxToRem(20px) pxToRem(30px); | ||
9 | + color: #b0b0b0; | ||
10 | + background: #fff; | ||
11 | + border-bottom: 1px solid #e0e0e0; | ||
12 | + | ||
13 | + .name, .tel { | ||
14 | + font-size: pxToRem(30px); | ||
15 | + line-height: pxToRem(56px); | ||
16 | + color: #444; | ||
17 | + font-weight: bold; | ||
18 | + } | ||
19 | + | ||
20 | + .tel { | ||
21 | + float: right; | ||
22 | + } | ||
23 | + | ||
24 | + .address-info { | ||
25 | + font-size: pxToRem(24px); | ||
26 | + line-height: pxToRem(38px); | ||
27 | + } | ||
28 | + | ||
29 | + .action { | ||
30 | + font-size: pxToRem(28px); | ||
31 | + line-height: pxToRem(40px); | ||
32 | + text-align: right; | ||
33 | + | ||
34 | + .edit { | ||
35 | + margin-right: pxToRem(30px); | ||
36 | + } | ||
37 | + } | ||
38 | + } | ||
39 | + | ||
40 | + .add-address { | ||
41 | + display: block; | ||
42 | + margin-top: pxToRem(30px); | ||
43 | + font-size: pxToRem(32px); | ||
44 | + line-height: pxToRem(88px); | ||
45 | + color: #444; | ||
46 | + background: #fff; | ||
47 | + text-align: center; | ||
48 | + font-weight: bold; | ||
49 | + border-top: 1px solid #e0e0e0; | ||
50 | + border-bottom: 1px solid #e0e0e0; | ||
51 | + } | ||
52 | + | ||
53 | + .confim-mask { | ||
54 | + position: fixed; | ||
55 | + width: 100%; | ||
56 | + height: 100%; | ||
57 | + left: 0; | ||
58 | + top: 0; | ||
59 | + background: rgba(0, 0, 0, .5); | ||
60 | + z-index: 5; | ||
61 | + } | ||
62 | + | ||
63 | + .confim-box { | ||
64 | + position: absolute; | ||
65 | + left: 50%; | ||
66 | + top: 50%; | ||
67 | + margin-left: pxToRem(-270px); | ||
68 | + margin-top: pxToRem(-144px); | ||
69 | + width: pxToRem(540px); | ||
70 | + text-align: center; | ||
71 | + color: #444; | ||
72 | + background: #fff; | ||
73 | + font-size: pxToRem(32px); | ||
74 | + font-weight: bold; | ||
75 | + border-radius: pxToRem(10px); | ||
76 | + | ||
77 | + .content { | ||
78 | + line-height: pxToRem(200px); | ||
79 | + } | ||
80 | + | ||
81 | + .action { | ||
82 | + line-height: pxToRem(88px); | ||
83 | + border-top: 1px solid #e0e0e0; | ||
84 | + | ||
85 | + span { | ||
86 | + display: inline-block; | ||
87 | + width: pxToRem(260px); | ||
88 | + | ||
89 | + &:first-child { | ||
90 | + border-right: 1px solid #e0e0e0; | ||
91 | + } | ||
92 | + } | ||
93 | + } | ||
94 | + | ||
95 | + .confim { | ||
96 | + color: #d0021b; | ||
97 | + } | ||
98 | + } | ||
99 | +} |
1 | {{> layout/header}} | 1 | {{> layout/header}} |
2 | <div class="my-address-page yoho-page"> | 2 | <div class="my-address-page yoho-page"> |
3 | + <div class="address-item"> | ||
4 | + <span class="name">张三</span> | ||
5 | + <span class="tel">13509877890</span> | ||
6 | + <p class="address-info">发的就看过环境是电话是多少姐发的就看过环境是电话是多少姐</p> | ||
7 | + <div class="action iconfont"> | ||
8 | + <span class="edit"></span> | ||
9 | + <span class="del"></span> | ||
10 | + </div> | ||
11 | + </div> | ||
12 | + <div class="address-item"> | ||
13 | + <span class="name">张三</span> | ||
14 | + <span class="tel">13509877890</span> | ||
15 | + <p class="address-info">发的就看过环境是电话是多少姐发的就看过环境是电话是多少姐</p> | ||
16 | + <div class="action iconfont"> | ||
17 | + <span class="edit"></span> | ||
18 | + <span class="del"></span> | ||
19 | + </div> | ||
20 | + </div> | ||
3 | 21 | ||
22 | + <a class="add-address"> | ||
23 | + 添加新地址 | ||
24 | + </a> | ||
25 | + | ||
26 | + <div class="confim-mask hide"> | ||
27 | + <div class="confim-box"> | ||
28 | + <div class="content"> | ||
29 | + 你确定要删除地址吗? | ||
30 | + </div> | ||
31 | + <div class="action"> | ||
32 | + <span class="cencel"> | ||
33 | + 取消 | ||
34 | + </span> | ||
35 | + <span class="confim"> | ||
36 | + 确认 | ||
37 | + </span> | ||
38 | + </div> | ||
39 | + </div> | ||
40 | + </div> | ||
4 | </div> | 41 | </div> |
5 | {{> layout/footer}} | 42 | {{> layout/footer}} |
@@ -34,60 +34,6 @@ class HomeController extends AbstractAction | @@ -34,60 +34,6 @@ class HomeController extends AbstractAction | ||
34 | $data['recommendForYou'] = \Index\UserModel::getPreferenceData($channel); | 34 | $data['recommendForYou'] = \Index\UserModel::getPreferenceData($channel); |
35 | // print_r($data); | 35 | // print_r($data); |
36 | 36 | ||
37 | - $data['homeHeader'] = array( | ||
38 | - 'myHomePage' => true, | ||
39 | - 'searchUrl' => Helpers::url('/search', null, 'search') | ||
40 | - ); | ||
41 | - | ||
42 | - /*$data['recommendForYou'] = array( | ||
43 | - 'recommendList' => array( | ||
44 | - array( | ||
45 | - 'img' => '', | ||
46 | - 'salePrice' => '567.44', | ||
47 | - 'oldPrice' => '876.44' | ||
48 | - ), | ||
49 | - array( | ||
50 | - 'img' => '', | ||
51 | - 'salePrice' => '567.44', | ||
52 | - 'oldPrice' => '' | ||
53 | - ), | ||
54 | - array( | ||
55 | - 'img' => '', | ||
56 | - 'salePrice' => '567.44', | ||
57 | - 'oldPrice' => '876.44' | ||
58 | - ), | ||
59 | - array( | ||
60 | - 'img' => '', | ||
61 | - 'salePrice' => '567.44', | ||
62 | - 'oldPrice' => '876.44' | ||
63 | - ), | ||
64 | - array( | ||
65 | - 'img' => '', | ||
66 | - 'salePrice' => '567.44', | ||
67 | - 'oldPrice' => '876.44' | ||
68 | - ), | ||
69 | - array( | ||
70 | - 'img' => '', | ||
71 | - 'salePrice' => '567.44', | ||
72 | - 'oldPrice' => '876.44' | ||
73 | - ), | ||
74 | - array( | ||
75 | - 'img' => '', | ||
76 | - 'salePrice' => '567.44', | ||
77 | - 'oldPrice' => '876.44' | ||
78 | - ), | ||
79 | - array( | ||
80 | - 'img' => '', | ||
81 | - 'salePrice' => '567.44', | ||
82 | - 'oldPrice' => '876.44' | ||
83 | - ), | ||
84 | - array( | ||
85 | - 'img' => '', | ||
86 | - 'salePrice' => '567.44', | ||
87 | - 'oldPrice' => '876.44' | ||
88 | - ) | ||
89 | - ) | ||
90 | - );*/ | ||
91 | $data['myIndexPage'] = true; | 37 | $data['myIndexPage'] = true; |
92 | $data['pageFooter'] = true; | 38 | $data['pageFooter'] = true; |
93 | 39 | ||
@@ -245,11 +191,22 @@ class HomeController extends AbstractAction | @@ -245,11 +191,22 @@ class HomeController extends AbstractAction | ||
245 | */ | 191 | */ |
246 | public function addressAction() | 192 | public function addressAction() |
247 | { | 193 | { |
248 | - $uid = $this->getUid(); | 194 | + // 设置网站标题 |
195 | + $this->setTitle('地址管理'); | ||
196 | + $this->setNavHeader('地址管理', true, SITE_MAIN); | ||
197 | + | ||
198 | + // $uid = $this->getUid(); | ||
199 | + $uid = 967016; | ||
249 | 200 | ||
250 | $address = \Index\UserModel::getAddressData($uid); | 201 | $address = \Index\UserModel::getAddressData($uid); |
251 | 202 | ||
252 | - print_r($address); | 203 | + // print_r($address); |
204 | + | ||
205 | + $this->_view->display('address', array( | ||
206 | + 'myIndexPage' => true, | ||
207 | + 'pageFooter' => true, | ||
208 | + 'address' => $address | ||
209 | + )); | ||
253 | } | 210 | } |
254 | 211 | ||
255 | /** | 212 | /** |
-
Please register or login to post a comment