修改禁用按钮样式

This commit is contained in:
zhouyanli
2026-04-20 15:40:43 +08:00
parent 05307a5d58
commit 2a9dc159b1
6 changed files with 46 additions and 14 deletions

View File

@@ -98,6 +98,8 @@
<script setup>
import { ref, computed, onMounted, watch } from 'vue'
import {onLoad} from '@dcloudio/uni-app'
import {getVillageList} from "/pages/api/api.js"
// 响应式数据
const searchText = ref('')
@@ -129,20 +131,6 @@ const allCommunities = ref([
{ id: 9, name: '万科城市花园', address: '万城市余杭区文一西路299号' },
{ id: 10, name: '保利中央公园', address: '保利市拱墅区莫干山路500号' },
{ id: 11, name: '龙湖天街小区', address: '龙湖市滨江区江南大道100号' },
// { id: 12, name: '华润幸福里', address: '华润市萧山区市心北路200号' },
// { id: 13, name: '融创壹号院', address: '融创市余杭区文二西路300号' },
// { id: 14, name: '中海国际社区', address: '中海市西湖区天目山路400号' },
// { id: 15, name: '世茂江滨花园', address: '世茂市江干区钱江路500号' },
// { id: 16, name: '恒大御景湾', address: '恒大市拱墅区湖墅南路600号' },
// { id: 17, name: '碧桂园凤凰城', address: '碧桂园市滨江区滨康路700号' },
// { id: 18, name: '万科金色家园', address: '万科市萧山区金城路800号' },
// { id: 19, name: '绿城桂花城', address: '绿城市西湖区文三路900号' },
// { id: 20, name: '滨江金色海岸', address: '滨江市江干区下沙路1000号' },
// { id: 21, name: '远洋公馆', address: '远洋市拱墅区莫干山路1100号' },
// { id: 22, name: '龙湖春江彼岸', address: '龙湖市滨江区闻涛路1200号' },
// { id: 23, name: '融信蓝孔雀', address: '融信市西湖区学院路1300号' },
// { id: 24, name: '德信早安', address: '德信市余杭区良睦路1400号' },
// { id: 25, name: '宋都阳光国际', address: '宋都市江干区下沙路1500号' }
])
// 计算属性
@@ -151,6 +139,37 @@ const totalPages = computed(() => {
})
// 方法
// 查询小区列表
const getCommunityList = () =>{
let params = {
keyword:searchText.value
}
getVillageList(params).then(res =>{
console.log('1111',res)
if(res.code === 200){
allCommunities.value = res.data
uni.showToast({
title:"查询成功",
icon:'success'
})
}else{
allCommunities.value = []
uni.showToast({
title:"查询失败",
icon:'error'
})
}
})
}
onLoad(() =>{
getCommunityList()
})
// 加载分页数据
const loadPageData = (pageNum) => {
isLoading.value = true