提交 c5560ab1 authored 作者: 刘旭's avatar 刘旭

优化界面

上级 54d903d1
...@@ -3,13 +3,13 @@ ...@@ -3,13 +3,13 @@
{ {
"path": "pages/index/index", "path": "pages/index/index",
"style": { "style": {
"navigationBarTitleText": "NDT Bot" "navigationBarTitleText": "项目登记"
} }
}, },
{ {
"path": "pages/query/index", "path": "pages/query/index",
"style": { "style": {
"navigationBarTitleText": "查询记录" "navigationBarTitleText": "项目记录"
} }
}, },
{ {
......
...@@ -117,7 +117,7 @@ const handleClick = () => { ...@@ -117,7 +117,7 @@ const handleClick = () => {
const inputValue = (value: string) => { const inputValue = (value: string) => {
initSelect(value) initSelect(value)
} }
const initSelect = (FName?: string) => { const initSelect = (FName?: string) => {
uni.showLoading({ uni.showLoading({
......
<template> <template>
<view class="queryRecords" @tap="toQueryPage"><text>登记记录</text></view> <view class="queryRecords" @tap="toQueryPage"><text>项目工时登记</text></view>
<view class="container"> <view class="container">
<view class="header"> <view class="header">
<text class="title">登记项目工时</text> <text class="title">登记项目工时</text>
......
<template> <template>
<view class='query-container'> <view class="card" v-for="(item, index) in list" :key="item.FID">
<view class="query-list"> <view class="query-item">
<uni-collapse> <view class="item">
<uni-collapse-item v-for="(item, index) in list" :key="item.FID" :open="false" <text>项目名称:</text>
:border="index === list.length - 1 ? false : true" show-animation <text>{{ item.FNAME }}</text>
:title-border="index === list.length - 1 ? 'none' : 'auto'"> </view>
<template #title> <view class="item">
<view class="header"> <text>工时:</text>
<view class="title"> <text>{{ item.F_LQKJ_WORKTIME }}</text>
{{ item.F_LQKJ_FNAME }} </view>
</view> <view class="item">
<view v-if="item.F_LQKJ_BILLSTATUS != 'C'" class="button" @tap.stop="edit(item)">修改</view> <text>登记时间:</text>
</view> <uni-dateformat :date="item.F_LQKJ_DATE2" format="yyyy/MM/dd"></uni-dateformat>
</template> </view>
<view class="query-item"> <view class="item">
<view class="item"> <text>审核状态:</text>
<text>项目编号:</text> <uni-tag v-if="item.F_LQKJ_BILLSTATUS == 'C'" text="已审核" type="success" size="small" :circle="true" />
<text>{{ item.F_LQKJ_FITEM }}</text> <uni-tag v-else text="未审核" size="small" :circle="true" />
</view> </view>
<view class="item"> </view>
<text>工时:</text> <view class="line" />
<text>{{ item.F_LQKJ_WORKTIME }}</text> <view class="footer">
</view> <view v-if="item.F_LQKJ_BILLSTATUS != 'C'" class="button" @tap.stop="edit(item)">修改</view>
<view class="item">
<text>创建时间:</text>
<!-- <text>{{ item.F_LQKJ_DATE2 }}</text> -->
<uni-dateformat :date="item.F_LQKJ_DATE2"></uni-dateformat>
</view>
<view class="item">
<text>审核状态:</text>
<uni-tag v-if="item.F_LQKJ_BILLSTATUS == 'C'" text="已审核" type="success" size="small"
:circle="true" />
<uni-tag v-else text="未审核" size="small" :circle="true" />
</view>
</view>
</uni-collapse-item>
</uni-collapse>
</view> </view>
</view> </view>
</template> </template>
...@@ -78,22 +64,47 @@ const edit = (row: number) => { ...@@ -78,22 +64,47 @@ const edit = (row: number) => {
</script> </script>
<style lang="scss" scoped> <style lang="scss" scoped>
.query-container { .card {
padding: 20rpx; box-sizing: border-box;
} margin: 16rpx;
padding: 10rpx 0;
border-radius: 8rpx;
border: 1px solid #e4e7ed;
background-color: #ffffff;
overflow: hidden;
color: #303133;
transition: .3s;
box-shadow: 0px 0px 12px rgba(0, 0, 0, .05);
.query-list { .query-item {
border: 1rpx solid rgba(204, 204, 204, 0.797); padding: 0 30rpx 20rpx;
border-radius: 6rpx; font-size: 28rpx;
padding: 6rpx;
.header { .item {
padding: 10rpx 0;
}
& .item:last-child {
padding: 0;
}
}
.line {
border-bottom: 1px solid #ddd;
width: 100%;
transform: scaleY(0.5);
}
.footer {
box-sizing: border-box;
padding: 10rpx;
display: flex; display: flex;
align-items: center; justify-content: flex-end;
justify-content: space-between; width: 100%;
padding: 16rpx;
.button { .button {
width: 60rpx;
text-align: center;
border: 1px solid rgba(0, 0, 0, .2); border: 1px solid rgba(0, 0, 0, .2);
border-radius: 6rpx; border-radius: 6rpx;
padding: 6rpx 20rpx; padding: 6rpx 20rpx;
...@@ -103,17 +114,5 @@ const edit = (row: number) => { ...@@ -103,17 +114,5 @@ const edit = (row: number) => {
color: #fff; color: #fff;
} }
} }
:deep(.uni-button:after) {
height: 20px;
}
.query-item {
padding: 0 30rpx 30rpx;
.item {
padding: 10rpx 0;
}
}
} }
</style> </style>
\ No newline at end of file
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论