前端上传

product
tengxi 2 years ago
parent 5581a01ccc
commit 0b0fbc4f37

@ -88,7 +88,7 @@ public class PoundlistController {
//处理id字段转名称若无需转或者为空可删除
for(PoundlistEntity entity:list){
Map<String,Object> materialCodeMap = new HashMap<>();
entity.setMaterialCode(generaterSwapUtil.getPopupSelectValue("381037852907038533","item_code","item_code",entity.getMaterialCode(),materialCodeMap));
// entity.setMaterialCode(generaterSwapUtil.getPopupSelectValue("381037852907038533","item_code","item_code",entity.getMaterialCode(),materialCodeMap));
Map<String,Object> salesNameMap = new HashMap<>();
entity.setSalesName(generaterSwapUtil.getPopupSelectValue("381038993740949317","contract_name","contract_name",entity.getSalesName(),salesNameMap));
Map<String,Object> licenseNoMap = new HashMap<>();
@ -96,7 +96,7 @@ public class PoundlistController {
entity.setPoundPictures(generaterSwapUtil.getFileNameInJson(entity.getPoundPictures()));
entity.setVehiclePictures(generaterSwapUtil.getFileNameInJson(entity.getVehiclePictures()));
Map<String,Object> purchaseNameMap = new HashMap<>();
entity.setPurchaseName(generaterSwapUtil.swapRelationFormValue("selectField121",entity.getPurchaseName(),"294090217084722181",purchaseNameMap));
// entity.setPurchaseName(generaterSwapUtil.swapRelationFormValue("selectField121",entity.getPurchaseName(),"294090217084722181",purchaseNameMap));
}
List<PoundlistListVO> listVO=JsonUtil.getJsonToList(list,PoundlistListVO.class);
for(PoundlistListVO poundlistVO:listVO){
@ -166,7 +166,7 @@ public class PoundlistController {
//处理id字段转名称若无需转或者为空可删除
for(PoundlistEntity entity:list){
Map<String,Object> materialCodeMap = new HashMap<>();
entity.setMaterialCode(generaterSwapUtil.swapRelationFormValue("selectField121",entity.getMaterialCode(),"294090217084722181",materialCodeMap));
// entity.setMaterialCode(generaterSwapUtil.swapRelationFormValue("selectField121",entity.getMaterialCode(),"294090217084722181",materialCodeMap));
Map<String,Object> salesNameMap = new HashMap<>();
entity.setSalesName(generaterSwapUtil.swapRelationFormValue("selectField121",entity.getSalesName(),"294090217084722181",salesNameMap));
Map<String,Object> licenseNoMap = new HashMap<>();
@ -174,7 +174,7 @@ public class PoundlistController {
entity.setPoundPictures(generaterSwapUtil.getFileNameInJson(entity.getPoundPictures()));
entity.setVehiclePictures(generaterSwapUtil.getFileNameInJson(entity.getVehiclePictures()));
Map<String,Object> purchaseNameMap = new HashMap<>();
entity.setPurchaseName(generaterSwapUtil.swapRelationFormValue("selectField121",entity.getPurchaseName(),"294090217084722181",purchaseNameMap));
// entity.setPurchaseName(generaterSwapUtil.swapRelationFormValue("selectField121",entity.getPurchaseName(),"294090217084722181",purchaseNameMap));
}
List<PoundlistListVO> listVO=JsonUtil.getJsonToList(list,PoundlistListVO.class);
for(PoundlistListVO poundlistVO:listVO){

@ -90,17 +90,17 @@ public class PoundlistEntity {
@TableField("SUPPLIER_NAME")
private String supplierName;
@TableField("PURCHASE_CODE")
private String purchaseCode;
@TableField("PURCHASE_ID")
private String purchaseId;
@TableField("PURCHASE_NAME")
private String purchaseName;
// @TableField("PURCHASE_NAME")
// private String purchaseName;
@TableField("MATERIAL_CODE")
private String materialCode;
@TableField("MATERIAL_ID")
private String materialId;
@TableField("MATERIAL_NAME")
private String materialName;
// @TableField("MATERIAL_NAME")
// private String materialName;
@TableField("ADVANCE")
private String advance;

@ -90,7 +90,7 @@ public class PoundlistServiceImpl extends ServiceImpl<PoundlistMapper, Poundlist
}
if(StringUtil.isNotEmpty(poundlistPagination.getMaterialName())){
poundlistNum++;
poundlistQueryWrapper.lambda().like(PoundlistEntity::getMaterialName,poundlistPagination.getMaterialName());
// poundlistQueryWrapper.lambda().like(PoundlistEntity::getMaterialName,poundlistPagination.getMaterialName());
}
if(StringUtil.isNotEmpty(poundlistPagination.getKeyword())){
poundlistNum++;
@ -166,7 +166,7 @@ public class PoundlistServiceImpl extends ServiceImpl<PoundlistMapper, Poundlist
}
if(StringUtil.isNotEmpty(poundlistPagination.getMaterialName())){
poundlistNum++;
poundlistQueryWrapper.lambda().like(PoundlistEntity::getMaterialName,poundlistPagination.getMaterialName());
// poundlistQueryWrapper.lambda().like(PoundlistEntity::getMaterialName,poundlistPagination.getMaterialName());
}
if(AllIdList.size()>0){

@ -43,9 +43,9 @@
@selection-change="handleSelectionChange" border>
<el-table-column type="index" width="50" label="序号" fixed="left" align="center" />
<el-table-column prop="mName" label="区域名称" width="300" align="center"sortable fixed="left" />
<el-table-column prop="creatortime" label="创建时间" width="300" sortablealign="center"/>
<el-table-column prop="creatorusername" label="创建人名称" width="300" sortablealign="center"/>
<el-table-column prop="lastmodifytime" label="修改时间" width="300" sortablealign="center"/>
<el-table-column prop="creatortime" label="创建时间" width="300" sortable align="center"/>
<el-table-column prop="creatorusername" label="创建人名称" width="300" sortable align="center"/>
<el-table-column prop="lastmodifytime" label="修改时间" width="300" sortable align="center"/>
<el-table-column prop="lastmodifyusername" label="修改人名称" width="300"sortable align="center"/>
<el-table-column label="操作" fixed="right" width="100">
<template slot-scope="scope">

@ -57,12 +57,13 @@
/>
<el-table-column prop="quantity" label="数量" width="120" sortable align="center"
/>
<el-table-column label="币别 " width="80" prop="currency" sortable algin="center"
>
<el-table-column label="币别" width="80" sortable prop="currency" align="center">
<template slot-scope="scope">
{{ scope.row.currency | dynamicText(currencyOptions) }}
</template>
</el-table-column>
<el-table-column prop="invoiceAmount" label="发票金额" sortable width="120" align="center"
/>
<el-table-column prop="invoiceQuantity" label="发票数量" sortable width="120" align="center"
@ -71,12 +72,13 @@
/>
<el-table-column prop="contractName" label="合同名称" sortable width="200" align="center"
/>
<el-table-column label="单据状态 " width="120" sortable prop="status" algin="center"
>
<el-table-column label="单据状态" width="120" sortable prop="status" align="center">
<template slot-scope="scope">
{{ scope.row.status | dynamicText(statusOptions) }}
</template>
</el-table-column>
<el-table-column prop="creatorUserName" label="制单人" width="120" sortable align="center"
/>
<el-table-column label="操作" fixed="right"

@ -48,7 +48,8 @@
<el-table-column prop="contractCode" label="合同编码" width="200" align="center" sortable fixed="left"/>
<el-table-column prop="contractName" label="合同名称" width="200" align="center" sortable fixed="left"/>
<el-table-column prop="contractNo" label="对方合同号" width="200" align="center" sortable/>
<el-table-column label="合同类型 " width="120" prop="contractType" algin="center" sortable>
<el-table-column label="合同类型" width="120" sortable prop="contractType" align="center">
<template slot-scope="scope">
{{ scope.row.contractType | dynamicText(contractTypeOptions) }}
</template>
@ -62,12 +63,12 @@
<el-table-column prop="remark" label="备注" width="120" align="center" sortable/>
<el-table-column prop="creatorusername" label="录入人" width="120" align="center" sortable/>
<el-table-column prop="status" label="合同状态" width="120" align="center" sortable>
<template slot-scope="scope">
{{ scope.row.status | dynamicText(statusOptions) }}
</template>
</el-table-column>
<el-table-column label="单据状态" width="120" sortable prop="status" align="center">
<template slot-scope="scope">
{{ scope.row.status | dynamicText(statusOptions) }}
</template>
</el-table-column>
<el-table-column prop="approval" label="集团审批" width="120" align="center" sortable>
<template slot-scope="scope">
<el-tag type="danger" disable-transitions v-if="scope.row.approval == '关'">

@ -60,9 +60,9 @@
<screenfull isContainer/>
</div>
</div>
<JNPF-table v-loading="listLoading" :data="list" @sort-change='sortChange'has-c :hasNO="false"
<JNPF-table v-loading="listLoading" :data="list" @sort-change='sortChange' has-c :hasNO="false"
@selection-change="handleSelectionChange" border>
<el-table-column type="index" width="50" label="序号" fixed="left" align="center" />
<el-table-column type="index" width="50" label="序号" fixed="left" align="center"/>
<el-table-column prop="supplierCd" label="客户编码" width="200" align="center" sortable fixed="left"
sortable="custom"/>
<el-table-column prop="supplierNm" label="客户名称" width="200" align="center" sortable fixed="left"
@ -71,12 +71,14 @@
sortable="custom"/>
<el-table-column prop="vatRegistrationNum" label="纳税编号" width="200" align="center" sortable
/>
<el-table-column label="客户等级" width="120" prop="customerLevel" algin="center" sortable
sortable="custom">
<el-table-column label="客户等级" width="120" sortable prop="customerLevel" align="center">
<template slot-scope="scope">
{{ scope.row.customerLevel | dynamicText(customerLevelOptions) }}
</template>
</el-table-column>
<el-table-column prop="contactName" label="联系人" width="120" align="center" sortable
sortable="custom"/>
<el-table-column prop="country" label="国家" width="120" align="center" sortable
@ -85,30 +87,35 @@
sortable="custom"/>
<!-- <el-table-column prop="province" label="省市县" width="0" align="left"-->
<!--/>-->
<el-table-column prop="bank" label="开户行" width="200" align="left" sortable
<el-table-column prop="bank" label="开户行" width="200" align="center" sortable
/>
<el-table-column label="是否启用" width="120" prop="status" algin="left" sortable
sortable="custom">
<el-table-column label="是否启用" width="120" sortable prop="status" align="center">
<template slot-scope="scope">
{{ scope.row.status | dynamicText(statusOptions) }}
</template>
</el-table-column>
<el-table-column prop="bankAccount" label="银行账号" width="0" align="left"
<el-table-column prop="bankAccount" label="银行账号" width="0" align="center"
/>
<el-table-column label="企业性质" width="0" prop="enterprise" algin="left"
>
<el-table-column label="企业性质" width="120" sortable prop="enterprise" align="center">
<template slot-scope="scope">
{{ scope.row.enterprise | dynamicText(enterpriseOptions) }}
</template>
</el-table-column>
<el-table-column prop="address" label="地址" width="0" align="left"
<el-table-column prop="address" label="地址" width="120" align="center"
sortable="custom"/>
<el-table-column label="客户分类" width="0" prop="classification" algin="left"
>
<el-table-column label="客户分类" width="120" sortable prop="classification" align="center">
<template slot-scope="scope">
{{ scope.row.classification | dynamicText(classificationOptions) }}
</template>
</el-table-column>
<el-table-column label="操作" fixed="right"
width="150">
<template slot-scope="scope">

@ -55,8 +55,7 @@
/>
<el-table-column prop="quantity" label="数量" width="120" align="center" sortable
/>
<el-table-column label="币别 " width="120" prop="currency" algin="center" sortable
>
<el-table-column label="币别" width="80" sortable prop="currency" align="center">
<template slot-scope="scope">
{{ scope.row.currency | dynamicText(currencyOptions) }}
</template>
@ -71,12 +70,13 @@
{{ scope.row.invoiceType | dynamicText(invoiceTypeOptions) }}
</template>
</el-table-column>
<el-table-column label="单据状态" width="120" prop="status" algin="center" sortable
>
<el-table-column label="单据状态" width="120" sortable prop="status" align="center">
<template slot-scope="scope">
{{ scope.row.status | dynamicText(statusOptions) }}
</template>
</el-table-column>
<el-table-column prop="creatorUserName" label="制单人" width="120" align="center" sortable
/>
<el-table-column label="操作" fixed="right"

@ -1,285 +1,314 @@
<template>
<el-dialog :title="!dataForm.id ? '新建' : isDetail ? '详情':'编辑'"
:close-on-click-modal="false" append-to-body
:visible.sync="visible" class="JNPF-dialog JNPF-dialog_center" lock-scroll
width="1000px">
<el-row :gutter="15" class="">
<el-form ref="elForm" :model="dataForm" :rules="rules" size="small" label-width="100px" label-position="right" >
<template v-if="!loading">
<el-col :span="12" >
<el-form-item label="物料编码"
prop="itemCode" >
<el-input v-model="dataForm.itemCode"
placeholder="请输入" clearable :style='{"width":"100%"}'>
<el-dialog :title="!dataForm.id ? '新建' : isDetail ? '详情':'编辑'"
:close-on-click-modal="false" append-to-body
:visible.sync="visible" class="JNPF-dialog JNPF-dialog_center" lock-scroll
width="1000px">
<el-row :gutter="15" class="">
<el-form ref="elForm" :model="dataForm" :rules="rules" size="small" label-width="100px" label-position="right">
<template v-if="!loading">
<el-col :span="12">
<el-form-item label="物料编码"
prop="itemCode">
<el-input v-model="dataForm.itemCode"
placeholder="请输入" clearable :style='{"width":"100%"}'>
</el-input>
</el-form-item>
</el-col>
<el-col :span="12" >
<el-form-item label="物料名称"
prop="itemName" >
<el-input v-model="dataForm.itemName"
placeholder="请输入" clearable :style='{"width":"100%"}'>
</el-input>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="物料名称"
prop="itemName">
<el-input v-model="dataForm.itemName"
placeholder="请输入" clearable :style='{"width":"100%"}'>
</el-input>
</el-form-item>
</el-col>
<el-col :span="12" >
<el-form-item label="物料说明"
prop="description" >
<el-input v-model="dataForm.description"
placeholder="请输入" clearable :style='{"width":"100%"}'>
</el-input>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="物料说明"
prop="description">
<el-input v-model="dataForm.description"
placeholder="请输入" clearable :style='{"width":"100%"}'>
</el-input>
</el-form-item>
</el-col>
<el-col :span="12" >
<el-form-item label="主单位名称"
prop="primaryUnitOmeasure" >
<el-select v-model="dataForm.primaryUnitOmeasure"
placeholder="请选择单位名称" clearable :style='{"width":"100%"}'>
<el-option v-for="(item, index) in primaryUnitOmeasureOptions" :key="index" :label="item.fullName" :value="item.id" :disabled="item.disabled" ></el-option>
</el-input>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="主单位名称"
prop="primaryUnitOmeasure">
<el-select v-model="dataForm.primaryUnitOmeasure"
placeholder="请选择单位名称" clearable :style='{"width":"100%"}'>
<el-option v-for="(item, index) in primaryUnitOmeasureOptions" :key="index" :label="item.fullName"
:value="item.id" :disabled="item.disabled"></el-option>
</el-select>
</el-form-item>
</el-col>
<el-col :span="12" >
<el-form-item label="是否可采购"
prop="purchaseFlag" >
<el-select v-model="dataForm.purchaseFlag"
placeholder="请选择" clearable :style='{"width":"100%"}'>
<el-option v-for="(item, index) in purchaseFlagOptions" :key="index" :label="item.fullName" :value="item.id" :disabled="item.disabled" ></el-option>
</el-select>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="是否可采购"
prop="purchaseFlag">
<el-select v-model="dataForm.purchaseFlag"
placeholder="请选择" clearable :style='{"width":"100%"}'>
<el-option v-for="(item, index) in purchaseFlagOptions" :key="index" :label="item.fullName"
:value="item.id" :disabled="item.disabled"></el-option>
</el-select>
</el-form-item>
</el-col>
<el-col :span="12" >
<el-form-item label="是否可销售 "
prop="salesFlag" >
<el-select v-model="dataForm.salesFlag"
placeholder="请选择" clearable :style='{"width":"100%"}'>
<el-option v-for="(item, index) in salesFlagOptions" :key="index" :label="item.fullName" :value="item.id" :disabled="item.disabled" ></el-option>
</el-select>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="是否可销售 "
prop="salesFlag">
<el-select v-model="dataForm.salesFlag"
placeholder="请选择" clearable :style='{"width":"100%"}'>
<el-option v-for="(item, index) in salesFlagOptions" :key="index" :label="item.fullName"
:value="item.id" :disabled="item.disabled"></el-option>
</el-select>
</el-form-item>
</el-col>
<el-col :span="12" >
<el-form-item label="默认出库区"
prop="outArea" >
<popupSelect v-model="dataForm.outArea"
placeholder="请选择" clearable field="outArea" interfaceId="381404161809350213" :columnOptions="outAreacolumnOptions" propsValue="id" relationField="areaname" popupType="dialog"
popupTitle="选择数据" popupWidth="800px"
>
</el-select>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="默认出库区"
prop="outArea">
<popupSelect v-model="dataForm.outArea"
placeholder="请选择" clearable field="outArea" interfaceId="381404161809350213"
:columnOptions="outAreacolumnOptions" propsValue="id" relationField="areaname"
popupType="dialog"
popupTitle="选择数据" popupWidth="800px"
>
</popupSelect>
</el-form-item>
</el-col>
<el-col :span="12" >
<el-form-item label="默认入库区"
prop="inArea" >
<popupSelect v-model="dataForm.inArea"
placeholder="请选择" clearable field="inArea" interfaceId="381404161809350213" :columnOptions="inAreacolumnOptions" propsValue="id" relationField="areaname" popupType="dialog"
popupTitle="选择数据" popupWidth="800px"
>
</popupSelect>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="默认入库区"
prop="inArea">
<popupSelect v-model="dataForm.inArea"
placeholder="请选择" clearable field="inArea" interfaceId="381404161809350213"
:columnOptions="inAreacolumnOptions" propsValue="id" relationField="areaname"
popupType="dialog"
popupTitle="选择数据" popupWidth="800px"
>
</popupSelect>
</el-form-item>
</el-col>
<el-col :span="12" >
<el-form-item label="标准成本"
prop="standardCost" >
<el-input v-model="dataForm.standardCost"
placeholder="请输入标准成本" clearable :style='{"width":"100%"}'>
</popupSelect>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="标准成本"
prop="standardCost">
<el-input v-model="dataForm.standardCost"
placeholder="请输入标准成本" clearable :style='{"width":"100%"}'>
</el-input>
</el-form-item>
</el-col>
<el-col :span="12" >
<el-form-item label="财务类别"
prop="financial" >
<el-input v-model="dataForm.financial"
placeholder="请输入财务类别" clearable :style='{"width":"100%"}'>
</el-input>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="财务类别"
prop="financial">
<el-input v-model="dataForm.financial"
placeholder="请输入财务类别" clearable :style='{"width":"100%"}'>
</el-input>
</el-form-item>
</el-col>
<el-col :span="12" >
<el-form-item label="类别名称"
prop="financialName" >
<el-input v-model="dataForm.financialName"
placeholder="请输入类别名称" clearable :style='{"width":"100%"}'>
</el-input>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="类别名称"
prop="financialName">
<el-input v-model="dataForm.financialName"
placeholder="请输入类别名称" clearable :style='{"width":"100%"}'>
</el-input>
</el-form-item>
</el-col>
<el-col :span="12" >
<el-form-item label="生效状态"
prop="effectiveStatus" >
<el-select v-model="dataForm.effectiveStatus"
placeholder="请选择" clearable :style='{"width":"100%"}'>
<el-option v-for="(item, index) in effectiveStatusOptions" :key="index" :label="item.fullName" :value="item.id" :disabled="item.disabled" ></el-option>
</el-input>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="生效状态"
prop="effectiveStatus">
<el-select v-model="dataForm.effectiveStatus"
placeholder="请选择" clearable :style='{"width":"100%"}'>
<el-option v-for="(item, index) in effectiveStatusOptions" :key="index" :label="item.fullName"
:value="item.id" :disabled="item.disabled"></el-option>
</el-select>
</el-form-item>
</el-col>
</template>
</el-form>
</el-select>
</el-form-item>
</el-col>
</template>
</el-form>
</el-row>
<span slot="footer" class="dialog-footer">
<el-button @click="visible = false"> </el-button>
<el-button type="primary" @click="dataFormSubmit()" v-if="!isDetail"> </el-button>
</span>
</el-dialog>
</el-dialog>
</template>
<script>
import request from '@/utils/request'
import { getDataInterfaceRes } from '@/api/systemData/dataInterface'
import { getDictionaryDataSelector } from '@/api/systemData/dictionary'
export default {
components: {},
props: [],
data() {
return {
visible: false,
loading: false,
isDetail: false,
dataForm: {
itemCode : '',
itemName : '',
description : '',
primaryUnitOmeasure : "",
purchaseFlag : "",
salesFlag : "",
outArea : "",
inArea : "",
standardCost : '',
financial : '',
financialName : '',
effectiveStatus : "Y",
itemId : '',
errorMessage : '',
creatorTime : "",
lastModifyTime : "",
},
rules:
{
itemCode: [
{
required: true,
message: '请输入',
trigger: 'blur'
},
],
itemName: [
{
required: true,
message: '请输入',
trigger: 'blur'
},
],
standardCost: [
],
},
primaryUnitOmeasureOptions:[{"fullName":"千克","id":"1"},{"fullName":"吨","id":"0"}],
purchaseFlagOptions:[{"fullName":"是","id":"Y"},{"fullName":"否","id":"N"}],
salesFlagOptions:[{"fullName":"是","id":"Y"},{"fullName":"否","id":"N"}],
outAreacolumnOptions:[ {"label":"库区编码","value":"areacode"}, {"label":"库区名称","value":"areaname"}, {"label":"仓库","value":"name"}, {"label":"最高库存","value":"maximum"},],
inAreacolumnOptions:[ {"label":"库区编码","value":"areacode"}, {"label":"库区名称","value":"areaname"}, {"label":"仓库","value":"name"}, {"label":"最高库存","value":"maximum"},],
effectiveStatusOptions:[{"fullName":"生效","id":"Y"},{"fullName":"不生效","id":"N"}],
import request from '@/utils/request'
import { getDataInterfaceRes } from '@/api/systemData/dataInterface'
import { getDictionaryDataSelector } from '@/api/systemData/dictionary'
}
},
computed: {},
watch: {},
created() {
},
mounted() {},
methods: {
clearData(data){
for (let key in data) {
if (data[key] instanceof Array) {
data[key] = [];
} else if (data[key] instanceof Object) {
this.clearData(data[key]);
} else {
data[key] = "";
}
}
},
init(id, isDetail) {
this.dataForm.id = id || 0;
this.visible = true;
this.isDetail = isDetail || false;
this.$nextTick(() => {
this.$refs['elForm'].resetFields();
if(this.dataForm.id){
this.loading = true
request({
url: '/api/example/Material/'+this.dataForm.id,
method: 'get'
}).then(res => {
this.dataInfo(res.data)
this.loading = false
});
}else{
this.clearData(this.dataForm)
}
});
this.$store.commit('generator/UPDATE_RELATION_DATA', {})
},
//
dataFormSubmit() {
this.$refs['elForm'].validate((valid) => {
if (valid) {
this.request()
}
})
},
request() {
var _data =this.dataList()
if (!this.dataForm.id) {
request({
url: '/api/example/Material',
method: 'post',
data: _data
}).then((res) => {
this.$message({
message: res.msg,
type: 'success',
duration: 1000,
onClose: () => {
this.visible = false
this.$emit('refresh', true)
}
})
})
}else{
request({
url: '/api/example/Material/'+this.dataForm.id,
method: 'PUT',
data: _data
}).then((res) => {
this.$message({
message: res.msg,
type: 'success',
duration: 1000,
onClose: () => {
this.visible = false
this.$emit('refresh', true)
}
})
})
}
},
dataList(){
var _data = JSON.parse(JSON.stringify(this.dataForm));
return _data;
},
dataInfo(dataAll){
let _dataAll =dataAll
this.dataForm = _dataAll
},
export default {
components: {},
props: [],
data() {
return {
visible: false,
loading: false,
isDetail: false,
dataForm: {
itemCode: '',
itemName: '',
description: '',
primaryUnitOmeasure: '',
purchaseFlag: '',
salesFlag: '',
outArea: '',
inArea: '',
standardCost: '',
financial: '',
financialName: '',
effectiveStatus: 'Y',
itemId: '',
errorMessage: '',
creatorTime: '',
lastModifyTime: ''
},
rules:
{
itemCode: [
{
required: true,
message: '请输入',
trigger: 'blur'
}
],
itemName: [
{
required: true,
message: '请输入',
trigger: 'blur'
}
],
outArea: [
{
required: true,
message: '请输入',
trigger: 'blur'
}
],
inArea: [
{
required: true,
message: '请输入',
trigger: 'blur'
}
],
standardCost: []
},
primaryUnitOmeasureOptions: [{ 'fullName': '千克', 'id': '1' }, { 'fullName': '吨', 'id': '0' }],
purchaseFlagOptions: [{ 'fullName': '是', 'id': 'Y' }, { 'fullName': '否', 'id': 'N' }],
salesFlagOptions: [{ 'fullName': '是', 'id': 'Y' }, { 'fullName': '否', 'id': 'N' }],
outAreacolumnOptions: [{ 'label': '库区编码', 'value': 'areacode' }, {
'label': '库区名称',
'value': 'areaname'
}, { 'label': '仓库', 'value': 'name' }, { 'label': '最高库存', 'value': 'maximum' }],
inAreacolumnOptions: [{ 'label': '库区编码', 'value': 'areacode' }, {
'label': '库区名称',
'value': 'areaname'
}, { 'label': '仓库', 'value': 'name' }, { 'label': '最高库存', 'value': 'maximum' }],
effectiveStatusOptions: [{ 'fullName': '生效', 'id': 'Y' }, { 'fullName': '不生效', 'id': 'N' }]
}
},
computed: {},
watch: {},
created() {
},
mounted() {
},
methods: {
clearData(data) {
for (let key in data) {
if (data[key] instanceof Array) {
data[key] = []
} else if (data[key] instanceof Object) {
this.clearData(data[key])
} else {
data[key] = ''
}
}
},
init(id, isDetail) {
this.dataForm.id = id || 0
this.visible = true
this.isDetail = isDetail || false
this.$nextTick(() => {
this.$refs['elForm'].resetFields()
if (this.dataForm.id) {
this.loading = true
request({
url: '/api/example/Material/' + this.dataForm.id,
method: 'get'
}).then(res => {
this.dataInfo(res.data)
this.loading = false
})
} else {
this.clearData(this.dataForm)
}
})
this.$store.commit('generator/UPDATE_RELATION_DATA', {})
},
//
dataFormSubmit() {
this.$refs['elForm'].validate((valid) => {
if (valid) {
this.request()
}
})
},
request() {
var _data = this.dataList()
if (!this.dataForm.id) {
request({
url: '/api/example/Material',
method: 'post',
data: _data
}).then((res) => {
this.$message({
message: res.msg,
type: 'success',
duration: 1000,
onClose: () => {
this.visible = false
this.$emit('refresh', true)
}
})
})
} else {
request({
url: '/api/example/Material/' + this.dataForm.id,
method: 'PUT',
data: _data
}).then((res) => {
this.$message({
message: res.msg,
type: 'success',
duration: 1000,
onClose: () => {
this.visible = false
this.$emit('refresh', true)
}
})
})
}
},
dataList() {
var _data = JSON.parse(JSON.stringify(this.dataForm))
return _data
},
dataInfo(dataAll) {
let _dataAll = dataAll
this.dataForm = _dataAll
}
}
}
</script>

@ -45,50 +45,52 @@
<JNPF-table v-loading="listLoading" :data="list" @sort-change='sortChange' has-c :hasNO="false"
@selection-change="handleSelectionChange" border>
<el-table-column type="index" width="50" label="序号" fixed="left" align="center" />
<el-table-column prop="itemCode" label="物料编码" width="0" align="left"
<el-table-column prop="itemCode" label="物料编码" width="200" align="center" sortable
/>
<el-table-column prop="itemName" label="物料名称" width="0" align="left"
<el-table-column prop="itemName" label="物料名称" width="200" align="center" sortable
/>
<el-table-column prop="description" label="物料说明" width="0" align="left"
<el-table-column prop="description" label="物料说明" width="150" align="center" sortable
/>
<el-table-column label="主单位名称" width="0" prop="primaryUnitOmeasure" algin="left"
>
<el-table-column label="主单位名称" width="120" sortable prop="primaryUnitOmeasure" align="center">
<template slot-scope="scope">
{{ scope.row.primaryUnitOmeasure | dynamicText(primaryUnitOmeasureOptions) }}
</template>
</el-table-column>
<el-table-column label="是否可采购" width="0" prop="purchaseFlag" algin="left"
>
<el-table-column label="是否可采购" width="120" sortable prop="purchaseFlag" align="center">
<template slot-scope="scope">
{{ scope.row.purchaseFlag | dynamicText(purchaseFlagOptions) }}
</template>
</el-table-column>
<el-table-column label="是否可销售 " width="0" prop="salesFlag" algin="left"
>
<el-table-column label="是否可销售" width="120" sortable prop="salesFlag" align="center">
<template slot-scope="scope">
{{ scope.row.salesFlag | dynamicText(salesFlagOptions) }}
</template>
</el-table-column>
<el-table-column prop="outArea" label="默认出库区" width="0" align="left"
<el-table-column prop="outArea" label="默认出库区" width="120" align="center" sortable
/>
<el-table-column prop="inArea" label="默认入库区" width="0" align="left"
<el-table-column prop="inArea" label="默认入库区" width="120" align="center" sortable
/>
<el-table-column prop="standardCost" label="标准成本" width="0" align="left"
<el-table-column prop="standardCost" label="标准成本" width="120" align="center" sortable
/>
<el-table-column prop="financial" label="财务类别" width="0" align="left"
<el-table-column prop="financial" label="财务类别" width="120" align="center" sortable
/>
<el-table-column prop="financialName" label="类别名称" width="0" align="left"
<el-table-column prop="financialName" label="类别名称" width="120" align="center" sortable
/>
<el-table-column prop="itemId" label="ERP物料ID" width="0" align="left"
<el-table-column prop="itemId" label="ERP物料ID" width="120" align="center" sortable
/>
<el-table-column prop="errorMessage" label="错误信息" width="0" align="left"
<el-table-column prop="errorMessage" label="错误信息" width="120" align="center" sortable
/>
<el-table-column label="生效状态" width="0" prop="effectiveStatus" algin="left"
>
<el-table-column label="生效状态" width="120" sortable prop="effectiveStatus" align="center">
<template slot-scope="scope">
{{ scope.row.effectiveStatus | dynamicText(effectiveStatusOptions) }}
</template>
</el-table-column>
<el-table-column label="操作" fixed="right"
width="100">
<template slot-scope="scope">
@ -203,6 +205,7 @@
}).then(res => {
var _list = []
for (let i = 0; i < res.data.list.length; i++) {
res.data.list[i].creatorTime = res.data.list[i].creatorTime ? res.data.list[i].creatorTime.substring(0, 10) : '';
let _data = res.data.list[i]
_list.push(_data)
}

@ -58,20 +58,22 @@
/>
<el-table-column prop="monitoringId" label="区域" width="200" align="center" sortable
/>
<el-table-column label="设备状态:" width="200" prop="mStatus" algin="center" sortable
>
<el-table-column label="设备状态" width="200" sortable prop="mStatus" align="center" >
<template slot-scope="scope">
{{ scope.row.mStatus | dynamicText(mStatusOptions) }}
</template>
</el-table-column>
<el-table-column prop="channelNumber" label="设备通道号" width="200" align="center" sortable
/>
<el-table-column label="是否显示" width="200" prop="isEnable" algin="center" sortable
>
<el-table-column label="是否显示" width="200" sortable prop="isEnable" align="center" >
<template slot-scope="scope">
{{ scope.row.isEnable | dynamicText(isEnableOptions) }}
</template>
</el-table-column>
<el-table-column label="操作" fixed="right"
width="100">
<template slot-scope="scope">

@ -64,12 +64,13 @@
/>
<el-table-column prop="supplierName" label="供应商名称" width="200" align="center" sortable fixed="left"
/>
<el-table-column label="币别 " width="80" prop="currency" algin="center" sortable
>
<el-table-column label="币别" width="120" sortable prop="currency" align="center" >
<template slot-scope="scope">
{{ scope.row.currency | dynamicText(currencyOptions) }}
</template>
</el-table-column>
<el-table-column prop="ramount" label="申请金额" width="120" align="center" sortable
/>
<el-table-column prop="paymentAmount" label="付款金额" width="120" align="center"sortable
@ -82,20 +83,21 @@
/>
<el-table-column prop="colectionBank" label="收款银行" width="120" align="center"sortable
/>
<el-table-column label="付款类型" width="100" prop="paymentType" algin="center"sortable
>
<el-table-column label="付款类型" width="120" sortable prop="paymentType" align="center" >
<template slot-scope="scope">
{{ scope.row.paymentType | dynamicText(paymentTypeOptions) }}
</template>
</el-table-column>
<el-table-column label="结算类型" width="100" prop="settlementType" algin="center"sortable
>
<el-table-column label="结算类型" width="120" sortable prop="settlementType" align="center" >
<template slot-scope="scope">
{{ scope.row.settlementType | dynamicText(settlementTypeOptions) }}
</template>
</el-table-column>
<el-table-column label="单据状态 " width="100" prop="status" algin="center"sortable
>
<el-table-column label="单据状态" width="120" sortable prop="status" align="center" >
<template slot-scope="scope">
{{ scope.row.status | dynamicText(statusOptions) }}
</template>

@ -47,17 +47,20 @@
<el-table-column prop="jg_purchaseorder.supplierName" label="供应商名称" width="200" align="center"sortable/>
<el-table-column prop="refundAmount" label="退货金额" width="120" align="center"sortable/>
<el-table-column prop="actualAmount" label="实退金额" width="120" align="center"sortable/>
<el-table-column label="币别 " width="120" prop="currency" algin="center" sortable>
<el-table-column label="币别" width="120" sortable prop="currency" align="center">
<template slot-scope="scope">
{{ scope.row.currency | dynamicText(currencyOptions) }}
</template>
</el-table-column>
<el-table-column prop="refundNum" label="退货数量" width="120" align="center"sortable/>
<el-table-column label="单据状态 " width="120" prop="status" algin="center">
<el-table-column label="单据状态" width="120" sortable prop="status" align="center">
<template slot-scope="scope">
{{ scope.row.status | dynamicText(statusOptions) }}
</template>
</el-table-column>
<el-table-column prop="creatorTime" label="创建时间" width="120" align="center"sortable/>
<el-table-column prop="creatorUserName" label="创建人" width="120" align="center"sortable/>
<el-table-column prop="remark" label="备注" width="0" align="center"sortable/>

@ -55,7 +55,7 @@
<JNPF-table v-loading="listLoading" :data="list" @sort-change='sortChange' has-c :hasNO="false"
@selection-change="handleSelectionChange" border>
<el-table-column type="index" width="50" label="序号" fixed="left" align="center" />
<el-table-column prop="documentNo" label="单据编号" width="200" align="center" fixed="left" sortable
<el-table-column prop="documentNo" label="单据编号" width="200" align="center" fixed="left" sortable
/>
<el-table-column prop="erpNo" label="ERP订单号" width="200" align="center" fixed="left" sortable
/>
@ -67,12 +67,13 @@
/>
<el-table-column prop="num" label="重量" width="120" align="center" sortable
/>
<el-table-column label="币种" width="80" prop="currency" algin="center" sortable
>
<el-table-column label="币种" width="120" sortable prop="currency" align="center">
<template slot-scope="scope">
{{ scope.row.currency | dynamicText(currencyOptions) }}
</template>
</el-table-column>
<el-table-column prop="payPrice" label="已付款金额" width="120" align="center" sortable
/>
<el-table-column prop="invoiceNum" label="发票数量" width="120" align="center" sortable
@ -83,12 +84,12 @@
/>
<el-table-column prop="creatorTime" label="制单时间" width="120" align="center" sortable sortable="custom"
/>
<el-table-column label="单据状态 " width="120" prop="status" algin="center" sortable
>
<template slot-scope="scope" >
<el-table-column label="单据状态" width="120" sortable prop="status" align="center">
<template slot-scope="scope">
{{ scope.row.status | dynamicText(statusOptions) }}
</template>
</el-table-column>
<el-table-column prop="creatorUserName" label="制单人" width="120" align="center" sortable
/>
<el-table-column label="操作" fixed="right"

@ -47,9 +47,9 @@
<JNPF-table v-loading="listLoading" :data="list" @sort-change='sortChange' has-c :hasNO="false"
@selection-change="handleSelectionChange" border>
<el-table-column type="index" width="50" label="序号" fixed="left" align="center" />
<el-table-column prop="areacode" label="库区编码" width="200" align="center" sortable fixed="left"
<el-table-column prop="areacode" label="库区编码" width="250" align="center" sortable fixed="left"
/>
<el-table-column prop="areaname" label="库区名称" width="200" align="center" sortable fixed="left"
<el-table-column prop="areaname" label="库区名称" width="250" align="center" sortable fixed="left"
/>
<el-table-column prop="maximum" label="最高库存" width="200" align="center" sortable
/>
@ -57,12 +57,13 @@
/>
<el-table-column prop="minimum" label="最低库存" width="200" align="center" sortable
/>
<el-table-column label="计量单位" width="200" prop="unit" algin="center" sortable
>
<el-table-column label="计量单位" width="120" sortable prop="unit" align="center" >
<template slot-scope="scope">
{{ scope.row.unit | dynamicText(unitOptions) }}
</template>
</el-table-column>
<el-table-column prop="warehouseId" label="仓库" width="200" align="center" sortable
/>
<el-table-column label="操作" fixed="right"

@ -38,7 +38,7 @@
<JNPF-table v-loading="listLoading" :data="list" @sort-change='sortChange' has-c :hasNO="false"
@selection-change="handleSelectionChange" border>
<el-table-column type="index" width="50" label="序号" fixed="left" align="center" />
<el-table-column prop="documentNo" label="单据编号" width="200" align="center" sortablefixed="left"
<el-table-column prop="documentNo" label="单据编号" width="200" align="center" sortable fixed="left"
/>
<el-table-column prop="salesOrderId" label="销售订单" width="200" align="center"sortable fixed="left"
/>
@ -50,20 +50,22 @@
/>
<el-table-column prop="actualAmount" label="实退金额" width="120" align="center" sortable
/>
<el-table-column label="币别" width="120" prop="currency" algin="center" sortable
>
<el-table-column label="币别" width="120" sortable prop="currency" align="center" >
<template slot-scope="scope">
{{ scope.row.currency | dynamicText(currencyOptions) }}
</template>
</el-table-column>
<el-table-column prop="refundNum" label="退货数量" width="120" align="center" sortable
/>
<el-table-column label="单据状态 " width="120" prop="status" algin="center" sortable
>
<el-table-column label="单据状态" width="120" sortable prop="status" align="center" >
<template slot-scope="scope">
{{ scope.row.status | dynamicText(statusOptions) }}
</template>
</el-table-column>
<el-table-column prop="creatorTime" label="创建时间" width="120" align="center" sortable
/>
<el-table-column prop="creatorUserName" label="创建人" width="120" align="center" sortable

@ -82,62 +82,72 @@
/>
<el-table-column prop="contactName" label="联系人" width="120" align="center" sortable
sortable="custom"/>
<el-table-column label="供应商等级" width="120" prop="supplierLevel" algin="center" sortable
sortable="custom">
<el-table-column label="供应商等级" width="120" sortable prop="supplierLevel" align="center">
<template slot-scope="scope">
{{ scope.row.supplierLevel | dynamicText(supplierLevelOptions) }}
</template>
</el-table-column>
<el-table-column prop="contactPhone" label="联系电话" width="200" align="center" sortable
sortable="custom"/>
<el-table-column label="供应商性质" width="120" prop="enterprise" algin="center" sortable
>
<el-table-column label="供应商性质" width="120" sortable prop="enterprise" align="center">
<template slot-scope="scope">
{{ scope.row.enterprise | dynamicText(enterpriseOptions) }}
</template>
</el-table-column>
<el-table-column prop="address" label="地址" width="200" align="center" sortable
sortable="custom"/>
<el-table-column label="供应商类型" width="120" prop="classification" algin="center" sortable
>
<el-table-column label="供应商类型" width="120" sortable prop="classification" align="center">
<template slot-scope="scope">
{{ scope.row.classification | dynamicText(classificationOptions) }}
</template>
</el-table-column>
<el-table-column prop="bank" label="开户行" width="200" align="center" sortable
/>
<el-table-column prop="vatRegistrationNum" label="纳税编号" width="200" align="center" sortable
/>
<el-table-column prop="bankAccount" label="银行账户" width="200" align="center" sortable
/>
<el-table-column label="默认税码" width="120" prop="taxCode" algin="center" sortable
>
<el-table-column label="默认税码" width="120" sortable prop="taxCode" align="center">
<template slot-scope="scope">
{{ scope.row.taxCode | dynamicText(taxCodeOptions) }}
</template>
</el-table-column>
<el-table-column prop="payable" label="应付科目" width="120" align="center" sortable
/>
<el-table-column label="是否采购" width="120" prop="isPurchase" algin="center" sortable
>
<el-table-column label="是否采购" width="120" sortable prop="isPurchase" align="center">
<template slot-scope="scope">
{{ scope.row.isPurchase | dynamicText(isPurchaseOptions) }}
</template>
</el-table-column>
<el-table-column prop="prepaid" label="预付科目" width="120" align="center" sortable
/>
<el-table-column label="是否付款" width="120" prop="isPayment" algin="center" sortable
>
<el-table-column label="是否付款" width="120" sortable prop="isPayment" align="center">
<template slot-scope="scope">
{{ scope.row.isPayment | dynamicText(isPaymentOptions) }}
</template>
</el-table-column>
<el-table-column label="是否启用" width="120" prop="status" algin="center" sortable
sortable="custom">
<el-table-column label="是否启用" width="120" sortable prop="status" align="center">
<template slot-scope="scope">
{{ scope.row.status | dynamicText(statusOptions) }}
</template>
</el-table-column>
<el-table-column prop="supplierSiteCode" label="供应商地点" width="120" align="center" sortable
sortable="custom"/>
<el-table-column label="操作" fixed="right"

@ -355,7 +355,7 @@
},
],
},
materialIdcolumnOptions:[ {"label":"物料编码","value":"item_code"}, {"label":"物料名称","value":"description"}, {"label":"默认库区","value":"areaname"}, {"label":"库存组织","value":"organization_id"},],
materialIdcolumnOptions:[ {"label":"物料编码","value":"item_code"}, {"label":"物料名称","value":"item_name"}, {"label":"默认库区","value":"areaname"}, {"label":"库存组织","value":"organization_id"},],
customerIdcolumnOptions:[ {"label":"客户编码","value":"supplier_cd"}, {"label":"客户名称","value":"supplier_nm"}, {"label":"地址","value":"address"}, {"label":"银行账号","value":"bank_account"},],
salesIdcolumnOptions:[ {"label":"合同编码","value":"contract_code"}, {"label":"合同名称","value":"contract_name"}, {"label":"合同类型","value":"contract_type"}, {"label":"供应商/客户名称","value":"name"},],
vehicleIdcolumnOptions:[ {"label":"车牌号","value":"ticketno"}, {"label":"司机","value":"drivername"}, {"label":"车辆照片","value":"vehiclephotos"}, {"label":"手机号","value":"contact"},],

@ -1,306 +1,317 @@
<template>
<div class="JNPF-common-layout">
<div class="JNPF-common-layout">
<div class="JNPF-common-layout-center">
<el-row class="JNPF-common-search-box" :gutter="16">
<el-form @submit.native.prevent>
<el-col :span="6">
<el-form-item label="磅单时间">
<el-date-picker v-model="query.poundDate" type="daterange"
value-format="timestamp" format="yyyy-MM-dd" start-placeholder="开始日期"
end-placeholder="结束日期" >
</el-date-picker>
</el-form-item>
</el-col>
<el-col :span="6">
<el-form-item label="磅单号">
<el-input v-model="query.poundlistNo" placeholder="请输入" clearable> </el-input>
</el-form-item>
</el-col>
<el-col :span="6">
<el-form-item>
<el-button type="primary" icon="el-icon-search" @click="search()"></el-button>
<el-button icon="el-icon-refresh-right" @click="reset()"></el-button>
</el-form-item>
</el-col>
</el-form>
</el-row>
<div class="JNPF-common-layout-main JNPF-flex-main">
<div class="JNPF-common-head">
<div>
<el-button type="primary" icon="el-icon-plus" @click="addOrUpdateHandle()">
</el-button>
<el-button type="text" icon="el-icon-download" @click="exportData()" >导出
</el-button>
<el-button type="text" icon="el-icon-delete" @click="handleBatchRemoveDel()" >批量删除
</el-button>
</div>
<div class="JNPF-common-head-right">
<el-tooltip effect="dark" content="刷新" placement="top">
<el-link icon="icon-ym icon-ym-Refresh JNPF-common-head-icon" :underline="false"
@click="reset()"/>
</el-tooltip>
<screenfull isContainer/>
</div>
</div>
<JNPF-table v-loading="listLoading" :data="list" @sort-change='sortChange' has-c @selection-change="handleSelectionChange">
<el-table-column prop="creatorTime" label="磅单日期" width="0" align="left"
/>
<el-table-column prop="vehicleId" label="车牌号" width="0" align="left"
/>
<el-table-column prop="materialId" label="物料名称" width="0" align="left"
/>
<el-table-column prop="grossWeight" label="毛重" width="0" align="left"
/>
<el-table-column prop="tareWeight" label="皮重" width="0" align="left"
/>
<el-table-column prop="buckleWeight" label="扣重" width="0" align="left"
/>
<el-table-column prop="netWeight" label="净重" width="0" align="left"
/>
<el-table-column prop="customerId" label="客户名称" width="0" align="left"
/>
<el-table-column prop="salesId" label="销售合同" width="0" align="left"
/>
<el-table-column label="是否垫资" width="0" prop="advance" algin="left"
>
<template slot-scope="scope">
{{ scope.row.advance | dynamicText(advanceOptions) }}
</template>
</el-table-column>
<el-table-column label="运输类型" width="0" prop="transportType" algin="left"
>
<template slot-scope="scope">
{{ scope.row.transportType | dynamicText(transportTypeOptions) }}
</template>
</el-table-column>
<el-table-column prop="transportPrice" label="运费" width="0" align="left"
/>
<el-table-column prop="salesPrice" label="销售价格" width="0" align="left"
/>
<el-table-column prop="creatorUserName" label="业务员" width="0" align="left"
/>
<el-table-column prop="remark" label="备注" width="0" align="left"
/>
<el-table-column label="操作" fixed="right"
width="150" >
<template slot-scope="scope">
<el-button type="text"
@click="addOrUpdateHandle(scope.row.id)" >编辑
</el-button>
<el-button type="text" class="JNPF-table-delBtn" @click="handleDel(scope.row.id)">
</el-button>
<el-button type="text"
@click="goDetail(scope.row.id)">详情
</el-button>
</template>
</el-table-column>
</JNPF-table>
<pagination :total="total" :page.sync="listQuery.currentPage" :limit.sync="listQuery.pageSize" @pagination="initData"/>
</div>
<div class="JNPF-common-layout-center">
<el-row class="JNPF-common-search-box" :gutter="16">
<el-form @submit.native.prevent>
<el-col :span="6">
<el-form-item label="磅单时间">
<el-date-picker v-model="query.poundDate" type="daterange"
value-format="timestamp" format="yyyy-MM-dd" start-placeholder="开始日期"
end-placeholder="结束日期">
</el-date-picker>
</el-form-item>
</el-col>
<el-col :span="6">
<el-form-item label="磅单号">
<el-input v-model="query.poundlistNo" placeholder="请输入" clearable></el-input>
</el-form-item>
</el-col>
<el-col :span="6">
<el-form-item>
<el-button type="primary" icon="el-icon-search" @click="search()"></el-button>
<el-button icon="el-icon-refresh-right" @click="reset()"></el-button>
</el-form-item>
</el-col>
</el-form>
</el-row>
<div class="JNPF-common-layout-main JNPF-flex-main">
<div class="JNPF-common-head">
<div>
<el-button type="primary" icon="el-icon-plus" @click="addOrUpdateHandle()">
</el-button>
<el-button type="text" icon="el-icon-download" @click="exportData()">
</el-button>
<el-button type="text" icon="el-icon-download" @click="">导入
</el-button>
<el-button type="text" icon="el-icon-delete" @click="handleBatchRemoveDel()">
</el-button>
</div>
<div class="JNPF-common-head-right">
<el-tooltip effect="dark" content="刷新" placement="top">
<el-link icon="icon-ym icon-ym-Refresh JNPF-common-head-icon" :underline="false"
@click="reset()"/>
</el-tooltip>
<screenfull isContainer/>
</div>
</div>
<JNPF-Form v-if="formVisible" ref="JNPFForm" @refresh="refresh"/>
<ExportBox v-if="exportBoxVisible" ref="ExportBox" @download="download"/>
<Detail v-if="detailVisible" ref="Detail" @refresh="detailVisible=false"/>
<JNPF-table v-loading="listLoading" :data="list" @sort-change='sortChange' has-c :hasNO="false"
@selection-change="handleSelectionChange" border>
<el-table-column type="index" width="50" label="序号" fixed="left" align="center" />
<el-table-column prop="creatorTime" label="磅单日期" width="200" align="center" sortable fixed="left"
/>
<el-table-column prop="vehicleId" label="车牌号" width="150" align="center" sortable fixed="left"
/>
<el-table-column prop="materialId" label="物料名称" width="200" align="center" sortable
/>
<el-table-column prop="grossWeight" label="毛重" width="120" align="center" sortable
/>
<el-table-column prop="tareWeight" label="皮重" width="120" align="center" sortable
/>
<el-table-column prop="buckleWeight" label="扣重" width="120" align="center" sortable
/>
<el-table-column prop="netWeight" label="净重" width="120" align="center" sortable
/>
<el-table-column prop="customerId" label="客户名称" width="200" align="center" sortable
/>
<el-table-column prop="salesId" label="销售合同" width="150" align="center" sortable
/>
<el-table-column label="是否垫资" width="120" sortable prop="advance" align="center" >
<template slot-scope="scope">
{{ scope.row.advance | dynamicText(advanceOptions) }}
</template>
</el-table-column>
<el-table-column label="运输类型" width="120" sortable prop="transportType" align="center" >
<template slot-scope="scope">
{{ scope.row.transportType | dynamicText(transportTypeOptions) }}
</template>
</el-table-column>
<el-table-column prop="transportPrice" label="运费" width="150" align="center" sortable
/>
<el-table-column prop="salesPrice" label="销售价格" width="150" align="center" sortable
/>
<el-table-column prop="creatorUserName" label="业务员" width="120" align="center" sortable
/>
<el-table-column prop="remark" label="备注" width="200" align="center" sortable
/>
<el-table-column label="操作" fixed="right"
width="150">
<template slot-scope="scope">
<el-button type="text"
@click="addOrUpdateHandle(scope.row.id)">编辑
</el-button>
<el-button type="text" class="JNPF-table-delBtn" @click="handleDel(scope.row.id)">
</el-button>
<el-button type="text"
@click="goDetail(scope.row.id)">详情
</el-button>
</template>
</el-table-column>
</JNPF-table>
<pagination :total="total" :page.sync="listQuery.currentPage" :limit.sync="listQuery.pageSize"
@pagination="initData"/>
</div>
</div>
<JNPF-Form v-if="formVisible" ref="JNPFForm" @refresh="refresh"/>
<ExportBox v-if="exportBoxVisible" ref="ExportBox" @download="download"/>
<Detail v-if="detailVisible" ref="Detail" @refresh="detailVisible=false"/>
</div>
</template>
<script>
import request from '@/utils/request'
import {getDictionaryDataSelector} from '@/api/systemData/dictionary'
import JNPFForm from './Form'
import ExportBox from './ExportBox'
import {getDataInterfaceRes} from '@/api/systemData/dataInterface'
import Detail from './Detail'
import request from '@/utils/request'
import { getDictionaryDataSelector } from '@/api/systemData/dictionary'
import JNPFForm from './Form'
import ExportBox from './ExportBox'
import { getDataInterfaceRes } from '@/api/systemData/dataInterface'
import Detail from './Detail'
export default {
components: {JNPFForm, ExportBox,Detail},
data() {
return {
detailVisible: false,
query: {
poundDate:undefined,
poundlistNo:undefined,
},
treeProps: {
children: 'children',
label: 'fullName',
value: 'id'
},
list: [],
listLoading: true,
multipleSelection: [], total: 0,
listQuery: {
currentPage: 1,
pageSize: 20,
sort: "desc",
sidx: "",
},
formVisible: false,
exportBoxVisible: false,
columnList: [
{prop: 'creatorTime', label: '磅单日期'},
{prop: 'vehicleId', label: '车牌号'},
{prop: 'materialId', label: '物料名称'},
{prop: 'grossWeight', label: '毛重'},
{prop: 'tareWeight', label: '皮重'},
{prop: 'buckleWeight', label: '扣重'},
{prop: 'netWeight', label: '净重'},
{prop: 'customerId', label: '客户名称'},
{prop: 'salesId', label: '销售合同'},
{prop: 'advance', label: '是否垫资'},
{prop: 'transportType', label: '运输类型'},
{prop: 'transportPrice', label: '运费'},
{prop: 'salesPrice', label: '销售价格'},
{prop: 'creatorUserName', label: '业务员'},
{prop: 'remark', label: '备注'},
],
unitOptions:[{"fullName":"吨","id":"0"},{"fullName":"千克","id":"1"}],
unitProps:{"label":"fullName","value":"id"},
transportTypeOptions:[{"fullName":"汽运","id":"0"},{"fullName":"船运","id":"1"},{"fullName":"火车","id":"2"}],
transportTypeProps:{"label":"fullName","value":"id"},
advanceOptions:[{"fullName":"否","id":"0"},{"fullName":"是","id":"1"}],
advanceProps:{"label":"fullName","value":"id"},
}
export default {
components: { JNPFForm, ExportBox, Detail },
data() {
return {
detailVisible: false,
query: {
poundDate: undefined,
poundlistNo: undefined
},
computed: {
menuId() {
return this.$route.meta.modelId || ''
}
treeProps: {
children: 'children',
label: 'fullName',
value: 'id'
},
created() {
this.initData()
list: [],
listLoading: true,
multipleSelection: [], total: 0,
listQuery: {
currentPage: 1,
pageSize: 20,
sort: 'desc',
sidx: ''
},
methods: {
goDetail(id){
this.detailVisible = true
this.$nextTick(() => {
this.$refs.Detail.init(id)
})
},
sortChange({column, prop, order}) {
this.listQuery.sort = order == 'ascending' ? 'asc' : 'desc'
this.listQuery.sidx = !order ? '' : prop
this.initData()
},
initData() {
this.listLoading = true;
let _query = {
...this.listQuery,
...this.query,
menuId:this.menuId
};
request({
url: `/api/tradeupload/Tradeupload/getList`,
method: 'post',
data: _query
}).then(res => {
var _list =[];
for(let i=0;i<res.data.list.length;i++){
let _data = res.data.list[i];
_list.push(_data)
}
this.list = _list
this.total = res.data.pagination.total
formVisible: false,
exportBoxVisible: false,
columnList: [
{ prop: 'creatorTime', label: '磅单日期' },
{ prop: 'vehicleId', label: '车牌号' },
{ prop: 'materialId', label: '物料名称' },
{ prop: 'grossWeight', label: '毛重' },
{ prop: 'tareWeight', label: '皮重' },
{ prop: 'buckleWeight', label: '扣重' },
{ prop: 'netWeight', label: '净重' },
{ prop: 'customerId', label: '客户名称' },
{ prop: 'salesId', label: '销售合同' },
{ prop: 'advance', label: '是否垫资' },
{ prop: 'transportType', label: '运输类型' },
{ prop: 'transportPrice', label: '运费' },
{ prop: 'salesPrice', label: '销售价格' },
{ prop: 'creatorUserName', label: '业务员' },
{ prop: 'remark', label: '备注' }
],
unitOptions: [{ 'fullName': '吨', 'id': '0' }, { 'fullName': '千克', 'id': '1' }],
unitProps: { 'label': 'fullName', 'value': 'id' },
transportTypeOptions: [{ 'fullName': '汽运', 'id': '0' }, { 'fullName': '船运', 'id': '1' }, {
'fullName': '火车',
'id': '2'
}],
transportTypeProps: { 'label': 'fullName', 'value': 'id' },
advanceOptions: [{ 'fullName': '否', 'id': '0' }, { 'fullName': '是', 'id': '1' }],
advanceProps: { 'label': 'fullName', 'value': 'id' }
}
},
computed: {
menuId() {
return this.$route.meta.modelId || ''
}
},
created() {
this.initData()
},
methods: {
goDetail(id) {
this.detailVisible = true
this.$nextTick(() => {
this.$refs.Detail.init(id)
})
},
sortChange({ column, prop, order }) {
this.listQuery.sort = order == 'ascending' ? 'asc' : 'desc'
this.listQuery.sidx = !order ? '' : prop
this.initData()
},
initData() {
this.listLoading = true
let _query = {
...this.listQuery,
...this.query,
menuId: this.menuId
}
request({
url: `/api/tradeupload/Tradeupload/getList`,
method: 'post',
data: _query
}).then(res => {
var _list = []
for (let i = 0; i < res.data.list.length; i++) {
res.data.list[i].creatorTime = res.data.list[i].creatorTime ? res.data.list[i].creatorTime.substring(0, 10) : '';
let _data = res.data.list[i]
_list.push(_data)
}
this.list = _list
this.total = res.data.pagination.total
this.listLoading = false
})
},
handleDel(id) {
this.$confirm('此操作将永久删除该数据, 是否继续?', '提示', {
type: 'warning'
}).then(() => {
request({
url: `/api/tradeupload/Tradeupload/${id}`,
method: 'DELETE'
}).then(res => {
this.$message({
type: 'success',
message: res.msg,
onClose: () => {
this.initData()
}
});
})
}).catch(() => {
});
},
handleSelectionChange(val) {
const res = val.map(item => item.id)
this.multipleSelection = res
},
handleBatchRemoveDel() {
if (!this.multipleSelection.length) {
this.$message({
type: 'error',
message: '请选择一条数据',
duration: 1500,
})
return
}
const ids = this.multipleSelection.join()
this.$confirm('您确定要删除这些数据吗, 是否继续?', '提示', {
type: 'warning'
}).then(() => {
request({
url: `/api/tradeupload/Tradeupload/batchRemove/${ids}`,
method: 'DELETE'
}).then(res => {
this.$message({
type: 'success',
message: res.msg,
onClose: () => {
this.initData()
}
});
})
}).catch(() => {
})
},
addOrUpdateHandle(id, isDetail) {
this.formVisible = true
this.$nextTick(() => {
this.$refs.JNPFForm.init(id, isDetail)
})
},
exportData() {
this.exportBoxVisible = true
this.$nextTick(() => {
this.$refs.ExportBox.init(this.columnList)
})
},
download(data) {
let query = {...data, ...this.listQuery, ...this.query,menuId:this.menuId}
request({
url: `/api/tradeupload/Tradeupload/Actions/Export`,
method: 'GET',
data: query
}).then(res => {
if (!res.data.url) return
this.jnpf.downloadFile(res.data.url)
this.$refs.ExportBox.visible = false
this.exportBoxVisible = false
})
},
search() {
this.listQuery = {
currentPage: 1,
pageSize: 20,
sort: "desc",
sidx: "",
}
this.listLoading = false
})
},
handleDel(id) {
this.$confirm('此操作将永久删除该数据, 是否继续?', '提示', {
type: 'warning'
}).then(() => {
request({
url: `/api/tradeupload/Tradeupload/${id}`,
method: 'DELETE'
}).then(res => {
this.$message({
type: 'success',
message: res.msg,
onClose: () => {
this.initData()
},
refresh(isrRefresh) {
this.formVisible = false
if (isrRefresh) this.reset()
},
reset() {
for (let key in this.query) {
this.query[key] = undefined
}
this.search()
}
}
})
})
}).catch(() => {
})
},
handleSelectionChange(val) {
const res = val.map(item => item.id)
this.multipleSelection = res
},
handleBatchRemoveDel() {
if (!this.multipleSelection.length) {
this.$message({
type: 'error',
message: '请选择一条数据',
duration: 1500
})
return
}
const ids = this.multipleSelection.join()
this.$confirm('您确定要删除这些数据吗, 是否继续?', '提示', {
type: 'warning'
}).then(() => {
request({
url: `/api/tradeupload/Tradeupload/batchRemove/${ids}`,
method: 'DELETE'
}).then(res => {
this.$message({
type: 'success',
message: res.msg,
onClose: () => {
this.initData()
}
})
})
}).catch(() => {
})
},
addOrUpdateHandle(id, isDetail) {
this.formVisible = true
this.$nextTick(() => {
this.$refs.JNPFForm.init(id, isDetail)
})
},
exportData() {
this.exportBoxVisible = true
this.$nextTick(() => {
this.$refs.ExportBox.init(this.columnList)
})
},
download(data) {
let query = { ...data, ...this.listQuery, ...this.query, menuId: this.menuId }
request({
url: `/api/tradeupload/Tradeupload/Actions/Export`,
method: 'GET',
data: query
}).then(res => {
if (!res.data.url) return
this.jnpf.downloadFile(res.data.url)
this.$refs.ExportBox.visible = false
this.exportBoxVisible = false
})
},
search() {
this.listQuery = {
currentPage: 1,
pageSize: 20,
sort: 'desc',
sidx: ''
}
this.initData()
},
refresh(isrRefresh) {
this.formVisible = false
if (isrRefresh) this.reset()
},
reset() {
for (let key in this.query) {
this.query[key] = undefined
}
this.search()
}
}
}
</script>

@ -1,55 +1,58 @@
<template>
<div class="JNPF-common-layout">
<div class="JNPF-common-layout">
<div class="JNPF-common-layout-center">
<el-row class="JNPF-common-search-box" :gutter="16">
<el-form @submit.native.prevent>
<el-col :span="6">
<el-form-item label="车牌号">
<el-input v-model="query.ticketno" placeholder="请输入" clearable> </el-input>
</el-form-item>
</el-col>
<el-col :span="6">
<el-form-item label="司机名称">
<el-input v-model="query.drivername" placeholder="请输入" clearable> </el-input>
</el-form-item>
</el-col>
<el-col :span="6">
<el-form-item>
<el-button type="primary" icon="el-icon-search" @click="search()"></el-button>
<el-button icon="el-icon-refresh-right" @click="reset()"></el-button>
</el-form-item>
</el-col>
</el-form>
</el-row>
<div class="JNPF-common-layout-main JNPF-flex-main">
<div class="JNPF-common-head">
<div>
<el-button type="primary" icon="el-icon-plus" @click="addOrUpdateHandle()">
</el-button>
<el-button type="text" icon="el-icon-download" @click="exportData()">
</el-button>
<el-button type="text" icon="el-icon-delete" @click="handleBatchRemoveDel()">
</el-button>
</div>
<div class="JNPF-common-head-right">
<el-tooltip effect="dark" content="刷新" placement="top">
<el-link icon="icon-ym icon-ym-Refresh JNPF-common-head-icon" :underline="false"
@click="reset()" />
</el-tooltip>
<screenfull isContainer />
</div>
</div>
<JNPF-table v-loading="listLoading" :data="list" @sort-change='sortChange' has-c
@selection-change="handleSelectionChange" >
<el-table-column prop="id" label="ID" width="0" align="left" />
<el-table-column prop="ticketno" label="车牌号" width="0" align="left" />
<el-table-column prop="drivername" label="司机" width="0" align="left" />
<el-table-column prop="vehiclephotos" label="车辆照片" width="0" align="left">
<div class="JNPF-common-layout-center">
<el-row class="JNPF-common-search-box" :gutter="16">
<el-form @submit.native.prevent>
<el-col :span="6">
<el-form-item label="车牌号">
<el-input v-model="query.ticketno" placeholder="请输入" clearable></el-input>
</el-form-item>
</el-col>
<el-col :span="6">
<el-form-item label="司机名称">
<el-input v-model="query.drivername" placeholder="请输入" clearable></el-input>
</el-form-item>
</el-col>
<el-col :span="6">
<el-form-item>
<el-button type="primary" icon="el-icon-search" @click="search()"></el-button>
<el-button icon="el-icon-refresh-right" @click="reset()"></el-button>
</el-form-item>
</el-col>
</el-form>
</el-row>
<div class="JNPF-common-layout-main JNPF-flex-main">
<div class="JNPF-common-head">
<div>
<el-button type="primary" icon="el-icon-plus" @click="addOrUpdateHandle()">
</el-button>
<el-button type="text" icon="el-icon-download" @click="exportData()">
</el-button>
<el-button type="text" icon="el-icon-download" @click="">导入
</el-button>
<el-button type="text" icon="el-icon-delete" @click="handleBatchRemoveDel()">
</el-button>
</div>
<div class="JNPF-common-head-right">
<el-tooltip effect="dark" content="刷新" placement="top">
<el-link icon="icon-ym icon-ym-Refresh JNPF-common-head-icon" :underline="false"
@click="reset()"/>
</el-tooltip>
<screenfull isContainer/>
</div>
</div>
<JNPF-table v-loading="listLoading" :data="list" @sort-change='sortChange' has-c :hasNO="false"
@selection-change="handleSelectionChange" border>
<el-table-column type="index" width="50" label="序号" fixed="center" align="center" />
<el-table-column prop="id" label="ID" width="0" align="left" fixed="center" sortable/>
<el-table-column prop="ticketno" label="车牌号" width="0" align="center" fixed="left" sortable/>
<el-table-column prop="drivername" label="司机" width="0" align="center" sortable/>
<el-table-column prop="vehiclephotos" label="车辆照片" width="0" align="center" sortable>
<template slot-scope="scope">
<span v-for="(item,index) in JSON.parse(scope.row.vehiclephotos)" :key="index">
<el-popover placement="bottom" trigger="click" width="1000">
<img :src="`/dev${item.url}`" width="100%" />
<img :src="`/dev${item.url}`" width="100%"/>
<img
slot="reference"
:src="`/dev${item.url}`"
@ -60,238 +63,240 @@
</span>
</template>
</el-table-column>
<el-table-column prop="contact" label="手机号" width="0" align="left" />
<el-table-column prop="creatorusername" label="录入人" width="0" align="left" />
<el-table-column prop="creatortime" label="创建时间" width="0" align="left" />
<el-table-column label="操作" fixed="right" width="100">
<template slot-scope="scope">
<el-button type="text" @click="addOrUpdateHandle(scope.row.id)">
</el-button>
<el-button type="text" class="JNPF-table-delBtn" @click="handleDel(scope.row.id)">
</el-button>
</template>
</el-table-column>
</JNPF-table>
<pagination :total="total" :page.sync="listQuery.currentPage" :limit.sync="listQuery.pageSize"
@pagination="initData" />
</div>
</div>
<JNPF-Form v-if="formVisible" ref="JNPFForm" @refresh="refresh" />
<ExportBox v-if="exportBoxVisible" ref="ExportBox" @download="download" />
<Detail v-if="detailVisible" ref="Detail" @refresh="detailVisible=false" />
</div>
<el-table-column prop="contact" label="手机号" width="0" align="center" sortable/>
<el-table-column prop="creatorusername" label="录入人" width="0" align="center" sortable/>
<el-table-column prop="creatortime" label="创建时间" width="0" align="center" sortable/>
<el-table-column label="操作" fixed="right" width="100">
<template slot-scope="scope">
<el-button type="text" @click="addOrUpdateHandle(scope.row.id)">
</el-button>
<el-button type="text" class="JNPF-table-delBtn" @click="handleDel(scope.row.id)">
</el-button>
</template>
</el-table-column>
</JNPF-table>
<pagination :total="total" :page.sync="listQuery.currentPage" :limit.sync="listQuery.pageSize"
@pagination="initData"/>
</div>
</div>
<JNPF-Form v-if="formVisible" ref="JNPFForm" @refresh="refresh"/>
<ExportBox v-if="exportBoxVisible" ref="ExportBox" @download="download"/>
<Detail v-if="detailVisible" ref="Detail" @refresh="detailVisible=false"/>
</div>
</template>
<script>
import request from '@/utils/request'
import {
getDictionaryDataSelector
} from '@/api/systemData/dictionary'
import JNPFForm from './Form'
import ExportBox from './ExportBox'
import {
getDataInterfaceRes
} from '@/api/systemData/dataInterface'
import Detail from './Detail'
import request from '@/utils/request'
import {
getDictionaryDataSelector
} from '@/api/systemData/dictionary'
import JNPFForm from './Form'
import ExportBox from './ExportBox'
import {
getDataInterfaceRes
} from '@/api/systemData/dataInterface'
import Detail from './Detail'
export default {
components: {
JNPFForm,
ExportBox,
Detail
},
data() {
return {
detailVisible: false,
query: {
ticketno: undefined,
drivername: undefined,
},
treeProps: {
children: 'children',
label: 'fullName',
value: 'id'
},
list: [],
listLoading: true,
multipleSelection: [],
total: 0,
listQuery: {
currentPage: 1,
pageSize: 20,
sort: "desc",
sidx: "",
},
formVisible: false,
exportBoxVisible: false,
columnList: [{
prop: 'ticketno',
label: '车牌号'
},
{
prop: 'drivername',
label: '司机名称'
},
{
prop: 'contact',
label: '手机号'
},
{
prop: 'creatorusername',
label: '录入人'
},
{
prop: 'creatortime',
label: '创建时间'
},
],
}
},
computed: {
menuId() {
return this.$route.meta.modelId || ''
}
},
created() {
this.initData()
},
methods: {
goDetail(id) {
this.detailVisible = true
this.$nextTick(() => {
this.$refs.Detail.init(id)
})
},
sortChange({
column,
prop,
order
}) {
this.listQuery.sort = order == 'ascending' ? 'asc' : 'desc'
this.listQuery.sidx = !order ? '' : prop
this.initData()
},
initData() {
this.listLoading = true;
let _query = {
...this.listQuery,
...this.query,
menuId: this.menuId
};
request({
url: `/api/example/Vehicle/getList`,
method: 'post',
data: _query
}).then(res => {
var _list = [];
for (let i = 0; i < res.data.list.length; i++) {
let _data = res.data.list[i];
_list.push(_data)
}
this.list = _list
this.total = res.data.pagination.total
export default {
components: {
JNPFForm,
ExportBox,
Detail
},
data() {
return {
detailVisible: false,
query: {
ticketno: undefined,
drivername: undefined
},
treeProps: {
children: 'children',
label: 'fullName',
value: 'id'
},
list: [],
listLoading: true,
multipleSelection: [],
total: 0,
listQuery: {
currentPage: 1,
pageSize: 20,
sort: 'desc',
sidx: ''
},
formVisible: false,
exportBoxVisible: false,
columnList: [{
prop: 'ticketno',
label: '车牌号'
},
{
prop: 'drivername',
label: '司机名称'
},
{
prop: 'contact',
label: '手机号'
},
{
prop: 'creatorusername',
label: '录入人'
},
{
prop: 'creatortime',
label: '创建时间'
}
]
}
},
computed: {
menuId() {
return this.$route.meta.modelId || ''
}
},
created() {
this.initData()
},
methods: {
goDetail(id) {
this.detailVisible = true
this.$nextTick(() => {
this.$refs.Detail.init(id)
})
},
sortChange({
column,
prop,
order
}) {
this.listQuery.sort = order == 'ascending' ? 'asc' : 'desc'
this.listQuery.sidx = !order ? '' : prop
this.initData()
},
initData() {
this.listLoading = true
let _query = {
...this.listQuery,
...this.query,
menuId: this.menuId
}
request({
url: `/api/example/Vehicle/getList`,
method: 'post',
data: _query
}).then(res => {
var _list = []
for (let i = 0; i < res.data.list.length; i++) {
let _data = res.data.list[i]
_list.push(_data)
}
this.list = _list
this.total = res.data.pagination.total
this.listLoading = false
})
},
handleDel(id) {
this.$confirm('此操作将永久删除该数据, 是否继续?', '提示', {
type: 'warning'
}).then(() => {
request({
url: `/api/example/Vehicle/${id}`,
method: 'DELETE'
}).then(res => {
this.$message({
type: 'success',
message: res.msg,
onClose: () => {
this.initData()
}
});
})
}).catch(() => {});
},
handleSelectionChange(val) {
const res = val.map(item => item.id)
this.multipleSelection = res
},
handleBatchRemoveDel() {
if (!this.multipleSelection.length) {
this.$message({
type: 'error',
message: '请选择一条数据',
duration: 1500,
})
return
}
const ids = this.multipleSelection.join()
this.$confirm('您确定要删除这些数据吗, 是否继续?', '提示', {
type: 'warning'
}).then(() => {
request({
url: `/api/example/Vehicle/batchRemove/${ids}`,
method: 'DELETE'
}).then(res => {
this.$message({
type: 'success',
message: res.msg,
onClose: () => {
this.initData()
}
});
})
}).catch(() => {})
},
addOrUpdateHandle(id, isDetail) {
this.formVisible = true
this.$nextTick(() => {
this.$refs.JNPFForm.init(id, isDetail)
})
},
exportData() {
this.exportBoxVisible = true
this.$nextTick(() => {
this.$refs.ExportBox.init(this.columnList)
})
},
download(data) {
let query = {
...data,
...this.listQuery,
...this.query,
menuId: this.menuId
}
request({
url: `/api/example/Vehicle/Actions/Export`,
method: 'GET',
data: query
}).then(res => {
if (!res.data.url) return
this.jnpf.downloadFile(res.data.url)
this.$refs.ExportBox.visible = false
this.exportBoxVisible = false
})
},
search() {
this.listQuery = {
currentPage: 1,
pageSize: 20,
sort: "desc",
sidx: "",
}
this.initData()
},
refresh(isrRefresh) {
this.formVisible = false
if (isrRefresh) this.reset()
},
reset() {
for (let key in this.query) {
this.query[key] = undefined
}
this.search()
}
}
}
this.listLoading = false
})
},
handleDel(id) {
this.$confirm('此操作将永久删除该数据, 是否继续?', '提示', {
type: 'warning'
}).then(() => {
request({
url: `/api/example/Vehicle/${id}`,
method: 'DELETE'
}).then(res => {
this.$message({
type: 'success',
message: res.msg,
onClose: () => {
this.initData()
}
})
})
}).catch(() => {
})
},
handleSelectionChange(val) {
const res = val.map(item => item.id)
this.multipleSelection = res
},
handleBatchRemoveDel() {
if (!this.multipleSelection.length) {
this.$message({
type: 'error',
message: '请选择一条数据',
duration: 1500
})
return
}
const ids = this.multipleSelection.join()
this.$confirm('您确定要删除这些数据吗, 是否继续?', '提示', {
type: 'warning'
}).then(() => {
request({
url: `/api/example/Vehicle/batchRemove/${ids}`,
method: 'DELETE'
}).then(res => {
this.$message({
type: 'success',
message: res.msg,
onClose: () => {
this.initData()
}
})
})
}).catch(() => {
})
},
addOrUpdateHandle(id, isDetail) {
this.formVisible = true
this.$nextTick(() => {
this.$refs.JNPFForm.init(id, isDetail)
})
},
exportData() {
this.exportBoxVisible = true
this.$nextTick(() => {
this.$refs.ExportBox.init(this.columnList)
})
},
download(data) {
let query = {
...data,
...this.listQuery,
...this.query,
menuId: this.menuId
}
request({
url: `/api/example/Vehicle/Actions/Export`,
method: 'GET',
data: query
}).then(res => {
if (!res.data.url) return
this.jnpf.downloadFile(res.data.url)
this.$refs.ExportBox.visible = false
this.exportBoxVisible = false
})
},
search() {
this.listQuery = {
currentPage: 1,
pageSize: 20,
sort: 'desc',
sidx: ''
}
this.initData()
},
refresh(isrRefresh) {
this.formVisible = false
if (isrRefresh) this.reset()
},
reset() {
for (let key in this.query) {
this.query[key] = undefined
}
this.search()
}
}
}
</script>

@ -53,20 +53,23 @@
/>
<el-table-column prop="location" label="仓库位置" width="200" align="center" sortable
/>
<el-table-column label="仓库类型" width="120" prop="type" algin="center" sortable
>
<el-table-column label="仓库类型" width="120" sortable prop="type" align="center" >
<template slot-scope="scope">
{{ scope.row.type | dynamicText(typeOptions) }}
</template>
</el-table-column>
<el-table-column prop="sublibrary" label="ERP子库" width="200" align="center" sortable
/>
<el-table-column label="激活状态 " width="120" prop="activestate" algin="center" sortable
>
<el-table-column label="激活状态" width="120" sortable prop="activestate" align="center" >
<template slot-scope="scope">
{{ scope.row.activestate | dynamicText(activestateOptions) }}
</template>
</el-table-column>
<el-table-column prop="remark" label="备注" width="0" align="center" sortable
/>
<el-table-column label="操作" fixed="right"

Loading…
Cancel
Save