index.wxml 5.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146
  1. <view class="container" wx:if="{{!isShow}}">
  2. <view wx:if="{{!isConfirm}}">
  3. <view class="item">
  4. <view class="txt">工单号</view>
  5. <input class="input" bindinput="bindBookNo" value="{{bookNo}}" type="number" disabled="{{bookNo.length>0}}"/>
  6. </view>
  7. <view class="item">
  8. <view class="txt">客户手机</view>
  9. <input class="input" bindinput="bindMobile" value="{{mobile}}" type="number" maxlength="11" />
  10. </view>
  11. </view>
  12. <view wx:if="{{isConfirm}}" style="border-bottom:1rpx solid #ccc">
  13. <view class="item">
  14. <view class="confirmTxt">技师名称</view>
  15. <view class="confirmTxt" >{{userInfo.name}}</view>
  16. </view>
  17. <view class="item">
  18. <view class="confirmTxt">客户手机</view>
  19. <view class="confirmTxt" >{{mobile}}</view>
  20. </view>
  21. </view>
  22. <view style="margin-bottom:150rpx">
  23. <view class="view" wx:for="{{pres}}" wx:key='*this'>
  24. <view class="title">{{item.categoryId.name}}</view>
  25. <view class="title" style="font-weight: 300;">
  26. {{item.deviceId.name}}
  27. <span wx:if="{{item.positionId.id}}">(</span>
  28. <span>{{item.positionId.name}}</span>
  29. <span wx:if="{{item.positionId.id}}">)</span>
  30. <view wx:if="{{!isConfirm}}" class="right" data-id="{{item.id}}" bindtap="deletePre">删除设备</view>
  31. </view>
  32. <view class="content">
  33. <view class="span" wx:for="{{item.problem}}" wx:key='*this' wx:for-item='question'>
  34. {{question.name}}
  35. </view>
  36. </view>
  37. <view class="img">
  38. <image class="weui-uploader__img" wx:for="{{item.files}}" wx:key='*this' wx:for-item='img' src="{{img}}" mode="aspectFill" />
  39. </view>
  40. <view class="item" wx:if="{{!isConfirm}}">
  41. <button class="btn" style="width:160rpx; height: 76rpx; line-height: 76rpx;" data-id='{{item.id}}' bindtap="modifyPre">编辑</button>
  42. </view>
  43. </view>
  44. </view>
  45. <view wx:if="{{isConfirm}}">
  46. <view class="form-item">
  47. <input class="captcha" type="number" value="{{captcha}}" bindinput="bindcaptchaInput" placeholder="填写验证码" auto-focus />
  48. <button class="form-item-getPhone" bindtap="getCaptcha">获取验证码</button>
  49. </view>
  50. <!-- <view style="margin:20rpx 0">
  51. <checkbox-group bindchange="bindAgreeChange">
  52. <checkbox value="{{isAgree}}" bind style="width:30rpx;height:30rpx;border:1rpx solid #ccc"/>
  53. <text style="margin-left: 20rpx;">服务条款及声明</text>
  54. </checkbox-group>
  55. </view> -->
  56. <button class="btn" style="width:auto" bindtap="savePre">我已理解上述问题</button>
  57. </view>
  58. <view wx:if="{{!isConfirm}}" class="item-btn">
  59. <button class="btn" bindtap="addPre">添加服务项</button>
  60. <button class="btn" bindtap="confirmPre">下一步用户确认</button>
  61. </view>
  62. </view>
  63. <!-- 预检项目选择 -->
  64. <view class="picker" wx:if="{{isShow}}">
  65. <view class="category">
  66. <view class="title">服务项</view>
  67. <view class="list">
  68. <view class="label" wx:for="{{base.category}}" wx:key='id' data-id='{{item.id}}' data-name='{{item.name}}' bindtap="bindCategory">
  69. <text wx:if="{{categoryId.id==item.id}}" class="action">✔</text>
  70. {{item.name}}
  71. </view>
  72. </view>
  73. </view>
  74. <view class="category" wx:if="{{selected.device.length>0}}">
  75. <view class="title">设备</view>
  76. <view class="list">
  77. <view class="label" wx:for="{{selected.device}}" wx:key='id' data-id='{{item.id}}' data-name='{{item.name}}' bindtap="bindDevice">
  78. <text wx:if="{{deviceId.id==item.id}}" class="action">✔</text>
  79. {{item.name}}
  80. </view>
  81. </view>
  82. </view>
  83. <view class="category" wx:if="{{selected.position.length>0}}">
  84. <view class="title">位置</view>
  85. <view class="list">
  86. <view class="label" wx:for="{{selected.position}}" wx:key='id' data-id='{{item.id}}' data-name='{{item.name}}' bindtap="bindPosition">
  87. <text wx:if="{{positionId.id==item.id}}" class="action">✔</text>
  88. {{item.name}}
  89. </view>
  90. </view>
  91. </view>
  92. <view class="category" wx:if="{{selected.problem.length>0}}">
  93. <view class="title">问题</view>
  94. <view class="list">
  95. <view class="label" wx:for="{{selected.problem}}" wx:key='id' data-id='{{item.id}}' data-name='{{item.problem}}' bindtap="bindQuestion">
  96. <text wx:if="{{item.checked}}" class="action">✔</text>
  97. {{item.problem}}
  98. </view>
  99. </view>
  100. </view>
  101. <view class="weui-uploader">
  102. <view class="weui-uploader__hd">
  103. <view class="weui-uploader__title">图片上传</view>
  104. <view class="weui-uploader__info">{{picUrls.length}}/{{files.length}}</view>
  105. </view>
  106. <view class="weui-uploader__bd">
  107. <view class="weui-uploader__files" id="uploaderFiles">
  108. <block wx:for="{{files}}" wx:key="*this">
  109. <view class="weui-uploader__file" bindtap="previewImage" id="{{item}}">
  110. <image class="weui-uploader__img" src="{{item}}" mode="aspectFill" />
  111. </view>
  112. </block>
  113. <view class="weui-uploader__input-box">
  114. <view class="weui-uploader__input" bindtap="chooseImage"></view>
  115. </view>
  116. </view>
  117. </view>
  118. </view>
  119. <view style="height:120rpx;border:1rpx solid #ccc;margin-top:20rpx;border-radius:10rpx;padding:10rpx">
  120. <textarea maxlength="50" bindinput="bindMemo" value="{{memo}}" style="width:100%;height:100%;color:#ccc" placeholder="如有其他问题,请填写"></textarea>
  121. </view>
  122. <view class="item" style="margin-bottom:20rpx">
  123. <button class="btn" bindtap="confirmAdd">确定添加</button>
  124. <button class="btn" bindtap="cancelAdd">取消</button>
  125. </view>
  126. </view>
  127. <canvas canvas-id='photo_canvas' style='position:fixed;left: 9999px;width:1200px;height:{{ canvasHeight }}px' class='myCanvas'></canvas>