Commit c2092722 authored by 罗成兵's avatar 罗成兵

Merge remote-tracking branch 'origin/gcl' into gcl

# Conflicts:
#	src/api/index.js
#	src/views/Home.vue
parents 453496e4 0844063e
This diff is collapsed.
......@@ -55,7 +55,8 @@
created() {
//获取妇幼权限和登录基本信息
// document.cookie = 'bGNnd3lwdF9hdA=8f26b5cc-1d66-4b31-8b86-26d916209e1e;'//昆明市
document.cookie = 'bGNnd3lwdF9hdA=e46a9c23-60e1-41f3-a652-089d50b3cbd9;'//云南省
document.cookie = 'bGNnd3lwdF9hdA=5028cd4d-4491-4351-9448-4b357d8f1591;'//云南省
let cookieToken = getCookie('bGNnd3lwdF9hdA')
if (cookieToken) {//根据cookie获取token并调用接口获取菜单并设置初始选中菜单
window.sessionStorage.setItem('token','bearer'+' ' + cookieToken);
......@@ -76,8 +77,7 @@
methods: {
setInitMenuInfo() {//设置默认菜单和菜单缓存
// this.menuList = JSON.parse(window.sessionStorage.getItem('menuList'));
this.menuList = this.menuTest;
console.log(999,this.menuList)
this.menuList = this.menuTest
if (!window.sessionStorage.getItem("tabs")) {
window.sessionStorage.setItem('tabs', JSON.stringify(this.menuTest));
this.$store.commit('changeTabs', this.menuTest)
......
......@@ -56,7 +56,7 @@
const columns = [
{
title: '发放单位',
dataIndex: 'typeName',
dataIndex: 'sendUnitName',
ellipsis: true
},
{
......@@ -138,7 +138,7 @@
}
},
created() {
this.getInStockList()
this.getInStorageList()
this.getAllFactory()
},
methods: {
......@@ -156,9 +156,9 @@
},
searchList() {
this.pagination.pageIndex = 1
this.getInStockList()
this.getInStorageList()
},
getInStockList() {
getInStorageList() {
this.loading = true
let pars = isEmptyParams(this.searchForm)
let par = {
......@@ -166,12 +166,12 @@
pageIndex: this.pagination.pageIndex,
pageSize: this.pagination.pageSize
}
this.$api.stockManage.fetchInStockList(par).then(({data = {}}) => {
this.$api.stockManage.fetchInStorageList(par).then(({data = {}}) => {
const {dataList = [], total = 0} = data
this.tableData = dataList
this.pagination.total = total
this.loading = false
}).finally(() => {
}).catch(() => {
this.loading = false
})
},
......@@ -179,12 +179,12 @@
showSizeChange(pageNum, pageSize) {
this.pagination.pageIndex = 1;
this.pagination.pageSize = pageSize;
this.getInStockList()
this.getInStorageList()
},
change(pageNum, pageSize) {
this.pagination.pageIndex = pageNum;
this.pagination.pageSize = pageSize;
this.getInStockList()
this.getInStorageList()
},
restSearchForm() {
this.searchForm = {
......
......@@ -57,56 +57,51 @@
import moment from 'moment'
const columns = [
{
title: '品牌',
title: '女方姓名',
dataIndex: 'medicineName',
ellipsis: true
},
{
title: '供应商名称',
title: '证件类型',
dataIndex: 'typeName',
ellipsis: true
},
{
title: '批次号',
title: '证件号码',
width: '120px',
dataIndex: 'factoryName',
ellipsis: true
},
{
title: '生产批次',
title: '男方姓名',
dataIndex: 'batchNumber',
ellipsis: true
},
{
title: '生产日期',
title: '证件类型',
dataIndex: 'specs',
ellipsis: true
},
{
title: '有效期',
title: '证件号码',
width: '120px',
scopedSlots: {customRender: 'expireDateS'},
},
{
title: '单价(元)',
title: '联系电话',
dataIndex: 'isHistoryName',
ellipsis: true
},
{
title: '规格',
title: '领取状态',
dataIndex: 'specs',
ellipsis: true
},
{
title: '库存总数',
title: '领取日期',
dataIndex: 'stockNum',
ellipsis: true
},
{
title: '入库日期',
dataIndex: 'isHistoryName',
ellipsis: true
},
{
title: '操作',
align: 'center',
......@@ -121,7 +116,6 @@
return {
// 搜索框对象
searchForm: {
breedId: undefined,
medicalName: '',
factoryId: '',
produceDate: undefined
......@@ -136,20 +130,13 @@
columns,
tableData: [],
loading: false,
allSupplyInfo:[],
}
},
created() {
this.getInStockList()
this.getFolviteApplyList()
this.getAllFactory()
},
methods: {
getAllSupply() {
let par= {}
this.$api.common.fetchAllSupply(par).then(({data = []}) => {
this.allSupplyInfo = data
})
},
getAllFactory() {
let par = {}
this.$api.common.fetchAllFactory(par).then(({data = []}) => {
......@@ -158,9 +145,9 @@
},
searchList() {
this.pagination.pageIndex = 1
this.getInStockList()
this.getFolviteApplyList()
},
getInStockList() {
getFolviteApplyList() {
this.loading = true
let pars = isEmptyParams(this.searchForm)
let par = {
......@@ -168,12 +155,12 @@
pageIndex: this.pagination.pageIndex,
pageSize: this.pagination.pageSize
}
this.$api.stockManage.fetchInStockList(par).then(({data = {}}) => {
this.$api.folviteApplyManage.fetchFolviteApplyList(par).then(({data = {}}) => {
const {dataList = [], total = 0} = data
this.tableData = dataList
this.pagination.total = total
this.loading = false
}).finally(() => {
}).catch(() => {
this.loading = false
})
},
......@@ -181,12 +168,12 @@
showSizeChange(pageNum, pageSize) {
this.pagination.pageIndex = 1;
this.pagination.pageSize = pageSize;
this.getInStockList()
this.getFolviteApplyList()
},
change(pageNum, pageSize) {
this.pagination.pageIndex = pageNum;
this.pagination.pageSize = pageSize;
this.getInStockList()
this.getFolviteApplyList()
},
restSearchForm() {
this.searchForm = {
......
......@@ -6,7 +6,7 @@
<a-input v-model="searchForm.idCar" placeholder="请输入证件号码" style="width: 250px"></a-input>
</a-form-item>
<a-form-item>
<a-button class="search_btn" @click="restSearchForm">读卡识别</a-button>
<!-- <a-button class="search_btn" @click="restSearchForm">读卡识别</a-button>-->
<a-button type="primary" class="search_btn" style="margin-left: 10px" @click="searchList">搜索</a-button>
<a-button class="search_btn" style="margin-left: 10px" @click="restSearchForm">清空</a-button>
</a-form-item>
......@@ -50,43 +50,43 @@
const columns = [
{
title: '发放日期',
dataIndex: 'medicineName',
dataIndex: 'provideDate',
ellipsis: true
},
{
title: '姓名',
dataIndex: 'typeName',
dataIndex: 'residentId',
ellipsis: true
},
{
title: '证件号码',
width: '120px',
dataIndex: 'factoryName',
dataIndex: 'residentId',
ellipsis: true
},
{
title: '联系电话',
dataIndex: 'batchNumber',
dataIndex: 'residentId',
ellipsis: true
},
{
title: '发放数量(瓶)',
dataIndex: 'specs',
dataIndex: 'number',
ellipsis: true
},
{
/* {
title: '发放时期',
width: '120px',
scopedSlots: {customRender: 'expireDateS'},
},
},*/
{
title: '现住址',
dataIndex: 'isHistoryName',
dataIndex: 'residentId',
ellipsis: true
},
{
title: '登记人',
dataIndex: 'specs',
dataIndex: 'provideDoctorId',
ellipsis: true
},
{
......@@ -115,14 +115,14 @@
}
},
created() {
this.getInStockList()
this.getFolviteDistributionList()
},
methods: {
searchList() {
this.pagination.pageIndex = 1
this.getInStockList()
this.getFolviteDistributionList()
},
getInStockList() {
getFolviteDistributionList() {
this.loading = true
let pars = isEmptyParams(this.searchForm)
let par = {
......@@ -130,12 +130,12 @@
pageIndex: this.pagination.pageIndex,
pageSize: this.pagination.pageSize
}
this.$api.stockManage.fetchInStockList(par).then(({data = {}}) => {
this.$api.folviteDistributionManage.fetchFolviteDistributionList(par).then(({data = {}}) => {
const {dataList = [], total = 0} = data
this.tableData = dataList
this.pagination.total = total
this.loading = false
}).finally(() => {
}).catch(() => {
this.loading = false
})
},
......@@ -143,12 +143,12 @@
showSizeChange(pageNum, pageSize) {
this.pagination.pageIndex = 1;
this.pagination.pageSize = pageSize;
this.getInStockList()
this.getFolviteDistributionList()
},
change(pageNum, pageSize) {
this.pagination.pageIndex = pageNum;
this.pagination.pageSize = pageSize;
this.getInStockList()
this.getFolviteDistributionList()
},
restSearchForm() {
this.searchForm = {
......
......@@ -82,7 +82,11 @@
return {
subLoad: false,
// form表单
formData: {},
formData: {
// supplierName: undefined,
// contactsName: undefined,
// contactsPhone: undefined,
},
formRules: {
supplierName: [
{required: true, message: '请选择供应商名称', trigger: 'change'},
......@@ -101,22 +105,23 @@
{required: true, message: '请输入详细地址', trigger: 'change'}
],
},
queryParams: {},
queryParams: {}
}
},
created() {
this.queryParams = this.$route.query;
if (this.queryParams.modeType === "update") {
this.$api.common.fetchSupplyById(this.queryParams.id).then(res => {
console.log(889, res.data)
if (res.code === 'SUCCESS') {
this.formData = res.data;
}
}).catch(() => {
});
}
},
methods: {
// 弹窗确定按钮
submitForm() {
let vm = this;
......
......@@ -28,6 +28,7 @@
:pagination="false"
>
<template slot="action" slot-scope="record">
<!--<a-button type="link" size="small" @click="toUpdate(record)">修改</a-button>-->
<a-popconfirm
:title="'确定' + (record.status === 1 ? '停用' : '启用') + '该供应商吗?'"
ok-text="是"
......@@ -36,6 +37,7 @@
>
<a href="#">{{record.status === 1 ? '停用' : '启用'}}</a>
</a-popconfirm>
<a-button type="link" size="small" @click="updateSupply(record)">修改</a-button>
<a-button type="link" size="small" @click="deleteConfirm(record)">删除</a-button>
</template>
......@@ -137,7 +139,7 @@
this.tableData = dataList
this.pagination.total = total
this.loading = false
}).finally(() => {
}).catch(() => {
this.loading = false
})
},
......@@ -159,7 +161,7 @@
this.searchList()
},
toAdd() {
this.$router.push({path: '/supplyManage/add', query: {modeType: "add"}});
this.$router.push({path:'/supplyManage/add'})
},
changeStatus(record) {
let par = {
......@@ -194,7 +196,6 @@
},
updateSupply(record) {
this.$router.push({path: '/supplyManage/add', query: {modeType: "update", id: record.id}});
console.log()
}
},
}
......
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