Commit efd64148 by yiyu.li

优化

parent b57238d3
...@@ -43,7 +43,12 @@ ...@@ -43,7 +43,12 @@
<div class="choose"> <div class="choose">
<p class="selectTitle">3.操作</p> <p class="selectTitle">3.操作</p>
<Tabs type="card" :value="tabindex"> <Tabs type="card" :value="tabindex">
<TabPane label="上料" :disabled="attr1" name="1"> <TabPane
label="上料"
:disabled="attr1"
name="1"
@click="getStorages()"
>
<div class="filter"> <div class="filter">
<label style="font-size: 16px" <label style="font-size: 16px"
>上料信息:</label >上料信息:</label
...@@ -116,8 +121,7 @@ ...@@ -116,8 +121,7 @@
<p class="infoLabel">产品图片:</p> <p class="infoLabel">产品图片:</p>
<div> <div>
<img <img
:src="orderDetail.url :src="orderDetail.url"
"
alt="" alt=""
style="width: 100%" style="width: 100%"
/> />
...@@ -132,7 +136,11 @@ ...@@ -132,7 +136,11 @@
> >
</div> </div>
</TabPane> </TabPane>
<TabPane label="下料" :disabled="attr2" name="2" <TabPane
label="下料"
:disabled="attr2"
name="2"
@click="getStorages()"
><div class="flex"> ><div class="flex">
<div> <div>
<Table <Table
...@@ -332,12 +340,11 @@ export default { ...@@ -332,12 +340,11 @@ export default {
detailobj: {}, detailobj: {},
sectionid: 0, sectionid: 0,
tabindex: "1", tabindex: "1",
locationobj:{} locationobj: {},
}; };
}, },
created() { created() {
this.getProLine(); this.getProLine();
}, },
mounted() { mounted() {
// this.getStations() // this.getStations()
...@@ -397,9 +404,15 @@ export default { ...@@ -397,9 +404,15 @@ export default {
}, },
//获取储位 //获取储位
getStorages() { getStorages() {
let code = ''; let code = "";
code = this.orderDetail.productCode? this.orderDetail.productCode :''; code = this.orderDetail.productCode
this.request("/acc/AutomationLocation/GetLocationList?fillsn=1&code="+code, "", "get") ? this.orderDetail.productCode
: "";
let data = {
fillsn: this.tabindex == "1" ? 0 : 1,
code: code,
};
this.request("/acc/AutomationLocation/GetLocationList", data, "get")
.then((res) => { .then((res) => {
if (res.data.ret == 1) { if (res.data.ret == 1) {
this.data1 = res.data.data; this.data1 = res.data.data;
...@@ -419,10 +432,14 @@ export default { ...@@ -419,10 +432,14 @@ export default {
.then((res) => { .then((res) => {
if (res.data.ret == 1) { if (res.data.ret == 1) {
let obj = res.data.data; let obj = res.data.data;
if(obj.url == null || obj.url=='' || obj.url ==undefined){ if (
obj.url = '' obj.url == null ||
}else{ obj.url == "" ||
obj.url = this.axios.publicPath +obj.url; obj.url == undefined
) {
obj.url = "";
} else {
obj.url = this.axios.publicPath + obj.url.slice(4);
} }
this.orderDetail = Object.assign( this.orderDetail = Object.assign(
{}, {},
...@@ -451,6 +468,15 @@ export default { ...@@ -451,6 +468,15 @@ export default {
.then((res) => { .then((res) => {
if (res.data.ret == 1) { if (res.data.ret == 1) {
let obj = res.data.data; let obj = res.data.data;
if (
obj.url == null ||
obj.url == "" ||
obj.url == undefined
) {
obj.url = "";
} else {
obj.url = this.axios.publicPath + obj.url.slice(4);
}
this.orderDetail = Object.assign( this.orderDetail = Object.assign(
{}, {},
this.orderDetail, this.orderDetail,
...@@ -521,7 +547,7 @@ export default { ...@@ -521,7 +547,7 @@ export default {
} }
let data = { let data = {
section: this.sectionid, section: this.sectionid,
id:this.locationobj.id, id: this.locationobj.id,
}; };
this.request("/acc/AutomationOperate/Unloading", data, "post").then( this.request("/acc/AutomationOperate/Unloading", data, "post").then(
(res) => { (res) => {
...@@ -564,8 +590,12 @@ export default { ...@@ -564,8 +590,12 @@ export default {
this.locationobj = currentRow; this.locationobj = currentRow;
this.orderDetail.fixtureGuid = this.detailobj.fixtureguid; this.orderDetail.fixtureGuid = this.detailobj.fixtureguid;
this.orderDetail.location = this.detailobj.locationid; this.orderDetail.location = this.detailobj.locationid;
if(this.locationobj.id){ if (this.locationobj.id) {
this.request("/acc/AutomationOperate/ScanCode?id="+this.locationobj.id, '', "get") this.request(
"/acc/AutomationOperate/ScanCode?id=" + this.locationobj.id,
"",
"get"
)
.then((res) => { .then((res) => {
if (res.data.ret == 1) { if (res.data.ret == 1) {
let obj = res.data.data; let obj = res.data.data;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment