代码备份

pro
anthonywj 2 years ago
parent 9988521e9f
commit f0df88f77a

@ -24,3 +24,22 @@ export function updateConfig(data) {
data: data
});
}
//查询已选入扫码单据类型
export function getBusList(params) {
return axios({
url: "/system/third/syncData/getBus",
method: "get",
params: params
});
}
//添加扫码单据类型
export function addBus(data) {
return axios({
url: "/system/third/syncData/addBus",
method: "post",
data: data
});
}

@ -1,14 +1,14 @@
<template>
<div>
<el-form>
<el-card style="margin-top: -10px;padding-top:10px ">
<el-card style="margin-top: -10px;padding-top:10px ">
<el-row :gutter="20" type="flex">
<el-col :span="80">
<!-- :disabled="true" 这个标识启用标识不能修改-->
<el-col :span="24">
<!-- :disabled="true" 这个标识启用标识不能修改-->
<el-form-item label="单据类型:" label-width="120px">
<el-input
size="mini"
splaceholder="请输入内容"
splaceholder="请输入内容" style="width: 80%"
v-model="inputQuery.name"
></el-input>
</el-form-item>
@ -16,22 +16,23 @@
</el-row>
<el-row :gutter="20" type="flex">
<el-col :span="50">
<el-form-item label="单据类型代码:" label-width="120px">
<el-input
size="mini"
splaceholder="请输入内容"
v-model="inputQuery.action"
></el-input>
</el-form-item>
</el-col>
<el-col :span="24">
<el-form-item label="单据类型代码:" label-width="120px">
<el-input
size="mini"
style="width: 80%"
splaceholder="请输入内容"
v-model="inputQuery.action"
></el-input>
</el-form-item>
</el-col>
</el-row>
<el-row :gutter="20" type="flex">
<el-col :span="50">
<el-col :span="24">
<el-form-item label="单据起始上传:" label-width="120px">
<el-input
size="mini"
splaceholder="请输入内容"
splaceholder="请输入内容" style="width: 80%"
:disabled="true"
v-model="inputQuery.createTime"
></el-input>
@ -39,41 +40,38 @@
</el-col>
</el-row>
<el-row :gutter="20" type="flex">
<el-col :span="50">
<el-col :span="24">
<el-form-item label="单据状态:" label-width="120px">
<el-radio-group v-model="configQuery.orderStatus" :disabled="configQuery.autoUpload">
<el-radio :label="1" :value="1" @change="handleRadioChange"></el-radio>
<el-radio :label="2" :value="2" @change="handleRadioChange"></el-radio>
<el-radio :label="3" :value="3" @change="handleRadioChange"></el-radio>
<el-radio :label="1" :value="1" @change="handleRadioChange"></el-radio>
<el-radio :label="2" :value="2" @change="handleRadioChange"></el-radio>
<el-radio :label="3" :value="3" @change="handleRadioChange"></el-radio>
</el-radio-group>
</el-form-item>
</el-col>
</el-row>
<el-row :gutter="20" type="flex">
<el-col :span="50">
<el-form-item label="单据来源:" label-width="120px">
<el-select
v-model="configQuery.orderSources"
multiple
collapse-tags
style="margin-left: 0px;width: 250px"
placeholder="请选择"
>
<el-option label="web端新增单据" value="checkWebNew"></el-option>
<el-option label="手持终端未校验单据" value="checkPdaUn"></el-option>
<el-option label="手持终端已校验单据" value="checkPdaEd"></el-option>
<el-option label="UDIMS平台" value="checkUdims"></el-option>
<el-option label="UDI扫码通" value="checkPc"></el-option>
<el-option label="自助平台同步" value="checkSp"></el-option>
<el-option label="缺量补单" value="checkChange"></el-option>
<el-option label="平衡补单" value="checkBalacne"></el-option>
</el-select>
</el-form-item>
</el-col>
<el-col :span="24">
<el-form-item label="单据来源:" label-width="120px">
<el-select
v-model="configQuery.orderSources"
multiple
collapse-tags
style="width: 80%"
placeholder="请选择"
>
<el-option label="web端新增单据" value="checkWebNew"></el-option>
<el-option label="手持终端未校验单据" value="checkPdaUn"></el-option>
<el-option label="手持终端已校验单据" value="checkPdaEd"></el-option>
<el-option label="UDIMS平台" value="checkUdims"></el-option>
<el-option label="UDI扫码通" value="checkPc"></el-option>
<el-option label="自助平台同步" value="checkSp"></el-option>
<el-option label="缺量补单" value="checkChange"></el-option>
<el-option label="平衡补单" value="checkBalacne"></el-option>
</el-select>
</el-form-item>
</el-col>
</el-row>
</el-card>
@ -96,24 +94,23 @@ export default {
methods: {
handleRadioChange(val) {
if (val === 1) {
this.configQuery.orderUnCheck=1;
this.configQuery.orderUnReceive=0;
this.configQuery.orderScanFinish=0;
this.configQuery.orderUnCheck = 1;
this.configQuery.orderUnReceive = 0;
this.configQuery.orderScanFinish = 0;
}
if (val === 2) {
this.configQuery.orderUnCheck=0;
this.configQuery.orderUnReceive=1;
this.configQuery.orderScanFinish=0;
this.configQuery.orderUnCheck = 0;
this.configQuery.orderUnReceive = 1;
this.configQuery.orderScanFinish = 0;
}
if (val === 3) {
this.configQuery.orderUnCheck=0;
this.configQuery.orderUnReceive=0;
this.configQuery.orderScanFinish=1;
this.configQuery.orderUnCheck = 0;
this.configQuery.orderUnReceive = 0;
this.configQuery.orderScanFinish = 1;
}
},
},
data() {
return {
@ -134,7 +131,7 @@ export default {
checkBalacne: null,
busTypes: [],
orderSources: [], //
orderStatus:3,//
orderStatus: 3,//
},
}
}

@ -51,116 +51,54 @@
</el-descriptions-item>
</el-descriptions>
<el-descriptions class="margin-top" title="上传至第三方系统" :column="1" style="margin-top: 30px"
border>
<el-descriptions-item>
<template slot="label">
单据时间
</template>
<el-row :gutter="20" class="el-row" type="flex">
<el-col :span="20" class="el-col">
<div>
<span>上传起始时间:&nbsp;</span>
<el-date-picker
type="date"
v-model="configQuery.orderStartTime"
format="yyyy-MM-dd"
value-format="yyyy-MM-dd"
:disabled="configQuery.autoUpload"
placeholder="选择日期">
</el-date-picker>
</div>
</el-col>
</el-row>
</el-descriptions-item>
<el-descriptions-item>
<template slot="label">
单据(单据状态)
</template>
<el-checkbox v-model="configQuery.orderUnCheck" :disabled="configQuery.autoUpload">
</el-checkbox>
<el-checkbox v-model="configQuery.orderUnReceive" :disabled="configQuery.autoUpload">
</el-checkbox>
<el-checkbox v-model="configQuery.orderScanFinish" :disabled="configQuery.autoUpload">
</el-checkbox>
</el-descriptions-item>
<el-descriptions-item>
<template slot="label">
单据来源
<div style="float: right;margin-bottom: 10px;margin-right: 25px;margin-top: 18px">
<el-button type="primary" size="small"
:disabled="configQuery.autoUpload"
@click="addBusTypeDialog()">添加扫码单据类型
</el-button>
</div>
<el-table
:data="checkedBusTypes"
border
style="width: 100%"
highlight-current-row
>
<el-table-column label="序号" type="index"></el-table-column>
<el-table-column
label="单据类型"
prop="name"
show-overflow-tooltip
></el-table-column>
<el-table-column
label="单据类型代码"
prop="action"
show-overflow-tooltip
></el-table-column>
<el-table-column
label="单据状态"
prop=""
show-overflow-tooltip
></el-table-column>
<el-table-column label="操作">
<template slot-scope="scope">
<el-button
type="text"
size="small"
@click.native.stop="printUpload(scope.row)"
>编辑
</el-button
>
<el-button
type="text"
size="small"
@click.native="removeBus(scope.$index, scope.row)"
>移除
</el-button
>
</template>
<el-checkbox v-model="configQuery.checkWebNew">web
</el-checkbox>
<el-checkbox v-model="configQuery.checkPdaUn">
</el-checkbox>
<el-checkbox v-model="configQuery.checkPdaEd">
</el-checkbox>
<el-checkbox v-model="configQuery.checkUdims">UDIMS
</el-checkbox>
<el-checkbox v-model="configQuery.checkPc">UDI</el-checkbox>
<el-checkbox v-model="configQuery.checkSp"></el-checkbox>
<el-checkbox v-model="configQuery.checkChange">
</el-checkbox>
<el-checkbox v-model="configQuery.checkBalacne">
</el-checkbox>
</el-descriptions-item>
<el-descriptions-item label="单据(单据类型)" label-style="width: 150px">
<div style="float: right;margin-bottom: 10px;margin-right: 25px">
<el-button type="primary" size="small"
:disabled="configQuery.autoUpload"
@click="addBusTypeDialog()">添加扫码单据类型
</el-button>
</div>
<el-table
:data="checkedBusTypes"
border
style="width: 100%"
highlight-current-row
>
<el-table-column label="序号" type="index"></el-table-column>
<el-table-column
label="单据类型"
prop="name"
show-overflow-tooltip
></el-table-column>
<el-table-column
label="单据类型代码"
prop="action"
show-overflow-tooltip
></el-table-column>
<el-table-column
label="单据状态"
prop=""
show-overflow-tooltip
></el-table-column>
<el-table-column label="操作">
<template slot-scope="scope">
<el-button
type="text"
size="small"
@click.native.stop="printUpload(scope.row)"
>编辑
</el-button
>
<el-button
type="text"
size="small"
@click.native="removeBus(scope.$index, scope.row)"
>移除
</el-button
>
</template>
</el-table-column>
</el-table>
</el-descriptions-item>
</el-descriptions>
</el-table-column>
</el-table>
</el-card>
<el-dialog
@ -214,7 +152,6 @@
show-overflow-tooltip
></el-table-column>
</el-table>
<pagination
v-show="total>0"
:total="total"
@ -230,7 +167,7 @@
<script>
import modifyDialog from "./uploadModify";
import {getBusTypeList} from "@/api/basic/busType";
import {getConfig, saveConfig, updateConfig} from "@/api/thrsys/thrUploadSet";
import {addBus, getBusList, getConfig, saveConfig, updateConfig} from "@/api/thrsys/thrUploadSet";
import {isBlank} from "@/utils/strUtil";
import {filterListInvoice} from "@/api/inout/orderDetailBiz";
import {updateBasicThirdSys} from "@/api/thrsys/basicThirdSys";
@ -238,14 +175,6 @@ import modifyDetailDialog from "@/views/thirdSys/api/BasicThirdSysDetailModify";
import DialogEditBusUpload from "@/views/thirdSys/api/DialogEditBusUpload";
import DialogEditBusDown from "@/views/thirdSys/api/DialogEditBusDown";
const formJson = {
site_id: "",
site_name: "",
describe: "",
ads: [],
};
export default {
name: "uploadSetting",
data() {
@ -346,7 +275,7 @@ export default {
cancelDialog() {
this.getBuType();
this.Updocument = false;
// this.modifyBusYypeDialogVisible = false;
// this.modifyBusYypeDialogVisible = false;
},
@ -362,26 +291,39 @@ export default {
}).catch(() => {
});
},
//
getSelectBus() {
getBusList().then((res) => {
if (res.code == 20000)
this.checkedBusTypes = res.data;
}).catch((error) => {
this.loading = false;
});
},
getConfig() {
getConfig().then((res) => {
this.configQuery = res.data;
this.checkedBusTypes = this.configQuery.busTypes;
if (this.configQuery.busTypes === null) {
this.$message.error(res.message);
}
}).catch((error) => {
this.loading = false;
this.list = [];
this.total = 0;
})
});
},
addBusType() {
let selectedData = this.multipleSelection;
selectedData.forEach((item) => {
item.outChange = false;
this.checkedBusTypes.push(item);
})
this.addBusDialogVisible = false;
let query = {
busTypes: selectedData,
};
addBus(query).then((res) => {
if (res.code == 20000) {
this.checkedBusTypes = this.res.data;
} else {
this.$message.error(res.message);
}
}).catch((error) => {
this.loading = false;
})
},
handleCheckedChange(row) {
this.multipleSelection = row;
@ -410,6 +352,7 @@ export default {
},
created() {
this.getBuType();
this.getSelectBus();
},
};
</script>

Loading…
Cancel
Save