正在显示
2 个修改的文件
包含
14 行增加
和
1 行删除
| @@ -635,6 +635,19 @@ Page({ | @@ -635,6 +635,19 @@ Page({ | ||
| 635 | return | 635 | return |
| 636 | } | 636 | } |
| 637 | }, | 637 | }, |
| 638 | + deleteTap: function () { | ||
| 639 | + var that = this | ||
| 640 | + wx.showModal({ | ||
| 641 | + title: '提示', | ||
| 642 | + content: '确认要删除吗?', | ||
| 643 | + success(res) { | ||
| 644 | + if (res.confirm) { | ||
| 645 | + that.delete() | ||
| 646 | + } else if (res.cancel) { | ||
| 647 | + } | ||
| 648 | + } | ||
| 649 | + }) | ||
| 650 | + }, | ||
| 638 | delete: function() { | 651 | delete: function() { |
| 639 | if (!this.cur_id || this.cur_id.length<1) { | 652 | if (!this.cur_id || this.cur_id.length<1) { |
| 640 | wx.navigateBack({ | 653 | wx.navigateBack({ |
| @@ -64,7 +64,7 @@ | @@ -64,7 +64,7 @@ | ||
| 64 | </view> | 64 | </view> |
| 65 | </view> | 65 | </view> |
| 66 | 66 | ||
| 67 | - <view class="btn_left" bindtap='delete'>删除</view> | 67 | + <view class="btn_left" bindtap='deleteTap'>删除</view> |
| 68 | <view class="btn_bottom_wrap"> | 68 | <view class="btn_bottom_wrap"> |
| 69 | <button class="btn_right" formType="submit">保存</button> | 69 | <button class="btn_right" formType="submit">保存</button> |
| 70 | </view> | 70 | </view> |
请
注册
或
登录
后发表评论