@{
|
ViewBag.Title = "ServiceExecStatus";
|
Layout = "~/Views/Shared/_LayoutVue.cshtml";
|
}
|
|
<div id="app" v-cloak>
|
<el-card class="box-card">
|
<el-form label-width="100px" v-bind:model="formData" class="demo-ruleForm" v-bind:inline="true">
|
<el-form-item label="@L("cshtml_serviceexecstatus_tasktype"):">
|
<hh-select-url v-model="formData.taskType"
|
v-bind:options="taskTypeOptions"
|
ref="ztt"></hh-select-url>
|
</el-form-item>
|
<el-form-item label="@L("cshtml_serviceexecstatus_taskno"):">
|
<el-input v-model="formData.taskNo" size="mini"></el-input>
|
</el-form-item>
|
<el-form-item label="@L("cshtml_serviceexecstatus_iscomplete"):">
|
<hh-select-url v-model="formData.isComplete"
|
v-bind:options="boolOptions"></hh-select-url>
|
</el-form-item>
|
<el-form-item label="@L("cshtml_serviceexecstatus_issendmes"):">
|
<hh-select-url v-model="formData.isSendMes"
|
v-bind:options="boolOptions"></hh-select-url>
|
</el-form-item>
|
|
<el-form-item>
|
</el-form-item>
|
|
</el-form>
|
<el-row style="padding-left: 10px; margin-top: 7px;">
|
<el-button style="margin-top:2px;" size="mini" type="primary" v-on:click="search">@L("cshtml_public_button_search")</el-button>
|
<el-button style="margin-top:2px;" size="mini" type="primary" v-on:click="restartTask">@L("cshtml_serviceexecstatus_restartexecute")</el-button>
|
@*<el-button size="mini" type="primary" v-on:click="add">导 出</el-button>*@
|
</el-row>
|
</el-card>
|
<hh-table v-bind:coloptions="cols"
|
v-bind:paging="true"
|
v-bind:check="true"
|
v-bind:rowno="true"
|
dh="120"
|
url="@Url.Action("GetServiceExecList")"
|
ref="list"></hh-table>
|
</div>
|
|
@section scripts{
|
<script>
|
new Vue({
|
el: "#app",
|
data: {
|
formData: {
|
taskType: "",
|
isComplete: "",
|
isSendMes: ""
|
},
|
taskTypeOptions: [{
|
value: '',
|
label: '全部'
|
}, {
|
value: '移送',
|
label: '移送'
|
}, {
|
value: '移库',
|
label: '移库'
|
}],
|
boolOptions: [{
|
value: '',
|
label: '全部'
|
}, {
|
value: 'Y',
|
label: 'Y'
|
}, {
|
value: 'N',
|
label: 'N'
|
}],
|
cols: [
|
{ f: "CN_S_TASK_TYPE", n: "@L("cshtml_serviceexecstatus_tasktype")", w: 80 },
|
{
|
f: "CN_S_TASK_NO", n: "@L("cshtml_serviceexecstatus_taskno")", w: 80, format: function (row) {
|
if (row.CN_S_TASK_TYPE == "移库")
|
return "";
|
return row.CN_S_TASK_NO;
|
}
|
},
|
{ f: "CN_S_TRANS_TYPE", n: "@L("cshtml_serviceexecstatus_transtype")", w: 80 },
|
{ f: "CN_S_TRAY_CODE", n: "@L("cshtml_serviceexecstatus_loadno")", w: 80 },
|
{ f: "CN_S_ITEM_CODE", n: "@L("cshtml_serviceexecstatus_itemcode")" },
|
{ f: "CN_S_ITEM_NAME", n: "@L("cshtml_serviceexecstatus_itemname")" },
|
{ f: "CN_N_PRIORITY", n: "@L("cshtml_serviceexecstatus_priority")", w: 100 },
|
{ f: "CN_S_START_LOCATION", n: "@L("cshtml_serviceexecstatus_startlocation")", w: 80 },
|
{ f: "CN_S_END_LOCATION", n: "@L("cshtml_serviceexecstatus_endlocation")", w: 80 },
|
{ f: "CN_T_CREATE", n: "@L("cshtml_serviceexecstatus_createtime")" },
|
{ f: "CN_S_MSG", n: "@L("cshtml_serviceexecstatus_message")" },
|
{ f: "CN_C_COMPLETE", n: "@L("cshtml_serviceexecstatus_iscomplete")", w: 100 },
|
{ f: "CN_C_SEND_MES", n: "@L("cshtml_serviceexecstatus_issendmes")", w: 110 }]
|
},
|
methods: {
|
search: function () {
|
this.$refs.list.loadData(this.formData);
|
},
|
restartTask: function () {
|
var $this = this;
|
$this.selectRowEvent(true, function (row) {
|
wms.confirm("@L("cshtml_serviceexecstatus_confirmexecute")?", function () {
|
ajaxManage({
|
url: '@Url.Action("RestartTask")?taskNo=' + row.CN_S_TASK_NO,
|
data: $this.formData,
|
success: function (data) {
|
switch (data.Status) {
|
case 0:
|
wms.error(data.Msg); break;
|
case 2:
|
wms.warning(data.Msg); break;
|
case 1:
|
wms.success("@L("cshtml_serviceexecstatus_executesuccess")!"); break;
|
break;
|
default: wms.error("@L("cshtml_serviceexecstatus_errorsystem")");
|
}
|
$this.search();
|
}
|
});
|
});
|
|
});
|
},
|
selectRowEvent: function (isSingle, callBack) {
|
var selectRow = this.$refs.list.selections;
|
var row = null;
|
if (isSingle) {
|
if (selectRow.length != 1) {
|
wms.warning("@L("cshtml_serviceexecstatus_confirmselect")");
|
return;
|
}
|
row = selectRow[0];
|
} else {
|
if (selectRow.length <= 0) {
|
wms.warning("@L("cshtml_serviceexecstatus_confirmselectsingle")");
|
return;
|
}
|
row = selectRow;
|
}
|
if (callBack)
|
callBack(row);
|
},
|
}
|
});
|
</script>
|
}
|