Pārlūkot izejas kodu

新增研究成果列表

LinWuTai 1 gadu atpakaļ
vecāks
revīzija
a6fdaf0b29
58 mainītis faili ar 230 papildinājumiem un 49 dzēšanām
  1. 6 3
      api/visitor.js
  2. 8 1
      pages.json
  3. 16 2
      pages/notice/notice.vue
  4. 22 4
      pages/visitor/index.vue
  5. 132 0
      pages/visitor/noticeList.vue
  6. 0 0
      unpackage/dist/dev/.sourcemap/mp-weixin/common/main.js.map
  7. 0 0
      unpackage/dist/dev/.sourcemap/mp-weixin/common/vendor.js.map
  8. 0 0
      unpackage/dist/dev/.sourcemap/mp-weixin/node-modules/uview-ui/components/u-avatar/u-avatar.js.map
  9. 0 0
      unpackage/dist/dev/.sourcemap/mp-weixin/node-modules/uview-ui/components/u-button/u-button.js.map
  10. 0 0
      unpackage/dist/dev/.sourcemap/mp-weixin/node-modules/uview-ui/components/u-cell-group/u-cell-group.js.map
  11. 0 0
      unpackage/dist/dev/.sourcemap/mp-weixin/node-modules/uview-ui/components/u-cell/u-cell.js.map
  12. 0 0
      unpackage/dist/dev/.sourcemap/mp-weixin/node-modules/uview-ui/components/u-col/u-col.js.map
  13. 0 0
      unpackage/dist/dev/.sourcemap/mp-weixin/node-modules/uview-ui/components/u-datetime-picker/u-datetime-picker.js.map
  14. 0 0
      unpackage/dist/dev/.sourcemap/mp-weixin/node-modules/uview-ui/components/u-empty/u-empty.js.map
  15. 0 0
      unpackage/dist/dev/.sourcemap/mp-weixin/node-modules/uview-ui/components/u-form-item/u-form-item.js.map
  16. 0 0
      unpackage/dist/dev/.sourcemap/mp-weixin/node-modules/uview-ui/components/u-icon/u-icon.js.map
  17. 0 0
      unpackage/dist/dev/.sourcemap/mp-weixin/node-modules/uview-ui/components/u-input/u-input.js.map
  18. 0 0
      unpackage/dist/dev/.sourcemap/mp-weixin/node-modules/uview-ui/components/u-line/u-line.js.map
  19. 0 0
      unpackage/dist/dev/.sourcemap/mp-weixin/node-modules/uview-ui/components/u-link/u-link.js.map
  20. 0 0
      unpackage/dist/dev/.sourcemap/mp-weixin/node-modules/uview-ui/components/u-list-item/u-list-item.js.map
  21. 0 0
      unpackage/dist/dev/.sourcemap/mp-weixin/node-modules/uview-ui/components/u-list/u-list.js.map
  22. 0 0
      unpackage/dist/dev/.sourcemap/mp-weixin/node-modules/uview-ui/components/u-loading-icon/u-loading-icon.js.map
  23. 0 0
      unpackage/dist/dev/.sourcemap/mp-weixin/node-modules/uview-ui/components/u-overlay/u-overlay.js.map
  24. 0 0
      unpackage/dist/dev/.sourcemap/mp-weixin/node-modules/uview-ui/components/u-picker/u-picker.js.map
  25. 0 0
      unpackage/dist/dev/.sourcemap/mp-weixin/node-modules/uview-ui/components/u-popup/u-popup.js.map
  26. 0 0
      unpackage/dist/dev/.sourcemap/mp-weixin/node-modules/uview-ui/components/u-row/u-row.js.map
  27. 0 0
      unpackage/dist/dev/.sourcemap/mp-weixin/node-modules/uview-ui/components/u-safe-bottom/u-safe-bottom.js.map
  28. 0 0
      unpackage/dist/dev/.sourcemap/mp-weixin/node-modules/uview-ui/components/u-search/u-search.js.map
  29. 0 0
      unpackage/dist/dev/.sourcemap/mp-weixin/node-modules/uview-ui/components/u-status-bar/u-status-bar.js.map
  30. 0 0
      unpackage/dist/dev/.sourcemap/mp-weixin/node-modules/uview-ui/components/u-text/u-text.js.map
  31. 0 0
      unpackage/dist/dev/.sourcemap/mp-weixin/node-modules/uview-ui/components/u-toolbar/u-toolbar.js.map
  32. 0 0
      unpackage/dist/dev/.sourcemap/mp-weixin/node-modules/uview-ui/components/u-transition/u-transition.js.map
  33. 0 0
      unpackage/dist/dev/.sourcemap/mp-weixin/pages/borrow/borrow.js.map
  34. 0 0
      unpackage/dist/dev/.sourcemap/mp-weixin/pages/home/home.js.map
  35. 0 0
      unpackage/dist/dev/.sourcemap/mp-weixin/pages/login/login.js.map
  36. 0 0
      unpackage/dist/dev/.sourcemap/mp-weixin/pages/logo/index.js.map
  37. 0 0
      unpackage/dist/dev/.sourcemap/mp-weixin/pages/menus/borrow-record/borrow-record.js.map
  38. 0 0
      unpackage/dist/dev/.sourcemap/mp-weixin/pages/menus/menu/menu.js.map
  39. 0 0
      unpackage/dist/dev/.sourcemap/mp-weixin/pages/menus/mine/mine.js.map
  40. 0 0
      unpackage/dist/dev/.sourcemap/mp-weixin/pages/return/return.js.map
  41. 0 0
      unpackage/dist/dev/.sourcemap/mp-weixin/pages/search/search.js.map
  42. 2 1
      unpackage/dist/dev/mp-weixin/app.json
  43. 16 11
      unpackage/dist/dev/mp-weixin/common/vendor.js
  44. 2 2
      unpackage/dist/dev/mp-weixin/node-modules/uview-ui/components/u-avatar/u-avatar.json
  45. 2 2
      unpackage/dist/dev/mp-weixin/node-modules/uview-ui/components/u-button/u-button.json
  46. 2 2
      unpackage/dist/dev/mp-weixin/node-modules/uview-ui/components/u-cell-group/u-cell-group.json
  47. 2 2
      unpackage/dist/dev/mp-weixin/node-modules/uview-ui/components/u-cell/u-cell.json
  48. 2 2
      unpackage/dist/dev/mp-weixin/node-modules/uview-ui/components/u-col/u-col.json
  49. 2 2
      unpackage/dist/dev/mp-weixin/node-modules/uview-ui/components/u-datetime-picker/u-datetime-picker.json
  50. 2 2
      unpackage/dist/dev/mp-weixin/node-modules/uview-ui/components/u-empty/u-empty.json
  51. 2 2
      unpackage/dist/dev/mp-weixin/node-modules/uview-ui/components/u-list-item/u-list-item.json
  52. 2 2
      unpackage/dist/dev/mp-weixin/node-modules/uview-ui/components/u-list/u-list.json
  53. 2 2
      unpackage/dist/dev/mp-weixin/node-modules/uview-ui/components/u-picker/u-picker.json
  54. 2 2
      unpackage/dist/dev/mp-weixin/node-modules/uview-ui/components/u-popup/u-popup.json
  55. 2 2
      unpackage/dist/dev/mp-weixin/node-modules/uview-ui/components/u-row/u-row.json
  56. 2 2
      unpackage/dist/dev/mp-weixin/node-modules/uview-ui/components/u-search/u-search.json
  57. 1 1
      utils/baseurl.js
  58. 1 0
      utils/permission.js

+ 6 - 3
api/visitor.js

@@ -9,8 +9,11 @@ export function assetDetail(barCode) {
 	return request.get(`/visitor/asset/detail/${barCode}`)
 	return request.get(`/visitor/asset/detail/${barCode}`)
 }
 }
 
 
-export function studyList() {
-	return request.get('/visitor/study/list')
+export function studyList(x,y){
+	return request.get('/visitor/study/list',{
+		pageNum:x,
+		pageSize:y
+	}).then(res=>res)
 }
 }
 
 
 export function studyNew(number) {
 export function studyNew(number) {
@@ -18,7 +21,7 @@ export function studyNew(number) {
 }
 }
 
 
 export function studyDetail(studyId) {
 export function studyDetail(studyId) {
-	return request.get(`/visitor/study/detail/${noticeId}`)
+	return request.get(`/visitor/study/detail/${studyId}`)
 }
 }
 
 
 export function getImage(src) {
 export function getImage(src) {

+ 8 - 1
pages.json

@@ -138,7 +138,14 @@
                 "enablePullDownRefresh": false
                 "enablePullDownRefresh": false
             }
             }
             
             
-        }
+        },
+				{
+					"path" : "pages/visitor/noticeList",
+					"style": {
+						"navigationBarTitleText": "成果列表",
+						"enablePullDownRefresh": false
+					}
+				}
     ],
     ],
 	"globalStyle": {
 	"globalStyle": {
 		"navigationBarTextStyle": "black",
 		"navigationBarTextStyle": "black",

+ 16 - 2
pages/notice/notice.vue

@@ -9,7 +9,8 @@
 </template>
 </template>
 
 
 <script>
 <script>
-	import { getNoticeDetail } from '@/api/notice.js'
+	import { studyDetail } from '@/api/visitor.js'
+	import baseUrl from '@/utils/baseurl.js'
 	export default {
 	export default {
 		data() {
 		data() {
 			return {
 			return {
@@ -24,7 +25,20 @@
 		},
 		},
 		methods:{
 		methods:{
 			init(){
 			init(){
-				getNoticeDetail(this.id).then(res=>{
+				const arr = baseUrl.split("/")
+				let url = ''
+				for(let i = 0; i < arr.length - 1; i++) {
+					if (i != arr.length - 2) {
+						url += arr[i] + "/"
+						continue
+					}
+					url += arr[i]
+				}
+				studyDetail(this.id).then(res=>{
+					res.noticeContent = res.noticeContent.replace(/<img [^>]*src=['"]([^'"]+)[^>]*>/gi, (match, p1) => {
+							console.log(match)
+					    return `<img style="width: 90%;text-align: center;" src='${p1.indexOf('http') > -1 ? p1 : url + p1}' />`
+					})
 					this.info = res
 					this.info = res
 				})
 				})
 			}
 			}

+ 22 - 4
pages/visitor/index.vue

@@ -1,6 +1,6 @@
 <template>
 <template>
 	<view class="container">
 	<view class="container">
-		<view class="search-area">
+		<!-- <view class="search-area">
 			<u-search 
 			<u-search 
 			placeholder="搜索设备" 
 			placeholder="搜索设备" 
 			v-model="keyword" 
 			v-model="keyword" 
@@ -16,14 +16,14 @@
 			bgColor="#fff"
 			bgColor="#fff"
 			height="40"
 			height="40"
 			@custom="search"></u-search>
 			@custom="search"></u-search>
-		</view>
+		</view> -->
 		
 		
 		<view class="study-box">
 		<view class="study-box">
 			<view class="title">
 			<view class="title">
 				研究成果栏
 				研究成果栏
 			</view>
 			</view>
 			<view class="list">
 			<view class="list">
-				<view class="study" v-for="study in studyList" :key="study.id">
+				<view class="study" v-for="study in studyList" :key="study.noticeId" @click="toNotice(study.noticeId)">
 					<view class="title">
 					<view class="title">
 						{{study.noticeTitle}}
 						{{study.noticeTitle}}
 					</view>
 					</view>
@@ -37,6 +37,9 @@
 					</view>
 					</view>
 				</view>
 				</view>
 			</view>
 			</view>
+			<view class="more" v-if="studyList.length" @click="toList">
+				更多
+			</view>
 		</view>
 		</view>
 		<view class="asset-box">
 		<view class="asset-box">
 			<view class="title">
 			<view class="title">
@@ -69,6 +72,7 @@
 		name: 'Visitor-Index',
 		name: 'Visitor-Index',
 		data() {
 		data() {
 			return {
 			return {
+				studyNumber: 3,
 				assetList: [],
 				assetList: [],
 				studyList: []
 				studyList: []
 			}
 			}
@@ -80,7 +84,7 @@
 				})
 				})
 			},
 			},
 			getNewStudy() {
 			getNewStudy() {
-				studyNew(5).then(res => {
+				studyNew(this.studyNumber).then(res => {
 					this.studyList = res
 					this.studyList = res
 					console.log('研究成果数据', res);
 					console.log('研究成果数据', res);
 				})
 				})
@@ -93,11 +97,21 @@
 			},
 			},
 			/** 搜索框 */
 			/** 搜索框 */
 			search() {},
 			search() {},
+			toList() {
+				uni.navigateTo({
+					url: '/pages/visitor/noticeList'
+				});
+			},
 			toDetail(asset) {
 			toDetail(asset) {
 				console.log('资产信息', asset);
 				console.log('资产信息', asset);
 				uni.navigateTo({
 				uni.navigateTo({
 					url: '/pages/visitor/assetDetail/assetDetail?barCode=' + asset.barCode
 					url: '/pages/visitor/assetDetail/assetDetail?barCode=' + asset.barCode
 				});
 				});
+			},
+			toNotice(id){
+				uni.navigateTo({
+					url:'/pages/notice/notice?id='+id,
+				})
 			}
 			}
 		},
 		},
 		onLoad() {
 		onLoad() {
@@ -155,6 +169,10 @@
 					overflow: hidden;
 					overflow: hidden;
 				}
 				}
 			}
 			}
+			.more {
+				text-align: right;
+				padding-top: 10rpx;
+			}
 		}
 		}
 		
 		
 		.asset-box{
 		.asset-box{

+ 132 - 0
pages/visitor/noticeList.vue

@@ -0,0 +1,132 @@
+<template>
+	<view style="padding:30rpx 0 0 0;height: 100vh;box-sizing: border-box;">
+		<u-list @scrolltolower="scrolltolower" class="notice-ul" height="100%">
+			<u-list-item  v-for="data in noticeData" :key="data.noticeId">
+				<view class="notice-area"  @click="toNotice(data.noticeId)">
+					<view class="area-header">
+						<view style="width: 100%;display: flex;">
+							<i class="iconfont icon-tongzhi"></i>
+							<text 
+							style="width: 100%;overflow: hidden;white-space: nowrap;text-overflow: ellipsis;">
+							{{data.noticeTitle}}
+							</text>
+						</view>
+						<text class="up-date">分布时间:{{data.updateTime}}</text>
+					</view>
+					<view class="area-content">
+						<rich-text 
+						:nodes="data.noticeContent" 
+						style="overflow: hidden;display: -webkit-box;-webkit-box-orient: vertical;-webkit-line-clamp: 3;line-height: 60rpx;">
+						</rich-text>
+					</view>
+				</view>
+			</u-list-item>
+			<u-list-item v-if="textShow">
+				<view style="text-align: center;margin-bottom: 30rpx;">
+					已加载全部数据
+				</view>
+			</u-list-item>
+		</u-list>
+		
+	</view>
+</template>
+
+<script>
+	import { studyList } from '@/api/visitor.js'
+	export default {
+		data() {
+			return {
+				noticeData:[],
+				page:1,
+				total:6,
+				pageSize:5,
+				textShow:false
+			};
+		},
+		methods:{
+			toNotice(id){
+				uni.navigateTo({
+					url:'/pages/notice/notice?id='+id,
+				})
+			},
+			handleDate(val){
+				let date = new Date(val)
+				let year = date.getFullYear()
+				let month = date.getMonth()+1
+				let day = date.getDate()
+				return year+"-"+month+"-"+day;
+			},
+			scrolltolower(){
+				if(Math.ceil(this.total/this.pageSize)<this.page){
+					return;
+				}else if(Math.ceil(this.total/this.pageSize)>=this.page){
+					this.getNoticeList(this.page,this.pageSize)
+				}
+			},
+			getNoticeList(x,y){
+				const that = this
+				uni.showLoading({
+					icon:"none",
+					title:"记载中"
+				})
+				try{
+					studyList(x,y).then(res=>{
+						uni.hideLoading()
+						if(res.data.rows){
+							if(that.page===1){
+								that.noticeData = res.data.rows
+							}else{
+								that.noticeData = [...that.noticeData,...res.data.rows]
+							}
+							that.total = res.data.total
+							that.page = that.page +1
+							if(Math.ceil(that.total/that.pageSize)<that.page){
+								that.textShow = true
+							}else{
+								that.textShow = false
+							}
+						}
+					})
+				}catch(err){
+					uni.hideLoading()
+				}
+				
+			}
+		},
+		onLoad() {
+			this.getNoticeList(1,this.pageSize)
+		}
+	}
+</script>
+
+<style lang="scss">
+page{
+	background-color: #f5f6fa;height: 100%;
+}
+.notice-area{
+	background-color: #fff;
+	margin: 0rpx 25rpx 30rpx 25rpx;
+	padding: 30rpx 32rpx;
+	border-radius: 30rpx;
+	box-shadow: 0px 0px 21px 0px rgba(241, 241, 241, 1);
+	.area-header{
+		padding-bottom: 10rpx;
+		font-size: 40rpx;
+		font-weight: bold;
+		color: #323232;
+		i{
+			font-size: 50rpx;
+			padding-right: 10rpx;
+			color: #228ff6;
+		}
+		.up-date{
+			color: #9b9b9b;
+			font-size: 26rpx;
+			font-weight: 500;
+		}
+	}
+	.area-content{
+		padding-top: 10rpx;
+	}
+}
+</style>

Failā izmaiņas netiks attēlotas, jo tās ir par lielu
+ 0 - 0
unpackage/dist/dev/.sourcemap/mp-weixin/common/main.js.map


Failā izmaiņas netiks attēlotas, jo tās ir par lielu
+ 0 - 0
unpackage/dist/dev/.sourcemap/mp-weixin/common/vendor.js.map


Failā izmaiņas netiks attēlotas, jo tās ir par lielu
+ 0 - 0
unpackage/dist/dev/.sourcemap/mp-weixin/node-modules/uview-ui/components/u-avatar/u-avatar.js.map


Failā izmaiņas netiks attēlotas, jo tās ir par lielu
+ 0 - 0
unpackage/dist/dev/.sourcemap/mp-weixin/node-modules/uview-ui/components/u-button/u-button.js.map


Failā izmaiņas netiks attēlotas, jo tās ir par lielu
+ 0 - 0
unpackage/dist/dev/.sourcemap/mp-weixin/node-modules/uview-ui/components/u-cell-group/u-cell-group.js.map


Failā izmaiņas netiks attēlotas, jo tās ir par lielu
+ 0 - 0
unpackage/dist/dev/.sourcemap/mp-weixin/node-modules/uview-ui/components/u-cell/u-cell.js.map


Failā izmaiņas netiks attēlotas, jo tās ir par lielu
+ 0 - 0
unpackage/dist/dev/.sourcemap/mp-weixin/node-modules/uview-ui/components/u-col/u-col.js.map


Failā izmaiņas netiks attēlotas, jo tās ir par lielu
+ 0 - 0
unpackage/dist/dev/.sourcemap/mp-weixin/node-modules/uview-ui/components/u-datetime-picker/u-datetime-picker.js.map


Failā izmaiņas netiks attēlotas, jo tās ir par lielu
+ 0 - 0
unpackage/dist/dev/.sourcemap/mp-weixin/node-modules/uview-ui/components/u-empty/u-empty.js.map


Failā izmaiņas netiks attēlotas, jo tās ir par lielu
+ 0 - 0
unpackage/dist/dev/.sourcemap/mp-weixin/node-modules/uview-ui/components/u-form-item/u-form-item.js.map


Failā izmaiņas netiks attēlotas, jo tās ir par lielu
+ 0 - 0
unpackage/dist/dev/.sourcemap/mp-weixin/node-modules/uview-ui/components/u-icon/u-icon.js.map


Failā izmaiņas netiks attēlotas, jo tās ir par lielu
+ 0 - 0
unpackage/dist/dev/.sourcemap/mp-weixin/node-modules/uview-ui/components/u-input/u-input.js.map


Failā izmaiņas netiks attēlotas, jo tās ir par lielu
+ 0 - 0
unpackage/dist/dev/.sourcemap/mp-weixin/node-modules/uview-ui/components/u-line/u-line.js.map


Failā izmaiņas netiks attēlotas, jo tās ir par lielu
+ 0 - 0
unpackage/dist/dev/.sourcemap/mp-weixin/node-modules/uview-ui/components/u-link/u-link.js.map


Failā izmaiņas netiks attēlotas, jo tās ir par lielu
+ 0 - 0
unpackage/dist/dev/.sourcemap/mp-weixin/node-modules/uview-ui/components/u-list-item/u-list-item.js.map


Failā izmaiņas netiks attēlotas, jo tās ir par lielu
+ 0 - 0
unpackage/dist/dev/.sourcemap/mp-weixin/node-modules/uview-ui/components/u-list/u-list.js.map


Failā izmaiņas netiks attēlotas, jo tās ir par lielu
+ 0 - 0
unpackage/dist/dev/.sourcemap/mp-weixin/node-modules/uview-ui/components/u-loading-icon/u-loading-icon.js.map


Failā izmaiņas netiks attēlotas, jo tās ir par lielu
+ 0 - 0
unpackage/dist/dev/.sourcemap/mp-weixin/node-modules/uview-ui/components/u-overlay/u-overlay.js.map


Failā izmaiņas netiks attēlotas, jo tās ir par lielu
+ 0 - 0
unpackage/dist/dev/.sourcemap/mp-weixin/node-modules/uview-ui/components/u-picker/u-picker.js.map


Failā izmaiņas netiks attēlotas, jo tās ir par lielu
+ 0 - 0
unpackage/dist/dev/.sourcemap/mp-weixin/node-modules/uview-ui/components/u-popup/u-popup.js.map


Failā izmaiņas netiks attēlotas, jo tās ir par lielu
+ 0 - 0
unpackage/dist/dev/.sourcemap/mp-weixin/node-modules/uview-ui/components/u-row/u-row.js.map


Failā izmaiņas netiks attēlotas, jo tās ir par lielu
+ 0 - 0
unpackage/dist/dev/.sourcemap/mp-weixin/node-modules/uview-ui/components/u-safe-bottom/u-safe-bottom.js.map


Failā izmaiņas netiks attēlotas, jo tās ir par lielu
+ 0 - 0
unpackage/dist/dev/.sourcemap/mp-weixin/node-modules/uview-ui/components/u-search/u-search.js.map


Failā izmaiņas netiks attēlotas, jo tās ir par lielu
+ 0 - 0
unpackage/dist/dev/.sourcemap/mp-weixin/node-modules/uview-ui/components/u-status-bar/u-status-bar.js.map


Failā izmaiņas netiks attēlotas, jo tās ir par lielu
+ 0 - 0
unpackage/dist/dev/.sourcemap/mp-weixin/node-modules/uview-ui/components/u-text/u-text.js.map


Failā izmaiņas netiks attēlotas, jo tās ir par lielu
+ 0 - 0
unpackage/dist/dev/.sourcemap/mp-weixin/node-modules/uview-ui/components/u-toolbar/u-toolbar.js.map


Failā izmaiņas netiks attēlotas, jo tās ir par lielu
+ 0 - 0
unpackage/dist/dev/.sourcemap/mp-weixin/node-modules/uview-ui/components/u-transition/u-transition.js.map


Failā izmaiņas netiks attēlotas, jo tās ir par lielu
+ 0 - 0
unpackage/dist/dev/.sourcemap/mp-weixin/pages/borrow/borrow.js.map


Failā izmaiņas netiks attēlotas, jo tās ir par lielu
+ 0 - 0
unpackage/dist/dev/.sourcemap/mp-weixin/pages/home/home.js.map


Failā izmaiņas netiks attēlotas, jo tās ir par lielu
+ 0 - 0
unpackage/dist/dev/.sourcemap/mp-weixin/pages/login/login.js.map


Failā izmaiņas netiks attēlotas, jo tās ir par lielu
+ 0 - 0
unpackage/dist/dev/.sourcemap/mp-weixin/pages/logo/index.js.map


Failā izmaiņas netiks attēlotas, jo tās ir par lielu
+ 0 - 0
unpackage/dist/dev/.sourcemap/mp-weixin/pages/menus/borrow-record/borrow-record.js.map


Failā izmaiņas netiks attēlotas, jo tās ir par lielu
+ 0 - 0
unpackage/dist/dev/.sourcemap/mp-weixin/pages/menus/menu/menu.js.map


Failā izmaiņas netiks attēlotas, jo tās ir par lielu
+ 0 - 0
unpackage/dist/dev/.sourcemap/mp-weixin/pages/menus/mine/mine.js.map


Failā izmaiņas netiks attēlotas, jo tās ir par lielu
+ 0 - 0
unpackage/dist/dev/.sourcemap/mp-weixin/pages/return/return.js.map


Failā izmaiņas netiks attēlotas, jo tās ir par lielu
+ 0 - 0
unpackage/dist/dev/.sourcemap/mp-weixin/pages/search/search.js.map


+ 2 - 1
unpackage/dist/dev/mp-weixin/app.json

@@ -15,7 +15,8 @@
     "pages/fault/fault-list/fault-list",
     "pages/fault/fault-list/fault-list",
     "pages/fault/fault-handle/fault-handle",
     "pages/fault/fault-handle/fault-handle",
     "pages/notice-list/notice-list",
     "pages/notice-list/notice-list",
-    "pages/visitor/assetDetail/assetDetail"
+    "pages/visitor/assetDetail/assetDetail",
+    "pages/visitor/noticeList"
   ],
   ],
   "subPackages": [],
   "subPackages": [],
   "window": {
   "window": {

+ 16 - 11
unpackage/dist/dev/mp-weixin/common/vendor.js

@@ -1557,7 +1557,7 @@ function initData(vueOptions, context) {
     try {
     try {
       data = data.call(context); // 支持 Vue.prototype 上挂的数据
       data = data.call(context); // 支持 Vue.prototype 上挂的数据
     } catch (e) {
     } catch (e) {
-      if (Object({"NODE_ENV":"development","VUE_APP_DARK_MODE":"false","VUE_APP_NAME":"lab-equipment-mini-program","VUE_APP_PLATFORM":"mp-weixin","BASE_URL":"/"}).VUE_APP_DEBUG) {
+      if (Object({"VUE_APP_DARK_MODE":"false","VUE_APP_NAME":"lab-equipment-mini-program","VUE_APP_PLATFORM":"mp-weixin","NODE_ENV":"development","BASE_URL":"/"}).VUE_APP_DEBUG) {
         console.warn('根据 Vue 的 data 函数初始化小程序 data 失败,请尽量确保 data 函数中不访问 vm 对象,否则可能影响首次数据渲染速度。', data);
         console.warn('根据 Vue 的 data 函数初始化小程序 data 失败,请尽量确保 data 函数中不访问 vm 对象,否则可能影响首次数据渲染速度。', data);
       }
       }
     }
     }
@@ -8938,7 +8938,7 @@ function type(obj) {
 
 
 function flushCallbacks$1(vm) {
 function flushCallbacks$1(vm) {
     if (vm.__next_tick_callbacks && vm.__next_tick_callbacks.length) {
     if (vm.__next_tick_callbacks && vm.__next_tick_callbacks.length) {
-        if (Object({"NODE_ENV":"development","VUE_APP_DARK_MODE":"false","VUE_APP_NAME":"lab-equipment-mini-program","VUE_APP_PLATFORM":"mp-weixin","BASE_URL":"/"}).VUE_APP_DEBUG) {
+        if (Object({"VUE_APP_DARK_MODE":"false","VUE_APP_NAME":"lab-equipment-mini-program","VUE_APP_PLATFORM":"mp-weixin","NODE_ENV":"development","BASE_URL":"/"}).VUE_APP_DEBUG) {
             var mpInstance = vm.$scope;
             var mpInstance = vm.$scope;
             console.log('[' + (+new Date) + '][' + (mpInstance.is || mpInstance.route) + '][' + vm._uid +
             console.log('[' + (+new Date) + '][' + (mpInstance.is || mpInstance.route) + '][' + vm._uid +
                 ']:flushCallbacks[' + vm.__next_tick_callbacks.length + ']');
                 ']:flushCallbacks[' + vm.__next_tick_callbacks.length + ']');
@@ -8959,14 +8959,14 @@ function nextTick$1(vm, cb) {
     //1.nextTick 之前 已 setData 且 setData 还未回调完成
     //1.nextTick 之前 已 setData 且 setData 还未回调完成
     //2.nextTick 之前存在 render watcher
     //2.nextTick 之前存在 render watcher
     if (!vm.__next_tick_pending && !hasRenderWatcher(vm)) {
     if (!vm.__next_tick_pending && !hasRenderWatcher(vm)) {
-        if(Object({"NODE_ENV":"development","VUE_APP_DARK_MODE":"false","VUE_APP_NAME":"lab-equipment-mini-program","VUE_APP_PLATFORM":"mp-weixin","BASE_URL":"/"}).VUE_APP_DEBUG){
+        if(Object({"VUE_APP_DARK_MODE":"false","VUE_APP_NAME":"lab-equipment-mini-program","VUE_APP_PLATFORM":"mp-weixin","NODE_ENV":"development","BASE_URL":"/"}).VUE_APP_DEBUG){
             var mpInstance = vm.$scope;
             var mpInstance = vm.$scope;
             console.log('[' + (+new Date) + '][' + (mpInstance.is || mpInstance.route) + '][' + vm._uid +
             console.log('[' + (+new Date) + '][' + (mpInstance.is || mpInstance.route) + '][' + vm._uid +
                 ']:nextVueTick');
                 ']:nextVueTick');
         }
         }
         return nextTick(cb, vm)
         return nextTick(cb, vm)
     }else{
     }else{
-        if(Object({"NODE_ENV":"development","VUE_APP_DARK_MODE":"false","VUE_APP_NAME":"lab-equipment-mini-program","VUE_APP_PLATFORM":"mp-weixin","BASE_URL":"/"}).VUE_APP_DEBUG){
+        if(Object({"VUE_APP_DARK_MODE":"false","VUE_APP_NAME":"lab-equipment-mini-program","VUE_APP_PLATFORM":"mp-weixin","NODE_ENV":"development","BASE_URL":"/"}).VUE_APP_DEBUG){
             var mpInstance$1 = vm.$scope;
             var mpInstance$1 = vm.$scope;
             console.log('[' + (+new Date) + '][' + (mpInstance$1.is || mpInstance$1.route) + '][' + vm._uid +
             console.log('[' + (+new Date) + '][' + (mpInstance$1.is || mpInstance$1.route) + '][' + vm._uid +
                 ']:nextMPTick');
                 ']:nextMPTick');
@@ -9062,7 +9062,7 @@ var patch = function(oldVnode, vnode) {
     });
     });
     var diffData = this.$shouldDiffData === false ? data : diff(data, mpData);
     var diffData = this.$shouldDiffData === false ? data : diff(data, mpData);
     if (Object.keys(diffData).length) {
     if (Object.keys(diffData).length) {
-      if (Object({"NODE_ENV":"development","VUE_APP_DARK_MODE":"false","VUE_APP_NAME":"lab-equipment-mini-program","VUE_APP_PLATFORM":"mp-weixin","BASE_URL":"/"}).VUE_APP_DEBUG) {
+      if (Object({"VUE_APP_DARK_MODE":"false","VUE_APP_NAME":"lab-equipment-mini-program","VUE_APP_PLATFORM":"mp-weixin","NODE_ENV":"development","BASE_URL":"/"}).VUE_APP_DEBUG) {
         console.log('[' + (+new Date) + '][' + (mpInstance.is || mpInstance.route) + '][' + this._uid +
         console.log('[' + (+new Date) + '][' + (mpInstance.is || mpInstance.route) + '][' + this._uid +
           ']差量更新',
           ']差量更新',
           JSON.stringify(diffData));
           JSON.stringify(diffData));
@@ -9519,7 +9519,7 @@ var whiteList = ['/',
   pattern: /^\/pages\/list.*/
   pattern: /^\/pages\/list.*/
 },
 },
 // 支持正则表达式
 // 支持正则表达式
-'/pages/home/home', '/pages/logo/index', '/pages/login/login', {
+'/pages/home/home', '/pages/logo/index', '/pages/login/login', '/pages/notice/notice', {
   pattern: /^\/pages\/visitor\/*/
   pattern: /^\/pages\/visitor\/*/
 }, {
 }, {
   pattern: /^\/pages\/login\/*/
   pattern: /^\/pages\/login\/*/
@@ -19342,14 +19342,19 @@ function assetList() {
 function assetDetail(barCode) {
 function assetDetail(barCode) {
   return _request.default.get("/visitor/asset/detail/".concat(barCode));
   return _request.default.get("/visitor/asset/detail/".concat(barCode));
 }
 }
-function studyList() {
-  return _request.default.get('/visitor/study/list');
+function studyList(x, y) {
+  return _request.default.get('/visitor/study/list', {
+    pageNum: x,
+    pageSize: y
+  }).then(function (res) {
+    return res;
+  });
 }
 }
 function studyNew(number) {
 function studyNew(number) {
   return _request.default.get("/visitor/study/new?number=".concat(number));
   return _request.default.get("/visitor/study/new?number=".concat(number));
 }
 }
 function studyDetail(studyId) {
 function studyDetail(studyId) {
-  return _request.default.get("/visitor/study/detail/".concat(noticeId));
+  return _request.default.get("/visitor/study/detail/".concat(studyId));
 }
 }
 function getImage(src) {
 function getImage(src) {
   if (!src) {
   if (!src) {
@@ -19497,7 +19502,7 @@ Object.defineProperty(exports, "__esModule", {
   value: true
   value: true
 });
 });
 exports.default = void 0;
 exports.default = void 0;
-var devUrl = 'http://192.168.0.105:80/dev-api';
+var devUrl = 'http://192.168.0.100:80/dev-api';
 // let devUrl = 'http://localhost:80/dev-api';
 // let devUrl = 'http://localhost:80/dev-api';
 var prodUrl = 'http://localhost:80/prod-api';
 var prodUrl = 'http://localhost:80/prod-api';
 var baseUrl =  true ? devUrl : undefined;
 var baseUrl =  true ? devUrl : undefined;
@@ -24026,7 +24031,7 @@ function _extends() {
 var formatRegExp = /%[sdj%]/g;
 var formatRegExp = /%[sdj%]/g;
 var warning = function warning() {}; // don't print warning message when in production env or node runtime
 var warning = function warning() {}; // don't print warning message when in production env or node runtime
 
 
-if (typeof process !== 'undefined' && Object({"NODE_ENV":"development","VUE_APP_DARK_MODE":"false","VUE_APP_NAME":"lab-equipment-mini-program","VUE_APP_PLATFORM":"mp-weixin","BASE_URL":"/"}) && "development" !== 'production' && typeof window !== 'undefined' && typeof document !== 'undefined') {
+if (typeof process !== 'undefined' && Object({"VUE_APP_DARK_MODE":"false","VUE_APP_NAME":"lab-equipment-mini-program","VUE_APP_PLATFORM":"mp-weixin","NODE_ENV":"development","BASE_URL":"/"}) && "development" !== 'production' && typeof window !== 'undefined' && typeof document !== 'undefined') {
   warning = function warning(type, errors) {
   warning = function warning(type, errors) {
     if (typeof console !== 'undefined' && console.warn) {
     if (typeof console !== 'undefined' && console.warn) {
       if (errors.every(function (e) {
       if (errors.every(function (e) {

+ 2 - 2
unpackage/dist/dev/mp-weixin/node-modules/uview-ui/components/u-avatar/u-avatar.json

@@ -1,7 +1,7 @@
 {
 {
-  "component": true,
   "usingComponents": {
   "usingComponents": {
     "u-icon": "/node-modules/uview-ui/components/u-icon/u-icon",
     "u-icon": "/node-modules/uview-ui/components/u-icon/u-icon",
     "u--text": "/node-modules/uview-ui/components/u--text/u--text"
     "u--text": "/node-modules/uview-ui/components/u--text/u--text"
-  }
+  },
+  "component": true
 }
 }

+ 2 - 2
unpackage/dist/dev/mp-weixin/node-modules/uview-ui/components/u-button/u-button.json

@@ -1,7 +1,7 @@
 {
 {
-  "component": true,
   "usingComponents": {
   "usingComponents": {
     "u-loading-icon": "/node-modules/uview-ui/components/u-loading-icon/u-loading-icon",
     "u-loading-icon": "/node-modules/uview-ui/components/u-loading-icon/u-loading-icon",
     "u-icon": "/node-modules/uview-ui/components/u-icon/u-icon"
     "u-icon": "/node-modules/uview-ui/components/u-icon/u-icon"
-  }
+  },
+  "component": true
 }
 }

+ 2 - 2
unpackage/dist/dev/mp-weixin/node-modules/uview-ui/components/u-cell-group/u-cell-group.json

@@ -1,6 +1,6 @@
 {
 {
-  "component": true,
   "usingComponents": {
   "usingComponents": {
     "u-line": "/node-modules/uview-ui/components/u-line/u-line"
     "u-line": "/node-modules/uview-ui/components/u-line/u-line"
-  }
+  },
+  "component": true
 }
 }

+ 2 - 2
unpackage/dist/dev/mp-weixin/node-modules/uview-ui/components/u-cell/u-cell.json

@@ -1,7 +1,7 @@
 {
 {
-  "component": true,
   "usingComponents": {
   "usingComponents": {
     "u-icon": "/node-modules/uview-ui/components/u-icon/u-icon",
     "u-icon": "/node-modules/uview-ui/components/u-icon/u-icon",
     "u-line": "/node-modules/uview-ui/components/u-line/u-line"
     "u-line": "/node-modules/uview-ui/components/u-line/u-line"
-  }
+  },
+  "component": true
 }
 }

+ 2 - 2
unpackage/dist/dev/mp-weixin/node-modules/uview-ui/components/u-col/u-col.json

@@ -1,4 +1,4 @@
 {
 {
-  "component": true,
-  "usingComponents": {}
+  "usingComponents": {},
+  "component": true
 }
 }

+ 2 - 2
unpackage/dist/dev/mp-weixin/node-modules/uview-ui/components/u-datetime-picker/u-datetime-picker.json

@@ -1,6 +1,6 @@
 {
 {
-  "component": true,
   "usingComponents": {
   "usingComponents": {
     "u-picker": "/node-modules/uview-ui/components/u-picker/u-picker"
     "u-picker": "/node-modules/uview-ui/components/u-picker/u-picker"
-  }
+  },
+  "component": true
 }
 }

+ 2 - 2
unpackage/dist/dev/mp-weixin/node-modules/uview-ui/components/u-empty/u-empty.json

@@ -1,6 +1,6 @@
 {
 {
-  "component": true,
   "usingComponents": {
   "usingComponents": {
     "u-icon": "/node-modules/uview-ui/components/u-icon/u-icon"
     "u-icon": "/node-modules/uview-ui/components/u-icon/u-icon"
-  }
+  },
+  "component": true
 }
 }

+ 2 - 2
unpackage/dist/dev/mp-weixin/node-modules/uview-ui/components/u-list-item/u-list-item.json

@@ -1,4 +1,4 @@
 {
 {
-  "component": true,
-  "usingComponents": {}
+  "usingComponents": {},
+  "component": true
 }
 }

+ 2 - 2
unpackage/dist/dev/mp-weixin/node-modules/uview-ui/components/u-list/u-list.json

@@ -1,4 +1,4 @@
 {
 {
-  "component": true,
-  "usingComponents": {}
+  "usingComponents": {},
+  "component": true
 }
 }

+ 2 - 2
unpackage/dist/dev/mp-weixin/node-modules/uview-ui/components/u-picker/u-picker.json

@@ -1,8 +1,8 @@
 {
 {
-  "component": true,
   "usingComponents": {
   "usingComponents": {
     "u-popup": "/node-modules/uview-ui/components/u-popup/u-popup",
     "u-popup": "/node-modules/uview-ui/components/u-popup/u-popup",
     "u-toolbar": "/node-modules/uview-ui/components/u-toolbar/u-toolbar",
     "u-toolbar": "/node-modules/uview-ui/components/u-toolbar/u-toolbar",
     "u-loading-icon": "/node-modules/uview-ui/components/u-loading-icon/u-loading-icon"
     "u-loading-icon": "/node-modules/uview-ui/components/u-loading-icon/u-loading-icon"
-  }
+  },
+  "component": true
 }
 }

+ 2 - 2
unpackage/dist/dev/mp-weixin/node-modules/uview-ui/components/u-popup/u-popup.json

@@ -1,10 +1,10 @@
 {
 {
-  "component": true,
   "usingComponents": {
   "usingComponents": {
     "u-overlay": "/node-modules/uview-ui/components/u-overlay/u-overlay",
     "u-overlay": "/node-modules/uview-ui/components/u-overlay/u-overlay",
     "u-transition": "/node-modules/uview-ui/components/u-transition/u-transition",
     "u-transition": "/node-modules/uview-ui/components/u-transition/u-transition",
     "u-status-bar": "/node-modules/uview-ui/components/u-status-bar/u-status-bar",
     "u-status-bar": "/node-modules/uview-ui/components/u-status-bar/u-status-bar",
     "u-icon": "/node-modules/uview-ui/components/u-icon/u-icon",
     "u-icon": "/node-modules/uview-ui/components/u-icon/u-icon",
     "u-safe-bottom": "/node-modules/uview-ui/components/u-safe-bottom/u-safe-bottom"
     "u-safe-bottom": "/node-modules/uview-ui/components/u-safe-bottom/u-safe-bottom"
-  }
+  },
+  "component": true
 }
 }

+ 2 - 2
unpackage/dist/dev/mp-weixin/node-modules/uview-ui/components/u-row/u-row.json

@@ -1,4 +1,4 @@
 {
 {
-  "component": true,
-  "usingComponents": {}
+  "usingComponents": {},
+  "component": true
 }
 }

+ 2 - 2
unpackage/dist/dev/mp-weixin/node-modules/uview-ui/components/u-search/u-search.json

@@ -1,6 +1,6 @@
 {
 {
-  "component": true,
   "usingComponents": {
   "usingComponents": {
     "u-icon": "/node-modules/uview-ui/components/u-icon/u-icon"
     "u-icon": "/node-modules/uview-ui/components/u-icon/u-icon"
-  }
+  },
+  "component": true
 }
 }

+ 1 - 1
utils/baseurl.js

@@ -1,4 +1,4 @@
-let devUrl = 'http://192.168.0.105:80/dev-api';
+let devUrl = 'http://192.168.0.100:80/dev-api';
 // let devUrl = 'http://localhost:80/dev-api';
 // let devUrl = 'http://localhost:80/dev-api';
 let prodUrl = 'http://localhost:80/prod-api';
 let prodUrl = 'http://localhost:80/prod-api';
 let baseUrl = process.env.NODE_ENV === 'development' ? devUrl : prodUrl;
 let baseUrl = process.env.NODE_ENV === 'development' ? devUrl : prodUrl;

+ 1 - 0
utils/permission.js

@@ -7,6 +7,7 @@ const whiteList = [
   '/pages/home/home',
   '/pages/home/home',
   '/pages/logo/index',
   '/pages/logo/index',
   '/pages/login/login',
   '/pages/login/login',
+	'/pages/notice/notice',
 	{ pattern: /^\/pages\/visitor\/*/ },
 	{ pattern: /^\/pages\/visitor\/*/ },
   { pattern: /^\/pages\/login\/*/ }
   { pattern: /^\/pages\/login\/*/ }
 ]
 ]

Daži faili netika attēloti, jo izmaiņu fails ir pārāk liels