UNPKG

zhsz-common-ui

Version:

This template should help get you started developing with Vue 3 in Vite. The template uses Vue 3 `<script setup>` SFCs, check out the [script setup docs](https://v3.vuejs.org/api/sfc-script-setup.html#sfc-script-setup) to learn more.

56 lines (50 loc) 1.65 kB
import {getAllCourier} from "@/api/supplierSide/expressCompany.js"; import {getPlatFormList} from "@/api/system/platform.js"; import {queryKingdeeBillList} from '@/api/scm/payment' import {getAllWarehouseList} from '@/api/warehouse/index.js' import {getUserListBySelect} from "@/api/system/user.js"; export default function () { const state = reactive({ courierList: [], platFormList: [], costItemList: [], warehouseList: [], userList: [] }) const getCourier = async () => { const res = await getAllCourier() const {code, data} = res if (code === 200) { state.courierList = data } } const getPlatList = async () => { const res = await getPlatFormList() const {code, data} = res if (code === 200) { state.platFormList = data } } const getCostItemList = async () => { const res = await queryKingdeeBillList() const {code, data} = res if (code === 200) { state.costItemList = data } } const getWareHouseList = async () => { const res = await getAllWarehouseList({}) const {code, data} = res if (code === 200) { state.warehouseList = data } } const getUserList = async () => { const res = await getUserListBySelect() const {code, data} = res if (code === 200) { state.userList = data } } return {getCourier, state, getPlatList, getCostItemList, getWareHouseList, getUserList} }