| | |
| | | <button class="fp_footer_submit" @click="submit">确认</button> |
| | | </view> |
| | | <!-- 选择日期 --> |
| | | <u-calendar :show="timeShow" @close="timeShow = false" @confirm="timeConfirm"></u-calendar> |
| | | <!-- <u-calendar :show="timeShow" @close="timeShow = false" @confirm="timeConfirm"></u-calendar> --> |
| | | <l-calendar :lunar="false" v-model="timeShow" @change="timeConfirm" :isRange="true" activeBgColor="#305ED5" |
| | | rangeColor="#305ED5" rangeBgColor="rgba(48, 80, 213, 0.1)"></l-calendar> |
| | | <!-- 选择设备 --> |
| | | <u-picker :show="show1" :columns="equipment" @confirm="confirm" @cancel="show1 = false" keyName="text"></u-picker> |
| | | </view> |
| | |
| | | this.form.equipmentId = val.value[0].id |
| | | this.form.equipmentName = val.value[0].text |
| | | this.personnelData = [] |
| | | getFindAll({ |
| | | deviceId: this.form.equipmentId |
| | | }).then(res => { |
| | | if (res.code === 200 && res.data && res.data.length !== 0) { |
| | | this.form.personnelId = [] |
| | | let arr = [] |
| | | res.data.forEach((item) => { |
| | | arr.push({ text: item.dmodel.name + '-' + item.umodel.name, id: item.userId }) |
| | | }) |
| | | this.personnelData = arr |
| | | } |
| | | this.show1 = false |
| | | }) |
| | | this.getUser() |
| | | }, |
| | | timeConfirm(val) { |
| | | this.form.startTime = val[0] |
| | | // this.form.startTime = val[0] |
| | | this.listData.startDate = val.startDate |
| | | this.listData.endDate = val.endDate |
| | | this.timeShow = false |
| | | }, |
| | | // 提交分配 |
| | |
| | | if (res.code === 200) { |
| | | uni.showToast({ title: '分配成功', icon: 'success', duration: 2000, mask: true }); |
| | | setTimeout(() => { |
| | | uni.$emit('update', { msg:'刷新列表' }) |
| | | uni.navigateBack({ delta: 1 }); |
| | | }, 2000) |
| | | } |
| | |
| | | res.data.forEach((element) => { |
| | | arr.push({ text: element.code + '-' + element.name, id: element.id, checked: false }) |
| | | }) |
| | | this.form.equipmentId = arr[0].id |
| | | this.form.equipmentName = arr[0].text |
| | | this.getUser() |
| | | this.equipment.push(arr) |
| | | } |
| | | }) |
| | | }, |
| | | getUser() { |
| | | getFindAll({ |
| | | deviceId: this.form.equipmentId |
| | | }).then(res => { |
| | | if (res.code === 200 && res.data && res.data.length !== 0) { |
| | | this.form.personnelId = [] |
| | | let arr = [] |
| | | res.data.forEach((item) => { |
| | | arr.push({ text: item.dmodel.name + '-' + item.umodel.name, id: item.userId }) |
| | | }) |
| | | this.personnelData = arr |
| | | } |
| | | this.show1 = false |
| | | }) |
| | | } |
| | | } |
| | | } |
| | |
| | | display: flex; |
| | | flex-direction: column; |
| | | } |
| | | .u-icon__icon { |
| | | margin-right: 0 !important; |
| | | } |
| | | .fp_list_item_right_dis { |
| | | display: flex; |
| | | align-items: center; |
| | |
| | | .black { |
| | | color: black !important; |
| | | } |
| | | input { |
| | | width: 180rpx; |
| | | height: 60rpx; |
| | | border-radius: 8rpx; |
| | | border: 2rpx solid #E5E5E5; |
| | | padding: 0 30rpx; |
| | | text-align: right; |
| | | font-size: 25rpx; |
| | | } |
| | | // input { |
| | | // width: 180rpx; |
| | | // height: 60rpx; |
| | | // border-radius: 8rpx; |
| | | // border: 2rpx solid #E5E5E5; |
| | | // padding: 0 30rpx; |
| | | // text-align: right; |
| | | // font-size: 25rpx; |
| | | // } |
| | | text { |
| | | font-size: 28rpx; |
| | | font-weight: 400; |
| | |
| | | font-weight: 400; |
| | | } |
| | | } |
| | | .fp_list_item_right { |
| | | .fp_list_item_right::v-deep { |
| | | display: flex; |
| | | align-items: center; |
| | | .u-icon__icon { |
| | | margin-right: 0 !important; |
| | | } |
| | | .wu { |
| | | text-align: center; |
| | | text { |
| | |
| | | .black { |
| | | color: black !important; |
| | | } |
| | | input { |
| | | width: 180rpx; |
| | | height: 60rpx; |
| | | border-radius: 8rpx; |
| | | border: 1rpx solid #E5E5E5; |
| | | padding: 0 30rpx; |
| | | text-align: right; |
| | | font-size: 25rpx; |
| | | } |
| | | // input { |
| | | // width: 180rpx; |
| | | // height: 60rpx; |
| | | // border-radius: 8rpx; |
| | | // border: 1rpx solid #E5E5E5; |
| | | // padding: 0 30rpx; |
| | | // text-align: right; |
| | | // font-size: 25rpx; |
| | | // } |
| | | text { |
| | | font-size: 28rpx; |
| | | font-weight: 400; |