You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
67 lines
2.3 KiB
67 lines
2.3 KiB
const signed_overdue_date_data = () => {
|
|
return {
|
|
init() {
|
|
this.$watch('data.department_id', () => {
|
|
this.changeDepartment()
|
|
})
|
|
}, data: {
|
|
system_name_options: [{
|
|
text: '全部',
|
|
value: ''
|
|
}, {
|
|
text: 'BPM',
|
|
value: 'bpm'
|
|
}, {
|
|
text: 'WMS',
|
|
value: 'wms'
|
|
}],
|
|
deparetment_options: deparetment_options,
|
|
signDetails: signDetails,
|
|
user_options: user_options,
|
|
system_name: '',
|
|
department_id: '',
|
|
user_id: '',
|
|
},
|
|
table_details: [],
|
|
searchLoading: false,
|
|
downloadLoading: false,
|
|
search() {
|
|
this.ssearchLoading = true;
|
|
const form = new FormData();
|
|
form.append('system_name', this.data.system_name);
|
|
form.append('department_id', this.data.department_id);
|
|
form.append('user_id', this.data.user_id);
|
|
axios.post('./api/getSingedDetails.php', form).then(res => {
|
|
this.data.signDetails = res.data;
|
|
this.searchLoading = false;
|
|
}).catch(error => {
|
|
console.log(error.response.data)
|
|
this.searchLoading = false
|
|
})
|
|
}, getDepartment() {
|
|
axios.post('./api/getDepartment.php').then(res => {
|
|
this.data.deparetment_options = res.data
|
|
}).catch(error => {
|
|
console.log(error.response.data)
|
|
this.downloadLoading = false
|
|
})
|
|
}, getUser() {
|
|
axios.post('./api/getUser.php').then(res => {
|
|
this.data.user_options = res.data
|
|
}).catch(error => {
|
|
console.log(error.response.data)
|
|
this.downloadLoading = false
|
|
})
|
|
}, changeDepartment() {
|
|
const form = new FormData();
|
|
form.append('department_id', this.data.department_id);
|
|
axios.post('./api/getUser.php', form).then(res => {
|
|
this.data.user_options = res.data
|
|
}).catch(error => {
|
|
console.log(error.response.data)
|
|
this.downloadLoading = false
|
|
})
|
|
}
|
|
}
|
|
}
|
|
|
|
|