盘点审核添加成本中心
This commit is contained in:
parent
22dbbd18b1
commit
d4d784886b
@ -44,3 +44,15 @@ export function createCheckPlan(data: any) {
|
||||
data: data
|
||||
})
|
||||
}
|
||||
|
||||
/**
|
||||
* 获取成本中心
|
||||
* @param data
|
||||
* @returns
|
||||
*/
|
||||
export function getCostCenter() {
|
||||
return request({
|
||||
url: '/api/CostCenter/getCostCenter',
|
||||
method: 'get',
|
||||
})
|
||||
}
|
@ -77,7 +77,15 @@
|
||||
|
||||
<div class="demo-date-picker" style="background-color: #fff; padding-top: 10px;">
|
||||
<el-row>
|
||||
<el-col :span="6" :offset="16">
|
||||
<el-col :span="6" :offset="9">
|
||||
<el-form-item label="成本中心" prop="costName">
|
||||
<el-select filterable v-model="state.costName" placeholder="下拉选择成本" size="small">
|
||||
<el-option v-for="item in costCenterList" :key="item.costCode"
|
||||
:label="item.costName" :value="item.costCode" />
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col :span="6" :offset="1">
|
||||
<el-form-item label="过账日期" prop="state.commitDate">
|
||||
<el-date-picker :clearable="true" :editable="true" v-model="state.commitDate" type="date" placeholder="选择过账时间" value-format="YYYY-MM-DD"/>
|
||||
</el-form-item>
|
||||
@ -101,7 +109,7 @@ import { reactive, ref, onMounted, toRefs, getCurrentInstance } from "vue";
|
||||
import { ElForm, ElMessageBox, ElTable } from "element-plus";
|
||||
import { getQueryList, getQueryPageList, BpelEvent } from '@/api/common';
|
||||
import { localStorage } from '@/utils/storage'
|
||||
import { Auditcheckmark, checkmarkAudit, overruleAudit } from '@/api/check'
|
||||
import { Auditcheckmark, getCostCenter, checkmarkAudit, overruleAudit } from '@/api/check'
|
||||
import { bTableHeight } from "../../../composables/calcTableHeight";
|
||||
import { getORG } from '@/api/auth'
|
||||
|
||||
@ -115,6 +123,8 @@ const { proxy }: any = getCurrentInstance();
|
||||
|
||||
const state = reactive({
|
||||
ERPFactoryList: [] as any, // 组织
|
||||
costCenterList: [] as any, // 成本中心
|
||||
costName: '',
|
||||
queryParams: {
|
||||
SHIPREQUESTNAME: '',
|
||||
CHECKPLANNAME: '',
|
||||
@ -138,7 +148,7 @@ const state = reactive({
|
||||
handleSelectionlist : [] as any
|
||||
});
|
||||
|
||||
const { ERPFactoryList,loading, list, list2, column, queryParams, rules, pageNum, pageSize, column1, total2 } = toRefs(state)
|
||||
const { costCenterList,ERPFactoryList,loading, list, list2, column, queryParams, rules, pageNum, pageSize, column1, total2 } = toRefs(state)
|
||||
|
||||
onMounted(() => {
|
||||
state.column = [
|
||||
@ -169,6 +179,7 @@ onMounted(() => {
|
||||
handleQuery2();
|
||||
updateTableHeight();
|
||||
ERPFactoryQuery();
|
||||
getCost();
|
||||
window.addEventListener('resize', handleResize);
|
||||
});
|
||||
function handleSelectionChange(val : any) {
|
||||
@ -180,6 +191,7 @@ function audit() {
|
||||
CHECKPLANNAME : state.queryParams.CHECKPLANNAME,
|
||||
PLANDATE : state.queryParams.PLANDATE,
|
||||
commitDate : state.commitDate,
|
||||
costName: state.costName,
|
||||
user : localStorage.get('userName')
|
||||
}
|
||||
Auditcheckmark(query).then((res : any) => {
|
||||
@ -192,7 +204,7 @@ function audit() {
|
||||
state.queryParams.CHECKPLANNAME = '';
|
||||
handleQuery2()
|
||||
} else {
|
||||
ElMessageBox.alert('审核过账失败:' + res.data.message, '提醒框', {
|
||||
ElMessageBox.alert('审核过账失败:' + res.message, '提醒框', {
|
||||
confirmButtonText: 'OK',
|
||||
})
|
||||
|
||||
@ -204,6 +216,11 @@ function audit() {
|
||||
});
|
||||
|
||||
}
|
||||
function getCost(){
|
||||
getCostCenter().then((res: any) => {
|
||||
state.costCenterList = res.data;
|
||||
})
|
||||
}
|
||||
//ERP工厂查询
|
||||
function ERPFactoryQuery() {
|
||||
getORG({ orgNo: null })
|
||||
|
Loading…
x
Reference in New Issue
Block a user