@{
|
ViewBag.Title = "ShowLocationContext";
|
Layout = "~/Views/Shared/_LayoutVue.cshtml";
|
}
|
|
<style type="text/css">
|
.el-form-item__content {
|
width: 120px !important;
|
margin-left: 10px;
|
}
|
</style>
|
|
<div id="list" v-cloak>
|
<el-card class="box-card">
|
<el-form label-width="100px" class="demo-ruleForm" v-bind:inline="true">
|
<el-form-item label="@HH.WMS.WebUI.LanService.LanServiceDll.translate("cshtml_locationview_location_code"):">
|
<el-input style="width:130px;" v-bind:disabled="true" v-model="locationCode" size="mini"></el-input>
|
</el-form-item>
|
@{
|
if ("hcbh".Equals(ViewBag.PROJECT_CODE) || "tzlj".Equals(ViewBag.PROJECT_CODE))
|
{
|
|
}
|
else if ("wxys".Equals(ViewBag.PROJECT_CODE))
|
{
|
if (ViewBag.DISPLAY_BTN)
|
{
|
<el-form-item style="width:130px;">
|
<el-button style="margin-top:2px;" size="mini" type="primary" v-on:click="toNormal">@HH.WMS.WebUI.LanService.LanServiceDll.translate("cshtml_locationview_returnnormal")</el-button>
|
</el-form-item>
|
}
|
}
|
else
|
{
|
<el-form-item style="width:130px;">
|
<el-button style="margin-top: 2px; " size="mini" type="primary" v-on:click="toNormal">@HH.WMS.WebUI.LanService.LanServiceDll.translate("cshtml_locationview_returnnormal")</el-button>
|
</el-form-item>
|
<el-form-item style="width:130px;">
|
<el-button style="margin-top: 2px;" size="mini" type="primary" v-on:click="unBindTray">@HH.WMS.WebUI.LanService.LanServiceDll.translate("cshtml_locationview_unbindtray")</el-button>
|
</el-form-item>
|
<el-form-item style="width:130px;">
|
<el-button style="margin-top: 2px; " size="mini" type="primary" v-on:click="bindTray">@HH.WMS.WebUI.LanService.LanServiceDll.translate("cshtml_locationview_bindtray")</el-button>
|
</el-form-item>
|
}
|
}
|
|
|
|
@{
|
if ("hcbh".Equals(ViewBag.PROJECT_CODE) || "tzlj".Equals(ViewBag.PROJECT_CODE))
|
{
|
<el-form-item>
|
<el-button style="margin-top: 2px; margin-left: 10px" size="mini" type="primary" v-on:click="emptyTray">@HH.WMS.WebUI.LanService.LanServiceDll.translate("cshtml_locationview_empty")</el-button>
|
</el-form-item>
|
<el-form-item>
|
<el-button style="margin-top: 2px; margin-left: 10px" size="mini" type="primary" v-on:click="fullTray">@HH.WMS.WebUI.LanService.LanServiceDll.translate("cshtml_locationview_full")</el-button>
|
</el-form-item>
|
}
|
}
|
|
</el-form>
|
</el-card>
|
<hh-table v-bind:coloptions="outCols"
|
v-bind:paging="false"
|
v-bind:check="false"
|
v-bind:where="where"
|
v-bind:rowno="true"
|
dh="110"
|
url="@Url.Action("GetTrayItem")?locationCode=@ViewData["locationCode"]"
|
ref="busslist"></hh-table>
|
</div>
|
@section scripts{
|
<script>
|
var outList = new Vue({
|
data: {
|
locationCode:"@ViewData["locationCode"]",
|
//formData: {
|
// stockCode: "",
|
// opType: "",
|
// opNo: "",
|
// itemCode: "",
|
// itemName: "",
|
// model: ""
|
//},
|
where: {},
|
outCols: [
|
{ f: "CN_S_ITEM_CODE", n: "@HH.WMS.WebUI.LanService.LanServiceDll.translate("cshtml_locationview_itemcode")", w: 200 },
|
{ f: "CN_S_ITEM_NAME", n: "@HH.WMS.WebUI.LanService.LanServiceDll.translate("cshtml_locationview_itemname")", w: 200 },
|
{ f: "CN_S_MODEL", n: "@HH.WMS.WebUI.LanService.LanServiceDll.translate("cshtml_locationview_model")", w: 100 },
|
{ f: "CN_S_LOT_NO", n: "@HH.WMS.WebUI.LanService.LanServiceDll.translate("cshtml_locationview_productbatch")", w: 100 },
|
{ f: "CN_S_TRAY_CODE", n: "@HH.WMS.WebUI.LanService.LanServiceDll.translate("cshtml_locationview_traycode")", w: 120 },
|
//{ f: "CN_S_USE_STATE", n: "托盘状态", w: 80 },
|
{ f: "CN_S_UNIQUE_CODE", n: "@HH.WMS.WebUI.LanService.LanServiceDll.translate("cshtml_locationview_bincode")", w: 120 },
|
//{ f: "CN_F_QUANTITY", n: "箱数", w: 50 },
|
{ f: "CN_S_SERIAL_NO", n: "@HH.WMS.WebUI.LanService.LanServiceDll.translate("cshtml_locationview_weight")", w: 80 },
|
{
|
f: "CN_QTY", n: "@HH.WMS.WebUI.LanService.LanServiceDll.translate("cshtml_locationview_divisor")", w: 80,
|
format: function (row, column) {
|
var weight = parseFloat(row.CN_S_WEIGHT);
|
if (weight > 0) {
|
return Math.round(row.CN_S_SERIAL_NO / row.CN_S_WEIGHT);
|
} else {
|
return 0;
|
}
|
}
|
},
|
//{
|
// f: "CN_S_MEASURE_UNIT", n: "单位", w: 50,
|
// format: function (row, column) {
|
// return "箱";
|
// }
|
//},
|
]
|
|
//{ f: "CN_S_ITEM_STATE", n: "物料状态", w: 80 },
|
//{ f: "CN_S_PRODUCTION_BATCH", n: "生产批次", w: 120 }
|
},
|
methods: {
|
//search: function () {
|
// this.$refs.busslist.loadData(this.locationCode);
|
//}
|
toNormal: function () {
|
var $this = this;
|
ajaxManage({
|
url: "@Url.Action("LocationToNormal")?locationCode=" + $this.locationCode + "&state=",
|
success: function (result) {
|
console.log(result);
|
}
|
});
|
},
|
unBindTray: function () {
|
var $this = this;
|
ajaxManage({
|
url: "@Url.Action("LocationToUnBind")?locationCode=" + $this.locationCode + "&state=",
|
success: function (result) {
|
console.log(result);
|
}
|
});
|
},
|
bindTray: function () {
|
var $this = this;
|
ajaxManage({
|
url: "@Url.Action("LocationToBind")?locationCode=" + $this.locationCode + "&state=",
|
success: function (result) {
|
console.log(result);
|
}
|
});
|
},
|
emptyTray: function () {
|
var $this = this;
|
ajaxManage({
|
url: "@Url.Action("UpdateUseState")?locationCode=" + $this.locationCode + "&state=空",
|
success: function (result) {
|
console.log(result);
|
}
|
});
|
},
|
fullTray: function () {
|
var $this = this;
|
ajaxManage({
|
url: "@Url.Action("UpdateUseState")?locationCode=" + $this.locationCode + "&state=满",
|
success: function (result) {
|
console.log(result);
|
}
|
});
|
}
|
},
|
el: '#list'
|
});
|
</script>
|
}
|