|
|
@ -36,10 +36,11 @@ |
|
|
|
<!-- 呆滞库存预警 --> |
|
|
|
<div class="title">{{ t('home.slack_stock_warning')}}</div> |
|
|
|
<el-table |
|
|
|
:data="materialData?.stagnantBalanceList" |
|
|
|
:data="stagnantBalanceList" |
|
|
|
style="width: 100%" |
|
|
|
stripe |
|
|
|
height="240px" |
|
|
|
row-key="id" |
|
|
|
> |
|
|
|
<el-table-column prop="itemCode" :label="t('home.material_code')" width="180px" /> |
|
|
|
<el-table-column prop="batch" :label="t('home.batch')" width="180px" /> |
|
|
@ -88,7 +89,7 @@ |
|
|
|
</template> |
|
|
|
</el-table-column> |
|
|
|
</el-table> |
|
|
|
<!-- <el-pagination style="margin-top:10px" |
|
|
|
<el-pagination style="margin-top:10px" |
|
|
|
v-model:current-page="currentPage_stagnantBalance" |
|
|
|
v-model:page-size="pageSize_stagnantBalance" |
|
|
|
:page-sizes="[10, 20, 30, 50, 100]" |
|
|
@ -96,17 +97,19 @@ |
|
|
|
:background="false" |
|
|
|
layout="total, sizes, prev, pager, next, jumper" |
|
|
|
:total="total_stagnantBalance" |
|
|
|
@current-change="handleCurrentChange_stagnantBalance" |
|
|
|
/> --> |
|
|
|
@size-change="getStagnantBalance" |
|
|
|
@current-change="getStagnantBalance" |
|
|
|
/> |
|
|
|
</div> |
|
|
|
<div class="data1 w-[47.3%]"> |
|
|
|
<!-- 超期库存预警 --> |
|
|
|
<div class="title">{{ t('home.overstock_warning') }}</div> |
|
|
|
<el-table |
|
|
|
:data="materialData?.overdueBalanceList" |
|
|
|
:data="overdueBalanceList" |
|
|
|
style="width: 100%" |
|
|
|
stripe |
|
|
|
height="240px" |
|
|
|
row-key="id" |
|
|
|
> |
|
|
|
<el-table-column prop="itemCode" :label="t('home.material_code')" width="180px" /> |
|
|
|
<el-table-column prop="batch" :label="t('home.batch')" width="180px" /> |
|
|
@ -155,7 +158,7 @@ |
|
|
|
</template> |
|
|
|
</el-table-column> |
|
|
|
</el-table> |
|
|
|
<!-- <el-pagination style="margin-top:10px" |
|
|
|
<el-pagination style="margin-top:10px" |
|
|
|
v-model:current-page="currentPage_overdueBalance" |
|
|
|
v-model:page-size="pageSize_overdueBalance" |
|
|
|
:page-sizes="[10, 20, 30, 50, 100]" |
|
|
@ -163,8 +166,9 @@ |
|
|
|
:background="false" |
|
|
|
layout="total, sizes, prev, pager, next, jumper" |
|
|
|
:total="total_overdueBalance" |
|
|
|
@current-change="handleCurrentChange_overdueBalance" |
|
|
|
/> --> |
|
|
|
@size-change="getOverdueBalance" |
|
|
|
@current-change="getOverdueBalance" |
|
|
|
/> |
|
|
|
</div> |
|
|
|
</div> |
|
|
|
<div class="two-row mt-14px"> |
|
|
@ -172,7 +176,7 @@ |
|
|
|
<!-- 高低储预警 --> |
|
|
|
<div class="title">{{ t('home.high_and_low_storage_warning') }}</div> |
|
|
|
<el-table |
|
|
|
:data="materialData?.warningBalanceList" |
|
|
|
:data="warningBalanceList" |
|
|
|
style="width: 100%" |
|
|
|
stripe |
|
|
|
height="240px" |
|
|
@ -224,7 +228,7 @@ |
|
|
|
</template> |
|
|
|
</el-table-column> |
|
|
|
</el-table> |
|
|
|
<!-- <el-pagination style="margin-top:10px" |
|
|
|
<el-pagination style="margin-top:10px" |
|
|
|
v-model:current-page="currentPage_warningBalance" |
|
|
|
v-model:page-size="pageSize_warningBalance" |
|
|
|
:page-sizes="[10, 20, 30, 50, 100]" |
|
|
@ -232,8 +236,9 @@ |
|
|
|
:background="false" |
|
|
|
layout="total, sizes, prev, pager, next, jumper" |
|
|
|
:total="total_warningBalance" |
|
|
|
@current-change="handleCurrentChange_warningBalance" |
|
|
|
/> --> |
|
|
|
@size-change="getWarningBalance" |
|
|
|
@current-change="getWarningBalance" |
|
|
|
/> |
|
|
|
</div> |
|
|
|
<div class="data1 w-[47.3%]"> |
|
|
|
<!-- 待处理任务 --> |
|
|
@ -262,6 +267,7 @@ const getMaterialData = () => { |
|
|
|
getJobCharts() |
|
|
|
}) |
|
|
|
} |
|
|
|
|
|
|
|
const formatter = (type, dict) => { |
|
|
|
let str = getStrDictOptions(dict).filter((item) => type == item.value)[0]?.label |
|
|
|
return str |
|
|
@ -285,32 +291,58 @@ const getJobCharts = async () => { |
|
|
|
lineIndex.value++ |
|
|
|
} |
|
|
|
onMounted(() => { |
|
|
|
// getMaterialData() |
|
|
|
getMaterialData() |
|
|
|
//呆滞库存预警 超期库存预警 |
|
|
|
Promise.all([ getStagnantBalance(),getOverdueBalance(),getWarningBalance()]) |
|
|
|
}) |
|
|
|
|
|
|
|
// 呆滞库存预警 |
|
|
|
const currentPage_stagnantBalance = ref(1) |
|
|
|
const pageSize_stagnantBalance = ref(10) |
|
|
|
const total_stagnantBalance= ref(100) |
|
|
|
const handleCurrentChange_stagnantBalance = (val)=>{ |
|
|
|
console.log('呆滞库存预警',val) |
|
|
|
const stagnantBalanceList = ref([]) |
|
|
|
const getStagnantBalance = ()=>{ |
|
|
|
IndexApi.getStagnantBalance({ |
|
|
|
pageNo: currentPage_stagnantBalance.value, |
|
|
|
pageSize: pageSize_stagnantBalance.value |
|
|
|
}).then((res) => { |
|
|
|
console.log('getStagnantBalance',res) |
|
|
|
stagnantBalanceList.value = res.list |
|
|
|
total_stagnantBalance.value = res.total |
|
|
|
}) |
|
|
|
} |
|
|
|
|
|
|
|
// 超期库存预警 |
|
|
|
const currentPage_overdueBalance = ref(1) |
|
|
|
const pageSize_overdueBalance = ref(10) |
|
|
|
const total_overdueBalance= ref(100) |
|
|
|
const handleCurrentChange_overdueBalance = (val)=>{ |
|
|
|
console.log('超期库存预警',val) |
|
|
|
const overdueBalanceList = ref([]) |
|
|
|
const getOverdueBalance = ()=>{ |
|
|
|
IndexApi.getOverdueBalance({ |
|
|
|
pageNo: currentPage_overdueBalance.value, |
|
|
|
pageSize: pageSize_overdueBalance.value |
|
|
|
}).then((res) => { |
|
|
|
console.log('getOverdueBalance',res) |
|
|
|
overdueBalanceList.value = res.list |
|
|
|
total_overdueBalance.value = res.total |
|
|
|
}) |
|
|
|
} |
|
|
|
|
|
|
|
// 高低储预警 |
|
|
|
const currentPage_warningBalance = ref(1) |
|
|
|
const pageSize_warningBalance = ref(10) |
|
|
|
const total_warningBalance= ref(100) |
|
|
|
const handleCurrentChange_warningBalance = (val)=>{ |
|
|
|
console.log('高低储预警',val) |
|
|
|
const warningBalanceList = ref([]) |
|
|
|
const getWarningBalance = ()=>{ |
|
|
|
IndexApi.getWarningBalance({ |
|
|
|
pageNo: currentPage_warningBalance.value, |
|
|
|
pageSize: pageSize_warningBalance.value |
|
|
|
}).then((res) => { |
|
|
|
console.log('getWarningBalance',res) |
|
|
|
warningBalanceList.value = res.list |
|
|
|
total_warningBalance.value = res.total |
|
|
|
}) |
|
|
|
} |
|
|
|
|
|
|
|
</script> |
|
|
|
<style scoped lang="scss"> |
|
|
|
.title { |
|
|
|