5/30提交

This commit is contained in:
Zy
2026-05-30 17:17:55 +08:00
parent ee55145548
commit 1fcb1dba55
8 changed files with 111 additions and 127 deletions

View File

@@ -3,13 +3,13 @@
* @Author: Zy
* @Date: 2026-05-18 15:36:10
* @LastEditor: Zy
* @LastEditTime: 2026-05-18 15:36:21
* @LastEditTime: 2026-05-30 16:53:07
*/
let baseUrl = ''
if (process.env.NODE_ENV === 'development') {
baseUrl = 'http://192.168.0.239:8080' // 开发环境
} else {
baseUrl = 'http://192.168.0.239:8080' // 生产环境
baseUrl = 'http://wuyeapi.ckdzkj.com' // 生产环境
}
export default baseUrl;

View File

@@ -174,7 +174,6 @@ async function uploadSingle(filePath) {
}
},
fail: err => {
console.error('上传失败', err)
remove(innerList.value.findIndex(item => item.url === filePath))
emit('fail', err)
reject(err)

View File

@@ -12,7 +12,9 @@ app.$mount()
// #endif
// #ifdef VUE3
import { createSSRApp } from 'vue'
import {
createSSRApp
} from 'vue'
export function createApp() {
const app = createSSRApp(App)
return {

View File

@@ -77,5 +77,5 @@
"locale": "zh-Hans",
"fallbackLocale": "zh-Hans"
}
/* ios打包配置 *//* SDK配置 */
/* ios打包配置 */
/* SDK配置 */

View File

@@ -18,13 +18,13 @@
</view>
<view class="inspection_item">
<text>巡检时间:</text>
<text>07:00:00 - 09:00:00</text>
<text>{{ info.taskTime }}</text>
</view>
<view class="inspection_item">
<text>巡检小区:</text>
<text>{{ info.villageName }}</text>
</view>
<view class="" v-for="(item, index) in baseFormData" :key="index">
<view v-for="(item, index) in baseFormData" :key="index">
<view class="inspection_item">
<text>巡检路线:</text>
<text>{{ item.routeName }}</text>
@@ -74,9 +74,7 @@
<view class="filePickerbox" v-if="!ite.complated">
<filePicker
v-model="ite.files"
:sourceType="['camera']"
file-field-name="file"
:extra-data="uploadParams"
uploadUrl="/resource/oss/upload"
@fail="onUploadFail"
></filePicker>
@@ -190,15 +188,16 @@ function init() {
}
onLoad(options => {
taskid.value = options.id
// taskid.value = '2044684785371725826'
init()
})
// ----------------------------------------------
const uploadParams = ref({})
function onUploadFail(e) {
console.log('上传失败', e)
function onUploadFail() {
uni.showToast({
icon: 'error',
title: '上传失败!'
})
}
/** 提交巡检点 检查情况 */
@@ -246,12 +245,7 @@ const isComputed = computed(() => {
*/
function previewImages(images, currentIndex) {
uni.previewImage({
urls: [
'https://picsum.photos/80',
'https://picsum.photos/80',
'https://picsum.photos/80',
'https://picsum.photos/80'
],
urls: images,
current: currentIndex
})
}

View File

@@ -24,21 +24,6 @@
</view>
</uni-forms-item>
<uni-forms-item label="房屋号">
<!-- #ifndef APP-IOS -->
<uni-easyinput
:inputBorder="false"
@tap="handleClick"
disabled
v-model="houseName"
placeholderStyle="color: #999999"
placeholder="请选择安装房屋"
>
<template #right>
<uni-icons type="forward" color="#737373"></uni-icons>
</template>
</uni-easyinput>
<!-- #endif -->
<!-- #ifdef APP-IOS -->
<view @tap="handleClick" style="width: 100%">
<uni-easyinput
:inputBorder="false"
@@ -52,7 +37,6 @@
</template>
</uni-easyinput>
</view>
<!-- #endif -->
</uni-forms-item>
</uni-forms>

View File

@@ -21,8 +21,13 @@
/>
</view>
<view class="search_list flex-1 flex">
<scroll-view lower-threshold="160" scroll-y="true" @scrolltolower="scrolltolower">
<radio-group @change="radioChange" v-if="searchlist.length > 0">
<scroll-view
v-if="searchlist.length > 0"
lower-threshold="160"
scroll-y="true"
@scrolltolower="scrolltolower"
>
<radio-group @change="radioChange">
<label v-for="(item, index) in searchlist" :key="index">
<view
class="search_item flex flex-between"
@@ -41,10 +46,10 @@
</view>
</label>
</radio-group>
</scroll-view>
<view class="noData" v-else>
<text>暂无数据</text>
</view>
</scroll-view>
</view>
<view class="action_btn" @tap="handleSelecthouse">
@@ -204,6 +209,7 @@ function handleSelecthouse() {
margin-top: 20rpx;
box-sizing: border-box;
overflow: hidden;
justify-content: center;
.search_item {
height: 116rpx;
margin-bottom: 20rpx;
@@ -236,7 +242,6 @@ function handleSelecthouse() {
border: 1rpx solid #4d5dfa;
}
}
}
.noData {
text-align: center;
color: rgba(0, 0, 0, 0.26);
@@ -244,6 +249,7 @@ function handleSelecthouse() {
padding-top: 50rpx;
letter-spacing: 10rpx;
}
}
.action_btn {
width: 670rpx;

View File

@@ -25,9 +25,8 @@
</uni-file-picker> -->
<filePicker
v-model="form.images"
:sourceType="['camera']"
file-field-name="file"
uploadUrl="/resource/oss/upload"
uploadUrl="/api/butler/file/uploadImage"
></filePicker>
</view>
</view>