人人商城

require.html 16KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469
  1. {php define('MUI', true);}
  2. {template 'common/header'}
  3. <div class="mui-content mc-profile activity-exchange">
  4. <div class="mui-table nav">
  5. <a href="javascript:;" class="mui-table-cell mui-active">
  6. 完善资料
  7. </a>
  8. <a href="{php echo url('mc/profile', array('name' => 'fans', 'uniacid' => $_W['uniacid']))}" class="mui-table-cell">
  9. 个人信息
  10. </a>
  11. </div>
  12. <form action="" method="post" enctype="multipart/form-data">
  13. <div class="form-group">
  14. <div style="padding:0 10px;" class="mui-mt15">
  15. <div class="alert-warning" style="padding:10px">
  16. <p><span><i class="fa fa-info-circle"></i>&nbsp;&nbsp;</span>当前系统须完善以下资料才能继续操作 {if !empty($pre)}- {$pre}{/if}</p>
  17. </div>
  18. </div></div>
  19. <div class="mui-input-group mui-mt15">
  20. {if isset($profile['avatar'])}
  21. {php echo tpl_app_form_field_avatar('avatar', $profile['avatar']);}
  22. {/if}
  23. {if isset($profile['nickname'])}
  24. <div class="mui-input-row">
  25. <label>{$system_fields['nickname']['title']}</label>
  26. {php echo tpl_app_fans_form('nickname', $profile['nickname'], $system_fields['nickname']['title']);}
  27. </div>
  28. {/if}
  29. {if isset($profile['realname'])}
  30. <div class="mui-input-row">
  31. <label>{$system_fields['realname']['title']}</label>
  32. {php echo tpl_app_fans_form('realname', $profile['realname'], $system_fields['realname']['title']);}
  33. </div>
  34. {/if}
  35. {if isset($profile['gender'])}
  36. <div class="mui-input-row">
  37. <label>{$system_fields['gender']['title']}</label>
  38. {php echo tpl_app_fans_form('gender', $profile['gender'], $system_fields['gender']['title']);}
  39. </div>
  40. {/if}
  41. {if isset($profile['birthyear'])}
  42. <div class="mui-input-row">
  43. <label>{$system_fields['birthyear']['title']}</label>
  44. {php echo tpl_app_fans_form('birth', array('year' => $profile['birthyear'], 'month' => $profile['birthmonth'], 'day' => $profile['birthday']), $system_fields['birthyear']['title']);}
  45. </div>
  46. {/if}
  47. {if isset($profile['resideprovince'])}
  48. <div class="mui-input-row">
  49. <label>{$system_fields['resideprovince']['title']}</label>
  50. {php echo tpl_app_fans_form('reside', array('province' => $profile['resideprovince'], 'city' => $profile['residecity'], 'district' => $profile['residedist']), $system_fields['resideprovince']['title']);}
  51. </div>
  52. {/if}
  53. {if isset($profile['address'])}
  54. <div class="mui-input-row">
  55. <label>{$system_fields['address']['title']}</label>
  56. {php echo tpl_app_fans_form('address',$profile['address'], $system_fields['address']['title']);}
  57. </div>
  58. {/if}
  59. {if isset($profile['mobile'])}
  60. <div class="mui-input-row">
  61. <label>{$system_fields['mobile']['title']}</label>
  62. {if !empty($profile['mobile'])}
  63. <input type="text" readonly name="mobile" value="{$profile['mobile']}">
  64. {else}
  65. {php echo tpl_app_fans_form('mobile',$profile['mobile'], $system_fields['mobile']['title']);}
  66. {/if}
  67. </div>
  68. {/if}
  69. {if isset($profile['qq'])}
  70. <div class="mui-input-row">
  71. <label>{$system_fields['qq']['title']}</label>
  72. {php echo tpl_app_fans_form('qq', $profile['qq'], $system_fields['qq']['title']);}
  73. </div>
  74. {/if}
  75. {if isset($profile['email'])}
  76. <div class="mui-input-row">
  77. <label>{$system_fields['email']['title']}</label>
  78. {if !empty($profile['email'])}
  79. <input type="text" readonly name="email" value="{$profile['email']}">
  80. {else}
  81. {php echo tpl_app_fans_form('email',$profile['email'], $system_fields['email']['title']);}
  82. {/if}
  83. </div>
  84. {/if}
  85. {if isset($profile['telephone'])}
  86. <div class="mui-input-row">
  87. <label>{$system_fields['telephone']['title']}</label>
  88. {php echo tpl_app_fans_form('telephone', $profile['telephone'], $system_fields['telephone']['title']);}
  89. </div>
  90. {/if}
  91. {if isset($profile['msn'])}
  92. <div class="mui-input-row">
  93. <label>{$system_fields['msn']['title']}</label>
  94. {php echo tpl_app_fans_form('msn', $profile['msn'], $system_fields['msn']['title']);}
  95. </div>
  96. {/if}
  97. {if isset($profile['taobao'])}
  98. <div class="mui-input-row">
  99. <label>{$system_fields['taobao']['title']}</label>
  100. {php echo tpl_app_fans_form('taobao', $profile['taobao'], $system_fields['taobao']['title']);}
  101. </div>
  102. {/if}
  103. {if isset($profile['alipay'])}
  104. <div class="mui-input-row">
  105. <label>{$system_fields['alipay']['title']}</label>
  106. {php echo tpl_app_fans_form('alipay', $profile['alipay'], $system_fields['alipay']['title']);}
  107. </div>
  108. {/if}
  109. {if isset($profile['studentid'])}
  110. <div class="mui-input-row">
  111. <label>{$system_fields['studentid']['title']}</label>
  112. {php echo tpl_app_fans_form('studentid', $profile['studentid'], $system_fields['studentid']['title']);}
  113. </div>
  114. {/if}
  115. {if isset($profile['graduateschool'])}
  116. <div class="mui-input-row">
  117. <label>{$system_fields['graduateschool']['title']}</label>
  118. {php echo tpl_app_fans_form('graduateschool', $profile['graduateschool'], $system_fields['graduateschool']['title']);}
  119. </div>
  120. {/if}
  121. {if isset($profile['education'])}
  122. <div class="mui-input-row">
  123. <label>{$system_fields['education']['title']}</label>
  124. {php echo tpl_app_fans_form('education', $profile['education'],$system_fields['education']['title']);}
  125. </div>
  126. {/if}
  127. {if isset($profile['company'])}
  128. <div class="mui-input-row">
  129. <label>{$system_fields['company']['title']}</label>
  130. {php echo tpl_app_fans_form('company', $profile['company'], $system_fields['company']['title']);}
  131. </div>
  132. {/if}
  133. {if isset($profile['occupation'])}
  134. <div class="mui-input-row">
  135. <label>{$system_fields['occupation']['title']}</label>
  136. {php echo tpl_app_fans_form('occupation', $profile['occupation'], $system_fields['occupation']['title']);}
  137. </div>
  138. {/if}
  139. {if isset($profile['position'])}
  140. <div class="mui-input-row">
  141. <label>{$system_fields['position']['title']}</label>
  142. {php echo tpl_app_fans_form('position', $profile['position'], $system_fields['position']['title']);}
  143. </div>
  144. {/if}
  145. {if isset($profile['revenue'])}
  146. <div class="mui-input-row">
  147. <label>{$system_fields['revenue']['title']}</label>
  148. {php echo tpl_app_fans_form('revenue', $profile['revenue'], $system_fields['revenue']['title']);}
  149. </div>
  150. {/if}
  151. {if isset($profile['constellation'])}
  152. <div class="mui-input-row">
  153. <label>{$system_fields['constellation']['title']}</label>
  154. {php echo tpl_app_fans_form('constellation', $profile['constellation'], $system_fields['constellation']['title']);}
  155. </div>
  156. {/if}
  157. {if isset($profile['zodiac'])}
  158. <div class="mui-input-row">
  159. <label>{$system_fields['zodiac']['title']}</label>
  160. {php echo tpl_app_fans_form('zodiac', $profile['zodiac'], $system_fields['zodiac']['title']);}
  161. </div>
  162. {/if}
  163. {if isset($profile['height'])}
  164. <div class="mui-input-row">
  165. <label>{$system_fields['height']['title']}</label>
  166. {php echo tpl_app_fans_form('height', $profile['height'], $system_fields['height']['title']);}
  167. </div>
  168. {/if}
  169. {if isset($profile['weight'])}
  170. <div class="mui-input-row">
  171. <label>{$system_fields['weight']['title']}</label>
  172. {php echo tpl_app_fans_form('weight', $profile['weight'], $system_fields['weight']['title']);}
  173. </div>
  174. {/if}
  175. {if isset($profile['bloodtype'])}
  176. <div class="mui-input-row">
  177. <label>{$system_fields['bloodtype']['title']}</label>
  178. {php echo tpl_app_fans_form('bloodtype', $profile['bloodtype'], $system_fields['bloodtype']['title']);}
  179. </div>
  180. {/if}
  181. {if isset($profile['idcard'])}
  182. <div class="mui-input-row">
  183. <label>{$system_fields['idcard']['title']}</label>
  184. {php echo tpl_app_fans_form('idcard', $profile['idcard'], $system_fields['idcard']['title']);}
  185. </div>
  186. {/if}
  187. {if isset($profile['zipcode'])}
  188. <div class="mui-input-row">
  189. <label>{$system_fields['zipcode']['title']}</label>
  190. {php echo tpl_app_fans_form('zipcode',$profile['zipcode'], $system_fields['zipcode']['title']);}
  191. </div>
  192. {/if}
  193. {if isset($profile['site'])}
  194. <div class="mui-input-row">
  195. <label>{$system_fields['site']['title']}</label>
  196. {php echo tpl_app_fans_form('site', $profile['site'], $system_fields['site']['title']);}
  197. </div>
  198. {/if}
  199. {if isset($profile['affectivestatus'])}
  200. <div class="mui-input-row">
  201. <label>{$system_fields['affectivestatus']['title']}</label>
  202. {php echo tpl_app_fans_form('affectivestatus', $profile['affectivestatus'], $system_fields['affectivestatus']['title']);}
  203. </div>
  204. {/if}
  205. {if isset($profile['lookingfor'])}
  206. <div class="mui-input-row">
  207. <label>{$system_fields['lookingfor']['title']}</label>
  208. {php echo tpl_app_fans_form('lookingfor', $profile['lookingfor'], $system_fields['lookingfor']['title']);}
  209. </div>
  210. {/if}
  211. {if isset($profile['bio'])}
  212. <div class="mui-input-row">
  213. <label>{$system_fields['bio']['title']}</label>
  214. {php echo tpl_app_fans_form('bio', $profile['bio'], $system_fields['bio']['title']);}
  215. </div>
  216. {/if}
  217. {if isset($profile['interest'])}
  218. <div class="mui-input-row">
  219. <label>{$system_fields['interest']['title']}</label>
  220. {php echo tpl_app_fans_form('interest', $profile['interest'], $system_fields['interest']['title']);}
  221. </div>
  222. {/if}
  223. </div>
  224. <div class="mui-content-padded">
  225. <button type="submit" class="mui-btn mui-btn-success mui-btn-block" name="submit" value="提交">提交</button>
  226. <input type="hidden" name="token" value="{$_W['token']}" />
  227. </div>
  228. </form>
  229. </div>
  230. <script>
  231. $(function(){
  232. $('form').submit(function(){
  233. var msg = '请认真填写您的';
  234. {if isset($profile['avatar'])}
  235. if($(this).find('input[name="avatart"]').val() == ''){
  236. util.message(msg+'{$titles['avatart']}');
  237. return false;
  238. }
  239. {/if}
  240. {if isset($profile['nickname'])}
  241. if($(this).find('input[name="nickname"]').val() == ''){
  242. util.message(msg+'{$titles['nickname']}');
  243. return false;
  244. }
  245. {/if}
  246. {if isset($profile['realname'])}
  247. if($(this).find('input[name="realname"]').val() == ''){
  248. util.message(msg+'{$titles['realname']}');
  249. return false;
  250. }
  251. {/if}
  252. {if isset($profile['gender'])}
  253. if($(this).find('input[name="gender"]').val() == ''){
  254. util.message(msg+'{$titles['gender']}');
  255. return false;
  256. }
  257. {/if}
  258. {if isset($profile['birthyear'])}
  259. if($(this).find('select[name="birth[year]"]').val() == ''){
  260. util.message(msg+'{$titles['birth']}'+"年份");
  261. return false;
  262. }
  263. if($(this).find('select[name="birth[month]"]').val() == ''){
  264. util.message(msg+'{$titles['birth']}'+"月份");
  265. return false;
  266. }
  267. if($(this).find('select[name="birth[day]"]').val() == '0'){
  268. util.message(msg+'{$titles['birth']}'+"日期");
  269. return false;
  270. }
  271. {/if}
  272. {if isset($profile['resideprovince'])}
  273. if($(this).find('select[name="reside[province]"]').val() == ''){
  274. util.message(msg+'{$titles['reside']}'+"省份");
  275. return false;
  276. }
  277. if($(this).find('select[name="reside[city]"]').val() == ''){
  278. util.message(msg+'{$titles['reside']}'+"市");
  279. return false;
  280. }
  281. if($(this).find('select[name="reside[district]"]').val() == ''){
  282. util.message(msg+'{$titles['reside']}'+"县区");
  283. return false;
  284. }
  285. {/if}
  286. {if isset($profile['address'])}
  287. if($(this).find('input[name="address"]').val() == ''){
  288. util.message(msg+'{$titles['address']}');
  289. return false;
  290. }
  291. {/if}
  292. {if isset($profile['mobile'])}
  293. if($(this).find('input[name="mobile"]').val() == ''){
  294. util.message(msg+'{$titles['mobile']}');
  295. return false;
  296. }
  297. {/if}
  298. {if isset($profile['qq'])}
  299. if($(this).find('input[name="qq"]').val() == ''){
  300. util.message(msg+'{$titles['qq']}');
  301. return false;
  302. }
  303. {/if}
  304. {if isset($profile['email'])}
  305. if($(this).find('input[name="email"]').val() == ''){
  306. util.message(msg+'{$titles['email']}');
  307. return false;
  308. }
  309. {/if}
  310. {if isset($profile['telephone'])}
  311. if($(this).find('input[name="telephone"]').val() == ''){
  312. util.message(msg+'{$titles['telephone']}');
  313. return false;
  314. }
  315. {/if}
  316. {if isset($profile['msn'])}
  317. if($(this).find('input[name="msn"]').val() == ''){
  318. util.message(msg+'{$titles['msn']}');
  319. return false;
  320. }
  321. {/if}
  322. {if isset($profile['taobao'])}
  323. if($(this).find('input[name="taobao"]').val() == ''){
  324. util.message(msg+'{$titles['taobao']}');
  325. return false;
  326. }
  327. {/if}
  328. {if isset($profile['alipay'])}
  329. if($(this).find('input[name="alipay"]').val() == ''){
  330. util.message(msg+'{$titles['alipay']}');
  331. return false;
  332. }
  333. {/if}
  334. {if isset($profile['studentid'])}
  335. if($(this).find('input[name="studentid"]').val() == ''){
  336. util.message(msg+'{$titles['studentid']}');
  337. return false;
  338. }
  339. {/if}
  340. {if isset($profile['grade'])}
  341. if($(this).find('input[name="grade"]').val() == ''){
  342. util.message(msg+'{$titles['grade']}');
  343. return false;
  344. }
  345. {/if}
  346. {if isset($profile['graduateschool'])}
  347. if($(this).find('input[name="graduateschool"]').val() == ''){
  348. util.message(msg+'{$titles['graduateschool']}');
  349. return false;
  350. }
  351. {/if}
  352. {if isset($profile['education'])}
  353. if($(this).find('input[name="education"]').val() == ''){
  354. util.message(msg+'{$titles['education']}');
  355. return false;
  356. }
  357. {/if}
  358. {if isset($profile['company'])}
  359. if($(this).find('input[name="company"]').val() == ''){
  360. util.message(msg+'{$titles['company']}');
  361. return false;
  362. }
  363. {/if}
  364. {if isset($profile['occupation'])}
  365. if($(this).find('input[name="occupation"]').val() == ''){
  366. util.message(msg+'{$titles['occupation']}');
  367. return false;
  368. }
  369. {/if}
  370. {if isset($profile['position'])}
  371. if($(this).find('input[name="position"]').val() == ''){
  372. util.message(msg+'{$titles['position']}');
  373. return false;
  374. }
  375. {/if}
  376. {if isset($profile['revenue'])}
  377. var revenue = parseFloat($(this).find('input[name="revenue"]').val())
  378. if(isNaN(revenue)){
  379. util.message(msg+'{$titles['revenue']}');
  380. return false;
  381. }
  382. {/if}
  383. {if isset($profile['constellation'])}
  384. if($(this).find('input[name="constellation"]').val() == ''){
  385. util.message(msg+'{$titles['constellation']}');
  386. return false;
  387. }
  388. {/if}
  389. {if isset($profile['zodiac'])}
  390. if($(this).find('input[name="zodiac"]').val() == ''){
  391. util.message(msg+'{$titles['zodiac']}');
  392. return false;
  393. }
  394. {/if}
  395. {if isset($profile['nationality'])}
  396. if($(this).find('input[name="nationality"]').val() == ''){
  397. util.message(msg+'{$titles['nationality']}');
  398. return false;
  399. }
  400. {/if}
  401. {if isset($profile['height'])}
  402. var height = parseFloat($(this).find('input[name="height"]').val())
  403. if(isNaN(height)){
  404. util.message(msg+'{$titles['height']}');
  405. return false;
  406. }
  407. {/if}
  408. {if isset($profile['weight'])}
  409. var weight = parseFloat($(this).find('input[name="weight"]').val())
  410. if(isNaN(weight)){
  411. util.message(msg+'{$titles['weight']}');
  412. return false;
  413. }
  414. {/if}
  415. {if isset($profile['bloodtype'])}
  416. if($(this).find('input[name="bloodtype"]').val() == ''){
  417. util.message(msg+'{$titles['bloodtype']}');
  418. return false;
  419. }
  420. {/if}
  421. {if isset($profile['idcard'])}
  422. if(/(^\d{15}$)|(^\d{18}$)|(^\d{17}(\d|X|x)$)/.test($(this).find('input[name="idcard"]').val()) === false) {
  423. util.message(msg+'{$titles['idcard']}');
  424. return false;
  425. }
  426. {/if}
  427. {if isset($profile['zipcode'])}
  428. if(/^\d{6}$/.test($(this).find('input[name="zipcode"]').val()) === false) {
  429. util.message(msg+'{$titles['zipcode']}');
  430. return false;
  431. }
  432. {/if}
  433. {if isset($profile['site'])}
  434. if($(this).find('input[name="site"]').val() == ''){
  435. util.message(msg+'{$titles['site']}');
  436. return false;
  437. }
  438. {/if}
  439. {if isset($profile['affectivestatus'])}
  440. if($(this).find('input[name="affectivestatus"]').val() == ''){
  441. util.message(msg+'{$titles['affectivestatus']}');
  442. return false;
  443. }
  444. {/if}
  445. {if isset($profile['lookingfor'])}
  446. if($(this).find('input[name="lookingfor"]').val() == ''){
  447. util.message(msg+'{$titles['lookingfor']}');
  448. return false;
  449. }
  450. {/if}
  451. {if isset($profile['bio'])}
  452. if($(this).find('textarea[name="bio"]').val() == ''){
  453. util.message(msg+'{$titles['bio']}');
  454. return false;
  455. }
  456. {/if}
  457. {if isset($profile['interest'])}
  458. if($(this).find('textarea[name="interest"]').val() == ''){
  459. util.message(msg+'{$titles['interest']}');
  460. return false;
  461. }
  462. {/if}
  463. return true;
  464. });
  465. });
  466. </script>
  467. {template 'common/footer'}