Commit 35a08557 authored by 周远喜's avatar 周远喜

vk31

parent ebc06c43
<template> <template>
<div style="padding: 0;" class="excute"> <div style="padding: 0;" class="excute">
<DataGrid <DataGrid
style="margin-top: -25px; margin-bottom: -25px;" style="margin-top:2px; margin-bottom: -20px;"
:columns="columns" :columns="columns"
ref="grid" ref="grid"
:easy="false" :easy="false"
......
...@@ -11,11 +11,10 @@ ...@@ -11,11 +11,10 @@
@on-selection-change="onSelect" @on-selection-change="onSelect"
:batch="true" :batch="true"
:border="true" :border="true"
:easy="false" :easy="true"
> >
<template slot="easySearch"></template> <template slot="easySearch">
<template slot="searchBack"> <div><Select
<Select
placeholder="选择排序优先级" placeholder="选择排序优先级"
v-model="tempValue" v-model="tempValue"
style="width: 150px;" style="width: 150px;"
...@@ -29,9 +28,17 @@ ...@@ -29,9 +28,17 @@
</a> </a>
<a style="font-weight: bold;" @click="openDuration"> <a style="font-weight: bold;" @click="openDuration">
<Icon type="md-create" size="14" />&nbsp;修改外协工期 <Icon type="md-create" size="14" />&nbsp;修改外协工期
</a>&nbsp;&nbsp;&nbsp;&nbsp; </a>
<Select placeholder="选择历史方案" style="width: 150px;"></Select>&nbsp;&nbsp;&nbsp;&nbsp; <Select placeholder="选择历史方案" style="width: 150px;"></Select>
<DatePicker </div>
</template>
<template slot="searchBack">
</template>
<template slot="searchForm">
<Search />
</template>
<template slot="buttons">
<DatePicker
type="date" type="date"
placeholder="设置基准日期" placeholder="设置基准日期"
style="width: 150px;" style="width: 150px;"
...@@ -41,11 +48,6 @@ ...@@ -41,11 +48,6 @@
<a style="font-weight: bold;" @click="openAddModel(1)"> <a style="font-weight: bold;" @click="openAddModel(1)">
<Icon type="ios-options" size="14" />&nbsp;工序参数调整 <Icon type="ios-options" size="14" />&nbsp;工序参数调整
</a> </a>
</template>
<template slot="searchForm">
<Search />
</template>
<template slot="buttons">
<Button <Button
type="primary" type="primary"
@click="goResults" @click="goResults"
......
...@@ -28,34 +28,13 @@ ...@@ -28,34 +28,13 @@
<Icon type="md-git-compare" /> <Icon type="md-git-compare" />
</a> </a>
<DropdownMenu slot="list" style="text-align: center;"> <DropdownMenu slot="list" style="text-align: center;">
<DropdownItem> <DropdownItem v-for="li in items" :key="li" v-dragging="{ item: li, list: items}">
<a href="#"> <a href="#">
<Icon type="md-apps" /> <Icon type="md-apps" />
</a> </a>
<span>转序规则</span> <span>{{li}}</span>
</DropdownItem> </DropdownItem>
<DropdownItem> </DropdownMenu>
<a href="#">
<Icon type="md-apps" />
</a>
<span>加班策略</span>
</DropdownItem>
<DropdownItem>
<a href="#">
<Icon type="md-apps" />
</a>
<span>任务平衡</span>
</DropdownItem>
<DropdownItem>
<a href="#">
<Icon type="md-apps" />
</a>
<span>是否离散</span>
</DropdownItem>
<!-- <div>
<Button type="text" class="ib" @click="handleOk">确定</Button><Button type="text" class="ib" @click="handle">关闭</Button>
</div>-->
</DropdownMenu>
</Dropdown> </Dropdown>
</div> </div>
<div class="slider"> <div class="slider">
...@@ -126,8 +105,8 @@ ...@@ -126,8 +105,8 @@
</Row> </Row>
<Divider /> <Divider />
<FormItem :label="l('isDiscrete')" prop="isDiscrete"> <FormItem :label="l('isDiscrete')" prop="dis">
<i-switch v-model="entity.isDiscrete" size="large"> <i-switch v-model="entity.dis" size="large">
<span slot="open"></span> <span slot="open"></span>
<span slot="close"></span> <span slot="close"></span>
</i-switch> </i-switch>
...@@ -159,22 +138,24 @@ import Api from "./api"; ...@@ -159,22 +138,24 @@ import Api from "./api";
export default { export default {
data() { data() {
return { return {
items:["是否多台","转序规则","加班策略","是否离散"],
entity: { entity: {
partTaskPk: 0, partTaskPk: 0,
opTaskPk: 0, opTaskPk: 0,
taskSeq: "", taskSeq: "",
flog: 5, //参数应用范围 flog: 5, //参数应用范围
calId: null, calId: -1,
planState: true, planState: false,
planMethod: "重叠", // 平行 重叠 planMethod: "重叠", // 平行 重叠
over: false, over: false,
overTime: "不加班", //"六日加班", 不加班 加班 overTime: "不加班", //"六日加班", 不加班 加班
efficiencyValue: 11, // 效率系数, 必须大于 0 efficiencyValue: 11, // 效率系数, 必须大于 0
shopId: null, shopId: -1,
isDiscrete: true,//是否离散 是否 dis:false,
isDiscrete: "否",//是否离散 是否
discrete: 1, //离散数值 必须大于 1 discrete: 1, //离散数值 必须大于 1
multiple: true, multiple: false,
multipleEquip: "", //"是否多台安排设备", 否 是 multipleEquip: "", //"是否多台安排设备", 否 是
multipleCount: 1, //多台数量 multipleCount: 1, //多台数量
multipleEquipPks: [], multipleEquipPks: [],
multipleEquipIds: "" //"设备id", 用英文逗号分隔 multipleEquipIds: "" //"设备id", 用英文逗号分隔
...@@ -245,7 +226,13 @@ export default { ...@@ -245,7 +226,13 @@ export default {
this.getCal(); //获取连班策略 this.getCal(); //获取连班策略
this.apsGet(); //获取参数级别和转序等的关系 this.apsGet(); //获取参数级别和转序等的关系
}, },
mounted() {}, mounted() {
this.$dragging.$on('dragged', ({ value }) => {
console.log(value.item)
console.log(value.list)
console.log(value.otherData)
})
},
methods: { methods: {
getCal() { getCal() {
Api.getallcal().then(res => { Api.getallcal().then(res => {
...@@ -298,9 +285,9 @@ export default { ...@@ -298,9 +285,9 @@ export default {
this.entity.multipleEquipIds = this.entity.multipleEquipPks.join(); this.entity.multipleEquipIds = this.entity.multipleEquipPks.join();
} }
// //
this.entity.planMethod = this.entity.planState ? "重叠" : "平行"; this.entity.planMethod = !this.entity.planState ? "重叠" : "平行";
this.entity.overTime = this.entity.over ? "不加班" : "加班"; this.entity.overTime = !this.entity.over ? "不加班" : "加班";
this.entity.isDiscrete = this.entity.isDiscrete ? "是" : "否"; this.entity.isDiscrete = this.entity.dis ? "是" : "否";
this.entity.multipleEquip = this.entity.multiple ? "是" : "否"; this.entity.multipleEquip = this.entity.multiple ? "是" : "否";
Api.apsschedulupdateparameter(this.entity) Api.apsschedulupdateparameter(this.entity)
.then(res => { .then(res => {
...@@ -356,13 +343,13 @@ export default { ...@@ -356,13 +343,13 @@ export default {
opTaskPk: this.row.op_task_pk, opTaskPk: this.row.op_task_pk,
taskSeq: this.row.task_seq, taskSeq: this.row.task_seq,
flog: 5, //参数应用范围 flog: 5, //参数应用范围
calId: null, calId: -1,
planState: this.row.plan_method=="平行", planState: this.row.plan_method=="平行",
planMethod: this.row.plan_method, // 平行 重叠 planMethod: this.row.plan_method, // 平行 重叠
over: this.row.over_time=="加班", over: this.row.over_time=="加班",
overTime: this.row.over_time, //"六日加班", 不加班 加班 overTime: this.row.over_time, //"六日加班", 不加班 加班
efficiencyValue:this.row.efficiency_value|1, // 效率系数, 必须大于 0 efficiencyValue:this.row.efficiency_value|1, // 效率系数, 必须大于 0
shopId: null, shopId: -1,
isDiscrete: this.row.isdiscrete=="是", isDiscrete: this.row.isdiscrete=="是",
discrete: this.row.discrete_value|1, //离散数值 必须大于 1 discrete: this.row.discrete_value|1, //离散数值 必须大于 1
multiple: this.row.multi_machine=="是", multiple: this.row.multi_machine=="是",
......
...@@ -126,10 +126,10 @@ service.interceptors.response.use( ...@@ -126,10 +126,10 @@ service.interceptors.response.use(
}, },
error => { error => {
if (error && error.response) { if (error && error.response) {
// if(error.response.status=="401"){ if(error.response.status=="401"){
// window.location.href = '/account/login'; window.location.href = '/account/login';
// return; return;
// } }
switch (error.response.status) { switch (error.response.status) {
case 400: error.message = '请求错误'; break; case 400: error.message = '请求错误'; break;
case 401: error.message = '未授权,请登录'; break; case 401: error.message = '未授权,请登录'; break;
......
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