Kaynağa Gözat

小程序修改政策解读样式并对接

wrh 2 yıl önce
ebeveyn
işleme
06393d58c3

+ 354 - 347
nngkxxdp/src/main/resources/static/nnzwminiapp/pages/publics/index/index.js

@@ -1,366 +1,373 @@
 // pages/nais/nais.js
 let app = getApp();
 import {
-  imgUrl
+	imgUrl
 } from "../../api/request"
 
 Page({
 
-  /**
-   * 页面的初始数据
-   */
-  data: {
-    // 图片前缀
-    imgUrl: imgUrl,
-    // 屏幕高度
-    navHeight: '',
-    // 区政府领导列表
-    leaderList: [{
-      id: '145044',
-      name: '王茂春',
-      pic: '图层 1298.png',
-      description: '区委副书记,区政府党组书记、区政府区长,重庆经开区党工委副书记(兼)'
-    }, {
-      id: '341997',
-      name: '唐昕',
-      pic: '图层 1298.png',
-      description: '区委常委,区政府党组副书记、常务副区长'
-    }, {
-      id: '341998',
-      name: '张进',
-      pic: '图层 1298.png',
-      description: '区委常委,区政府党组成员、副区长'
-    }, {
-      id: '341999',
-      name: '蒋文新',
-      pic: '图层 1298.png',
-      description: '民盟重庆市南岸区委主委,区政府副区长'
-    }],
-    // 政府信息公开
-    governmentInfoList: [{
-        title: '政府信息公开指南',
-        pic: 'public-zw1.png'
-      },
-      {
-        title: '政府信息公开制度',
-        pic: 'public-zw2.png'
-      },
-      {
-        title: '法定主动公开内容',
-        pic: 'public-zw3.png'
-      },
-      {
-        title: '政府信息公开年报',
-        pic: 'public-zw4.png'
-      }
-    ],
-    // 基层政务公开
-    baseList: [{
-        pic: 'publics-base-1.png',
-        name: '重项目建设'
-      },
-      {
-        pic: 'publics-base-2.png',
-        name: '公共资源交易'
-      },
-      {
-        pic: 'publics-base-3.png',
-        name: '义务教育'
-      },
-      {
-        pic: 'publics-base-4.png',
-        name: '社会救助'
-      },
-      {
-        pic: 'publics-base-5.png',
-        name: '养老服务'
-      },
-      {
-        pic: 'publics-base-6.png',
-        name: '公共法律服务'
-      },
-      {
-        pic: 'publics-base-7.png',
-        name: '就业创业领域'
-      },
-      {
-        pic: 'publics-base-8.png',
-        name: '社会保险领域'
-      },
-      {
-        pic: 'publics-base-9.png',
-        name: '社会保险领域'
-      }
-    ],
-    // 政策文件tab
-    fileTab: 0,
-    // 政策文件item
-    fileItem: 0,
-    // 政策文件列表
-    fileList: [],
-    // 政策解读
-    policyInterpretation: [{
-      name: '文字解读'
-    }, {
-      name: '图片解读'
-    }, {
-      name: '视频解读'
-    }, {
-      name: '媒体解读'
-    }],
-    // 文字解读
-    textInterpretationList: [],
-    // 图片解读
-    pictureInterpretationList: [],
-    // 视频解读
-    videoInterpretationList: [],
-    // 媒体解读
-    mediaInterpretationList: [],
-    // 政策解读默认项
-    currentTab: 0,
-    // 政务专题
-    topics: ['图层 3269.png', '图层 3270.png', '图层 3269.png']
-  },
+	/**
+	 * 页面的初始数据
+	 */
+	data: {
+		// 图片前缀
+		imgUrl: imgUrl,
+		// 屏幕高度
+		navHeight: '',
+		// 区政府领导列表
+		leaderList: [{
+			id: '145044',
+			name: '王茂春',
+			pic: '图层 1298.png',
+			description: '区委副书记,区政府党组书记、区政府区长,重庆经开区党工委副书记(兼)'
+		}, {
+			id: '341997',
+			name: '唐昕',
+			pic: '图层 1298.png',
+			description: '区委常委,区政府党组副书记、常务副区长'
+		}, {
+			id: '341998',
+			name: '张进',
+			pic: '图层 1298.png',
+			description: '区委常委,区政府党组成员、副区长'
+		}, {
+			id: '341999',
+			name: '蒋文新',
+			pic: '图层 1298.png',
+			description: '民盟重庆市南岸区委主委,区政府副区长'
+		}],
+		// 政府信息公开
+		governmentInfoList: [{
+				title: '政府信息公开指南',
+				pic: 'public-zw1.png'
+			},
+			{
+				title: '政府信息公开制度',
+				pic: 'public-zw2.png'
+			},
+			{
+				title: '法定主动公开内容',
+				pic: 'public-zw3.png'
+			},
+			{
+				title: '政府信息公开年报',
+				pic: 'public-zw4.png'
+			}
+		],
+		// 基层政务公开
+		baseList: [{
+				pic: 'publics-base-1.png',
+				name: '重项目建设'
+			},
+			{
+				pic: 'publics-base-2.png',
+				name: '公共资源交易'
+			},
+			{
+				pic: 'publics-base-3.png',
+				name: '义务教育'
+			},
+			{
+				pic: 'publics-base-4.png',
+				name: '社会救助'
+			},
+			{
+				pic: 'publics-base-5.png',
+				name: '养老服务'
+			},
+			{
+				pic: 'publics-base-6.png',
+				name: '公共法律服务'
+			},
+			{
+				pic: 'publics-base-7.png',
+				name: '就业创业领域'
+			},
+			{
+				pic: 'publics-base-8.png',
+				name: '社会保险领域'
+			},
+			{
+				pic: 'publics-base-9.png',
+				name: '社会保险领域'
+			}
+		],
+		// 政策文件tab
+		fileTab: 0,
+		// 政策文件item
+		fileItem: 0,
+		// 政策文件列表
+		fileList: [],
+		// 政策解读
+		policyInterpretation: [{
+			name: '文字解读'
+		}, {
+			name: '图片解读'
+		}, {
+			name: '视频解读'
+		}, {
+			name: '媒体解读'
+		}],
+		// 文字解读
+		textInterpretationList: [],
+		// 图片解读
+		pictureInterpretationList: [],
+		// 视频解读
+		videoInterpretationList: [],
+		// 媒体解读
+		mediaInterpretationList: [],
+		// 政策解读默认项
+		currentTab: 0,
+		// 政务专题
+		topics: ['图层 3269.png', '图层 3270.png', '图层 3269.png']
+	},
 
 
-  /**
-   * 生命周期函数--监听页面初次渲染完成
-   */
-  onReady() {
-    if (typeof this.getTabBar === 'function' && this.getTabBar()) {
-      this.getTabBar().setData({
-        selected: 1
-      })
-    }
-  },
-  onHide() {
-    if (typeof this.getTabBar === 'function' &&
-      this.getTabBar()) {
-      this.getTabBar().setData({
-        selected: -1
-      })
-    }
-  },
-  // 事件处理函数
-  onLoad() {
-    // 政策文件
-    this.getFileListById(161753);
-    // 政策解读
-    this.getInterpretation();
-    this.setData({
-      navHeight: app.globalData.navHeight + app.globalData.menuHeight / 2
-    })
-  },
-  // 获取政策文件列表
-  getFileListById() {
-    var chennelId = 161753
-    switch (this.data.fileTab) {
-      case 1:
-        chennelId = 20442;
-        break;
-      case 2:
-        chennelId = 69336;
-        break;
-      default:
-        chennelId = 161753;
-        break;
-    }
-    // 161753 规范性文件 20442-其他文件 69336-废止和失效文件 161758-废止和失效文件
-    wx.request({
-      url: 'https://data.cqna.gov.cn/mini/hlw/send?page=1&limit=10&channelId=' + chennelId,
-      method: 'GET',
-      success: res => {
-        if (res.data.data.DATA) {
-          this.setData({
-            fileList: res.data.data.DATA
-          })
-        }
-      }
-    })
-  },
-  // 获取政策解读列表
-  getInterpretation() {
-    // 文字解读
-    wx.request({
-      url: 'https://data.cqna.gov.cn/mini/hlw/send?page=1&limit=3&channelId=222894',
-      method: 'GET',
-      success: res => {
-        this.setData({
-          textInterpretationList: res.data.data.DATA
-        })
-      }
-    })
-    // 图片解读
-    wx.request({
-      url: 'https://data.cqna.gov.cn/mini/hlw/send?page=1&limit=3&channelId=222894',
-      method: 'GET',
-      success: res => {
-        this.setData({
-          pictureInterpretationList: res.data.data.DATA
-        })
-      }
-    })
-    // 视频解读
-    wx.request({
-      url: 'https://data.cqna.gov.cn/mini/hlw/send?page=1&limit=3&channelId=222894',
-      method: 'GET',
-      success: res => {
-        this.setData({
-          videoInterpretationList: res.data.data.DATA
-        })
-      }
-    })
-    // 媒体解读
-    wx.request({
-      url: 'https://data.cqna.gov.cn/mini/hlw/send?page=1&limit=3&channelId=222894',
-      method: 'GET',
-      success: res => {
-        this.setData({
-          mediaInterpretationList: res.data.data.DATA
-        })
-      }
-    })
-  },
-  // 跳转更多界面
-  goToMore() {
-    console.log("跳转到详细界面");
-  },
-  gotoInterpretation() {
-    wx.navigateTo({
-      url: '/pages/publics/interpretation/interpretation',
-    })
-  },
-  goToGovernment(e) {
-    if (e.currentTarget.dataset.index) {
-      wx.navigateTo({
-        url: '/pages/publics/government/government?index=' + e.currentTarget.dataset.index,
-      })
-    } else {
-      wx.navigateTo({
-        url: '/pages/publics/government/government',
-      })
-    }
-  },
-  // 切换政策文件类型
-  clickFileTab: function (e) {
-    this.setData({
-      fileItem: e.currentTarget.dataset.item
-    })
-  },
-  // 滑动政策文件类型
-  changeFileTab: function (e) {
-    this.setData({
-      fileTab: e.detail.current,
-      fileList: []
-    })
-    this.getFileListById(this.data.fileTab)
-  },
-  // 切换政策解读
-  tabNav(e) {
-    let currentTab = e.currentTarget.dataset.index
-    this.setData({
-      currentTab
-    })
-  },
-  // 滑动政策解读
-  handleSwiper(e) {
-    console.log("1212121");
-    let {
-      current,
-      source
-    } = e.detail
-    if (source === 'autoplay' || source === 'touch') {
-      const currentTab = current
-      this.setData({
-        currentTab
-      })
-    }
-  },
+	/**
+	 * 生命周期函数--监听页面初次渲染完成
+	 */
+	onReady() {
+		if (typeof this.getTabBar === 'function' && this.getTabBar()) {
+			this.getTabBar().setData({
+				selected: 1
+			})
+		}
+	},
+	onHide() {
+		if (typeof this.getTabBar === 'function' &&
+			this.getTabBar()) {
+			this.getTabBar().setData({
+				selected: -1
+			})
+		}
+	},
+	// 事件处理函数
+	onLoad() {
+		// 政策文件
+		this.getFileListById(161753);
+		// 政策解读
+		this.getInterpretation();
+		this.setData({
+			navHeight: app.globalData.navHeight + app.globalData.menuHeight / 2
+		})
+	},
+	// 获取政策文件列表
+	getFileListById() {
+		var chennelId = 161753
+		switch (this.data.fileTab) {
+			case 1:
+				chennelId = 20442;
+				break;
+			case 2:
+				chennelId = 69336;
+				break;
+			default:
+				chennelId = 161753;
+				break;
+		}
+		// 161753 规范性文件 20442-其他文件 69336-废止和失效文件 161758-废止和失效文件
+		wx.request({
+			url: 'https://data.cqna.gov.cn/mini/hlw/send?page=1&limit=10&channelId=' + chennelId,
+			method: 'GET',
+			success: res => {
+				if (res.data.data.DATA) {
+					this.setData({
+						fileList: res.data.data.DATA
+					})
+				}
+			}
+		})
+	},
+	// 获取政策解读列表
+	getInterpretation() {
+		let that = this;
+		// 文字解读
+		wx.request({
+			url: 'https://data.cqna.gov.cn/mini/hlw/send?page=1&limit=3&channelId=222894',
+			method: 'GET',
+			success: res => {
+				this.setData({
+					textInterpretationList: res.data.data.DATA
+				})
+			}
+		})
+		// 图片解读
+		setTimeout(function () {
+			wx.request({
+				url: 'https://data.cqna.gov.cn/mini/hlw/send?page=1&limit=3&channelId=158049',
+				method: 'GET',
+				success: res => {
+					that.setData({
+						pictureInterpretationList: res.data.data.DATA
+					})
+				}
+			})
+		}, 500)
+		// 视频解读
+		setTimeout(function () {
+			wx.request({
+				url: 'https://data.cqna.gov.cn/mini/hlw/send?page=1&limit=3&channelId=158049',
+				method: 'GET',
+				success: res => {
+					that.setData({
+						videoInterpretationList: res.data.data.DATA
+					})
+				}
+			})
+		}, 1200)
+		// 媒体解读
+		setTimeout(function () {
+			wx.request({
+				url: 'https://data.cqna.gov.cn/mini/hlw/send?page=1&limit=3&channelId=222894',
+				method: 'GET',
+				success: res => {
+					that.setData({
+						mediaInterpretationList: res.data.data.DATA
+					})
+				}
+			})
+		}, 1500)
+	},
+	// 跳转更多界面
+	goToMore() {
+		console.log("跳转到详细界面");
+	},
+	gotoInterpretation() {
+		wx.navigateTo({
+			url: '/pages/publics/interpretation/interpretation',
+		})
+	},
+	goToGovernment(e) {
+		if (e.currentTarget.dataset.index) {
+			wx.navigateTo({
+				url: '/pages/publics/government/government?index=' + e.currentTarget.dataset.index,
+			})
+		} else {
+			wx.navigateTo({
+				url: '/pages/publics/government/government',
+			})
+		}
+	},
+	// 切换政策文件类型
+	clickFileTab: function (e) {
+		this.setData({
+			fileItem: e.currentTarget.dataset.item
+		})
+	},
+	// 滑动政策文件类型
+	changeFileTab: function (e) {
+		this.setData({
+			fileTab: e.detail.current,
+			fileList: []
+		})
+		this.getFileListById(this.data.fileTab)
+	},
+	// 切换政策解读
+	tabNav(e) {
+		let currentTab = e.currentTarget.dataset.index
+		this.setData({
+			currentTab
+		})
+	},
+	// 滑动政策解读
+	handleSwiper(e) {
+		console.log("1212121");
+		let {
+			current,
+			source
+		} = e.detail
+		if (source === 'autoplay' || source === 'touch') {
+			const currentTab = current
+			this.setData({
+				currentTab
+			})
+		}
+	},
 
-  /**
-   * 生命周期函数--监听页面显示
-   */
-  onShow() {
-    if (typeof this.getTabBar === 'function' && this.getTabBar()) {
-      this.getTabBar().setData({
-        selected: 1
-      })
-    }
-  },
+	/**
+	 * 生命周期函数--监听页面显示
+	 */
+	onShow() {
+		if (typeof this.getTabBar === 'function' && this.getTabBar()) {
+			this.getTabBar().setData({
+				selected: 1
+			})
+		}
+	},
 
-  /**
-   * 生命周期函数--监听页面卸载
-   */
-  onUnload() {
+	/**
+	 * 生命周期函数--监听页面卸载
+	 */
+	onUnload() {
 
-  },
+	},
 
-  /**
-   * 页面相关事件处理函数--监听用户下拉动作
-   */
-  onPullDownRefresh() {
+	/**
+	 * 页面相关事件处理函数--监听用户下拉动作
+	 */
+	onPullDownRefresh() {
 
-  },
+	},
 
-  /**
-   * 页面上拉触底事件的处理函数
-   */
-  onReachBottom() {
+	/**
+	 * 页面上拉触底事件的处理函数
+	 */
+	onReachBottom() {
 
-  },
+	},
 
-  /**
-   * 用户点击右上角分享
-   */
-  onShareAppMessage() {
+	/**
+	 * 用户点击右上角分享
+	 */
+	onShareAppMessage() {
 
-  },
-  gotoZXWDK() {
-    wx.navigateTo({
-      url: '/pages/ZCWDK/index/index',
-    })
-  },
-  gotoLeaderDetail() {
-    wx.navigateTo({
-      url: '/pages/publics/publicLeaderDetail/publicLeaderDetail',
-    })
-  },
-  goToBaseAffairs() {
-    wx.navigateTo({
-      url: '/pages/publics/baseAffairs/baseAffairs',
-    })
-  },
-  goToFileList() {
-    wx.navigateTo({
-      url: '/pages/publics/fileList/fileList',
-    })
-  },
-  goTOFileDetail(e) {
-    var url = e.target.dataset.url
-    url = url.substring(0, url.lastIndexOf("/") + 1)
-    var docId = 0;
-    if (e.target.dataset.item) {
-      docId = e.target.dataset.item
-    }
-    var chennelId = 0;
-    switch (this.data.fileTab) {
-      case 0:
-        chennelId = 161753;
-        break;
-      case 1:
-        chennelId = 20442;
-        break;
-      case 2:
-        chennelId = 69336;
-        break;
-      default:
-        chennelId = 0;
-        break;
-    }
-    if (chennelId != 0 && docId != 0) {
-      wx.navigateTo({
-        url: `/pages/publics/fileDetail/fileDetail?channelId=${chennelId}&docId=${docId}&url=${url}`
-      })
-    }
-  }
+	},
+	gotoZXWDK() {
+		wx.navigateTo({
+			url: '/pages/ZCWDK/index/index',
+		})
+	},
+	gotoLeaderDetail() {
+		wx.navigateTo({
+			url: '/pages/publics/publicLeaderDetail/publicLeaderDetail',
+		})
+	},
+	goToBaseAffairs() {
+		wx.navigateTo({
+			url: '/pages/publics/baseAffairs/baseAffairs',
+		})
+	},
+	goToFileList() {
+		wx.navigateTo({
+			url: '/pages/publics/fileList/fileList',
+		})
+	},
+	goTOFileDetail(e) {
+		var url = e.target.dataset.url
+		url = url.substring(0, url.lastIndexOf("/") + 1)
+		var docId = 0;
+		if (e.target.dataset.item) {
+			docId = e.target.dataset.item
+		}
+		var chennelId = 0;
+		switch (this.data.fileTab) {
+			case 0:
+				chennelId = 161753;
+				break;
+			case 1:
+				chennelId = 20442;
+				break;
+			case 2:
+				chennelId = 69336;
+				break;
+			default:
+				chennelId = 0;
+				break;
+		}
+		if (chennelId != 0 && docId != 0) {
+			wx.navigateTo({
+				url: `/pages/publics/fileDetail/fileDetail?channelId=${chennelId}&docId=${docId}&url=${url}`
+			})
+		}
+	}
 })

+ 146 - 94
nngkxxdp/src/main/resources/static/nnzwminiapp/pages/publics/interpretation/interpretation.js

@@ -1,98 +1,150 @@
 // pages/publics/interpretation/interpretation.js
+import {
+	imgUrl
+} from "../../api/request"
 Page({
 
-  /**
-   * 页面的初始数据
-   */
-  data: {
-    interpretationList: [{
-        title: '文字解读'
-      },
-      {
-        title: '图文解读'
-      },
-      {
-        title: '视频解读'
-      },
-      {
-        title: '媒体解读'
-      }
-    ],
-    currentTab: 0
-  },
-  // 切换
-  tabNav(e) {
-    let currentTab = e.currentTarget.dataset.index
-    this.setData({
-      currentTab
-    })
-  },
-  // 切换
-  handleSwiper(e) {
-    let {
-      current,
-      source
-    } = e.detail
-    if (source === 'autoplay' || source === 'touch') {
-      const currentTab = current
-      this.setData({
-        currentTab
-      })
-    }
-  },
-  /**
-   * 生命周期函数--监听页面加载
-   */
-  onLoad(options) {
-
-  },
-
-  /**
-   * 生命周期函数--监听页面初次渲染完成
-   */
-  onReady() {
-
-  },
-
-  /**
-   * 生命周期函数--监听页面显示
-   */
-  onShow() {
-
-  },
-
-  /**
-   * 生命周期函数--监听页面隐藏
-   */
-  onHide() {
-
-  },
-
-  /**
-   * 生命周期函数--监听页面卸载
-   */
-  onUnload() {
-
-  },
-
-  /**
-   * 页面相关事件处理函数--监听用户下拉动作
-   */
-  onPullDownRefresh() {
-
-  },
-
-  /**
-   * 页面上拉触底事件的处理函数
-   */
-  onReachBottom() {
-
-  },
-
-  /**
-   * 用户点击右上角分享
-   */
-  onShareAppMessage() {
-
-  }
+	/**
+	 * 页面的初始数据
+	 */
+	data: {
+		// 图片前缀
+		imgUrl: imgUrl,
+		interpretationList: [{
+				title: '文字解读',
+				channelId: '222894'
+			},
+			{
+				title: '图文解读',
+				channelId: '158049'
+			},
+			{
+				title: '视频解读',
+				channelId: '158049'
+			},
+			{
+				title: '媒体解读',
+				channelId: '222894'
+			}
+		],
+		currentTab: 0,
+		interpretationListInfo: [],
+		page: 1
+	},
+	// 切换
+	tabNav(e) {
+		let currentTab = e.currentTarget.dataset.index
+		this.setData({
+			currentTab
+		})
+	},
+	// 切换
+	handleSwiper(e) {
+		let {
+			current,
+			source
+		} = e.detail
+		if (source === 'autoplay' || source === 'touch') {
+			const currentTab = current
+			this.setData({
+				currentTab
+			})
+		}
+		this.setData({
+			interpretationListInfo: [],
+			page: 1
+		})
+		this.getInterpretationById();
+	},
+	// 获取政策解读列表
+	getInterpretationById() {
+		wx.showToast({
+			title: '加载中',
+			icon: 'loading',
+			duration: 1500
+		})
+
+		wx.request({
+			url: 'https://data.cqna.gov.cn/mini/hlw/send?page=' + this.data.page + '&limit=10&channelId=' + this.data.interpretationList[this.data.currentTab].channelId,
+			method: 'GET',
+			success: res => {
+				if (res.data.data.DATA.length > 0) {
+					let temp = res.data.data.DATA;
+					temp = this.data.interpretationListInfo.concat(temp);
+					this.setData({
+						interpretationListInfo: temp
+					})
+					wx.hideToast();
+				} else {
+					wx.showToast({
+						title: '已加载全部数据',
+						icon: 'success',
+						duration: 1000
+					})
+				}
+			}
+		})
+	},
+	// 触底
+	scrollBottom(e) {
+		this.setData({
+			page: this.data.page + 1
+		})
+		this.getInterpretationById()
+	},
+	/**
+	 * 生命周期函数--监听页面加载
+	 */
+	onLoad(options) {
+		this.getInterpretationById();
+	},
+
+	/**
+	 * 生命周期函数--监听页面初次渲染完成
+	 */
+	onReady() {
+
+	},
+
+	/**
+	 * 生命周期函数--监听页面显示
+	 */
+	onShow() {
+
+	},
+
+	/**
+	 * 生命周期函数--监听页面隐藏
+	 */
+	onHide() {
+
+	},
+
+	/**
+	 * 生命周期函数--监听页面卸载
+	 */
+	onUnload() {
+
+	},
+
+	/**
+	 * 页面相关事件处理函数--监听用户下拉动作
+	 */
+	onPullDownRefresh() {
+
+	},
+
+	/**
+	 * 页面上拉触底事件的处理函数
+	 */
+	onReachBottom() {
+
+	},
+
+	/**
+	 * 用户点击右上角分享
+	 */
+	onShareAppMessage() {
+
+	}
 })

+ 51 - 24
nngkxxdp/src/main/resources/static/nnzwminiapp/pages/publics/interpretation/interpretation.wxml

@@ -1,27 +1,54 @@
 <!--pages/publics/interpretation/interpretation.wxml-->
+<wxs module="filter" src="./util.wxs"></wxs>
 <view style="background: #FFFFFF;">
-  <scroll-view class="scroll-wrapper" scroll-x scroll-with-animation="true" scroll-into-view="item{{currentTab < 2 ? 0 : currentTab - 1}}">
-    <view class="navigate-item" id="item{{index}}" wx:for="{{interpretationList}}" wx:key="index" data-index="{{index}}" bindtap="tabNav">
-      <view class="names {{currentTab === index ? 'active' : ''}}">{{item.title}}</view>
-      <view class="currtline {{currentTab === index ? 'active' : ''}}" wx:if="{{currentTab === index}}"></view>
-    </view>
-  </scroll-view>
-  <swiper current="{{currentTab}}" style="width: 100%;height: 90vh;" bindchange="handleSwiper">
-    <swiper-item wx:for="{{interpretationList}}">
-      <scroll-view style="height: 100%;" scroll-y="true">
-        <view>
-          <ul class="list">
-            <li bindtap="gotoDetail">
-              <text class="title">《重庆市南岸区行政许可事项清单(2022年版)》政策解读</text>
-              <text class="time">2022-01-06 00:00</text>
-            </li>
-            <li bindtap="gotoDetail">
-              <text class="title">重庆市南岸区卫生健康发展“十四五”规划政策解读</text>
-              <text class="time">2022-09-11 13:23</text>
-            </li>
-          </ul>
-        </view>
-      </scroll-view>
-    </swiper-item>
-  </swiper>
+	<scroll-view class="scroll-wrapper" scroll-x scroll-with-animation="true" scroll-into-view="item{{currentTab < 2 ? 0 : currentTab - 1}}">
+		<view class="navigate-item" id="item{{index}}" wx:for="{{interpretationList}}" wx:key="index" data-index="{{index}}" bindtap="tabNav">
+			<view class="names {{currentTab === index ? 'active' : ''}}">{{item.title}}</view>
+			<view class="currtline {{currentTab === index ? 'active' : ''}}" wx:if="{{currentTab === index}}"></view>
+		</view>
+	</scroll-view>
+	<swiper current="{{currentTab}}" style="width: 100%;height: 90vh;" bindchange="handleSwiper">
+		<!-- 文字解读 -->
+		<swiper-item>
+			<scroll-view scroll-y="true" style="height: 100%;padding:0;margin:0;" bindscrolltolower="scrollBottom">
+				<view wx:for-item="item" wx:for-index="index" wx:key="index" wx:for="{{interpretationListInfo}}" style="display: flex;align-items: center;justify-content: space-between;flex-wrap: wrap;height: 120rpx;font-size: 28rpx;color: #666666;width: 700rpx;margin-left: 23rpx;border-bottom: 2rpx solid #CCCCCC;">
+					<view class="limit-text-1" style="width: 400rpx;-webkit-line-clamp:2;overflow:hidden;text-overflow: ellipsis;display: -webkit-box;-webkit-box-orient:vertical;">{{item.DOCTITLE}}</view>
+					<view>{{filter.formateDate(item.DOCPUBTIME)}}</view>
+					<view style="color: #c0d1e5;border: 1rpx solid #c0d1e5;border-radius: 10rpx;padding: 10rpx;">政策原文</view>
+				</view>
+			</scroll-view>
+		</swiper-item>
+		<!-- 图片解读 -->
+		<swiper-item>
+			<scroll-view scroll-y="true" style="height: 100%;padding:0;margin:0;" bindscrolltolower="scrollBottom">
+				<view style="display: flex;justify-content: space-around;flex-wrap: wrap;">
+					<view style="width: 327rpx;" wx:for="{{interpretationListInfo}}" wx:key="index">
+						<image src="{{imgUrl}}图层 3261.png" style="width: 327rpx;height: 227rpx;"></image>
+						<view style="font-size: 25rpx;font-family: PingFang SC;color: #666666;-webkit-line-clamp:2;overflow:hidden;text-overflow: ellipsis;display: -webkit-box;-webkit-box-orient:vertical;">{{item.DOCTITLE}}</view>
+					</view>
+				</view>
+			</scroll-view>
+		</swiper-item>
+		<!-- 视频解读 -->
+		<swiper-item>
+			<scroll-view scroll-y="true" style="height: 100%;padding:0;margin:0;" bindscrolltolower="scrollBottom">
+				<view style="display: flex;justify-content: space-around;flex-wrap: wrap;">
+					<view style="width: 327rpx;" wx:for="{{interpretationListInfo}}" wx:key="index">
+						<image src="{{imgUrl}}图层 3261.png" style="width: 327rpx;height: 227rpx;"></image>
+						<view style="font-size: 25rpx;font-family: PingFang SC;color: #666666;-webkit-line-clamp:2;overflow:hidden;text-overflow: ellipsis;display: -webkit-box;-webkit-box-orient:vertical;">{{item.DOCTITLE}}</view>
+					</view>
+				</view>
+			</scroll-view>
+		</swiper-item>
+		<!-- 媒体解读 -->
+		<swiper-item>
+			<scroll-view scroll-y="true" style="height: 100%;padding:0;margin:0;" bindscrolltolower="scrollBottom">
+				<view wx:for-item="item" wx:for-index="index" wx:key="index" wx:for="{{interpretationListInfo}}" style="display: flex;align-items: center;justify-content: space-between;flex-wrap: wrap;height: 120rpx;font-size: 28rpx;color: #666666;width: 700rpx;margin-left: 23rpx;border-bottom: 2rpx solid #CCCCCC;">
+					<view class="limit-text-1" style="width: 400rpx;-webkit-line-clamp:2;overflow:hidden;text-overflow: ellipsis;display: -webkit-box;-webkit-box-orient:vertical;">{{item.DOCTITLE}}</view>
+					<view>{{filter.formateDate(item.DOCPUBTIME)}}</view>
+					<view style="color: #c0d1e5;border: 1rpx solid #c0d1e5;border-radius: 10rpx;padding: 10rpx;">政策原文</view>
+				</view>
+			</scroll-view>
+		</swiper-item>
+	</swiper>
 </view>

+ 14 - 0
nngkxxdp/src/main/resources/static/nnzwminiapp/pages/publics/interpretation/util.wxs

@@ -0,0 +1,14 @@
+// 支持es4语法
+var filter = {
+	formateDate: function(data) {
+		if (data && data != '') {
+			return data.slice(5,10)
+		} else {
+			return ''
+		}
+	}
+}
+// 导出对外暴露的属性
+module.exports = {
+	formateDate: filter.formateDate
+}