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

fencang
anthonywj 3 years ago
commit 6ffbf5845e

@ -4,7 +4,7 @@ import axios from "../../utils/axios";
export function getHospitalUserList(query) {
return axios({
url: '/admin/auth/admin/hospitalUserList',
method: 'get',
params: query
method: 'post',
data: query
})
}

@ -107,8 +107,8 @@ export function exportJson(query) {
export function warehouseUserList(query) {
return axios({
url: '/warehouse/inout/warehouseUserList',
method: 'get',
params: query
method: 'post',
data: query
});
}
@ -116,8 +116,8 @@ export function warehouseUserList(query) {
export function warehouseBussinessTypeList(query) {
return axios({
url: '/warehouse/inout/warehouseBussniessTypeList',
method: 'get',
params: query
method: 'post',
data: query
});
}

@ -332,14 +332,14 @@ export default {
//
warehouseUserList(query).then((res) => {
this.entrustUserArray = [];
this.entrustUserArray = res.data;
this.entrustUserArray = res.data.list;
}).catch((error) => {
this.$message.error("用户数据加载失败")
});
//
warehouseBussinessTypeList(query).then((res) => {
this.entrustBusArray = res.data;
this.entrustBusArray = res.data.list;
}).catch((error) => {
this.$message.error("单据类型数据加载失败")

@ -236,6 +236,14 @@
</template>
</el-table-column>
</el-table>
<el-pagination
:page-size="userQuery.limit"
@current-change="loadUserList"
layout="prev, pager, next"
:total="userTotal"
:current-page="userQuery.page"
>
</el-pagination>
</el-card>
<el-card style="width: 49%; float: right; margin-left: 0px;">
@ -273,6 +281,15 @@
</template>
</el-table-column>
</el-table>
<el-pagination
:page-size="busQuery.limit"
@current-change="loadBusList"
layout="prev, pager, next"
:total="busTotal"
:current-page="busQuery.page"
>
</el-pagination>
</el-card>
</div>
@ -296,6 +313,15 @@
<el-table-column label="用户名" prop="employeeName" fixed></el-table-column>
</el-table>
<el-pagination
:page-size="hospitalUserQuery.limit"
@current-change="getHospitalUser"
layout="prev, pager, next"
:total="hospitalUserTotal"
:current-page="hospitalUserQuery.page"
>
</el-pagination>
<div slot="footer" class="dialog-footer">
<el-button @click.native="userFormVisible = !userFormVisible"
>取消
@ -328,6 +354,15 @@
<el-table-column label="单据类型名称" prop="name" fixed></el-table-column>
</el-table>
<el-pagination
:page-size="bussinessTypeQuery.limit"
@current-change="getBussinessType"
layout="prev, pager, next"
:total="bussinessTypeTotal"
:current-page="bussinessTypeQuery.page"
>
</el-pagination>
<div slot="footer" class="dialog-footer">
<el-button @click.native="bussinessTypeFormVisible = !bussinessTypeFormVisible"
>取消
@ -831,6 +866,29 @@ export default {
configParms: {},
subData: {},
subFromName: "add",
userQuery: {
code: null,
page: 1,
limit: 10
},
userTotal: 0,
busQuery: {
code: null,
page: 1,
limit: 10
},
busTotal: 0,
hospitalUserQuery: {
page: 1,
limit: 10
},
hospitalUserTotal: 0,
bussinessTypeQuery: {
enabled: true,
page: 1,
limit: 10
},
bussinessTypeTotal: 0
};
},
methods: {
@ -842,6 +900,8 @@ export default {
name: "",
status: "",
};
this.userQuery.page = 1;
this.busQuery.page = 1;
this.getList();
},
onSubmit() {
@ -1222,19 +1282,36 @@ export default {
},
loadLinkData(row) {
let query = {
code: row.code
this.userQuery.page = 1;
this.busQuery.page = 1;
this.userQuery.code = row.code;
this.busQuery.code = row.code;
//
this.loadUserList();
//
this.loadBusList();
},
loadUserList(val) {
if (val != null) {
this.userQuery.page = val;
}
//
warehouseUserList(query).then((res) => {
this.userData = res.data;
warehouseUserList(this.userQuery).then((res) => {
this.userData = res.data.list;
this.userTotal = res.data.total;
}).catch((error) => {
this.$message.error("用户数据加载失败")
});
},
loadBusList(val) {
if (val != null) {
this.busQuery.page = val;
}
//
warehouseBussinessTypeList(query).then((res) => {
this.bussinessTypeData = res.data;
warehouseBussinessTypeList(this.busQuery).then((res) => {
this.bussinessTypeData = res.data.list;
this.busTotal = res.data.total;
}).catch((error) => {
this.$message.error("单据类型数据加载失败")
});
@ -1249,24 +1326,56 @@ export default {
this.$message.error("请先选择当前分库!")
} else {
this.userFormVisible = true;
getHospitalUserList().then((res) => {
this.selectUserList = [];
this.userList = res.data;
var that = this;
that.$nextTick(() => {
if (that.$refs.checkUserList) {
that.$refs.checkUserList.clearSelection();
this.hospitalUserQuery.page = 1;
this.getHospitalUser();
}
},
getHospitalUser(val) {
if (val != null) {
this.hospitalUserQuery.page = val;
}
getHospitalUserList(this.hospitalUserQuery).then((res) => {
this.selectUserList = [];
this.userList = res.data.list;
this.hospitalUserTotal = res.data.total;
var that = this;
that.$nextTick(() => {
if (that.$refs.checkUserList) {
that.$refs.checkUserList.clearSelection();
}
that.userList.forEach(row => {
for (let j in that.userData) {
if (row.id == that.userData[j].userid) {
that.$refs.checkUserList.toggleRowSelection(row, true);
}
}
that.userList.forEach(row => {
for (let j in that.userData) {
if (row.id == that.userData[j].userid) {
that.$refs.checkUserList.toggleRowSelection(row, true);
}
});
})
});
},
getBussinessType(val) {
if (val != null) {
this.bussinessTypeQuery.page = val;
}
getJoinBussinessType(this.bussinessTypeQuery).then((res) => {
this.selectBussinessTypeList = [];
this.bussinessTypeList = res.data.list;
var that = this;
that.$nextTick(() => {
if (that.$refs.typeList) {
that.$refs.typeList.clearSelection();
}
that.bussinessTypeList.forEach(row => {
for (let j in that.bussinessTypeData) {
if (row.action == that.bussinessTypeData[j].action) {
that.$refs.typeList.toggleRowSelection(row, true);
}
});
})
}
});
});
}
}).catch((error) => {
});
},
handleUserSelectionChange(row) {
let _this = this;
@ -1330,28 +1439,8 @@ export default {
this.$message.error("请先选择当前分库!")
} else {
this.bussinessTypeFormVisible = true;
let query = {
enabled: true
};
getJoinBussinessType(query).then((res) => {
this.selectBussinessTypeList = [];
this.bussinessTypeList = res.data.list;
var that = this;
that.$nextTick(() => {
if (that.$refs.typeList) {
that.$refs.typeList.clearSelection();
}
that.bussinessTypeList.forEach(row => {
for (let j in that.bussinessTypeData) {
if (row.action == that.bussinessTypeData[j].action) {
that.$refs.typeList.toggleRowSelection(row, true);
}
}
});
});
}).catch((error) => {
});
this.bussinessTypeQuery.page = 1;
this.getBussinessType();
}
},
addBussinessTypeData() {

Loading…
Cancel
Save