add:委外出库增加单据修改删除功能
This commit is contained in:
@@ -15,6 +15,7 @@ import org.nl.common.exception.BadRequestException;
|
||||
import org.nl.common.utils.IdUtil;
|
||||
import org.nl.common.utils.SecurityUtils;
|
||||
import org.nl.wms.ext_manage.api.ZDWmsApi;
|
||||
import org.nl.wms.ext_manage.enums.EXTConstant;
|
||||
import org.nl.wms.ext_manage.sap.api.SapApi;
|
||||
import org.nl.wms.ext_manage.sap.api.dto.SubcontractConfirmBody;
|
||||
import org.nl.wms.ext_manage.sap.api.dto.SubcontractConfirmHeader;
|
||||
@@ -49,6 +50,8 @@ import org.nl.wms.warehouse_manage.enums.IOSEnum;
|
||||
import org.nl.wms.warehouse_manage.inAndOut.service.IOutBillService;
|
||||
import org.nl.wms.warehouse_manage.subcontractReverse.dao.SapSubcontractReverseRecord;
|
||||
import org.nl.wms.warehouse_manage.subcontractReverse.service.ISapSubcontractReverseRecordService;
|
||||
import org.nl.wms.system_manage.service.param.ISysParamService;
|
||||
import org.nl.wms.system_manage.service.param.dao.Param;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Service;
|
||||
import org.springframework.transaction.annotation.Transactional;
|
||||
@@ -97,6 +100,8 @@ public class OutboundDeliveryServiceImpl extends ServiceImpl<OutboundDeliveryMap
|
||||
private ZDWmsApi zdWmsApi;
|
||||
@Autowired
|
||||
private ISapSubcontractReverseRecordService reverseRecordService;
|
||||
@Autowired
|
||||
private ISysParamService sysParamService;
|
||||
|
||||
@Override
|
||||
@Transactional(rollbackFor = Exception.class)
|
||||
@@ -462,6 +467,7 @@ public class OutboundDeliveryServiceImpl extends ServiceImpl<OutboundDeliveryMap
|
||||
if (CollectionUtils.isEmpty(items)) {
|
||||
throw new BadRequestException("下推失败:单据明细不存在");
|
||||
}
|
||||
assertNotZdStor(order, items);
|
||||
Map<String, List<OutboundDeliveryItem>> grouped = items.stream()
|
||||
.peek(item -> {
|
||||
if (StrUtil.isBlank(item.getLgort())) {
|
||||
@@ -476,6 +482,53 @@ public class OutboundDeliveryServiceImpl extends ServiceImpl<OutboundDeliveryMap
|
||||
orderMapper.updateById(order);
|
||||
}
|
||||
|
||||
/**
|
||||
* 中鼎托管仓库校验:系统参数 ZD_STOR_SET 配置的仓库由中鼎 WMS 管理,库存以中鼎为准,
|
||||
* 不能再下推生成本地出库单,否则会造成两边重复出库。
|
||||
*/
|
||||
private void assertNotZdStor(OutboundDelivery order, List<OutboundDeliveryItem> items) {
|
||||
Set<String> zdStors = listZdStors();
|
||||
if (zdStors.isEmpty()) {
|
||||
return;
|
||||
}
|
||||
List<String> zdLgorts = items.stream()
|
||||
.filter(Objects::nonNull)
|
||||
.map(OutboundDeliveryItem::getLgort)
|
||||
.filter(StrUtil::isNotBlank)
|
||||
.map(String::trim)
|
||||
.distinct()
|
||||
.filter(zdStors::contains)
|
||||
.collect(Collectors.toList());
|
||||
if (!zdLgorts.isEmpty()) {
|
||||
throw new BadRequestException("下推失败:交货单" + order.getVbeln() + "的存储地点"
|
||||
+ String.join("、", zdLgorts) + "属于中鼎仓库,不能下推出库");
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* 中鼎仓库集合:系统参数 ZD_STOR_SET(仓库编码数组)
|
||||
*/
|
||||
private Set<String> listZdStors() {
|
||||
Param param = sysParamService.findByCode(EXTConstant.ZD_STOR_SET);
|
||||
if (param == null || StrUtil.isBlank(param.getValue())) {
|
||||
return Collections.emptySet();
|
||||
}
|
||||
List<String> codes;
|
||||
try {
|
||||
codes = JSONObject.parseArray(param.getValue(), String.class);
|
||||
} catch (Exception e) {
|
||||
// 兼容逗号分隔配置
|
||||
codes = StrUtil.split(param.getValue(), ',');
|
||||
}
|
||||
if (CollectionUtils.isEmpty(codes)) {
|
||||
return Collections.emptySet();
|
||||
}
|
||||
return codes.stream()
|
||||
.filter(StrUtil::isNotBlank)
|
||||
.map(String::trim)
|
||||
.collect(Collectors.toSet());
|
||||
}
|
||||
|
||||
@Override
|
||||
public void pushZd(String billType, List<Long> ids) {
|
||||
if (CollectionUtils.isEmpty(ids)) {
|
||||
|
||||
@@ -79,16 +79,23 @@
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column prop="created_at" label="创建时间" min-width="160" show-overflow-tooltip />
|
||||
<el-table-column label="操作" width="100" align="center" fixed="right">
|
||||
<el-table-column v-permission="operationPermission" label="操作" width="120" align="center" fixed="right">
|
||||
<template slot-scope="scope">
|
||||
<el-button size="mini" type="text" @click="openDetailDialog(scope.row)">明细</el-button>
|
||||
<el-button size="mini" type="text" :disabled="!canEdit(scope.row)" @click="handleEdit(scope.row)">编辑</el-button>
|
||||
<el-button size="mini" type="text" :disabled="!canEdit(scope.row)" @click="handleDelete(scope.row)">删除</el-button>
|
||||
</template>
|
||||
</el-table-column>
|
||||
</el-table>
|
||||
<pagination />
|
||||
</div>
|
||||
|
||||
<el-dialog :visible.sync="detailVisible" :title="pageTitle + '明细'" width="1100px" :close-on-click-modal="false" @close="closeDetailDialog">
|
||||
<el-dialog
|
||||
:visible.sync="detailVisible"
|
||||
:title="(pageTitle || '交货单') + '明细'"
|
||||
width="1100px"
|
||||
:close-on-click-modal="false"
|
||||
@close="closeDetailDialog"
|
||||
>
|
||||
<div style="margin-bottom: 10px; color: #606266; font-size: 13px;">
|
||||
交货单号:<strong>{{ currentOrder.vbeln }}</strong> |
|
||||
供应商:<strong>{{ currentOrder.lifnr_name || currentOrder.lifnr || '-' }}</strong> |
|
||||
@@ -102,14 +109,136 @@
|
||||
<el-table-column prop="matl_desc" label="物料描述" min-width="160" show-overflow-tooltip />
|
||||
<el-table-column prop="deliv_qty" label="交货数量" width="100" align="right" />
|
||||
<el-table-column prop="unit" label="单位" width="70" align="center" />
|
||||
<el-table-column prop="po_number" label="采购凭证" min-width="120" show-overflow-tooltip />
|
||||
<el-table-column prop="po_item" label="采购行" width="80" align="center" />
|
||||
<el-table-column prop="werks" label="工厂" width="80" align="center" />
|
||||
<el-table-column prop="lgort" label="存储地点" width="90" align="center" />
|
||||
<el-table-column prop="po_number" label="采购凭证" min-width="120" show-overflow-tooltip />
|
||||
</el-table>
|
||||
<div slot="footer" class="dialog-footer">
|
||||
<el-button size="mini" @click="closeDetailDialog">关闭</el-button>
|
||||
</div>
|
||||
</el-dialog>
|
||||
|
||||
<el-dialog
|
||||
:visible.sync="editVisible"
|
||||
:title="'编辑' + (pageTitle || '交货单')"
|
||||
width="1100px"
|
||||
:close-on-click-modal="false"
|
||||
@close="closeEditDialog"
|
||||
>
|
||||
<el-form ref="form" :model="editForm" :rules="rules" size="mini" label-width="120px" label-suffix=":" style="border: 1px solid #cfe0df; padding: 10px;">
|
||||
<el-row>
|
||||
<el-col :span="8">
|
||||
<el-form-item label="交货单号" prop="vbeln">
|
||||
<el-input v-model.trim="editForm.vbeln" disabled />
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col :span="8">
|
||||
<el-form-item label="供应商编码" prop="lifnr">
|
||||
<el-input v-model.trim="editForm.lifnr" placeholder="请输入供应商编码" />
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col :span="8">
|
||||
<el-form-item label="供应商名称">
|
||||
<el-input v-model.trim="editForm.lifnr_name" placeholder="留空按供应商编码自动补查" />
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col :span="8">
|
||||
<el-form-item label="交货类型">
|
||||
<el-input v-model="editForm.lfart" disabled />
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col :span="8">
|
||||
<el-form-item label="单据类型">
|
||||
<el-input :value="billtypeLabel(editForm.billtype)" disabled />
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col :span="8">
|
||||
<el-form-item label="单据日期" prop="bldat">
|
||||
<el-date-picker v-model="editForm.bldat" type="date" value-format="yyyy-MM-dd" placeholder="请选择单据日期" style="width: 100%;" />
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col :span="8">
|
||||
<el-form-item label="计划发货日期">
|
||||
<el-date-picker v-model="editForm.wadat" type="date" value-format="yyyy-MM-dd" placeholder="请选择计划发货日期" style="width: 100%;" />
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col :span="8">
|
||||
<el-form-item label="交货日期">
|
||||
<el-date-picker v-model="editForm.lfdat" type="date" value-format="yyyy-MM-dd" placeholder="请选择交货日期" style="width: 100%;" />
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col :span="8">
|
||||
<el-form-item label="实际发货日期">
|
||||
<el-date-picker v-model="editForm.wadat_ist" type="date" value-format="yyyy-MM-dd" placeholder="请选择实际发货日期" style="width: 100%;" />
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
</el-row>
|
||||
</el-form>
|
||||
<div style="margin: 12px 0 8px; display: flex; justify-content: space-between; align-items: center;">
|
||||
<span style="font-weight: 600;">行项目</span>
|
||||
<el-button size="mini" type="primary" icon="el-icon-plus" @click="addItem">新增行项目</el-button>
|
||||
</div>
|
||||
<el-table v-loading="editItemLoading" :data="editForm.items" size="mini" border max-height="300">
|
||||
<el-table-column label="行项目号" width="110">
|
||||
<template slot-scope="scope">
|
||||
<el-input v-model.trim="scope.row.posnr" size="mini" placeholder="行号" />
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="物料编号" min-width="140">
|
||||
<template slot-scope="scope">
|
||||
<el-input v-model.trim="scope.row.material" size="mini" placeholder="物料编号" />
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="物料描述" min-width="150">
|
||||
<template slot-scope="scope">
|
||||
<el-input v-model.trim="scope.row.matl_desc" size="mini" placeholder="物料描述" />
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="交货数量" width="120">
|
||||
<template slot-scope="scope">
|
||||
<el-input-number v-model="scope.row.deliv_qty" :min="0" :precision="3" :controls="false" size="mini" style="width: 100%;" />
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="单位" width="80">
|
||||
<template slot-scope="scope">
|
||||
<el-input v-model.trim="scope.row.unit" size="mini" />
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="采购凭证" min-width="120">
|
||||
<template slot-scope="scope">
|
||||
<el-input v-model.trim="scope.row.po_number" size="mini" />
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="采购行" width="90">
|
||||
<template slot-scope="scope">
|
||||
<el-input v-model.trim="scope.row.po_item" size="mini" />
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="工厂" width="90">
|
||||
<template slot-scope="scope">
|
||||
<el-input v-model.trim="scope.row.werks" size="mini" />
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="存储地点" width="90">
|
||||
<template slot-scope="scope">
|
||||
<el-input v-model.trim="scope.row.lgort" size="mini" />
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="操作" width="70" align="center" fixed="right">
|
||||
<template slot-scope="scope">
|
||||
<el-button type="text" size="mini" @click="removeItem(scope.$index)">删除</el-button>
|
||||
</template>
|
||||
</el-table-column>
|
||||
</el-table>
|
||||
<div v-if="componentItems.length" style="margin-top: 8px; color: #909399; font-size: 12px;">
|
||||
该单据含 {{ componentItems.length }} 条委外组件行,编辑时不显示,保存时原样保留。
|
||||
</div>
|
||||
<div slot="footer" class="dialog-footer">
|
||||
<el-button size="mini" @click="closeEditDialog">取消</el-button>
|
||||
<el-button size="mini" type="primary" :loading="editSaving" @click="submitEdit">确认</el-button>
|
||||
</div>
|
||||
</el-dialog>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
@@ -118,7 +247,34 @@ import CRUD, { crud, header, presenter } from '@crud/crud'
|
||||
import crudOperation from '@crud/CRUD.operation'
|
||||
import rrOperation from '@crud/RR.operation'
|
||||
import pagination from '@crud/Pagination'
|
||||
import { getDetail } from './outBoundDelivery'
|
||||
import { getDetail, getParamValue } from './outBoundDelivery'
|
||||
|
||||
const createItem = () => ({
|
||||
posnr: '',
|
||||
material: '',
|
||||
matl_desc: '',
|
||||
deliv_qty: undefined,
|
||||
unit: '',
|
||||
po_number: '',
|
||||
po_item: '',
|
||||
werks: '',
|
||||
lgort: ''
|
||||
})
|
||||
|
||||
const createDefaultForm = () => ({
|
||||
id: null,
|
||||
vbeln: '',
|
||||
lifnr: '',
|
||||
lifnr_name: '',
|
||||
lfart: '',
|
||||
billtype: '',
|
||||
bldat: '',
|
||||
wadat: '',
|
||||
lfdat: '',
|
||||
wadat_ist: '',
|
||||
status: 'CREATED',
|
||||
items: []
|
||||
})
|
||||
|
||||
export default {
|
||||
name: 'SapDeliveryOutbound',
|
||||
@@ -144,16 +300,35 @@ export default {
|
||||
{ value: 'SUBCONTRACT_OUT', label: '委外交货出库' },
|
||||
{ value: 'TRANSFER_IN', label: '公司间调拨收货' },
|
||||
{ value: 'SALES_OUT', label: '原材料销售出库' },
|
||||
{ value: 'TRANSFER_OUT', label: 'SAP公司间调拨出货' },
|
||||
{ value: 'SALES_RETURN_IN', label: '原材料销售退货' }
|
||||
],
|
||||
rules: {
|
||||
vbeln: [{ required: true, message: '请输入交货单号', trigger: 'blur' }]
|
||||
},
|
||||
pushZdLoading: false,
|
||||
multipleSelection: [],
|
||||
// 中鼎托管仓库(系统参数 ZD_STOR_SET):属于这些仓库的单据不能下推本地出库
|
||||
zdStorSet: [],
|
||||
editVisible: false,
|
||||
editSaving: false,
|
||||
editItemLoading: false,
|
||||
editForm: createDefaultForm(),
|
||||
componentItems: [],
|
||||
detailVisible: false,
|
||||
detailLoading: false,
|
||||
currentOrder: {},
|
||||
itemList: []
|
||||
}
|
||||
},
|
||||
computed: {
|
||||
operationPermission() {
|
||||
return [].concat(this.permission.edit, this.permission.del)
|
||||
}
|
||||
},
|
||||
created() {
|
||||
this.loadZdStorSet()
|
||||
},
|
||||
methods: {
|
||||
[CRUD.HOOK.beforeRefresh]() {
|
||||
if (this.query.datepick && this.query.datepick.length) {
|
||||
@@ -176,10 +351,42 @@ export default {
|
||||
const map = { CREATED: 'warning', POSTED: 'primary', COMPLETED: 'success', CANCELED: 'info' }
|
||||
return map[status] || ''
|
||||
},
|
||||
canEdit(row) {
|
||||
return row && (row.status === 'CREATED' || row.status === 'CANCELED')
|
||||
},
|
||||
handleSelectionChange(selection) {
|
||||
this.multipleSelection = selection
|
||||
this.crud.selectionChangeHandler(selection)
|
||||
},
|
||||
// 中鼎仓库集合,取不到时后端仍会校验,不影响页面使用
|
||||
loadZdStorSet() {
|
||||
getParamValue('ZD_STOR_SET').then(res => {
|
||||
const value = res.data && res.data.value
|
||||
this.zdStorSet = this.parseStorSet(value)
|
||||
}).catch(() => {
|
||||
this.zdStorSet = []
|
||||
})
|
||||
},
|
||||
parseStorSet(value) {
|
||||
if (!value) {
|
||||
return []
|
||||
}
|
||||
try {
|
||||
const parsed = JSON.parse(value)
|
||||
if (Array.isArray(parsed)) {
|
||||
return parsed.filter(item => item != null).map(item => String(item).trim())
|
||||
}
|
||||
} catch (e) {
|
||||
// 兼容逗号分隔配置
|
||||
}
|
||||
return String(value).split(',').map(item => item.trim()).filter(item => item)
|
||||
},
|
||||
isZdStor(lgort) {
|
||||
if (!lgort) {
|
||||
return false
|
||||
}
|
||||
return this.zdStorSet.indexOf(String(lgort).trim()) !== -1
|
||||
},
|
||||
isPushDisabled() {
|
||||
if (this.multipleSelection.length !== 1) {
|
||||
return true
|
||||
@@ -192,6 +399,10 @@ export default {
|
||||
return
|
||||
}
|
||||
const row = this.multipleSelection[0]
|
||||
if (this.isZdStor(row.lgort)) {
|
||||
this.$message.error('交货单 ' + row.vbeln + ' 的存储地点 ' + row.lgort + ' 属于中鼎仓库,不能下推出库')
|
||||
return
|
||||
}
|
||||
this.$confirm('确认下推交货单 ' + row.vbeln + ' 生成出库单?', '下推出库', {
|
||||
confirmButtonText: '确定',
|
||||
cancelButtonText: '取消',
|
||||
@@ -232,6 +443,7 @@ export default {
|
||||
})
|
||||
}).catch(() => {})
|
||||
},
|
||||
// 点击交货单号查看明细
|
||||
openDetailDialog(row) {
|
||||
this.currentOrder = { ...row }
|
||||
this.detailVisible = true
|
||||
@@ -250,6 +462,141 @@ export default {
|
||||
this.detailVisible = false
|
||||
this.currentOrder = {}
|
||||
this.itemList = []
|
||||
},
|
||||
handleEdit(row) {
|
||||
if (!this.canEdit(row)) {
|
||||
this.$message.warning('仅已创建或已取消状态的交货单可编辑')
|
||||
return
|
||||
}
|
||||
this.editForm = {
|
||||
...createDefaultForm(),
|
||||
id: row.id,
|
||||
vbeln: row.vbeln,
|
||||
lifnr: row.lifnr,
|
||||
lifnr_name: row.lifnr_name,
|
||||
lfart: row.lfart,
|
||||
billtype: row.billtype,
|
||||
bldat: row.bldat,
|
||||
wadat: row.wadat,
|
||||
lfdat: row.lfdat,
|
||||
wadat_ist: row.wadat_ist,
|
||||
status: row.status,
|
||||
items: []
|
||||
}
|
||||
this.componentItems = []
|
||||
this.editVisible = true
|
||||
this.loadEditItems(row.vbeln)
|
||||
},
|
||||
loadEditItems(vbeln) {
|
||||
this.editItemLoading = true
|
||||
getDetail(vbeln).then(res => {
|
||||
const detail = res.data || res || {}
|
||||
const items = detail.items || []
|
||||
this.editForm.items = items
|
||||
.filter(item => !item.rspos || item.rspos === 0)
|
||||
.map(item => ({ ...item }))
|
||||
this.componentItems = items.filter(item => item.rspos && item.rspos !== 0)
|
||||
}).catch(() => {
|
||||
this.editForm.items = []
|
||||
this.componentItems = []
|
||||
}).finally(() => {
|
||||
this.editItemLoading = false
|
||||
})
|
||||
},
|
||||
addItem() {
|
||||
this.editForm.items.push(createItem())
|
||||
},
|
||||
removeItem(index) {
|
||||
this.editForm.items.splice(index, 1)
|
||||
},
|
||||
submitEdit() {
|
||||
this.$refs.form.validate(valid => {
|
||||
if (!valid) {
|
||||
return
|
||||
}
|
||||
if (!this.editForm.items.length) {
|
||||
this.$message.warning('请至少保留一条行项目')
|
||||
return
|
||||
}
|
||||
const empty = this.editForm.items.find(item => !item.material || !String(item.material).trim())
|
||||
if (empty) {
|
||||
this.$message.warning('行项目物料编号不能为空')
|
||||
return
|
||||
}
|
||||
const items = this.editForm.items.concat(this.componentItems).map(item => this.toItemPayload(item))
|
||||
this.editSaving = true
|
||||
this.api.edit({
|
||||
id: this.editForm.id,
|
||||
vbeln: this.editForm.vbeln,
|
||||
lifnr: this.editForm.lifnr,
|
||||
lifnr_name: this.editForm.lifnr_name,
|
||||
lfart: this.editForm.lfart,
|
||||
billtype: this.editForm.billtype,
|
||||
bldat: this.editForm.bldat,
|
||||
wadat: this.editForm.wadat,
|
||||
lfdat: this.editForm.lfdat,
|
||||
wadat_ist: this.editForm.wadat_ist,
|
||||
status: this.editForm.status,
|
||||
items
|
||||
}).then(() => {
|
||||
this.$message.success('修改成功')
|
||||
this.closeEditDialog()
|
||||
this.crud.refresh()
|
||||
}).finally(() => {
|
||||
this.editSaving = false
|
||||
})
|
||||
})
|
||||
},
|
||||
toItemPayload(item) {
|
||||
return {
|
||||
id: item.id,
|
||||
posnr: item.posnr,
|
||||
material: item.material,
|
||||
matl_desc: item.matl_desc,
|
||||
deliv_qty: item.deliv_qty,
|
||||
unit: item.unit,
|
||||
po_number: item.po_number,
|
||||
po_item: item.po_item,
|
||||
werks: item.werks,
|
||||
lgort: item.lgort,
|
||||
ntgew: item.ntgew,
|
||||
brgew: item.brgew,
|
||||
gewei: item.gewei,
|
||||
volum: item.volum,
|
||||
oleh: item.oleh,
|
||||
uebtk: item.uebtk,
|
||||
uebto: item.uebto,
|
||||
untto: item.untto,
|
||||
lifexpos: item.lifexpos,
|
||||
rspos: item.rspos,
|
||||
component_material: item.component_material,
|
||||
component_qty: item.component_qty
|
||||
}
|
||||
},
|
||||
closeEditDialog() {
|
||||
this.editVisible = false
|
||||
this.editSaving = false
|
||||
this.editForm = createDefaultForm()
|
||||
this.componentItems = []
|
||||
if (this.$refs.form) {
|
||||
this.$refs.form.clearValidate()
|
||||
}
|
||||
},
|
||||
handleDelete(row) {
|
||||
if (!this.canEdit(row)) {
|
||||
this.$message.warning('已下发或已完成的交货单不能删除')
|
||||
return
|
||||
}
|
||||
this.$confirm('确认删除交货单 ' + row.vbeln + ' 及其行项目?', '删除交货单', {
|
||||
confirmButtonText: '确定',
|
||||
cancelButtonText: '取消',
|
||||
type: 'warning'
|
||||
}).then(() => {
|
||||
this.api.del([row.id]).then(() => {
|
||||
this.$message.success('删除成功')
|
||||
this.crud.toQuery()
|
||||
})
|
||||
}).catch(() => {})
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -63,4 +63,11 @@ export function reverse(data) {
|
||||
})
|
||||
}
|
||||
|
||||
export default { add, edit, del, get, getDetail, outPush, pushZd, reverse }
|
||||
export function getParamValue(code) {
|
||||
return request({
|
||||
url: 'api/param/getValueByCode/' + code,
|
||||
method: 'post'
|
||||
})
|
||||
}
|
||||
|
||||
export default { add, edit, del, get, getDetail, outPush, pushZd, reverse, getParamValue }
|
||||
|
||||
Reference in New Issue
Block a user