Commit 193082a1 by pangchong

feat: 我的待办

parent c9d7df8f
......@@ -165,8 +165,8 @@ const getStyle = computed(() => {
let padding = typeof ps.padding == 'number' ? ps.padding + 'rpx' : ps.padding
let margin = typeof ps.margin == 'number' ? ps.margin + 'rpx' : ps.margin
let style = {
margin: margin,
padding: padding
margin,
padding
}
return style
})
......
......@@ -4,6 +4,8 @@
ref="paging"
v-model="dataList"
:auto="auto"
:fixed="fixed"
:height="height"
:refresher-enabled="refresherEnabled"
:refresher-threshold="refresherThreshold"
:auto-show-back-to-top="autoShowBackToTop"
......@@ -75,6 +77,16 @@ const ps = defineProps({
type: [String, Number],
default: 0
},
//是页面滚动还是局部滚动(默认页面滚动)
fixed: {
type: Boolean,
default: true
},
//局部滚动的高度
height: {
type: String,
default: ''
},
//是否自动加载
auto: {
type: Boolean,
......@@ -202,8 +214,8 @@ const getStyle = computed(() => {
let padding = typeof ps.padding == 'number' ? ps.padding + 'rpx' : ps.padding
let margin = typeof ps.margin == 'number' ? ps.margin + 'rpx' : ps.margin
let style = {
margin: margin,
padding: padding
margin,
padding
}
return style
})
......
<template>
<!-- 全局下拉框控件 -->
<view class="picker" :style="style">
<global-popup v-model="show" @close="show = false" :height="592" :customStyle="{ padding: '28rpx 32rpx' }" v-if="filter" :distance="distance">
<global-popup v-model="show" :height="592" :customStyle="{ padding: '28rpx 32rpx' }" v-if="filter" :distance="distance">
<template #top>
<view>
<up-search :placeholder="placeholder" :showAction="false" v-model="searchKey"></up-search>
......
......@@ -25,7 +25,7 @@
<script setup>
import { computed, nextTick, ref, watch } from 'vue'
const es = defineEmits(['close', 'open'])
const es = defineEmits(['update:modelValue', 'close', 'open'])
const ps = defineProps({
modelValue: {
type: Boolean,
......@@ -117,10 +117,11 @@ watch(
}
)
const close = () => {
es('close', false)
es('update:modelValue', false)
es('close')
}
const open = () => {
es('open', true)
es('open')
}
</script>
<style lang="scss">
......
......@@ -9,6 +9,7 @@
:itemStyle="getItemStyle"
:current="current"
:keyName="keyName"
:scrollable="scrollable"
@click="handleClick"
@change="handleChange"
>
......
<template>
<!-- 全局图片下载 -->
<!-- 全局图片上传 -->
<up-upload
:width="width + 'rpx'"
:height="height + 'rpx'"
......
<template>
<!-- 全局文件下载 -->
<!-- 全局文件上传 -->
<view class="upload" :style="style">
<view class="upload-list">
<view class="upload-item" v-for="(item, index) in getFileList" :key="item.id">
......
import { nextTick, ref } from 'vue'
import { ref } from 'vue'
// utils/message.js
// 通用提示
export const showToast = (msg, options) => {
uni.showToast({
title: msg || '操作失败',
......@@ -9,7 +9,6 @@ export const showToast = (msg, options) => {
...options
})
}
export const messageCount = ref(0)
// 消息提示
export const toast = (message) => {
uni.$emit('useMessage', { type: 'default', message })
......
......@@ -3,7 +3,8 @@ import Day from './dayjs'
/**
* 时间戳格式化
* 1715072168340 => 2024-05-07 16:56:08 format=YYYY/MM/DD HH:mm:ss
* 1715072168340 => 2024-05-07 16:56:08
* format=YYYY/MM/DD HH:mm:ss
*/
export const timeStampFormat = (timeStamp, opt) => {
if (!timeStamp || timeStamp == -1 || timeStamp == '-1' || timeStamp == 0 || timeStamp == '0') {
......
<template>
<global-popup v-model="showPopup" mode="right" :width="580" background="#F7F8FA" title="选择责任单位" :round="32" @close="showPopup = false">
<global-popup v-model="showPopup" mode="right" :width="580" background="#F7F8FA" title="选择责任单位" :round="32">
<view class="list">
<view class="item" v-for="item in arrangeWorkExtendList" :key="item.id" @tap="handleClick(item)">
{{ item.companyFullName }}
......
<template>
<view class="content" :style="{ height: `calc(100vh - 344rpx - ${safeAreaInsets?.top + 'px'} - ${safeAreaInsets?.bottom + 'px'} - 50px)` }">
<view class="tab-nav">
<global-tabs :list="tabNav" @handleClick="handleClick" :scrollable="false"></global-tabs>
<global-tabs :list="tabNav" @handleClick="handleClick"></global-tabs>
</view>
<scroll-view class="tab-content" scroll-y="true">
<view class="tab-content-item" v-if="activeIndex == 0">
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment