...
|
...
|
@@ -190,6 +190,8 @@ |
|
|
:page-size="20"
|
|
|
:pager-count="11"
|
|
|
layout="prev, pager, next"
|
|
|
:current-change="pageNum"
|
|
|
@current-change="changePageNum"
|
|
|
:total="total"
|
|
|
>
|
|
|
</el-pagination>
|
...
|
...
|
@@ -239,9 +241,9 @@ |
|
|
<div class="ziliao-list">
|
|
|
<el-upload
|
|
|
class="upload-demo"
|
|
|
action="https://jsonplaceholder.typicode.com/posts/"
|
|
|
:on-preview="handlePreview"
|
|
|
:on-remove="handleRemove"
|
|
|
:action="uploadFile()"
|
|
|
:on-success="uploadSucc"
|
|
|
:on-error="uploadErr"
|
|
|
:before-remove="beforeRemove"
|
|
|
multiple
|
|
|
:limit="3"
|
...
|
...
|
@@ -351,8 +353,9 @@ |
|
|
<div class="fa-ji">传真照片</div>
|
|
|
<div class="chuanzheng">
|
|
|
<el-upload
|
|
|
action="https://jsonplaceholder.typicode.com/posts/"
|
|
|
:action="uploadFile()"
|
|
|
list-type="picture-card"
|
|
|
:on-success="uploadPic"
|
|
|
:on-preview="handlePictureCardPreview"
|
|
|
:on-remove="handleRemove"
|
|
|
>
|
...
|
...
|
@@ -511,15 +514,13 @@ |
|
|
<div class="sd">
|
|
|
<div class="fa-ji">传真照片</div>
|
|
|
<div class="img-chuan">
|
|
|
<!-- <div class="lisg" v-for="(item,index) in details.photoIds" :key="index">
|
|
|
<img :src="item" class="tu" alt="" />
|
|
|
<img
|
|
|
src="../../assets/fanda.png"
|
|
|
class="fan"
|
|
|
alt=""
|
|
|
@click="chuans"
|
|
|
/>
|
|
|
</div> -->
|
|
|
<el-image
|
|
|
v-for="(bb, index) in details.photoIds"
|
|
|
:key="index"
|
|
|
style="width: 100px; height: 100px"
|
|
|
:src="bb"
|
|
|
:preview-src-list="details.photoIds"
|
|
|
error="我裂开啦" ></el-image>
|
|
|
</div>
|
|
|
</div>
|
|
|
</div>
|
...
|
...
|
@@ -569,7 +570,24 @@ |
|
|
<div class="ziliaotu">
|
|
|
<div class="ziliao-left">
|
|
|
<img src="../../assets/21.png" class="ziliao-img" alt="" />
|
|
|
<span class="text-sp">food.jpg</span>
|
|
|
<el-image
|
|
|
v-for="(cc, index1) in details.fileIds"
|
|
|
:key="index1"
|
|
|
style="width: 100px; height: 100px"
|
|
|
:src="cc"
|
|
|
:preview-src-list="details.fileIds"
|
|
|
error="我裂开啦"
|
|
|
>
|
|
|
</el-image>
|
|
|
<el-image
|
|
|
v-for="(cc1, index2) in details.fileIds"
|
|
|
:key="index2"
|
|
|
style="width: 100px; height: 100px"
|
|
|
:src="cc1"
|
|
|
:preview-src-list="details.fileIds"
|
|
|
error="我裂开啦"
|
|
|
>
|
|
|
</el-image>
|
|
|
</div>
|
|
|
</div>
|
|
|
</div>
|
...
|
...
|
@@ -634,15 +652,13 @@ |
|
|
<div class="sd">
|
|
|
<div class="fa-ji">传真照片</div>
|
|
|
<div class="img-chuan">
|
|
|
<!-- <div class="lisg" v-for="(item,index) in details.photoIds" :key="index">
|
|
|
<img :src="item" class="tu" alt="" />
|
|
|
<img
|
|
|
src="../../assets/fanda.png"
|
|
|
class="fan"
|
|
|
alt=""
|
|
|
@click="chuans"
|
|
|
/>
|
|
|
</div> -->
|
|
|
<el-image
|
|
|
v-for="(bb, index) in details.photoIds"
|
|
|
:key="index"
|
|
|
style="width: 100px; height: 100px"
|
|
|
:src="bb"
|
|
|
:preview-src-list="details.photoIds"
|
|
|
error="我裂开啦" ></el-image>
|
|
|
</div>
|
|
|
</div>
|
|
|
</div>
|
...
|
...
|
@@ -692,7 +708,16 @@ |
|
|
<div class="ziliaotu">
|
|
|
<div class="ziliao-left">
|
|
|
<img src="../../assets/21.png" class="ziliao-img" alt="" />
|
|
|
<span class="text-sp">food.jpg</span>
|
|
|
<el-image
|
|
|
v-for="(cc, index1) in details.fileIds"
|
|
|
:key="index1"
|
|
|
style="width: 100px; height: 100px"
|
|
|
:src="cc"
|
|
|
:preview-src-list="details.fileIds"
|
|
|
error="我裂开啦"
|
|
|
>
|
|
|
</el-image>
|
|
|
|
|
|
</div>
|
|
|
</div>
|
|
|
</div>
|
...
|
...
|
@@ -717,23 +742,23 @@ |
|
|
</el-table-column>
|
|
|
|
|
|
<el-table-column fixed="right" label="操作" width="272">
|
|
|
<template slot-scope="scope">
|
|
|
|
|
|
<el-button
|
|
|
@click="handleClick(scope.row.shipId, 3)"
|
|
|
type="text"
|
|
|
size="small"
|
|
|
>确认完成</el-button
|
|
|
>
|
|
|
</template>
|
|
|
</el-table-column>
|
|
|
</el-table>
|
|
|
</div>
|
|
|
<div class="queren">
|
|
|
<el-button type="primary" round @click="dialogVisibleq = false"
|
|
|
>确认</el-button
|
|
|
|
|
|
<div class="queren" >
|
|
|
<el-button type="primary" round @click="handleClick(3)">确认</el-button
|
|
|
>
|
|
|
<el-button round @click="dialogVisibleq = false">取消</el-button>
|
|
|
|
|
|
</div>
|
|
|
|
|
|
</div>
|
|
|
</el-dialog>
|
|
|
<!-- 查看详情 -->
|
...
|
...
|
@@ -766,15 +791,13 @@ |
|
|
<div class="sd">
|
|
|
<div class="fa-ji">传真照片</div>
|
|
|
<div class="img-chuan">
|
|
|
<!-- <div class="lisg" v-for="(item,index) in details.photoIds" :key="index">
|
|
|
<img :src="item" class="tu" alt="" />
|
|
|
<img
|
|
|
src="../../assets/fanda.png"
|
|
|
class="fan"
|
|
|
alt=""
|
|
|
@click="chuans"
|
|
|
/>
|
|
|
</div> -->
|
|
|
<el-image
|
|
|
v-for="(bb, index) in details.photoIds"
|
|
|
:key="index"
|
|
|
style="width: 100px; height: 100px"
|
|
|
:src="bb"
|
|
|
:preview-src-list="details.photoIds"
|
|
|
error="我裂开啦" ></el-image>
|
|
|
</div>
|
|
|
</div>
|
|
|
</div>
|
...
|
...
|
@@ -823,8 +846,15 @@ |
|
|
<div class="ziliao-lists">
|
|
|
<div class="ziliaotu">
|
|
|
<div class="ziliao-left">
|
|
|
<img src="../../assets/21.png" class="ziliao-img" alt="" />
|
|
|
<span class="text-sp">food.jpg</span>
|
|
|
<el-image
|
|
|
v-for="(cc, index1) in details.fileIds"
|
|
|
:key="index1"
|
|
|
style="width: 100px; height: 100px"
|
|
|
:src="cc"
|
|
|
:preview-src-list="details.fileIds"
|
|
|
error="我裂开啦"
|
|
|
>
|
|
|
</el-image>
|
|
|
</div>
|
|
|
</div>
|
|
|
</div>
|
...
|
...
|
@@ -885,24 +915,20 @@ export default { |
|
|
data() {
|
|
|
return {
|
|
|
tableData: [],
|
|
|
tablelist: [{
|
|
|
productId: "",
|
|
|
num: "",
|
|
|
moneyTime: "",
|
|
|
detailId: "",
|
|
|
lastNum: "",
|
|
|
shipId: "",
|
|
|
status: "",
|
|
|
},],
|
|
|
fileList: [{
|
|
|
name: 'food.jpeg',
|
|
|
url: 'https://fuss10.elemecdn.com/3/63/4e7f3a15429bfda99bce42a18cdd1jpeg.jpeg?imageMogr2/thumbnail/360x360/format/webp/quality/100'
|
|
|
}, {
|
|
|
name: 'food2.jpeg',
|
|
|
url: 'https://fuss10.elemecdn.com/3/63/4e7f3a15429bfda99bce42a18cdd1jpeg.jpeg?imageMogr2/thumbnail/360x360/format/webp/quality/100'
|
|
|
}],
|
|
|
tablelist: [
|
|
|
{
|
|
|
productId: "",
|
|
|
num: "",
|
|
|
moneyTime: "",
|
|
|
detailId: "",
|
|
|
lastNum: "",
|
|
|
shipId: "",
|
|
|
status: "",
|
|
|
},
|
|
|
],
|
|
|
fileList: [],
|
|
|
|
|
|
tablelists: [],
|
|
|
tablelists: "",
|
|
|
options: [],
|
|
|
dialogVisible: false,
|
|
|
dialogVisibleg: false,
|
...
|
...
|
@@ -929,15 +955,16 @@ export default { |
|
|
shipId: "", //申请计划
|
|
|
telegramListName: "", //电站名称
|
|
|
pageNum: 1,
|
|
|
photoIds: "",
|
|
|
pageSize: 10,
|
|
|
details: [],
|
|
|
total: null, //总条数
|
|
|
optionsas: [],
|
|
|
name: "",
|
|
|
clickfinishshipId:''// 点击完成发货计划ID
|
|
|
};
|
|
|
},
|
|
|
computed: {
|
|
|
},
|
|
|
computed: {},
|
|
|
mounted() {
|
|
|
this.dian();
|
|
|
this.fahuo();
|
...
|
...
|
@@ -952,12 +979,35 @@ export default { |
|
|
console.log(file);
|
|
|
},
|
|
|
handleExceed(files, fileList) {
|
|
|
this.$message.warning(`当前限制选择 3 个文件,本次选择了 ${files.length} 个文件,共选择了 ${files.length + fileList.length} 个文件`);
|
|
|
this.$message.warning(
|
|
|
`当前限制选择 3 个文件,本次选择了 ${files.length} 个文件,共选择了 ${
|
|
|
files.length + fileList.length
|
|
|
} 个文件`
|
|
|
);
|
|
|
},
|
|
|
beforeRemove(file, fileList) {
|
|
|
return this.$confirm(`确定移除 ${file.name}?`);
|
|
|
},
|
|
|
|
|
|
/**上传地址 */
|
|
|
uploadFile() {
|
|
|
return "api/file/upload";
|
|
|
},
|
|
|
/*上传附件成功*/
|
|
|
uploadSucc(fileList) {
|
|
|
this.fileList =
|
|
|
this.fileList == "" ? fileList.msg + "," : this.fileList + fileList.msg;
|
|
|
console.log(this.fileList);
|
|
|
},
|
|
|
/**上传图片 */
|
|
|
uploadPic(fileList) {
|
|
|
this.photoIds =
|
|
|
this.photoIds == "" ? fileList.msg + "," : this.photoIds + fileList.msg;
|
|
|
console.log(this.photoIds);
|
|
|
},
|
|
|
/* 上传失败 */
|
|
|
uploadErr() {
|
|
|
console.log("上传失败");
|
|
|
},
|
|
|
onSubmit(val) {
|
|
|
this.value = val;
|
|
|
this.dian();
|
...
|
...
|
@@ -966,6 +1016,9 @@ export default { |
|
|
chaxun() {
|
|
|
this.fahuo();
|
|
|
},
|
|
|
|
|
|
|
|
|
|
|
|
//select发生改变市
|
|
|
currentSel(selVal) {
|
|
|
console.log(selVal);
|
...
|
...
|
@@ -990,10 +1043,15 @@ export default { |
|
|
console.log(err);
|
|
|
});
|
|
|
},
|
|
|
/* 奥利给分页 */
|
|
|
changePageNum(page){
|
|
|
this.pageNum=page;
|
|
|
this.fahuo();
|
|
|
},
|
|
|
//确认完成
|
|
|
handleClick(id, index) {
|
|
|
handleClick(index) {
|
|
|
let that = this;
|
|
|
var url = "/api/ship/ship/" + id + "/" + index;
|
|
|
var url = "/api/ship/ship/" + that.clickfinishshipId + "/" + index;
|
|
|
let params = {};
|
|
|
that.$axios
|
|
|
.put(url)
|
...
|
...
|
@@ -1002,9 +1060,8 @@ export default { |
|
|
message: "确认完成",
|
|
|
type: "success",
|
|
|
});
|
|
|
// that.dialogVisibleg = false;
|
|
|
// that.fahuo();
|
|
|
// console.log(res);
|
|
|
that.dialogVisibleq = false
|
|
|
that.fahuo();
|
|
|
})
|
|
|
.catch(function (err) {
|
|
|
console.log(err);
|
...
|
...
|
@@ -1034,8 +1091,8 @@ export default { |
|
|
//搜索
|
|
|
getCategoryOptions(val, index, rows) {
|
|
|
console.log(val);
|
|
|
console.log()
|
|
|
this.chanping(val, index, rows)
|
|
|
console.log();
|
|
|
this.chanping(val, index, rows);
|
|
|
// this.chan()
|
|
|
},
|
|
|
//根据产品id搜索
|
...
|
...
|
@@ -1047,7 +1104,7 @@ export default { |
|
|
.get(url)
|
|
|
.then(function (res) {
|
|
|
console.log(index, rows);
|
|
|
rows[index].detailId = res.data.productCoding
|
|
|
rows[index].detailId = res.data.productCoding;
|
|
|
})
|
|
|
.catch(function (err) {
|
|
|
console.log(err);
|
...
|
...
|
@@ -1106,25 +1163,26 @@ export default { |
|
|
},
|
|
|
//获取发货计划列表
|
|
|
fahuo() {
|
|
|
console.log("11")
|
|
|
console.log(this.$axios.defaults.headers)
|
|
|
let that = this;
|
|
|
var url = "/api/ship/ship/list";
|
|
|
let params = {
|
|
|
pageSize: that.pageSize,
|
|
|
createBy: that.createBy,
|
|
|
createTime: that.createTime,
|
|
|
contractCode: that.contractCode,
|
|
|
pageNum: that.pageNum,
|
|
|
pageSize: that.pageSize,
|
|
|
shipId: that.shipId,
|
|
|
telegramListName: that.telegramListName,
|
|
|
} || '';
|
|
|
that.$axios.post(url, params).then(res => {
|
|
|
console.log(res);
|
|
|
that.tableData = res.rows;
|
|
|
that.total = res.total;
|
|
|
})
|
|
|
let params =
|
|
|
{
|
|
|
pageSize: that.pageSize,
|
|
|
createBy: that.createBy,
|
|
|
createTime: that.createTime,
|
|
|
contractCode: that.contractCode,
|
|
|
pageNum: that.pageNum,
|
|
|
pageSize: that.pageSize,
|
|
|
shipId: that.shipId,
|
|
|
telegramListName: that.telegramListName,
|
|
|
} || "";
|
|
|
that.$axios
|
|
|
.post(url, params)
|
|
|
.then((res) => {
|
|
|
console.log(res);
|
|
|
that.tableData = res.rows;
|
|
|
that.total = res.total;
|
|
|
})
|
|
|
.catch(function (err) {
|
|
|
console.log(err);
|
|
|
});
|
...
|
...
|
@@ -1138,20 +1196,44 @@ export default { |
|
|
that.$axios
|
|
|
.get(url)
|
|
|
.then(function (res) {
|
|
|
console.log(res);
|
|
|
|
|
|
res=that.changePicAdress(res)
|
|
|
that.details = res.data;
|
|
|
console.log(that.details);
|
|
|
})
|
|
|
.catch(function (err) {
|
|
|
console.log(err);
|
|
|
});
|
|
|
},
|
|
|
|
|
|
|
|
|
//改变后台数据
|
|
|
changePicAdress(res){
|
|
|
let arr = [];
|
|
|
res.data.photoIds = res.data.photoIds.indexOf(",") > -1? (res.data.photoIds = res.data.photoIds.split(",")): (res.data.photoIds = arr.push(res.data.photoIds));
|
|
|
//添加地址
|
|
|
res.data.photoIds=res.data.photoIds.map((element) => {
|
|
|
element = "http://wisdom.jd.brotop.cn/file/download/" + element;
|
|
|
return element;
|
|
|
});
|
|
|
|
|
|
let brr = [];
|
|
|
res.data.fileIds =res.data.fileIds.indexOf(",") > -1 ? (res.data.fileIds = res.data.fileIds.split(",")): (res.data.fileIds = brr.push(res.data.fileIds));
|
|
|
//添加地址
|
|
|
res.data.fileIds=res.data.fileIds.map((element) => {
|
|
|
element = "http://wisdom.jd.brotop.cn/file/download/" + element;
|
|
|
return element;
|
|
|
});
|
|
|
|
|
|
return res;
|
|
|
},
|
|
|
//新增发货计划确认
|
|
|
btn() {
|
|
|
let that = this;
|
|
|
var url = "/api/ship/ship/add";
|
|
|
let params = {
|
|
|
shipPlan: that.shipPlan, //发货计划
|
|
|
fileIds: "https://zqvcil8xjx.feishu.cn/docs/doccnzYUyK8v7fK3MQrPNodwPMQ", //附带资料
|
|
|
fileIds: that.fileList, //附带资料
|
|
|
moneyContactPerson: that.moneyContactPerson, //到货联系人
|
|
|
telegramList: that.value, //发电站编码集合
|
|
|
latitude: "31.25658", //经度
|
...
|
...
|
@@ -1164,23 +1246,23 @@ export default { |
|
|
productionStatus: that.productionStatus, //生产情况
|
|
|
vehicleRequirements: that.vehicleRequirements, //车辆要求
|
|
|
remarks: that.remarks, //备注
|
|
|
photoIds: "https://images.cnblogs.com/cnblogs_com/s313139232/1258426/o_o_headers.jpg", //传真照片
|
|
|
photoIds: that.photoIds, //传真照片
|
|
|
mainShipDetail: that.tablelist,
|
|
|
};
|
|
|
that.$axios
|
|
|
.post(url, params)
|
|
|
.then(function (res) {
|
|
|
console.log(res);
|
|
|
console.log("确认订单" + res);
|
|
|
that.$message({
|
|
|
message: "添加成功",
|
|
|
type: "success",
|
|
|
});
|
|
|
that.dialogVisible = false;
|
|
|
that.contractCode = ''
|
|
|
that.fahuo()
|
|
|
that.contractCode = "";
|
|
|
that.fahuo();
|
|
|
})
|
|
|
.catch(function (err) {
|
|
|
that.$message.error(err.msg)
|
|
|
that.$message.error(err.msg);
|
|
|
console.log(err);
|
|
|
});
|
|
|
},
|
...
|
...
|
@@ -1239,7 +1321,7 @@ export default { |
|
|
that.$axios
|
|
|
.get(url)
|
|
|
.then(function (res) {
|
|
|
console.log(res);
|
|
|
res=that.changePicAdress(res)
|
|
|
that.details = res.data;
|
|
|
})
|
|
|
.catch(function (err) {
|
...
|
...
|
@@ -1248,6 +1330,7 @@ export default { |
|
|
},
|
|
|
//确认发货
|
|
|
que(id) {
|
|
|
this.clickfinishshipId=id; //我每次都赋值
|
|
|
this.dialogVisibleq = true;
|
|
|
let that = this;
|
|
|
var url = "/api/ship/ship/" + id;
|
...
|
...
|
@@ -1255,9 +1338,9 @@ export default { |
|
|
that.$axios
|
|
|
.get(url)
|
|
|
.then(function (res) {
|
|
|
console.log(res);
|
|
|
that.details = res.data;
|
|
|
that.fahuo()
|
|
|
res=that.changePicAdress(res)
|
|
|
that.details = res.data;
|
|
|
that.fahuo();
|
|
|
})
|
|
|
.catch(function (err) {
|
|
|
console.log(err);
|
...
|
...
|
|