mirror of
https://gitee.com/java110/WechatOwnerService.git
synced 2026-06-11 06:07:24 +08:00
finish charge
This commit is contained in:
parent
5d8233a8e6
commit
10eed0917a
@ -57,3 +57,31 @@ export function saveExamineStaffValue(dataObj){
|
||||
});
|
||||
})
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* 查询用工考核
|
||||
* @param {Object} dataObj 对象
|
||||
*/
|
||||
export function getExamineStaffValue(dataObj) {
|
||||
return new Promise(
|
||||
(resolve, reject) => {
|
||||
request({
|
||||
url: url.listExamineStaffValue,
|
||||
method: "GET",
|
||||
data: dataObj,
|
||||
//动态数据
|
||||
success: function(res) {
|
||||
if (res.data.code == 0) {
|
||||
let _data = res.data.data;
|
||||
resolve(_data);
|
||||
return;
|
||||
}
|
||||
reject(res.data.msg);
|
||||
},
|
||||
fail: function(e) {
|
||||
reject(e);
|
||||
}
|
||||
});
|
||||
})
|
||||
}
|
||||
|
||||
@ -14,6 +14,14 @@ from '../../constant/url.js'
|
||||
|
||||
import mapping from '../../constant/MappingConstant.js'
|
||||
|
||||
export function getOwnerId() {
|
||||
let _ownerInfo = wx.getStorageSync(mapping.OWNER_INFO);
|
||||
if (_ownerInfo) {
|
||||
return _ownerInfo.ownerId;
|
||||
}
|
||||
return "-1"
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询当前业主信息
|
||||
*/
|
||||
|
||||
@ -201,6 +201,8 @@ export default {
|
||||
stopCharge:baseUrl+"app/chargeMachine.stopCharge", // 结束充电
|
||||
listChargeMachineOrder:baseUrl+"app/chargeMachine.listChargeMachineOrder", // 查询充电订单
|
||||
saveExamineStaffValue:baseUrl+"app/examine.saveExamineStaffValue", // 查询充电订单
|
||||
listExamineStaffValue:baseUrl+"app/examine.listExamineStaffValue", // 查询充电订单
|
||||
|
||||
|
||||
NEED_NOT_LOGIN_PAGE: [
|
||||
'pages/login/login',
|
||||
|
||||
@ -42,8 +42,10 @@
|
||||
|
||||
<script>
|
||||
import uSlider from '@/components/u-slider/u-slider.vue';
|
||||
import {getExamineStaffs,saveExamineStaffValue} from '../../api/examine/examineApi.js';
|
||||
import {getExamineStaffs,saveExamineStaffValue,getExamineStaffValue} from '../../api/examine/examineApi.js';
|
||||
import {getCommunityId} from '../../api/community/communityApi.js';
|
||||
import {getOwnerId} from '../../api/owner/ownerApi.js'
|
||||
|
||||
export default {
|
||||
data() {
|
||||
return {
|
||||
@ -72,6 +74,7 @@
|
||||
communityId:getCommunityId()
|
||||
}).then(_data=>{
|
||||
_that.staff = _data[0];
|
||||
_that._loadOwnerScoreStaff()
|
||||
})
|
||||
},
|
||||
_showStaffId:function(_staffId){
|
||||
@ -89,6 +92,30 @@
|
||||
}).then(_data=>{
|
||||
uni.navigateBack();
|
||||
})
|
||||
},
|
||||
_loadOwnerScoreStaff:function(){
|
||||
let _that = this;
|
||||
let date = new Date();
|
||||
let year = date.getFullYear();
|
||||
getExamineStaffValue({
|
||||
page:1,
|
||||
row:50,
|
||||
staffId:this.staff.staffId,
|
||||
esYear:year,
|
||||
ownerId:getOwnerId(),
|
||||
communityId:getCommunityId()
|
||||
}).then(_data =>{
|
||||
if(!_data || _data.length < 1){
|
||||
return ;
|
||||
}
|
||||
_that.staff.projects.forEach((item)=>{
|
||||
_data.forEach(_project=>{
|
||||
if(item.projectId = _project.projectId){
|
||||
item.value = _project.examineValue;
|
||||
}
|
||||
})
|
||||
})
|
||||
})
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@ -148,7 +148,7 @@
|
||||
},
|
||||
|
||||
_switchPort:function(_port){
|
||||
if(!_port.state == 'FREE'){
|
||||
if(_port.state != 'FREE'){
|
||||
return;
|
||||
}
|
||||
this.curPort = _port;
|
||||
|
||||
Loading…
Reference in New Issue
Block a user