diff --git a/App.vue b/App.vue index 0d24abb..aafd85b 100644 --- a/App.vue +++ b/App.vue @@ -23,11 +23,12 @@ .card { position: relative; width: 693.93rpx; - margin: 0 auto; + background-color: #fff; box-sizing: border-box; padding: 20rpx 20rpx; border-radius: 21.03rpx 21.03rpx 21.03rpx 21.03rpx; + margin: 0 auto; margin-bottom: 40rpx; font-size: 29.79rpx; diff --git a/api/file.js b/api/api.js similarity index 95% rename from api/file.js rename to api/api.js index 01e33ea..5a89a0c 100644 --- a/api/file.js +++ b/api/api.js @@ -44,6 +44,8 @@ export const landproduct = (data) => syhttp.get('/land/product', data) //绑定产品 export const bindproduct = (data) => syhttp.post('/land/bind', data) +//溯源结果展示 +export const suYuan = (data) => syhttp.get('/index/suYuan', data) diff --git a/api/chick.js b/api/chick.js deleted file mode 100644 index b12e6b2..0000000 --- a/api/chick.js +++ /dev/null @@ -1,46 +0,0 @@ -import syhttp from "@/utils/syhttp.js"; - -/** - * 家畜列表 - */ -export const animalListAPI = (data) => syhttp.get('/PoultryBreed/poultryList', data) -// 监测数据/api -export const animalEnvDataAPI = (data) => syhttp.get('/PoultryBreed/poultryEnvData', data) -// 添加动物 -export const addAnimalAPI = (data) => syhttp.post('/PoultryBreed/addPoultry', data) -// 操作列表 -export const actionsAPI = (data) => syhttp.get('/user/actions', data) -// 操作列表 -export const animalInfoAPI = (data) => syhttp.get('/PoultryBreed/poultryInfo', data) -// 图片列表 -export const animalPicListAPI = (data) => syhttp.get('/PoultryBreed/poultryPicList', data) -// 上传动物图片 -export const addAnimalPicAPI = (data) => syhttp.post('/PoultryBreed/addPoultryPic', data) -// 家禽详情 -export const poultryInfoAPI = (data) => syhttp.get('/PoultryBreed/poultryInfo', data) -// 更新状态 -export const poultryStatusAPI = (data) => syhttp.post('/PoultryBreed/poultryStatus', data) -// 种植操作列表 -// export const actionsListAPI = (data) => syhttp.get('/user/actions', data) -// 种植操作详情 -// export const actionsDetailAPI = (data) => syhttp.get('/user/actionsDetail', data) -// /api/PoultryBreed/poultryPicList - - -// 种植操作列表 -export const actionsListAPI = (data) => syhttp.get('/user/actions', data) -// 种植操作详情 -export const actionsDetailAPI = (data) => syhttp.get('/user/actionsDetail', data) - -// 种植操作详情列表 -export const landCropRecordInfoAPI = (data) => syhttp.get('/PoultryBreed/poultryRecordInfo', data) -// 进行操作 -export const addLandCropRecordAPI = (data) => syhttp.post('/PoultryBreed/addPoultryRecord', data) -// 删除操作 delLandCropRecord -export const delLandCropRecordAPI = (data) => syhttp.post('/PoultryBreed/delPoultryRecord', data) -// 编辑 -export const ediLandCropRecordAPI = (data) => syhttp.post('/PoultryBreed/ediPoultryRecord', data) -// 生长记录表 -export const landCropRecordListAPI = (data) => syhttp.get('/PoultryBreed/poultryRecordList', data) -// 搜索 -export const animalSearchByCodeAPI = (data) => syhttp.get('/PoultryBreed/poultrySearchByCode', data) \ No newline at end of file diff --git a/api/plant.js b/api/plant.js deleted file mode 100644 index 46fce9a..0000000 --- a/api/plant.js +++ /dev/null @@ -1,37 +0,0 @@ -import syhttp from "@/utils/syhttp.js"; - -/** - * 用户信息 - */ -export const userInfoAPI = (data) => syhttp.get('/user/userInfo', data) -// 土地详情 -export const landInfoAPI = (data) => syhttp.get('/LandPlant/landInfo', data) -// 添加土地详情 -export const AddlandInfoAPI = (data) => syhttp.post('/LandPlant/addLandCrop', data) -// 添加土地详情 -export const addLandCropPicAPI = (data) => syhttp.post('/LandPlant/addLandCropPic', data) - -// 实时监测记录 -export const landEnvDataCurrAPI = (data) => syhttp.get('/LandPlant/landEnvDataCurr', data) -// 标记为成熟 -export const setLandCropRipeAPI = (data) => syhttp.post('/LandPlant/setLandCropRipe', data) -// 种植图片列表 -export const landCropPicListAPI = (data) => syhttp.get('/LandPlant/landCropPicList', data) -// 种植操作列表 -export const actionsListAPI = (data) => syhttp.get('/user/actions', data) -// 种植操作详情 -export const actionsDetailAPI = (data) => syhttp.get('/user/actionsDetail', data) -// 种植操作详情列表 -export const landCropRecordInfoAPI = (data) => syhttp.get('/LandPlant/landCropRecordInfo', data) -// 检测数据表 -export const landEnvDataChartAPI = (data) => syhttp.get('/LandPlant/landEnvDataChart', data) -// 进行操作 -export const addLandCropRecordAPI = (data) => syhttp.post('/LandPlant/addLandCropRecord', data) -// 删除操作 delLandCropRecord -export const delLandCropRecordAPI = (data) => syhttp.post('/LandPlant/delLandCropRecord', data) -// 编辑 -export const ediLandCropRecordAPI = (data) => syhttp.post('/LandPlant/ediLandCropRecord', data) -// 生长记录表 -export const landCropRecordListAPI = (data) => syhttp.get('/LandPlant/landCropRecordList', data) -// 全部成熟 -export const landCropAllRipeAPI = (data) => syhttp.post('/LandPlant/landCropAllRipe', data) \ No newline at end of file diff --git a/components/plant/landInfo.vue b/components/plant/landInfo.vue index 6ca7c33..658f532 100644 --- a/components/plant/landInfo.vue +++ b/components/plant/landInfo.vue @@ -65,7 +65,7 @@ }) const perviewFn = (url) => { - console.log(url) + uni.previewImage({ urls: [url] }) diff --git a/manifest.json b/manifest.json index 4046606..3df60bf 100644 --- a/manifest.json +++ b/manifest.json @@ -10,6 +10,7 @@ "usingComponents" : true, "nvueStyleCompiler" : "uni-app", "compilerVersion" : 3, + "screenOrientation":["portrait-primary","portrait-secondary","landscape-primary","landscape-secondary"], "splashscreen" : { "alwaysShowBeforeRender" : true, "waiting" : true, @@ -21,7 +22,9 @@ "Geolocation" : {}, "Maps" : {}, "LivePusher" : {}, - "VideoPlayer" : {} + "VideoPlayer" : {}, + "Barcode" : {}, + "Camera" : {} }, /* 应用发布信息 */ "distribute" : { diff --git a/pages.json b/pages.json index 6fbc502..ccfd175 100644 --- a/pages.json +++ b/pages.json @@ -116,6 +116,15 @@ "navigationBarTextStyle": "black" } }, + { + "path": "pages/landDetail/results", + "style": { + "navigationBarTitleText": "溯源结果", + "enablePullDownRefresh": false, + "navigationBarBackgroundColor": "#F4F4F4", + "navigationBarTextStyle": "black" + } + }, { "path": "pages/updatePassword/updatePassword", "style": { @@ -125,7 +134,6 @@ "navigationBarTextStyle": "black" } }, - { "path": "pages/index/personal", "style": { diff --git a/pages/Login/login.vue b/pages/Login/login.vue index baaf438..b608ab7 100644 --- a/pages/Login/login.vue +++ b/pages/Login/login.vue @@ -31,7 +31,7 @@ customStyle="background:#F5F5F5;height:80rpx;;padding-left:40rpx;border:none" placeholder="请输入密码" border="surround" v-model="formData.password"> - + 用户注册 @@ -51,7 +51,7 @@ login, xinregister - } from '@/api/file.js'; + } from '@/api/api.js'; import { useStore } from 'vuex' @@ -133,7 +133,14 @@ }) } + //注册 + const resgiter = () => { + uni.navigateTo({ + url: '/pages/Login/resgier' + }) + } + //登录 const submitFn = () => { @@ -262,7 +269,7 @@ } .resgiter { - font-size: 20rpx; + font-size: 30rpx; margin-top: 40rpx; } diff --git a/pages/Login/resgier.vue b/pages/Login/resgier.vue index ef66dc4..f8d6e24 100644 --- a/pages/Login/resgier.vue +++ b/pages/Login/resgier.vue @@ -44,7 +44,7 @@ - \ No newline at end of file diff --git a/pages/landDetail/tudi.vue b/pages/landDetail/tudi.vue index 5f2a6f5..46fce7d 100644 --- a/pages/landDetail/tudi.vue +++ b/pages/landDetail/tudi.vue @@ -32,7 +32,7 @@ - @@ -42,21 +42,30 @@ - - {{item.type_text.slice(0, -2)}}种类:{{item.detail.kind}} + + + {{item.type_text.slice(0, -2)}}种类:{{item.detail.kind}} + + + {{item.type_text.slice(0, -2)}}品种: {{item.detail.breed}} + + + {{item.type_text.slice(0, -2)}}面积: {{item.detail.area}} + - - {{item.type_text.slice(0, -2)}}品种: {{item.detail.breed}} - - - {{item.type_text.slice(0, -2)}}面积: {{item.detail.area}} + + {{item.type_text.slice(0, -2)}}方式:{{item.detail.type==0?"喷灌":item.detail.type==1?"滴灌":"沟灌"}} 参与人员: {{item.detail.user}} - - 开始日期: {{item.create_time}} + + 开始日期: {{item.detail.start_date}} + + 结束日期: {{item.detail.end_date}} + + @@ -100,7 +109,7 @@ plantdetail, actionlist, landdetail - } from '@/api/file.js' + } from '@/api/api.js' import { onLoad, @@ -179,12 +188,12 @@ landdetail({ land_id: id }).then((res) => { - console.log(res); + if (res.code == 1) { res.data.kind = a res.data.datapic=b Object.assign(dataobj, res.data); - console.log(dataobj) + } }); @@ -215,7 +224,7 @@ }) } const navtoForm = (item, type) => { - console.log(item, type) + // console.log(item, type) switch (type) { // 施肥 @@ -273,7 +282,7 @@ return currentTime } const perviewFn = (url) => { - console.log(url) + uni.previewImage({ urls: [url] }) diff --git a/pages/live/live.nvue b/pages/live/live.nvue index d8f7ec4..37a3a15 100644 --- a/pages/live/live.nvue +++ b/pages/live/live.nvue @@ -3,7 +3,10 @@ - @@ -49,18 +52,18 @@ mounted() { // 初始化时播放第一个源 - this.$nextTick(() => { - this.playCurrent(); - }); + + // this.playCurrent(); + }, methods: { - playCurrent() { - + onVideoLoaded() { + console.log(this.$refs.videoPlayer) if (this.$refs.videoPlayer) { - this.$refs.videoPlayer.load(); + // this.$refs.videoPlayer.load(); this.$refs.videoPlayer.play(); - + } }, @@ -70,7 +73,7 @@ if (this.currentIndex >= this.rtmpSources.length) { this.currentIndex = 0; // 回到第一个源 } - + this.playCurrent(); } diff --git a/pages/updatePassword/updatePassword.vue b/pages/updatePassword/updatePassword.vue index 934c7f4..3e1d4ca 100644 --- a/pages/updatePassword/updatePassword.vue +++ b/pages/updatePassword/updatePassword.vue @@ -6,9 +6,10 @@ - + @@ -16,9 +17,10 @@ - + @@ -26,9 +28,10 @@ - + @@ -45,7 +48,7 @@