MainPage.js 22 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706
  1. /**
  2. * Sample React Native App
  3. * https://github.com/facebook/react-native
  4. *
  5. * @format
  6. * @flow
  7. */
  8. import React, { Component } from "react";
  9. import {
  10. Platform,
  11. StyleSheet,
  12. Text,
  13. View,
  14. Image,
  15. FlatList,
  16. TouchableOpacity,
  17. ImageBackground,
  18. TextInput,
  19. Button,
  20. ViewPagerAndroid,
  21. DeviceEventEmitter,
  22. SectionList,
  23. Animated,
  24. TouchableHighlight
  25. } from "react-native";
  26. import Swiper from "react-native-swiper";
  27. import AndroidUtil from "../../util/AndroidUtil";
  28. import BasePage from "../BasePage";
  29. import Header from "./Header";
  30. import MySwiper from "./Swiper";
  31. import Dimensions from '../utils/dimensions';
  32. import TopicTitle from './TopicTitle';
  33. import ScrollRow from "./ScrollRow";
  34. import LibraryUrl from '../services/library'
  35. import { ScrollView } from "react-native-gesture-handler";
  36. export default class MainPage extends BasePage {
  37. constructor(props) {
  38. super(props);
  39. }
  40. componentDidMount() {
  41. this.updateRender('PRIMARY_SCHOOL')
  42. }
  43. updateRender(index) {
  44. LibraryUrl.getIndex(index).success(res => {
  45. console.log(res)
  46. const monthTopicTitle = res.data.monthTopic.zone.title;
  47. const monthTopicScroll = res.data.monthTopic.zoneCourseVOList;
  48. const schedule = res.data.schedule;
  49. const hotCourse = res.data.hotCourse;
  50. const recommend = res.data.recommend; //全部课程
  51. const banner = res.data.banner; //轮播图
  52. // const listData = [];
  53. // for(let item in res.data){
  54. // console.log(item)
  55. // listData.push(1)
  56. // }
  57. // console.log(typeof listData)
  58. // console.log(listData)
  59. // console.log(listData.length)
  60. let scheduleWeek = schedule[0].featureMap ? schedule[0].featureMap.weekSeq : '1'
  61. this.setState({
  62. // listData: listData.length? listData : [],
  63. hotCourse,
  64. monthTopicTitle,
  65. monthTopicScroll,
  66. schedule,
  67. recommend,
  68. banner,
  69. scheduleWeek
  70. })
  71. console.log(this.state.banner)
  72. }).fail(() => {
  73. alert(1111)
  74. })
  75. }
  76. state = {
  77. grade: '大学',
  78. text: '小伙子',
  79. ifGradeMenuShow: false,
  80. fadeAnim: new Animated.Value(0),
  81. schedule: [],
  82. recommend: [],
  83. listData: [],
  84. banner: [],
  85. currentSwitch: { title: '小学', param: 'PRIMARY_SCHOOL' },
  86. switchList: [
  87. // { title: '幼儿园', param: 'KINDERGARTEN' },
  88. { title: '学前', param: 'PRESCHOOL' },
  89. { title: '小学', param: 'PRIMARY_SCHOOL' },
  90. { title: '中学', param: 'MIDDLE_SCHOOL' },
  91. ],
  92. scheduleWeek: '1'
  93. }
  94. renderBtn = (item, index) => {
  95. return (
  96. // this.state.currentSwitch.param === item.param
  97. // ?
  98. // null
  99. // :
  100. // <TouchableOpacity onPress={() => this.switchGrade(index)} key={index} style={index === 1 ? styles.gradeItemMid : styles.gradeItem}>
  101. // <Text style={styles.gradeText}>{item.title}</Text>
  102. // </TouchableOpacity>
  103. <TouchableOpacity onPress={() => this.switchGrade(index)} key={index} style={index === 1 ? styles.gradeItemMid : styles.gradeItem}>
  104. <Text style={styles.gradeText}>{item.title}</Text>
  105. </TouchableOpacity>
  106. )
  107. }
  108. switchGrade = (index) => {
  109. const obj = this.state.switchList[index]
  110. this.setState({
  111. currentSwitch: obj
  112. })
  113. this.hideGradeMenu()
  114. // if (obj.param === this.state.currentSwitch.param) return
  115. this.updateRender(obj.param)
  116. }
  117. render() {
  118. // const abc =Object.keys(this.state.data).map((k)=>this.state.data[k])
  119. return (
  120. <View style={{ flex: 1 }} onPress={this.hideGradeMenu}>
  121. {/* <SectionList sectionList组件 性能好 但是针对当前布局是否有要用的必要,以后可能迭代
  122. sections={this.state.listData}
  123. renderItem={({ item }) => {
  124. return this.loadFlatItem(item);
  125. }}
  126. keyExtractor={(item, index) => item.key.toString()}
  127. ListHeaderComponent={() => this.headerorfooterComponent()}
  128. renderSectionHeader={this.sectionTitle}
  129. onScroll={this.hideGradeMenu}
  130. /> */}
  131. <ScrollView style={{ height: Dimensions.height }} showsVerticalScrollIndicator={false} onScroll={this.hideGradeMenu} >
  132. {this.headerorfooterComponent()}
  133. {this.getSwiperElement()}
  134. {this.getScheduleElement()}
  135. {this.getMonthTopic()}
  136. {this.getHotCourse()}
  137. {this.getAllCourses()}
  138. </ScrollView>
  139. {
  140. this.state.ifGradeMenuShow ? (
  141. <Animated.View
  142. style={{
  143. ...styles.callUpGrade,
  144. opacity: this.state.fadeAnim
  145. }}>
  146. {this.state.switchList.map((item, index) => this.renderBtn(item, index))}
  147. </Animated.View>
  148. ) : (
  149. null
  150. )
  151. }
  152. </View>
  153. );
  154. }
  155. // 头部组件
  156. headerorfooterComponent() {
  157. return (
  158. <View>
  159. <Header
  160. uri="https://ss1.bdstatic.com/70cFvXSh_Q1YnxGkpoWK1HF6hhy/it/u=1295208965,3056573814&amp;fm=26&amp;gp=0.jpg"
  161. width={400}
  162. height={150}
  163. username="卡通笨笨熊"
  164. flowerNumber="123234"
  165. onPress={() => this.toNextPage("userCenter")}
  166. />
  167. {/* 搜索区域 */}
  168. <View style={styles.searchSection}>
  169. <TextInput
  170. style={styles.searchBox}
  171. onChangeText={(text) => this.setState({ text })}
  172. value={this.state.text}
  173. />
  174. <TouchableOpacity onPress={this.tabCallOutHandler}>
  175. <View
  176. style={styles.rightBtn}
  177. >
  178. <Image
  179. source={require('../images/common/switch.png')}
  180. style={styles.rightBtnIcon}
  181. />
  182. <Text
  183. style={styles.rightBtnText}
  184. >
  185. {this.state.currentSwitch.title}
  186. </Text>
  187. </View>
  188. </TouchableOpacity>
  189. </View>
  190. </View>
  191. );
  192. }
  193. // 渲染轮播图
  194. getSwiperElement() {
  195. return (
  196. <View
  197. style={{
  198. height: Dimensions.getHeight(163),
  199. flex: 1,
  200. justifyContent: "center",
  201. alignItems: "center",
  202. flexDirection: "row",
  203. }}
  204. >
  205. <View
  206. style={{
  207. width: Dimensions.getWidth(358),
  208. height: Dimensions.getHeight(153),
  209. justifyContent: "center",
  210. overflow: 'hidden'
  211. }}
  212. >
  213. <MySwiper
  214. autoplay={true}
  215. loop={true}
  216. ifShowMiddle={true}
  217. data={this.state.banner}
  218. />
  219. </View>
  220. </View>
  221. );
  222. }
  223. // 渲染课程表
  224. getScheduleElement() {
  225. let renderScheduleItem = (item, index) => {
  226. const id = item.boothId
  227. return (
  228. <TouchableOpacity
  229. style={{
  230. width: Dimensions.getWidth(172),
  231. height: Dimensions.getHeight(86),
  232. marginRight: 12
  233. }}
  234. onPress={() => this.toNextPage('SchedulePage',{id})}
  235. key={index}
  236. activeOpacity={1}
  237. >
  238. <ImageBackground
  239. source={{
  240. uri: item.boothContent
  241. }}
  242. key={index}
  243. style={{
  244. flex: 1,
  245. // justifyContent: "center",
  246. // alignItems: "center",
  247. borderRadius: 10
  248. }}
  249. >
  250. {
  251. item.operationContent === 'KINDERGARTE'
  252. ?
  253. null
  254. :
  255. <View style={{
  256. width: Dimensions.getWidth(90),
  257. height: Dimensions.getHeight(45),
  258. marginLeft: Dimensions.getWidth(15),
  259. marginTop: Dimensions.getHeight(15),
  260. justifyContent: 'center',
  261. alignItems: 'center'
  262. }}>
  263. <Text style={{
  264. color: '#fff',
  265. fontSize: 18,
  266. }}>{item.title}</Text>
  267. <Text
  268. style={{
  269. color: '#fff',
  270. fontSize: 18,
  271. }}
  272. >{item.summary}</Text>
  273. </View>
  274. }
  275. </ImageBackground>
  276. </TouchableOpacity>
  277. )
  278. }
  279. return (
  280. <View
  281. style={{
  282. flex: 1,
  283. flexDirection: "column",
  284. height: Dimensions.getHeight(160),
  285. }}
  286. >
  287. <TopicTitle title={`课程表:第${this.state.scheduleWeek}周`} ifTubeShow={true} />
  288. {/* <View
  289. style={{
  290. flex: 2,
  291. flexDirection: "row",
  292. alignItems: 'center',
  293. paddingLeft: 10
  294. }}
  295. >
  296. {this.state.schedule.map((item, index) => renderScheduleItem(item, index))}
  297. </View> */}
  298. <FlatList
  299. data={this.state.schedule}
  300. horizontal={true}
  301. style={{ paddingLeft: '3.2%' }}
  302. renderItem={({ item, index }) => renderScheduleItem(item, index)}
  303. keyExtractor={(item, index) => index.toString()}
  304. showsHorizontalScrollIndicator={false}
  305. />
  306. </View>
  307. );
  308. }
  309. // 渲染月主题
  310. getMonthTopic() {
  311. return (
  312. <View style={{
  313. flex: 1,
  314. height: 225,
  315. }}>
  316. <TopicTitle title={this.state.monthTopicTitle} summary={'每天30分钟'} ifTubeShow={true} />
  317. <ScrollRow itemWidth={352} itemHeight={153} nav={this.props.navigation.navigate} data={this.state.monthTopicScroll} />
  318. </View>
  319. );
  320. }
  321. // 渲染热门课程
  322. getHotCourse() {
  323. return (
  324. <View style={{
  325. flex: 1,
  326. height: 220,
  327. }}>
  328. <TopicTitle title={'热门课程'} ifTubeShow={true} />
  329. <ScrollRow itemWidth={106} itemHeight={150} nav={this.props.navigation.navigate} data={this.state.hotCourse} />
  330. </View>
  331. )
  332. }
  333. // 渲染全部课程
  334. getAllCourses() {
  335. return (
  336. <View>
  337. {this.state.recommend.map((item, index) => {
  338. return (
  339. <View
  340. style={{
  341. flex: 1,
  342. height: 240,
  343. }}
  344. key={index}
  345. >
  346. {index === 0
  347. ?
  348. null
  349. :
  350. <View style={{ width: Dimensions.width, height: 4, backgroundColor: '#f0f1f5' }}></View>
  351. }
  352. <TopicTitle title={item.zone.title} />
  353. <ScrollRow itemWidth={106} itemHeight={150} nav={this.props.navigation.navigate} data={item.zoneCourseVOList} />
  354. </View>
  355. )
  356. })}
  357. </View>
  358. )
  359. }
  360. // 渲染每一个块儿 sectionList组件的data,没有用到,以后可能会用
  361. loadFlatItem(data) {
  362. switch (data.title) {
  363. // 轮播图
  364. case 'banner':
  365. return this.getSwiperElement();
  366. break;
  367. // 课程表
  368. case 'schedule':
  369. return this.getScheduleElement();
  370. break;
  371. // 大图主题
  372. case 'monthTopic':
  373. return this.getMonthTopic();
  374. break;
  375. // 热门课程
  376. case 'hotCourse':
  377. return this.getHotCourse();
  378. break;
  379. case 'recommend':
  380. return this.getAllCourses();
  381. break;
  382. default:
  383. break;
  384. }
  385. }
  386. // 渲染每一个section的title sectionList组件的data,没有用到,以后可能会用
  387. sectionTitle = (info) => {
  388. switch (info.section.title) {
  389. case 'operation':
  390. return (
  391. <View
  392. style={{
  393. width: Dimensions.width,
  394. height: 10,
  395. backgroundColor: '#f0f1f5'
  396. }}
  397. />
  398. );
  399. break;
  400. case 'courses':
  401. return <TopicTitle title={'全部课程'} tubeColor={'#7d9fff'} background={'#f0f1f5'} ifTubeShow={true} />
  402. break;
  403. default:
  404. break;
  405. }
  406. }
  407. // 点击呼出学龄菜单
  408. tabCallOutHandler = () => {
  409. this.setState({
  410. ifGradeMenuShow: !this.state.ifGradeMenuShow
  411. }, () => {
  412. Animated.timing(
  413. this.state.fadeAnim,
  414. {
  415. toValue: this.state.ifGradeMenuShow ? 1 : 0,
  416. duration: 300,
  417. }
  418. ).start();
  419. })
  420. }
  421. // 如果切换学龄在显示状态,那么在它失去焦点时将它隐藏
  422. hideGradeMenu = () => {
  423. if (this.state.ifGradeMenuShow) {
  424. this.setState({
  425. ifGradeMenuShow: false
  426. })
  427. }
  428. }
  429. }
  430. const styles = StyleSheet.create({
  431. title_text: {
  432. justifyContent: "center",
  433. alignItems: "center",
  434. color: "red",
  435. fontSize: 30,
  436. textAlign: "center",
  437. marginTop: 30,
  438. marginBottom: 50
  439. },
  440. /* 搜索区域 */
  441. searchSection: {
  442. flex: 1,
  443. width: Dimensions.width,
  444. height: Dimensions.getHeight(60),
  445. flexDirection: 'row',
  446. alignItems: 'center',
  447. backgroundColor: '#f0f1f5',
  448. justifyContent: 'space-around',
  449. position: 'relative',
  450. },
  451. searchBox: {
  452. width: Dimensions.getWidth(232),
  453. height: Dimensions.getHeight(40),
  454. backgroundColor: '#fff',
  455. borderRadius: 20
  456. },
  457. rightBtn: {
  458. width: Dimensions.getWidth(113),
  459. height: Dimensions.getHeight(40),
  460. backgroundColor: '#fff',
  461. borderRadius: 20,
  462. alignItems: 'center',
  463. justifyContent: 'center',
  464. justifyContent: 'space-around',
  465. flexDirection: 'row',
  466. paddingLeft: 20,
  467. paddingRight: 10,
  468. },
  469. rightBtnIcon: {
  470. width: Dimensions.getWidth(23),
  471. height: Dimensions.getHeight(23),
  472. },
  473. rightBtnText: {
  474. color: '#151515',
  475. fontSize: 18,
  476. },
  477. callUpGrade: {
  478. width: 113,
  479. height: 120,
  480. borderRadius: 20,
  481. position: 'absolute',
  482. right: 9,
  483. top: 125,
  484. zIndex: 999,
  485. elevation: 999,
  486. backgroundColor: '#fff',
  487. flexDirection: 'column'
  488. },
  489. gradeItem: {
  490. zIndex: 999,
  491. flex: 1,
  492. alignItems: 'center',
  493. justifyContent: 'center',
  494. },
  495. gradeItemMid: {
  496. zIndex: 999,
  497. flex: 1,
  498. alignItems: 'center',
  499. justifyContent: 'center',
  500. borderTopWidth: 1,
  501. borderBottomWidth: 1,
  502. borderColor: '#f0f1f5'
  503. },
  504. gradeText: {
  505. color: '#151515',
  506. fontSize: 18,
  507. }
  508. });
  509. const sectionData = [
  510. {
  511. title: 'swiper',
  512. data: [{
  513. //轮播
  514. key: 111,
  515. typea: 1,
  516. text: "第一种类型"
  517. },
  518. {
  519. //只有一个标题下面两个图片
  520. key: 222,
  521. typea: 2,
  522. item: {
  523. item_type: 1,
  524. title: "课程表:第一周",
  525. icon_item: [
  526. {
  527. icon:
  528. "https://timgsa.baidu.com/timg?image&quality=80&size=b9999_10000&sec=1556277324856&di=dc1548a0c5ba10481af922e174912937&imgtype=0&src=http%3A%2F%2Fwww.51pptmoban.com%2Fd%2Ffile%2F2012%2F05%2F12%2F82c4568a90055adcf8fbb896f0841c69.jpg",
  529. name: "第一张图片文字"
  530. },
  531. {
  532. icon:
  533. "https://timgsa.baidu.com/timg?image&quality=80&size=b9999_10000&sec=1556277324856&di=dc1548a0c5ba10481af922e174912937&imgtype=0&src=http%3A%2F%2Fwww.51pptmoban.com%2Fd%2Ffile%2F2012%2F05%2F12%2F82c4568a90055adcf8fbb896f0841c69.jpg",
  534. name: "第二张图片文字"
  535. }
  536. ]
  537. }
  538. },]
  539. },
  540. {
  541. title: 'operation',
  542. data: [{
  543. //一个标题,大长图
  544. key: 444,
  545. typea: 3,
  546. title: "五月主题:五一启程,去看看不同世界",
  547. text: "每天30分钟,玩学两不误",
  548. icon_item: [
  549. {
  550. icon:
  551. "https://timgsa.baidu.com/timg?image&quality=80&size=b9999_10000&sec=1556277324856&di=dc1548a0c5ba10481af922e174912937&imgtype=0&src=http%3A%2F%2Fwww.51pptmoban.com%2Fd%2Ffile%2F2012%2F05%2F12%2F82c4568a90055adcf8fbb896f0841c69.jpg",
  552. name: "第一张图片文字"
  553. },
  554. {
  555. icon:
  556. "https://timgsa.baidu.com/timg?image&quality=80&size=b9999_10000&sec=1556277324856&di=dc1548a0c5ba10481af922e174912937&imgtype=0&src=http%3A%2F%2Fwww.51pptmoban.com%2Fd%2Ffile%2F2012%2F05%2F12%2F82c4568a90055adcf8fbb896f0841c69.jpg",
  557. name: "第二张图片文字"
  558. },
  559. {
  560. icon:
  561. "https://timgsa.baidu.com/timg?image&quality=80&size=b9999_10000&sec=1556277324856&di=dc1548a0c5ba10481af922e174912937&imgtype=0&src=http%3A%2F%2Fwww.51pptmoban.com%2Fd%2Ffile%2F2012%2F05%2F12%2F82c4568a90055adcf8fbb896f0841c69.jpg",
  562. name: "第三张图片文字"
  563. },
  564. {
  565. icon:
  566. "https://timgsa.baidu.com/timg?image&quality=80&size=b9999_10000&sec=1556277324856&di=dc1548a0c5ba10481af922e174912937&imgtype=0&src=http%3A%2F%2Fwww.51pptmoban.com%2Fd%2Ffile%2F2012%2F05%2F12%2F82c4568a90055adcf8fbb896f0841c69.jpg",
  567. name: "第四张图片文字"
  568. },
  569. {
  570. icon:
  571. "https://timgsa.baidu.com/timg?image&quality=80&size=b9999_10000&sec=1556277324856&di=dc1548a0c5ba10481af922e174912937&imgtype=0&src=http%3A%2F%2Fwww.51pptmoban.com%2Fd%2Ffile%2F2012%2F05%2F12%2F82c4568a90055adcf8fbb896f0841c69.jpg",
  572. name: "第五张图片文字"
  573. }
  574. ]
  575. },
  576. {
  577. key: 555,
  578. typea: 4,
  579. title: "热门课程",
  580. text: "text",
  581. mask: false,
  582. icon_item: [
  583. {
  584. icon:
  585. "https://timgsa.baidu.com/timg?image&quality=80&size=b9999_10000&sec=1556277324856&di=dc1548a0c5ba10481af922e174912937&imgtype=0&src=http%3A%2F%2Fwww.51pptmoban.com%2Fd%2Ffile%2F2012%2F05%2F12%2F82c4568a90055adcf8fbb896f0841c69.jpg",
  586. name: "第一张图片文字"
  587. },
  588. {
  589. icon:
  590. "https://timgsa.baidu.com/timg?image&quality=80&size=b9999_10000&sec=1556277324856&di=dc1548a0c5ba10481af922e174912937&imgtype=0&src=http%3A%2F%2Fwww.51pptmoban.com%2Fd%2Ffile%2F2012%2F05%2F12%2F82c4568a90055adcf8fbb896f0841c69.jpg",
  591. name: "第二张图片文字"
  592. },
  593. {
  594. icon:
  595. "https://timgsa.baidu.com/timg?image&quality=80&size=b9999_10000&sec=1556277324856&di=dc1548a0c5ba10481af922e174912937&imgtype=0&src=http%3A%2F%2Fwww.51pptmoban.com%2Fd%2Ffile%2F2012%2F05%2F12%2F82c4568a90055adcf8fbb896f0841c69.jpg",
  596. name: "第三张图片文字"
  597. },
  598. {
  599. icon:
  600. "https://timgsa.baidu.com/timg?image&quality=80&size=b9999_10000&sec=1556277324856&di=dc1548a0c5ba10481af922e174912937&imgtype=0&src=http%3A%2F%2Fwww.51pptmoban.com%2Fd%2Ffile%2F2012%2F05%2F12%2F82c4568a90055adcf8fbb896f0841c69.jpg",
  601. name: "第四张图片文字"
  602. },
  603. {
  604. icon:
  605. "https://timgsa.baidu.com/timg?image&quality=80&size=b9999_10000&sec=1556277324856&di=dc1548a0c5ba10481af922e174912937&imgtype=0&src=http%3A%2F%2Fwww.51pptmoban.com%2Fd%2Ffile%2F2012%2F05%2F12%2F82c4568a90055adcf8fbb896f0841c69.jpg",
  606. name: "第五张图片文字"
  607. }
  608. ]
  609. },]
  610. },
  611. {
  612. title: 'courses',
  613. data: [{
  614. //一个标题,大长图
  615. key: 444,
  616. typea: 5,
  617. title: "五月主题:五一启程,去看看不同世界",
  618. text: "每天30分钟,玩学两不误",
  619. icon_item: [
  620. {
  621. icon:
  622. "https://timgsa.baidu.com/timg?image&quality=80&size=b9999_10000&sec=1556277324856&di=dc1548a0c5ba10481af922e174912937&imgtype=0&src=http%3A%2F%2Fwww.51pptmoban.com%2Fd%2Ffile%2F2012%2F05%2F12%2F82c4568a90055adcf8fbb896f0841c69.jpg",
  623. name: "第一张图片文字"
  624. },
  625. {
  626. icon:
  627. "https://timgsa.baidu.com/timg?image&quality=80&size=b9999_10000&sec=1556277324856&di=dc1548a0c5ba10481af922e174912937&imgtype=0&src=http%3A%2F%2Fwww.51pptmoban.com%2Fd%2Ffile%2F2012%2F05%2F12%2F82c4568a90055adcf8fbb896f0841c69.jpg",
  628. name: "第二张图片文字"
  629. },
  630. {
  631. icon:
  632. "https://timgsa.baidu.com/timg?image&quality=80&size=b9999_10000&sec=1556277324856&di=dc1548a0c5ba10481af922e174912937&imgtype=0&src=http%3A%2F%2Fwww.51pptmoban.com%2Fd%2Ffile%2F2012%2F05%2F12%2F82c4568a90055adcf8fbb896f0841c69.jpg",
  633. name: "第三张图片文字"
  634. },
  635. {
  636. icon:
  637. "https://timgsa.baidu.com/timg?image&quality=80&size=b9999_10000&sec=1556277324856&di=dc1548a0c5ba10481af922e174912937&imgtype=0&src=http%3A%2F%2Fwww.51pptmoban.com%2Fd%2Ffile%2F2012%2F05%2F12%2F82c4568a90055adcf8fbb896f0841c69.jpg",
  638. name: "第四张图片文字"
  639. },
  640. {
  641. icon:
  642. "https://timgsa.baidu.com/timg?image&quality=80&size=b9999_10000&sec=1556277324856&di=dc1548a0c5ba10481af922e174912937&imgtype=0&src=http%3A%2F%2Fwww.51pptmoban.com%2Fd%2Ffile%2F2012%2F05%2F12%2F82c4568a90055adcf8fbb896f0841c69.jpg",
  643. name: "第五张图片文字"
  644. }
  645. ]
  646. },
  647. {
  648. key: 555,
  649. typea: 5,
  650. title: "热门课程",
  651. text: "text",
  652. mask: false,
  653. icon_item: [
  654. {
  655. icon:
  656. "https://timgsa.baidu.com/timg?image&quality=80&size=b9999_10000&sec=1556277324856&di=dc1548a0c5ba10481af922e174912937&imgtype=0&src=http%3A%2F%2Fwww.51pptmoban.com%2Fd%2Ffile%2F2012%2F05%2F12%2F82c4568a90055adcf8fbb896f0841c69.jpg",
  657. name: "第一张图片文字"
  658. },
  659. {
  660. icon:
  661. "https://timgsa.baidu.com/timg?image&quality=80&size=b9999_10000&sec=1556277324856&di=dc1548a0c5ba10481af922e174912937&imgtype=0&src=http%3A%2F%2Fwww.51pptmoban.com%2Fd%2Ffile%2F2012%2F05%2F12%2F82c4568a90055adcf8fbb896f0841c69.jpg",
  662. name: "第二张图片文字"
  663. },
  664. {
  665. icon:
  666. "https://timgsa.baidu.com/timg?image&quality=80&size=b9999_10000&sec=1556277324856&di=dc1548a0c5ba10481af922e174912937&imgtype=0&src=http%3A%2F%2Fwww.51pptmoban.com%2Fd%2Ffile%2F2012%2F05%2F12%2F82c4568a90055adcf8fbb896f0841c69.jpg",
  667. name: "第三张图片文字"
  668. },
  669. {
  670. icon:
  671. "https://timgsa.baidu.com/timg?image&quality=80&size=b9999_10000&sec=1556277324856&di=dc1548a0c5ba10481af922e174912937&imgtype=0&src=http%3A%2F%2Fwww.51pptmoban.com%2Fd%2Ffile%2F2012%2F05%2F12%2F82c4568a90055adcf8fbb896f0841c69.jpg",
  672. name: "第四张图片文字"
  673. },
  674. {
  675. icon:
  676. "https://timgsa.baidu.com/timg?image&quality=80&size=b9999_10000&sec=1556277324856&di=dc1548a0c5ba10481af922e174912937&imgtype=0&src=http%3A%2F%2Fwww.51pptmoban.com%2Fd%2Ffile%2F2012%2F05%2F12%2F82c4568a90055adcf8fbb896f0841c69.jpg",
  677. name: "第五张图片文字"
  678. }
  679. ]
  680. },]
  681. }
  682. ]