Commit 5b373c1b authored by 沈翠玲's avatar 沈翠玲

添加ERP数据同步按钮

parent 6931d16c
......@@ -42,3 +42,11 @@ export function delClient(clientId) {
method: 'delete'
})
}
// 同步ERP数据
export function syncData() {
return request({
url: '/mes/md/client/syncData',
method: 'post'
})
}
\ No newline at end of file
......@@ -50,3 +50,11 @@ export function becomeFormalProduct(itemId) {
method: 'put'
})
}
// 同步ERP数据
export function syncData() {
return request({
url: '/mes/md/mditem/syncData',
method: 'post'
})
}
......@@ -42,3 +42,12 @@ export function delVendor(vendorId) {
method: 'delete'
})
}
// 同步ERP数据
export function syncData() {
return request({
url: '/mes/md/vendor/syncData',
method: 'post'
})
}
......@@ -126,3 +126,11 @@ export function printInfo(workorderId) {
method: 'get'
})
}
// 同步ERP数据
export function syncData() {
return request({
url: '/mes/pro/workorder/syncData',
method: 'post'
})
}
......@@ -49,3 +49,11 @@ export function delWarehouse(warehouseId) {
method: 'delete'
})
}
// 同步ERP数据
export function syncData() {
return request({
url: '/mes/wm/warehouse/syncData',
method: 'post'
})
}
\ No newline at end of file
......@@ -2959,5 +2959,6 @@
"分配角色": "分配角色",
"菜单字段": "menuName",
"工时单位必选": "工时单位必选",
"委外加工商必选": "委外加工商必选"
"委外加工商必选": "委外加工商必选",
"ERP数据同步": "ERP数据同步"
}
......@@ -103,6 +103,10 @@
v-hasPermi="['mes:md:client:remove']"
>{{$t('删除')}}</el-button>
</el-col>
<el-col :span="1.5">
<el-button type="success" plain size="mini"
@click="handleSyncData">{{$t('ERP数据同步')}}</el-button>
</el-col>
<el-col :span="1.5">
<el-button
type="warning"
......@@ -269,7 +273,7 @@
<script>
import {listClient, getClient, delClient, addClient, updateClient} from "@/api/mes/md/client";
import {listClient, getClient, delClient, addClient, updateClient, syncData} from "@/api/mes/md/client";
import BaseInfo from '@/views/mes/md/client/components/BaseInfo'
import UrgeEmail from '@/views/mes/md/client/components/UrgeEmail'
import AddrInfo from '@/views/mes/md/client/components/AddrInfo'
......@@ -431,6 +435,11 @@ export default {
this.loading = false;
});
},
handleSyncData() {
syncData().then((response) => {
this.getList()
});
},
// 取消按钮
cancel() {
this.open = false;
......
......@@ -49,6 +49,10 @@
<el-button type="success" plain icon="el-icon-edit" size="mini" :disabled="multiple"
@click="handBecomeFormalProduct">{{$t('转正式产品')}}</el-button>
</el-col>
<el-col :span="1.5">
<el-button type="success" plain size="mini"
@click="handleSyncData">{{$t('ERP数据同步')}}</el-button>
</el-col>
<el-col :span="1.5">
<el-button type="info" plain icon="el-icon-upload2" size="mini" @click="handleImport">{{ $t('common.import') }}</el-button>
</el-col>
......@@ -255,6 +259,7 @@ import {
addMdItem,
updateMdItem,
becomeFormalProduct,
syncData
} from "@/api/mes/md/mdItem";
import BaseInfo from "./components/baseInfo.vue";
......@@ -395,6 +400,11 @@ export default {
this.loading = false;
});
},
handleSyncData() {
syncData().then((response) => {
this.getList()
});
},
getUnits() {
listAllUnitmeasure().then((response) => {
this.measureOptions = response.data;
......
......@@ -87,6 +87,10 @@
v-hasPermi="['mes:md:vendor:remove']"
>{{ $t('common.del') }}</el-button>
</el-col>
<el-col :span="1.5">
<el-button type="success" plain size="mini"
@click="handleSyncData">{{$t('ERP数据同步')}}</el-button>
</el-col>
<el-col :span="1.5">
<el-button
type="warning"
......@@ -363,7 +367,7 @@
<script>
import { listVendor, getVendor, delVendor, addVendor, updateVendor } from "@/api/mes/md/vendor";
import { listVendor, getVendor, delVendor, addVendor, updateVendor, syncData } from "@/api/mes/md/vendor";
import { getToken } from "@/utils/auth";
import {genCode} from "@/api/system/autocode/rule"
export default {
......@@ -452,6 +456,11 @@ export default {
this.getList();
},
methods: {
handleSyncData() {
syncData().then((response) => {
this.getList()
});
},
/** 查询供应商列表 */
getList() {
this.loading = true;
......
......@@ -102,6 +102,10 @@
</el-button
>
</el-col> -->
<el-col :span="1.5">
<el-button type="success" plain size="mini"
@click="handleSyncData">{{$t('ERP数据同步')}}</el-button>
</el-col>
<el-col :span="1.5">
<el-button type="warning" plain icon="el-icon-download" size="mini" @click="handleExport"
v-hasPermi="['mes:pro:workorder:export']">{{$t('导出')}}</el-button>
......@@ -502,7 +506,8 @@ import {
dofinish,
printInfo,
doCheckToolNum,
closeWorkorder
closeWorkorder,
syncData
} from "@/api/mes/pro/workorder";
import { addProtaskList } from "@/api/mes/pro/protask";
......@@ -694,6 +699,11 @@ export default {
})
},
methods: {
handleSyncData() {
syncData().then((response) => {
this.getList()
});
},
//筛选日期设置默认值
setDate() {
......
......@@ -56,6 +56,10 @@
v-hasPermi="['mes:wm:warehouse:remove']"
>{{ $t('common.del') }}</el-button>
</el-col>
<el-col :span="1.5">
<el-button type="success" plain size="mini"
@click="handleSyncData">{{$t('ERP数据同步')}}</el-button>
</el-col>
<right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar>
</el-row>
......@@ -176,7 +180,7 @@
<script>
import { listWarehouse, getWarehouse, delWarehouse, addWarehouse, updateWarehouse } from "@/api/mes/wm/warehouse";
import { listWarehouse, getWarehouse, delWarehouse, addWarehouse, updateWarehouse, syncData } from "@/api/mes/wm/warehouse";
import {genCode} from "@/api/system/autocode/rule"
export default {
name: "Warehouse",
......@@ -230,6 +234,11 @@ export default {
this.getList();
},
methods: {
handleSyncData() {
syncData().then((response) => {
this.getList()
});
},
/** 查询仓库设置列表 */
getList() {
this.loading = true;
......
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