pref: 优化客户查询单选组的警告
fix: 调整周计划查看页面高度
This commit is contained in:
@@ -298,7 +298,7 @@ let handleCopyInfo=(item)=>{
|
|||||||
}
|
}
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
<style scoped>
|
<style lang="scss" scoped>
|
||||||
.all-body {
|
.all-body {
|
||||||
/* #ifdef APP-PLUS */
|
/* #ifdef APP-PLUS */
|
||||||
top: 150rpx;
|
top: 150rpx;
|
||||||
@@ -343,7 +343,10 @@ let handleCopyInfo=(item)=>{
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
.btn-edit{
|
.white-bg:hover{
|
||||||
white-space: nowrap;
|
//background-color: #f1f1f1;
|
||||||
|
background-color: #f1f1f1; /* Chrome, Safari, Opera */
|
||||||
|
box-shadow: 0px 0px 5rpx white;
|
||||||
|
//filter: rgba(237, 242, 250, 0.5);
|
||||||
}
|
}
|
||||||
</style>
|
</style>
|
||||||
@@ -179,7 +179,7 @@
|
|||||||
<!-- 索引:hobbyIndex 范围:hobbyList 响应:handleHobbyChange-->
|
<!-- 索引:hobbyIndex 范围:hobbyList 响应:handleHobbyChange-->
|
||||||
<uni-easyinput v-model="formData.hobby" placeholder="请输入爱好"/>
|
<uni-easyinput v-model="formData.hobby" placeholder="请输入爱好"/>
|
||||||
<multipleSelect :multiple="true" :value="hobbyIndex" downInner :options="hobbyList"
|
<multipleSelect :multiple="true" :value="hobbyIndex" downInner :options="hobbyList"
|
||||||
@change="handleHobbyChange" :key="Math.round()" :slabel="'name'"
|
@change="handleHobbyChange" :slabel="'name'"
|
||||||
|
|
||||||
></multipleSelect><!--placeholder="请选择爱好标签"-->
|
></multipleSelect><!--placeholder="请选择爱好标签"-->
|
||||||
</uni-forms-item>
|
</uni-forms-item>
|
||||||
@@ -435,6 +435,7 @@ let handleFunctionChange = (e) => {
|
|||||||
console.log(e.detail.value, '职能索引');
|
console.log(e.detail.value, '职能索引');
|
||||||
const {name} = functionalRequirementList[e.detail.value];
|
const {name} = functionalRequirementList[e.detail.value];
|
||||||
formData.value.functionalRequirements = name;
|
formData.value.functionalRequirements = name;
|
||||||
|
formData.value.function = name;
|
||||||
getRecommendLevel();
|
getRecommendLevel();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -16,13 +16,13 @@
|
|||||||
<!-- 正文内容 -->
|
<!-- 正文内容 -->
|
||||||
<view class="all-body">
|
<view class="all-body">
|
||||||
<!-- 搜索-->
|
<!-- 搜索-->
|
||||||
<!-- <view class="search">-->
|
<view class="search">
|
||||||
<!-- <uni-search-bar class="custom-search" radius="28" placeholder="请输入客户人员名称" clearButton="auto"-->
|
<!-- <uni-search-bar class="custom-search" radius="28" placeholder="请输入客户人员名称" clearButton="auto"-->
|
||||||
<!-- cancelButton="none" bgColor="#6FA2F8" textColor="#ffffff"-->
|
<!-- cancelButton="none" bgColor="#6FA2F8" textColor="#ffffff"-->
|
||||||
<!-- v-model="searchValue"-->
|
<!-- v-model="searchValue"-->
|
||||||
<!-- />-->
|
<!-- />-->
|
||||||
<!-- <!– <button type="default" @click="clearSearchValue" size="mini" class="btn-search">清空</button>–>-->
|
<view class="custom-search"></view>
|
||||||
<!-- </view>-->
|
</view>
|
||||||
|
|
||||||
<!-- 分页部分 -->
|
<!-- 分页部分 -->
|
||||||
<mescroll-uni ref="mescrollRef" @init="mescrollInit" @down="downCallback" @up="upCallback"
|
<mescroll-uni ref="mescrollRef" @init="mescrollInit" @down="downCallback" @up="upCallback"
|
||||||
@@ -90,16 +90,9 @@ let timerId = null;
|
|||||||
let handleSearch = () => {
|
let handleSearch = () => {
|
||||||
// 防抖搜索 console.log(searchValue.value)
|
// 防抖搜索 console.log(searchValue.value)
|
||||||
if (timerId) clearTimeout(timerId);
|
if (timerId) clearTimeout(timerId);
|
||||||
uni.showLoading()
|
|
||||||
timerId = setTimeout(async () => {
|
timerId = setTimeout(async () => {
|
||||||
|
|
||||||
cssFlag.value = true;
|
|
||||||
|
|
||||||
// let res = await getList(1, upOption.value.page.size)
|
// let res = await getList(1, upOption.value.page.size)
|
||||||
await downCallback(mescrollRef.value.mescroll);
|
await downCallback(mescrollRef.value.mescroll);
|
||||||
|
|
||||||
cssFlag.value = false;
|
|
||||||
uni.hideLoading();
|
|
||||||
clearTimeout(timerId);
|
clearTimeout(timerId);
|
||||||
timerId = null;
|
timerId = null;
|
||||||
}, 500)
|
}, 500)
|
||||||
@@ -138,6 +131,8 @@ const mescrollInit = (mescroll) => {
|
|||||||
// 下拉刷新
|
// 下拉刷新
|
||||||
const downCallback = async (mescroll) => {
|
const downCallback = async (mescroll) => {
|
||||||
try {
|
try {
|
||||||
|
uni.showLoading();
|
||||||
|
cssFlag.value = true;
|
||||||
setTimeout(async () => {
|
setTimeout(async () => {
|
||||||
// 重置页码为第一页
|
// 重置页码为第一页
|
||||||
const res = await getList(1, mescroll.size || upOption.page.size);
|
const res = await getList(1, mescroll.size || upOption.page.size);
|
||||||
@@ -145,6 +140,8 @@ const downCallback = async (mescroll) => {
|
|||||||
list.value = res.list;
|
list.value = res.list;
|
||||||
// 正确传递 total 参数
|
// 正确传递 total 参数
|
||||||
mescroll.endSuccess(res.list.length, res.total > (mescroll.size || upOption.page.size));
|
mescroll.endSuccess(res.list.length, res.total > (mescroll.size || upOption.page.size));
|
||||||
|
uni.hideLoading();
|
||||||
|
cssFlag.value = false;
|
||||||
}, 500);
|
}, 500);
|
||||||
} catch (error) {
|
} catch (error) {
|
||||||
console.log(error)
|
console.log(error)
|
||||||
@@ -162,6 +159,7 @@ const upCallback = async (mescroll) => {
|
|||||||
} else {
|
} else {
|
||||||
list.value.push(...res.list);
|
list.value.push(...res.list);
|
||||||
}
|
}
|
||||||
|
mescroll.endBySize(res.list.length, res.total);
|
||||||
// 正确判断是否还有更多数据
|
// 正确判断是否还有更多数据
|
||||||
mescroll.endSuccess(res.list.length, res.total > mescroll.num * mescroll.size);
|
mescroll.endSuccess(res.list.length, res.total > mescroll.num * mescroll.size);
|
||||||
}, 500);
|
}, 500);
|
||||||
@@ -218,7 +216,6 @@ let handleDetail = (item) => {
|
|||||||
/* #endif */
|
/* #endif */
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
.scroll-h {
|
.scroll-h {
|
||||||
/* #ifdef APP-PLUS */
|
/* #ifdef APP-PLUS */
|
||||||
height: calc(100vh - 120px);
|
height: calc(100vh - 120px);
|
||||||
|
|||||||
@@ -32,8 +32,8 @@
|
|||||||
<view class="white-bg margin-bottom20" v-for="(item, index) in list" :key="index"
|
<view class="white-bg margin-bottom20" v-for="(item, index) in list" :key="index"
|
||||||
@click.stop="handleDetail(item)">
|
@click.stop="handleDetail(item)">
|
||||||
<view class="report-list">
|
<view class="report-list">
|
||||||
<view class="w-b-title title" @touchstart.prevent="handleTouchStart(item)"
|
<view class="w-b-title title" @touchstart="handleTouchStart(item)"
|
||||||
@touchend.prevent="handleTouchEnd">
|
@touchend="handleTouchEnd">
|
||||||
{{ item.cusName }}
|
{{ item.cusName }}
|
||||||
<view v-if="item.nodeCode" class="r-right btn-edit" :class="statusColorMap[item.nodeCode]">
|
<view v-if="item.nodeCode" class="r-right btn-edit" :class="statusColorMap[item.nodeCode]">
|
||||||
{{ item.nodeCode }}
|
{{ item.nodeCode }}
|
||||||
|
|||||||
@@ -33,10 +33,9 @@
|
|||||||
<radio-group class="block" @change="radioChange">
|
<radio-group class="block" @change="radioChange">
|
||||||
<view class="white-bg" v-for="(item, index) in list" :key="index" @click="handleDetail(item)">
|
<view class="white-bg" v-for="(item, index) in list" :key="index" @click="handleDetail(item)">
|
||||||
<radio class='radio'
|
<radio class='radio'
|
||||||
:class="index==selectIndex?'checked':''"
|
:class="index === selectIndex ? 'checked' : ''"
|
||||||
:checked="index==selectIndex?true:false"
|
:checked="index === selectIndex"
|
||||||
:value="item"
|
:value="index+''">
|
||||||
:data-index="index">
|
|
||||||
</radio>
|
</radio>
|
||||||
|
|
||||||
<view class="report-list">
|
<view class="report-list">
|
||||||
@@ -118,7 +117,6 @@ let timerId = null;
|
|||||||
watch(searchValue, (newValue, oldValue) => {
|
watch(searchValue, (newValue, oldValue) => {
|
||||||
// console.log(`新值: ${newValue}, 旧值: ${oldValue}`);
|
// console.log(`新值: ${newValue}, 旧值: ${oldValue}`);
|
||||||
if(timerId) clearTimeout(timerId);
|
if(timerId) clearTimeout(timerId);
|
||||||
cssFlag.value = true;
|
|
||||||
timerId = setTimeout(async ()=>{
|
timerId = setTimeout(async ()=>{
|
||||||
handleSearch();
|
handleSearch();
|
||||||
clearTimeout(timerId);
|
clearTimeout(timerId);
|
||||||
@@ -130,7 +128,6 @@ watch(searchValue, (newValue, oldValue) => {
|
|||||||
const downCallback = async (mescroll) => {
|
const downCallback = async (mescroll) => {
|
||||||
try {
|
try {
|
||||||
const res = await getList(1, upOption.value.page.size);
|
const res = await getList(1, upOption.value.page.size);
|
||||||
cssFlag.value = false;
|
|
||||||
list.value = res.list;
|
list.value = res.list;
|
||||||
// 正确结束下拉刷新状态
|
// 正确结束下拉刷新状态
|
||||||
mescroll.endSuccess(res.list.length, res.total >= upOption.value.page.size);
|
mescroll.endSuccess(res.list.length, res.total >= upOption.value.page.size);
|
||||||
@@ -163,9 +160,11 @@ const upCallback = async (mescroll) => {
|
|||||||
let handleSearch = async () => {
|
let handleSearch = async () => {
|
||||||
// 触发下拉刷新以重新加载数据
|
// 触发下拉刷新以重新加载数据
|
||||||
if (mescrollRef.value) {
|
if (mescrollRef.value) {
|
||||||
|
cssFlag.value = true;
|
||||||
uni.showLoading()
|
uni.showLoading()
|
||||||
await downCallback(mescrollRef.value.mescroll);
|
await downCallback(mescrollRef.value.mescroll);
|
||||||
uni.hideLoading()
|
uni.hideLoading()
|
||||||
|
cssFlag.value = false;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
// 获取数据列表
|
// 获取数据列表
|
||||||
@@ -181,12 +180,10 @@ const getList = async (pageIndex, pageSize) => {
|
|||||||
// 选中项的索引号
|
// 选中项的索引号
|
||||||
const selectIndex = ref(null);
|
const selectIndex = ref(null);
|
||||||
const radioChange = (e) => {
|
const radioChange = (e) => {
|
||||||
let {value} = e.detail;
|
let {value} = e.detail; // index
|
||||||
let {index} = e.target.dataset;
|
|
||||||
// console.log(value);
|
// console.log(value);
|
||||||
// console.log(e.target.dataset);
|
|
||||||
const eventChannel = instance.getOpenerEventChannel();
|
const eventChannel = instance.getOpenerEventChannel();
|
||||||
eventChannel.emit('cuSelected', value);
|
eventChannel.emit('cuSelected', list.value[value]);
|
||||||
uni.navigateBack()
|
uni.navigateBack()
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -366,6 +366,13 @@ let handleDetail = (rowIndex, colIndex) => {
|
|||||||
width: 690rpx;
|
width: 690rpx;
|
||||||
margin: 20rpx 0 0 0;
|
margin: 20rpx 0 0 0;
|
||||||
border-radius: 8px 8px 0 0;
|
border-radius: 8px 8px 0 0;
|
||||||
|
/* #ifdef APP-PLUS */
|
||||||
|
min-height: calc(100vh - 160rpx/*.topbar height*/ - 68rpx/*.search height*/ - 40rpx/*.white-bg padding-top*/ - 40rpx/*.white-bg padding-bottom*/);
|
||||||
|
/* #endif */
|
||||||
|
/* #ifndef APP-PLUS */
|
||||||
|
min-height: calc(100vh - 116rpx/*.topbar height*/ - 68rpx/*.search height*/ - 40rpx/*.white-bg padding-top*/ - 40rpx/*.white-bg padding-bottom*/);
|
||||||
|
/* #endif */
|
||||||
|
//overflow-y: auto;
|
||||||
}
|
}
|
||||||
|
|
||||||
.white-bg.white-bg-2 {
|
.white-bg.white-bg-2 {
|
||||||
|
|||||||
Reference in New Issue
Block a user