|
@@ -1,5 +1,9 @@
|
|
<template>
|
|
<template>
|
|
<view class="uni-column container">
|
|
<view class="uni-column container">
|
|
|
|
+ <view class="top">
|
|
|
|
+ <button class="top-btn" @click="HandleSeleteInviteUser(null)"><text class="label">邀请报工</text></button>
|
|
|
|
+
|
|
|
|
+ </view>
|
|
<scroll-view class="scroll-container" scroll-y>
|
|
<scroll-view class="scroll-container" scroll-y>
|
|
<view v-for="(item, index) in listData" :key="index" class="list-item">
|
|
<view v-for="(item, index) in listData" :key="index" class="list-item">
|
|
<view class="title-container">
|
|
<view class="title-container">
|
|
@@ -66,6 +70,7 @@
|
|
<dialog-end-work ref="endWorkDialog" @sendEquipment='getEquipment' />
|
|
<dialog-end-work ref="endWorkDialog" @sendEquipment='getEquipment' />
|
|
<dialog-selectEquipment ref='selectEquipment'
|
|
<dialog-selectEquipment ref='selectEquipment'
|
|
@handleAddDayWorkItem='handleAddDayWorkItem'></dialog-selectEquipment>
|
|
@handleAddDayWorkItem='handleAddDayWorkItem'></dialog-selectEquipment>
|
|
|
|
+ <dialog-selectInviteUser ref="inviteUser" @handleAddDayWorkItem='handleAddDayWorkItem' ></dialog-selectInviteUser>
|
|
</view>
|
|
</view>
|
|
</template>
|
|
</template>
|
|
|
|
|
|
@@ -97,6 +102,7 @@
|
|
const equipmentList = ref([]) // 设备列表
|
|
const equipmentList = ref([]) // 设备列表
|
|
const endWorkDialog = ref(null) // 组件
|
|
const endWorkDialog = ref(null) // 组件
|
|
const selectEquipment = ref(null) // 组件
|
|
const selectEquipment = ref(null) // 组件
|
|
|
|
+ const inviteUser = ref(null) // 组件
|
|
const dayWorkItem = ref({}) // 添加传输对象
|
|
const dayWorkItem = ref({}) // 添加传输对象
|
|
const reqParam = ref([]) // 请求参数
|
|
const reqParam = ref([]) // 请求参数
|
|
const userInfo = ref(null) // 登录员工信息
|
|
const userInfo = ref(null) // 登录员工信息
|
|
@@ -155,6 +161,10 @@
|
|
// 调用子组件中的方法
|
|
// 调用子组件中的方法
|
|
endWorkDialog.value.open(data)
|
|
endWorkDialog.value.open(data)
|
|
}
|
|
}
|
|
|
|
+
|
|
|
|
+ function HandleSeleteInviteUser(data) {
|
|
|
|
+ inviteUser.value.open(data)
|
|
|
|
+ }
|
|
|
|
|
|
function HandleChangevehicle() {
|
|
function HandleChangevehicle() {
|
|
uni.navigateTo({
|
|
uni.navigateTo({
|
|
@@ -234,23 +244,23 @@
|
|
reqParam.value = dayWorkItem.value;
|
|
reqParam.value = dayWorkItem.value;
|
|
}
|
|
}
|
|
console.log(reqParam.value)
|
|
console.log(reqParam.value)
|
|
- saveDayWorkItemBatch(reqParam.value).then(res => {
|
|
|
|
- if (res.code === 200) {
|
|
|
|
- uni.showToast({
|
|
|
|
- icon: 'success',
|
|
|
|
- title: '操作成功',
|
|
|
|
- duration: 2000
|
|
|
|
- });
|
|
|
|
- reqParam.value = [];
|
|
|
|
- uni.$emit('dayworkItemUpdate');
|
|
|
|
- } else {
|
|
|
|
- uni.showToast({
|
|
|
|
- icon: 'error',
|
|
|
|
- title: '操作失败',
|
|
|
|
- duration: 2000
|
|
|
|
- });
|
|
|
|
- }
|
|
|
|
- })
|
|
|
|
|
|
+ // saveDayWorkItemBatch(reqParam.value).then(res => {
|
|
|
|
+ // if (res.code === 200) {
|
|
|
|
+ // uni.showToast({
|
|
|
|
+ // icon: 'success',
|
|
|
|
+ // title: '操作成功',
|
|
|
|
+ // duration: 2000
|
|
|
|
+ // });
|
|
|
|
+ // reqParam.value = [];
|
|
|
|
+ // uni.$emit('dayworkItemUpdate');
|
|
|
|
+ // } else {
|
|
|
|
+ // uni.showToast({
|
|
|
|
+ // icon: 'error',
|
|
|
|
+ // title: '操作失败',
|
|
|
|
+ // duration: 2000
|
|
|
|
+ // });
|
|
|
|
+ // }
|
|
|
|
+ // })
|
|
}
|
|
}
|
|
</script>
|
|
</script>
|
|
|
|
|
|
@@ -264,7 +274,7 @@
|
|
|
|
|
|
.scroll-container {
|
|
.scroll-container {
|
|
position: relative;
|
|
position: relative;
|
|
- top: 24rpx;
|
|
|
|
|
|
+ top: 104rpx;
|
|
// right: 0;
|
|
// right: 0;
|
|
// bottom: 144rpx;
|
|
// bottom: 144rpx;
|
|
// left: 0;
|
|
// left: 0;
|
|
@@ -339,6 +349,24 @@
|
|
|
|
|
|
}
|
|
}
|
|
}
|
|
}
|
|
|
|
+ .top{
|
|
|
|
+ position: fixed;
|
|
|
|
+ top: 0;
|
|
|
|
+ right: 0;
|
|
|
|
+ left: 0;
|
|
|
|
+ height: 80rpx;
|
|
|
|
+ padding: 16rpx 24rpx;
|
|
|
|
+ align-items: center;
|
|
|
|
+ justify-content: center;
|
|
|
|
+ background-color: #FFFFFF;
|
|
|
|
+ .top-btn {
|
|
|
|
+ font-size: 28rpx;
|
|
|
|
+ color: #FFFFFF;
|
|
|
|
+ background-color: #1684fc;
|
|
|
|
+ width: 100%;
|
|
|
|
+
|
|
|
|
+ }
|
|
|
|
+ }
|
|
|
|
|
|
.bottom {
|
|
.bottom {
|
|
position: fixed;
|
|
position: fixed;
|