巴林闲侠
2 years ago
9 changed files with 275 additions and 8 deletions
@ -0,0 +1,109 @@ |
|||||
|
// package/troubleshooting/shootingForm/index.js
|
||||
|
Page({ |
||||
|
|
||||
|
/** |
||||
|
* 页面的初始数据 |
||||
|
*/ |
||||
|
data: { |
||||
|
shootingid: '', |
||||
|
maintenancePersonId: null, |
||||
|
maintenanceRequirement: '', |
||||
|
planStartTimePopupShow: false, |
||||
|
planStartTime: '', |
||||
|
planEndTimePopupShow: false, |
||||
|
planEndTime: '', |
||||
|
}, |
||||
|
|
||||
|
/** |
||||
|
* 生命周期函数--监听页面加载 |
||||
|
*/ |
||||
|
onLoad (options) { |
||||
|
const { shootingid } = options |
||||
|
if (shootingid) { |
||||
|
this.setData({ |
||||
|
shootingid |
||||
|
}) |
||||
|
} else { |
||||
|
|
||||
|
} |
||||
|
}, |
||||
|
|
||||
|
onMaintenancePersonPopupChange (e) { |
||||
|
this.setData({ |
||||
|
multiIndex: e.detail.value |
||||
|
}) |
||||
|
}, |
||||
|
|
||||
|
showPlanStartTimePopup () { |
||||
|
this.setData({ planStartTimePopupShow: true }) |
||||
|
}, |
||||
|
|
||||
|
closePlanStartTimePopup () { |
||||
|
this.setData({ planStartTimePopupShow: false }) |
||||
|
}, |
||||
|
|
||||
|
onPlanStartTimeChange (event) { |
||||
|
this.setData({ planStartTime: event.detail, }) |
||||
|
}, |
||||
|
|
||||
|
showPlanEndTimePopup () { |
||||
|
this.setData({ planEndTimePopupShow: true }) |
||||
|
}, |
||||
|
|
||||
|
closePlanEndTimePopup () { |
||||
|
this.setData({ planEndTimePopupShow: false }) |
||||
|
}, |
||||
|
|
||||
|
onPlanEndTimeChange (event) { |
||||
|
this.setData({ planEndTime: event.detail, }) |
||||
|
}, |
||||
|
|
||||
|
/** |
||||
|
* 生命周期函数--监听页面初次渲染完成 |
||||
|
*/ |
||||
|
onReady () { |
||||
|
|
||||
|
}, |
||||
|
|
||||
|
/** |
||||
|
* 生命周期函数--监听页面显示 |
||||
|
*/ |
||||
|
onShow () { |
||||
|
|
||||
|
}, |
||||
|
|
||||
|
/** |
||||
|
* 生命周期函数--监听页面隐藏 |
||||
|
*/ |
||||
|
onHide () { |
||||
|
|
||||
|
}, |
||||
|
|
||||
|
/** |
||||
|
* 生命周期函数--监听页面卸载 |
||||
|
*/ |
||||
|
onUnload () { |
||||
|
|
||||
|
}, |
||||
|
|
||||
|
/** |
||||
|
* 页面相关事件处理函数--监听用户下拉动作 |
||||
|
*/ |
||||
|
onPullDownRefresh () { |
||||
|
|
||||
|
}, |
||||
|
|
||||
|
/** |
||||
|
* 页面上拉触底事件的处理函数 |
||||
|
*/ |
||||
|
onReachBottom () { |
||||
|
|
||||
|
}, |
||||
|
|
||||
|
/** |
||||
|
* 用户点击右上角分享 |
||||
|
*/ |
||||
|
onShareAppMessage () { |
||||
|
|
||||
|
} |
||||
|
}) |
@ -0,0 +1,12 @@ |
|||||
|
{ |
||||
|
"usingComponents": { |
||||
|
"van-button": "@vant/weapp/button/index", |
||||
|
"van-field": "@vant/weapp/field/index", |
||||
|
"van-cell": "@vant/weapp/cell/index", |
||||
|
"van-cell-group": "@vant/weapp/cell-group/index", |
||||
|
"van-picker": "@vant/weapp/picker/index", |
||||
|
"van-popup": "@vant/weapp/popup/index", |
||||
|
"van-icon": "@vant/weapp/icon/index", |
||||
|
"van-datetime-picker": "@vant/weapp/datetime-picker/index" |
||||
|
} |
||||
|
} |
@ -0,0 +1,78 @@ |
|||||
|
<view style="background:#F7F7FA; min-height:calc(100vh - 48rpx); padding:24rpx 0"> |
||||
|
<van-cell-group inset class="mission-card"> |
||||
|
<view class="mission-card-title"> |
||||
|
<span>巡检信息</span> |
||||
|
</view> |
||||
|
<van-field value="输入框已禁用" label="结构物名称" readonly border="{{ false }}" /> |
||||
|
<van-field value="输入框已禁用" label="巡检人" readonly border="{{ false }}" /> |
||||
|
<van-field value="输入框已禁用" label="巡检单位" readonly border="{{ false }}" /> |
||||
|
<van-field value="输入框已禁用" label="巡检时间" readonly border="{{ false }}" /> |
||||
|
<view class="mission-card-title mission-center-card-title"> |
||||
|
<span>问题详情</span> |
||||
|
</view> |
||||
|
<van-field value="输入框已禁用" label="点位名称" readonly border="{{ false }}" /> |
||||
|
<van-field value="输入框已禁用" label="检查项" readonly border="{{ false }}" /> |
||||
|
<van-field value="输入框已禁用" label="异常等级" readonly border="{{ false }}" /> |
||||
|
<van-field value="输入框已禁用" label="问题描述" readonly border="{{ false }}" /> |
||||
|
<van-cell border="{{false}}"> |
||||
|
<view style="display:flex"> |
||||
|
<view class="fs-cell-title" style="">现场照片</view> |
||||
|
<view class="fs-cell-content" style=""> |
||||
|
123 |
||||
|
<!-- <image class='weui-uploader__img showImg' src="{{imgUrl + item}}" data-img="{{imgUrl + item}}" data-index="{{index}}" data-key="{{key}}" mode="aspectFill" bindtap="previewImg"></image> --> |
||||
|
</view> |
||||
|
</view> |
||||
|
</van-cell> |
||||
|
<view class="mission-card-title mission-center-card-title"> |
||||
|
<span>维修计划信息</span> |
||||
|
</view> |
||||
|
<van-cell> |
||||
|
<view style="display:flex"> |
||||
|
<view class="fs-cell-title" style="">维修人</view> |
||||
|
<picker style="width:100%;text-align:left" bindchange="onMaintenancePersonPopupChange" value="{{0}}" range="{{['array']}}"> |
||||
|
<view class="fs-cell-content" style="width:100%"> |
||||
|
当前选择 |
||||
|
<van-icon name="arrow" style="float:right;position:relative; top:4px" /> |
||||
|
</view> |
||||
|
</picker> |
||||
|
</view> |
||||
|
</van-cell> |
||||
|
<van-field value="xxxx" label="维修单位" placeholder="请填写" readonly="{{0}}" border="{{ true }}" /> |
||||
|
<van-cell> |
||||
|
<view style="display:flex"> |
||||
|
<view class="fs-cell-title" style="">质检人</view> |
||||
|
<picker style="width:100%;text-align:left" bindchange="onMaintenancePersonPopupChange" value="{{0}}" range="{{['array']}}"> |
||||
|
<view class="fs-cell-content" style="width:100%"> |
||||
|
当前选择 |
||||
|
<van-icon name="arrow" style="float:right;position:relative; top:4px" /> |
||||
|
</view> |
||||
|
</picker> |
||||
|
</view> |
||||
|
</van-cell> |
||||
|
<van-cell> |
||||
|
<view style="display:flex"> |
||||
|
<view class="fs-cell-title" style="">计划开始时间</view> |
||||
|
<view class="fs-cell-content" style="width:100%;text-align:left" bindtap="showPlanStartTimePopup"> |
||||
|
当前选择 |
||||
|
<van-icon name="arrow" style="float:right;position:relative; top:4px" /> |
||||
|
</view> |
||||
|
<van-popup show="{{ planStartTimePopupShow }}" position="bottom" custom-style="height: 50%;" bind:close="closePlanStartTimePopup"> |
||||
|
<van-datetime-picker value="{{ planStartTime }}" bind:input="onInput" show-toolbar="{{false}}" /> |
||||
|
</van-popup> |
||||
|
</view> |
||||
|
</van-cell> |
||||
|
<van-cell> |
||||
|
<view style="display:flex"> |
||||
|
<view class="fs-cell-title" style="">计划结束时间</view> |
||||
|
<view class="fs-cell-content" style="width:100%;text-align:left" bindtap="showPlanStartTimePopup"> |
||||
|
当前选择 |
||||
|
<van-icon name="arrow" style="float:right;position:relative; top:4px" /> |
||||
|
</view> |
||||
|
<van-popup show="{{ planStartTimePopupShow }}" position="bottom" custom-style="height: 50%;" bind:close="closePlanStartTimePopup"> |
||||
|
<van-datetime-picker value="{{ planStartTime }}" bind:input="onInput" show-toolbar="{{false}}" /> |
||||
|
</van-popup> |
||||
|
</view> |
||||
|
</van-cell> |
||||
|
<van-field value="{{ maintenanceRequirement }}" label="维修要求" type="textarea" placeholder="请输入" autosize border="{{ true }}" /> |
||||
|
</van-cell-group> |
||||
|
</view> |
@ -0,0 +1,26 @@ |
|||||
|
/* package/troubleshooting/shootingForm/index.wxss */ |
||||
|
|
||||
|
.mission-card-title { |
||||
|
background-color: #fff; |
||||
|
overflow: auto; |
||||
|
padding: 24rpx 16px; |
||||
|
display: flex; |
||||
|
justify-content: space-between; |
||||
|
align-items: center |
||||
|
} |
||||
|
|
||||
|
.mission-center-card-title { |
||||
|
padding-top: 64rpx; |
||||
|
} |
||||
|
|
||||
|
.fs-cell-title { |
||||
|
max-width: 6.2em; |
||||
|
min-width: 6.2em; |
||||
|
margin-right: 12px; |
||||
|
text-align: left; |
||||
|
color: var(--field-label-color, #646566) |
||||
|
} |
||||
|
|
||||
|
.fs-cell-content { |
||||
|
color: var(--field-input-text-color, #323233) |
||||
|
} |
Loading…
Reference in new issue