Java後臺審覈和提現功能(Vue爲前端)

其實審覈功能是一個更新的功能,更新審覈狀態就好了,做法也很簡單.

1.前端代碼

<el-popover  placement="top"  width="160"  v-model="scope.row.visible1">
    <p style="margin-left: 35px;">審覈是否通過?</p>
    <div style="text-align: right; margin: 0;margin-top: 10px;">
      <el-button type="success" size="mini" @click="checkPass(scope.$index, scope.row)">是</el-button>
      <el-button type="primary" size="mini" @click="checkNoPass(scope.$index, scope.row)" style="margin-right: 18%;">否</el-button>
    </div>
    <el-button slot="reference" type="primary"  size="mini" >審覈</el-button>
</el-popover>

2.後臺代碼

public RetKit check(ZddUserWithdraw entitySearch)throws Exception{
	RetKit retKit = new RetKit();
	customFile.info("審覈:");
	//ZddUserWithdraw entitySearch = new ZddUserWithdraw();
    entitySearch.setWithdrawId(entitySearch.getWithdrawId());
	//更新審覈狀態
	Integer result = zddUserWithdrawService.updateById(entitySearch);

	//查詢結果
	if( result > 0 ){
        retKit.set("success",true);
    	retKit.set("data",result);
    }else {
        retKit.set("success",false);
    }
    return retKit;
}

3.mapper文件

<update id="updateById" parameterType="com.user.entity.ZddUserWithdraw" >
    update zdd_withdraw
    <set >
      <if test="userId != null" >
        user_id = #{userId,jdbcType=VARCHAR},
      </if>
      <if test="userPhone != null" >
        user_phone = #{userPhone,jdbcType=VARCHAR},
      </if>
      <if test="withdrawStatus != null" >
        withdraw_status = #{withdrawStatus,jdbcType=VARCHAR},
      </if>
      <if test="withdrawCheckStatus != null" >
        withdraw_check_status = #{withdrawCheckStatus,jdbcType=VARCHAR},
      </if>
      <if test="createTime != null" >
        create_time = #{createTime,jdbcType=VARCHAR},
      </if>
      <if test="updateTime != null" >
        update_time = #{updateTime,jdbcType=VARCHAR},
      </if>
    </set>
    where withdraw_id = #{withdrawId,jdbcType=VARCHAR}
  </update>

 

1這就是審覈的大致過程了.

 

發表評論
所有評論
還沒有人評論,想成為第一個評論的人麼? 請在上方評論欄輸入並且點擊發布.
相關文章