// pages/deleteusers/index.js
Page({
  inputdelCollege:function(e){
    this.setData({
      delUser_College:e.detail.value,
    })
  },
  inputdelGrade:function(e){
    this.setData({
      delUser_Grade:e.detail.value,
    })
  },
  inputdelClass:function(e){
    this.setData({
      delUser_Class:e.detail.value,
    })
  },
  removeDataFn:function(){
    wx.cloud.callFunction({
      name: 'useroption',
      data: {
        option: 'deleteusers',
        //要删除的数据
        delUser_College:this.data.delUser_College,
        delUser_Grade:this.data.delUser_Grade,
        delUser_Class:this.data.delUser_Class
      },
      success: res => {
        wx.showToast({
          title: '用户删除成功',
        })
        console.log(res)
      },
      fail: err => {
        wx.showToast({
          title: '用户删除失败',
        })
      }
    })
  },
  getback:function(){
    wx.navigateBack({
      delta:2,
    })
  }
})