提交 af54e348 authored 作者: caodi\cd's avatar caodi\cd

fix:井道完成

上级 38f620e9
......@@ -15,11 +15,24 @@ uni-page-head .uni-btn-icon {
}
.uni-nav-bar-right-text{
.uni-nav-bar-right-text {
font-size: 14px !important;
}
.uni-navbar-btn-text>text{
.uni-nav-bar-text {
height: 28.8px;
width: 28.8px;
background: #ffffff;
border: 0.32px solid rgba(224, 224, 224, 1);
border-radius: 14.4px;
color: #333;
display: flex;
align-items: center;
justify-content: center;
text-align: center;
}
.uni-navbar-btn-text>text {
font-size: 14px !important;
}
......@@ -45,7 +58,7 @@ uni-page-head .uni-btn-icon {
}
.uni-navbar__header {
padding: 0 32px !important;
padding: 0 25.6px !important;
/* padding-right: 18px !important; */
}
......
<template>
<view>
<view class="canvas-container">
<canvas canvas-id="canvas" id="canvas" :disable-scroll="true" style="width: 100%; height: 200px;background-color: #FFFFFF;"
@touchstart="handleTouchStart($event)" @touchmove="handleTouchMove($event)" @touchend="handleTouchEnd($event)"
@touchcancel="handleEnd($event)"></canvas>
</view>
<view class="btn-container">
<button class="cu-btn lg bg-blue" @click="handleConfirm()">确定</button>
<button class="cu-btn lg line-gray" @click="reset()">重置</button>
</view>
</view>
</template>
<script>
var context = null
export default {
props: {
dialogVisiable: {
type: Boolean,
default: false
}
},
data() {
return {
canvasData: []
};
},
watch: {
dialogVisiable() {
if (this.dialogVisiable === true) {
context = uni.createCanvasContext('canvas')
context.setLineWidth(3)
context.setStrokeStyle("#000000")
this.reset()
}
},
canvasData() {
context.moveTo(this.canvasData[0].x, this.canvasData[0].y)
for (let i = 0; i < this.canvasData.length; i++) {
context.lineTo(this.canvasData[i].x, this.canvasData[i].y)
}
context.stroke()
context.draw(true)
}
},
methods: {
reset() {
context.draw()
},
hideModal() {
this.$emit('update:dialogVisiable', false)
},
handleTouchStart(e) {
this.canvasData = []
const a = e.changedTouches[0]
this.canvasData.push({
x: a.x,
y: a.y
})
},
handleTouchMove(e) {
const a = e.changedTouches[0]
this.canvasData.push({
x: a.x,
y: a.y
})
},
handleTouchEnd(e) {
const a = e.changedTouches[0]
this.canvasData.push({
x: a.x,
y: a.y
})
},
handleEnd() {
context.stroke()
context.draw(true)
},
handleConfirm() {
uni.canvasToTempFilePath({
canvasId: 'canvas',
success: res => {
this.$emit('success', res.tempFilePath)
}
})
}
}
}
</script>
<style lang="scss" scoped>
.canvas-container {
width: 400px;
}
.btn-container {
padding-bottom: 20rpx;
display: flex;
justify-content: space-around;
}
</style>
import Signature from './components/jackyq-signature.vue'
export default Signature
\ No newline at end of file
<template>
<!-- 巡检管理 -->
<view class="inspection-management">
<uni-nav-bar :fixed="true" background-color="rgba(214, 240, 255, 0.0)" status-bar rightWidth="300">
<uni-nav-bar
:fixed="true"
background-color="rgba(214, 240, 255, 0.0)"
status-bar
rightWidth="300"
>
<block slot="left">
<view class="uni-nav-bar-text" @click="back">
<text class="iconfont icon-Arrow-Left"></text>
......@@ -26,13 +31,21 @@
<view class="month-list">
<!-- 每月记录 -->
<view class="month-record-item" v-for="(item, index) in list" :key="index">
<view
class="month-record-item"
v-for="(item, index) in list"
:key="index"
>
<view v-if="(item.list || []).length" class="seconed-title">
{{ item.submitTime || item.time}}
{{ item.submitTime || item.time }}
</view>
<view class="inspect-list">
<InspectionItem v-for="ele in item.list" :key="ele.uid" :details="ele" />
<InspectionItem
v-for="ele in item.list"
:key="ele.uid"
:details="ele"
/>
</view>
</view>
......@@ -46,17 +59,13 @@
</template>
<script>
import SearchCom from "@/components/searchCom/index.vue";
import InspectionItem from "@/components/inspectionItem/index.vue";
import {
getDarft
} from "@/request/index.js";
import {
getAllInspections
} from "@/request/index.js";
import Empty from "@/components/empty/index.vue";
import SearchCom from "@/components/searchCom/index.vue";
import InspectionItem from "@/components/inspectionItem/index.vue";
import { getDarft } from "@/request/index.js";
import { getAllInspections } from "@/request/index.js";
import Empty from "@/components/empty/index.vue";
export default {
export default {
components: {
SearchCom,
InspectionItem,
......@@ -98,7 +107,6 @@
userInfo() {
return this.$store.state.now_user || {};
},
},
methods: {
// 返回
......@@ -114,15 +122,12 @@
uni.navigateTo({
url: "/pages/shaftInspection/shaftInspectionNew",
});
}
},
init() {
const all_data = this.all_data || [];
const {
inspectionTime = []
} = this.searchForm;
const { inspectionTime = [] } = this.searchForm;
const startTime = inspectionTime[0];
const endTime = inspectionTime[1];
......@@ -132,13 +137,13 @@
return true;
} else {
return (
new Date(startTime).getTime() <= new Date(item.submitTime).getTime() &&
new Date(startTime).getTime() <=
new Date(item.submitTime).getTime() &&
new Date(item.submitTime).getTime() <= new Date(endTime).getTime()
);
}
});
// 属于同一个月的数据 聚合
const tempAllData = {};
timeFrame.forEach((item) => {
......@@ -165,23 +170,28 @@
});
this.list = list;
console.log("this.list",this.list)
console.log("this.list", this.list);
},
coverData(arr = []) {
console.log("arr",arr)
const {
isException = "",
inspectionType = "",
synchronization = "",
} = this.searchForm;
return arr.filter((item) => {
return (
(!isException || isException == "all" || item.isException == isException) &&
(!inspectionType || inspectionType == "all" || item.inspectionType == inspectionType) &&
(!synchronization || synchronization == "all" || item.synchronization == synchronization)
(!isException ||
isException == "all" ||
item.isException == isException) &&
(!inspectionType ||
inspectionType == "all" ||
item.inspectionType == inspectionType) &&
(!synchronization ||
synchronization == "all" ||
item.synchronization == synchronization)
);
});
},
......@@ -230,93 +240,83 @@
});
},
},
};
};
</script>
<style scoped lang="less">
/* 导航栏样式 */
.uni-nav-bar-text {
height: 36px;
width: 36px;
.uni-nav-bar-text {
height: 28.8px;
width: 28.8px;
background: #ffffff;
border: 0.4px solid rgba(224, 224, 224, 1);
border-radius: 18px;
border-radius: 50%;
border: 0.32px solid rgba(224, 224, 224, 1);
border-radius: 14.4px;
color: #333;
display: flex;
align-items: center;
justify-content: center;
text-align: center;
.iconfont {
font-size: 20px;
line-height: 36px;
}
}
.nav-right {
width: 240px;
font-size: 16px;
line-height: 28.8px;
}
.header-buttons {
}
.nav-right {
width: 192px;
}
.header-buttons {
display: flex;
align-items: center;
margin-left: auto; // 将按钮组推到最右侧
margin-left: auto;
.button {
width: 112px;
height: 36px;
background: #FFFFFF;
border-radius: 18px;
margin-left: 16px;
width: 89.6px;
height: 28.8px;
background: #ffffff;
border-radius: 14.4px;
margin-left: 12.8px;
font-family: PingFangSC-Regular;
font-size: 16px;
font-size: 12.8px;
color: #000000;
line-height: 36px;
line-height: 28.8px;
font-weight: 400;
border: 0;
}
}
.inspection-management {
background-image: linear-gradient(115deg, #E8F0FB 0%, #E1EBFA 100%);
padding: 0 32px;
}
.inspection-management {
background-image: linear-gradient(115deg, #e8f0fb 0%, #e1ebfa 100%);
padding: 0 25.6px;
.inspection-management-content {
.count-tatal {
font-family: PingFangSC-Medium;
margin: 16px 0px 24px;
font-size: 14px;
margin: 12.8px 0px 19.2px;
font-size: 11.2px;
color: #4a4a4a;
font-weight: 400;
height: 28px;
line-height: 28px;
height: 22.4px;
line-height: 22.4px;
.num {
font-size: 20px;
font-size: 16px;
color: #3774f6;
line-height: 28px;
line-height: 22.4px;
font-weight: 500;
margin-right: 2px;
margin-right: 1.6px;
}
}
.month-list {
height: calc(100vh - 26px - 16px - 8px - 36px - 62px);
height: calc(100vh - 20.8px - 12.8px - 6.4px - 28.8px - 49.6px - 25px);
overflow: auto;
padding-bottom: 140px;
// padding-bottom: 112px;
.seconed-title {
font-size: 20px;
font-size: 16px;
color: #000000;
line-height: 28px;
line-height: 22.4px;
font-weight: 500;
margin-bottom: 12px;
margin-bottom: 9.6px;
}
.month-record-item {
margin-bottom: 24px;
margin-bottom: 19.2px;
&:last-of-type {
margin: 0;
}
.inspect-list {
display: flex;
flex-wrap: wrap;
......@@ -325,21 +325,20 @@
}
}
}
.inspection-button {
display: flex;
align-items: center;
justify-content: center;
position: fixed;
bottom: 60px;
width: 240px;
height: 48px;
bottom: 48px;
width: 192px;
height: 38.4px;
left: 50%;
color: #fff;
transform: translateX(-50%);
background-image: linear-gradient(180deg, #3773f6 0%, #2c57f6 99%);
box-shadow: 0px 10px 24px 0px rgba(51, 104, 246, 0.24);
border-radius: 27px;
}
box-shadow: 0px 8px 19.2px 0px rgba(51, 104, 246, 0.24);
border-radius: 21.6px;
}
}
</style>
......@@ -330,8 +330,10 @@ export default {
background: #ffffff;
border: 0.32px solid rgba(224, 224, 224, 1);
border-radius: 14.4px;
border-radius: 50%;
color: #333;
display: flex;
align-items: center;
justify-content: center;
text-align: center;
.iconfont {
......
......@@ -280,21 +280,6 @@ export default {
<style lang="less" scoped>
/* 导航栏样式 */
.uni-nav-bar-text {
height: 28.8px;
width: 28.8px;
background: #ffffff;
border: 0.32px solid rgba(224, 224, 224, 1);
border-radius: 14.4px;
border-radius: 50%;
color: #333;
text-align: center;
.iconfont {
font-size: 16px;
line-height: 28.8px;
}
}
.nav-right {
width: 192px;
......
<template>
<view class="uni-navbar" :class="{'uni-dark':dark, 'uni-nvue-fixed': fixed}">
<view class="uni-navbar__content" :class="{ 'uni-navbar--fixed': fixed, 'uni-navbar--shadow': shadow, 'uni-navbar--border': border }"
:style="{ 'background-color': themeBgColor }" >
<view class="uni-navbar__content"
:class="{ 'uni-navbar--fixed': fixed, 'uni-navbar--shadow': shadow, 'uni-navbar--border': border }"
:style="{ 'background-color': themeBgColor }">
<status-bar v-if="statusBar" />
<view :style="{ color: themeColor,backgroundColor: themeBgColor ,height:navbarHeight}"
class="uni-navbar__header">
<view :style="{ color: themeColor,backgroundColor: themeBgColor ,height:navbarHeight}" class="uni-navbar__header">
<view @tap="onClickLeft" class="uni-navbar__header-btns uni-navbar__header-btns-left"
:style="{width:leftIconWidth}">
<slot name="left">
......@@ -20,8 +20,7 @@
<view class="uni-navbar__header-container " @tap="onClickTitle">
<slot>
<view class="uni-navbar__header-container-inner" v-if="title.length>0">
<text class="uni-nav-bar-text uni-ellipsis-1"
:style="{color: themeColor }">{{ title }}</text>
<text class="uni-nav-bar-text uni-ellipsis-1" :style="{color: themeColor }">{{ title }}</text>
</view>
</slot>
</view>
......@@ -205,11 +204,16 @@
position: sticky;
/* #endif */
}
.uni-navbar {
// box-sizing: border-box;
}
.uni-nav-bar-text {
display: flex;
align-items: center;
justify-content: center;
text-align: center;
/* #ifdef APP-PLUS */
font-size: 34rpx;
/* #endif */
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论