|
@@ -52,6 +52,13 @@
|
|
<el-table-column label="创建时间" prop="createTime" width="200" align="center" />
|
|
<el-table-column label="创建时间" prop="createTime" width="200" align="center" />
|
|
<el-table-column label="开始时间" prop="startTime" width="200" align="center" />
|
|
<el-table-column label="开始时间" prop="startTime" width="200" align="center" />
|
|
<el-table-column label="结束时间" prop="endTime" width="200" align="center" />
|
|
<el-table-column label="结束时间" prop="endTime" width="200" align="center" />
|
|
|
|
+ <el-table-column label="盘点年月" prop="stockTime" width="150" align="center" >
|
|
|
|
+ <template #default="scope">
|
|
|
|
+ <el-date-picker v-if="scope.row.selectDateStatus" v-model="scope.row.stockTime" type="month" value-format="YYYY-M"
|
|
|
|
+ :editable="false" clearable placeholder="请选择" style="width: 130px" />
|
|
|
|
+ <div v-else>{{ scope.row.stockTime }}</div>
|
|
|
|
+ </template>
|
|
|
|
+ </el-table-column>
|
|
<el-table-column label="盘点状态" prop="status" width="80" align="center" >
|
|
<el-table-column label="盘点状态" prop="status" width="80" align="center" >
|
|
<template #default="scope">
|
|
<template #default="scope">
|
|
<dict-tag :options="take_stock_status" :value="scope.row.status" />
|
|
<dict-tag :options="take_stock_status" :value="scope.row.status" />
|
|
@@ -66,7 +73,7 @@
|
|
<div v-else>{{ scope.row.remark }}</div>
|
|
<div v-else>{{ scope.row.remark }}</div>
|
|
</template>
|
|
</template>
|
|
</el-table-column>
|
|
</el-table-column>
|
|
- <el-table-column label="操作" align="center" width="250">
|
|
|
|
|
|
+ <el-table-column label="操作" align="center" width="300">
|
|
<template #default="scope">
|
|
<template #default="scope">
|
|
<el-button v-show="!scope.row.editStatus" v-hasPermi="['business:inventoryCheck:edit']"
|
|
<el-button v-show="!scope.row.editStatus" v-hasPermi="['business:inventoryCheck:edit']"
|
|
link type="warning" icon="Edit" @click="handleUpdate(scope.row)"
|
|
link type="warning" icon="Edit" @click="handleUpdate(scope.row)"
|
|
@@ -104,6 +111,8 @@
|
|
@click="handleSave(scope.row)"
|
|
@click="handleSave(scope.row)"
|
|
>保存</el-button
|
|
>保存</el-button
|
|
>
|
|
>
|
|
|
|
+ <el-button v-if="scope.row.status != 0" link type="primary" icon="Download" @click="handleExport(scope.row)">导出
|
|
|
|
+ </el-button>
|
|
</template>
|
|
</template>
|
|
</el-table-column>
|
|
</el-table-column>
|
|
</el-table>
|
|
</el-table>
|
|
@@ -165,11 +174,17 @@ function getTakeStockPeriodList() {
|
|
}
|
|
}
|
|
//新增
|
|
//新增
|
|
function handleAdd() {
|
|
function handleAdd() {
|
|
- takeStockPeriodList.value.unshift({createTime:proxy.moment().format("YYYY-MM-DD HH:mm:ss"),startTime:null,endTime:null,status:"0",remark:null, editStatus: true })
|
|
|
|
|
|
+ takeStockPeriodList.value.unshift({createTime:proxy.moment().format("YYYY-MM-DD HH:mm:ss"),startTime:null,stockTime:null,endTime:null,status:"0",remark:null, editStatus: true,selectDateStatus:true })
|
|
hasAlreadyAddTakeStock.value = true
|
|
hasAlreadyAddTakeStock.value = true
|
|
}
|
|
}
|
|
//保存按钮
|
|
//保存按钮
|
|
function handleSave(row) {
|
|
function handleSave(row) {
|
|
|
|
+ if(row.stockTime == null) {
|
|
|
|
+ proxy.$modal.msgError("请选择盘点时间")
|
|
|
|
+ return
|
|
|
|
+ }
|
|
|
|
+ row.stockYear = row.stockTime.substring(0,4)
|
|
|
|
+ row.stockMonth = row.stockTime.substring(5,7)
|
|
console.log(row)
|
|
console.log(row)
|
|
addTakeStockPeriod(row).then(res => {
|
|
addTakeStockPeriod(row).then(res => {
|
|
if(res.code === 200) {
|
|
if(res.code === 200) {
|
|
@@ -177,6 +192,12 @@ function handleSave(row) {
|
|
}
|
|
}
|
|
})
|
|
})
|
|
}
|
|
}
|
|
|
|
+function handleExport(data) {
|
|
|
|
+ console.log(data)
|
|
|
|
+ proxy.download('/ezhizao-dms-production/business/taksStockLot/download', {
|
|
|
|
+ id: data.id
|
|
|
|
+ }, `盘点汇总${new Date().getTime()}.xlsx`)
|
|
|
|
+}
|
|
//查看按钮
|
|
//查看按钮
|
|
function handleView(row) {
|
|
function handleView(row) {
|
|
proxy.$refs.inventoryCheckFormRef.open(row);
|
|
proxy.$refs.inventoryCheckFormRef.open(row);
|