Merge branch 'main' of http://106.15.139.36:30000/bestunion/Otsuka-APP
* 'main' of http://106.15.139.36:30000/bestunion/Otsuka-APP: 更新 readme.txt 订单管理列表 订单管理
This commit is contained in:
commit
56db1ccfb7
@ -8,6 +8,16 @@ export function listsalemain(data,query) {
|
|||||||
|
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// 新增订单时获取货主/system/dept/productListWithUserId
|
||||||
|
export function productListWithUserId() {
|
||||||
|
return request({
|
||||||
|
url: '/system/dept/productListWithUserId',
|
||||||
|
method: 'get',
|
||||||
|
isEncrypt: false
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
||||||
// 查询s生产单位列表
|
// 查询s生产单位列表
|
||||||
export function listproductList(data,query) {
|
export function listproductList(data,query) {
|
||||||
return request({
|
return request({
|
||||||
@ -35,6 +45,16 @@ export function getsalemaincheckAmount(queryParams) {
|
|||||||
// isEncrypt: false
|
// isEncrypt: false
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
// 获取当前商业用户票扣列表
|
||||||
|
// 相当于补差
|
||||||
|
export function salemainpiAoKouList(data) {
|
||||||
|
return request({
|
||||||
|
url: '/bussiness/salemain/piAoKouLiSt',
|
||||||
|
method: 'post',
|
||||||
|
data: data,
|
||||||
|
isEncrypt: false
|
||||||
|
})
|
||||||
|
}
|
||||||
// 新增
|
// 新增
|
||||||
export function addsalemain(data) {
|
export function addsalemain(data) {
|
||||||
return request({
|
return request({
|
||||||
@ -73,7 +93,6 @@ export function businessManagerReviewGoodsList(salemainId) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
// 删除
|
// 删除
|
||||||
export function delsalemain(id) {
|
export function delsalemain(id) {
|
||||||
return request({
|
return request({
|
||||||
|
|||||||
@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"pinia-plugin-persistedstate": "^4.5.0",
|
"pinia-plugin-persistedstate": "^4.7.1",
|
||||||
"radash": "^12.1.1"
|
"radash": "^12.1.1"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
178
pages/work/OrderManager/ListItem.vue
Normal file
178
pages/work/OrderManager/ListItem.vue
Normal file
@ -0,0 +1,178 @@
|
|||||||
|
<template>
|
||||||
|
<uni-card
|
||||||
|
v-for="(item,index) in items"
|
||||||
|
:key="item.saleid"
|
||||||
|
:class="index % 2 === 0 ? 'card-even' : 'card-odd'"
|
||||||
|
:extra="item.contractcode"
|
||||||
|
:title="item.usernames"
|
||||||
|
style="margin: 0;margin-bottom: 20px"
|
||||||
|
@click="handleDetail(item)"
|
||||||
|
>
|
||||||
|
<view class="context">
|
||||||
|
<view class="label">
|
||||||
|
<text>货主:</text>
|
||||||
|
<text>{{ item.companyName }}</text>
|
||||||
|
</view>
|
||||||
|
<view class="label">
|
||||||
|
<text>金额:</text>
|
||||||
|
<text>{{ formatPrice(item.contractmoney) }}</text>
|
||||||
|
</view>
|
||||||
|
<view class="label">
|
||||||
|
<text>订单类型:</text>
|
||||||
|
<view>
|
||||||
|
<dict-tag :options="orderTypeList" :value="item.type"/>
|
||||||
|
</view>
|
||||||
|
</view>
|
||||||
|
<view class="label">
|
||||||
|
<text>制单日期:</text>
|
||||||
|
<text>{{ formatDate(item.adddate, 'yyyy-MM-dd') }}</text>
|
||||||
|
</view>
|
||||||
|
<view class="label">
|
||||||
|
<text>状态:</text>
|
||||||
|
<text>
|
||||||
|
<text>{{ item.stateText }}</text>
|
||||||
|
</text>
|
||||||
|
</view>
|
||||||
|
<view class="label">
|
||||||
|
<text>操作:</text>
|
||||||
|
<view class="action-buttons">
|
||||||
|
<button type='primary' :plain="true" @click="Edit(item)" class="btn">编辑</button>
|
||||||
|
<button type='warn'
|
||||||
|
plain='true'
|
||||||
|
@click="deleteData(item)"
|
||||||
|
class="btn"
|
||||||
|
v-if="item.state == 1 || item.state == -1 || item.state == -2"
|
||||||
|
>删除</button>
|
||||||
|
</view>
|
||||||
|
</view>
|
||||||
|
</view>
|
||||||
|
|
||||||
|
</uni-card>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<script setup>
|
||||||
|
import {defineOptions, defineProps, getCurrentInstance,computed,onMounted, ref} from 'vue'
|
||||||
|
import UniCard from "../../../uni_modules/uni-card/components/uni-card/uni-card.vue";
|
||||||
|
import {formatDate} from "../../../uni_modules/uni-dateformat/components/uni-dateformat/date-format";
|
||||||
|
import {formatPrice} from "../../../utils/utils";
|
||||||
|
import DictTag from "../../../components/dict-tag/dict-tag.vue";
|
||||||
|
|
||||||
|
import {delsalemain} from "../../../api/orderManager/index.js"
|
||||||
|
|
||||||
|
const {proxy} = getCurrentInstance()
|
||||||
|
|
||||||
|
// const {order_state, dazhong_dingdan_type} = proxy.useDict(['order_state', 'dazhong_dingdan_type'])
|
||||||
|
|
||||||
|
import {getDicts} from "../../../api/system/dict/data.js"
|
||||||
|
|
||||||
|
defineOptions({
|
||||||
|
name: 'ListItem'
|
||||||
|
})
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
const props = defineProps(['items'])
|
||||||
|
|
||||||
|
const stateList = ref([])
|
||||||
|
const orderTypeList = ref([])
|
||||||
|
// 初始化数据
|
||||||
|
onMounted(async () => {
|
||||||
|
try {
|
||||||
|
await getDictData()
|
||||||
|
} finally {
|
||||||
|
}
|
||||||
|
})
|
||||||
|
|
||||||
|
const Edit = async (row) => {
|
||||||
|
try {
|
||||||
|
console.log(row,'当前行数据')
|
||||||
|
//具体逻辑
|
||||||
|
|
||||||
|
|
||||||
|
} catch (error) {
|
||||||
|
console.error('失败:', error)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
// 删除
|
||||||
|
const deleteData = async (row) => {
|
||||||
|
uni.showModal({
|
||||||
|
title: '删除确认',
|
||||||
|
content: `确定删除合同 ${row.contractcode || ''} 吗?`,
|
||||||
|
confirmText: '确定',
|
||||||
|
cancelText: '取消',
|
||||||
|
confirmColor: '#DD524D',
|
||||||
|
success: async (res) => {
|
||||||
|
if (res.confirm) {
|
||||||
|
try {
|
||||||
|
uni.showLoading({
|
||||||
|
title: '删除中...',
|
||||||
|
mask: true
|
||||||
|
})
|
||||||
|
|
||||||
|
await delsalemain(row.saleid)
|
||||||
|
|
||||||
|
uni.hideLoading()
|
||||||
|
uni.showToast({
|
||||||
|
title: '删除成功',
|
||||||
|
icon: 'success'
|
||||||
|
})
|
||||||
|
|
||||||
|
// 触发父组件刷新
|
||||||
|
proxy.$emit('refresh')
|
||||||
|
|
||||||
|
} catch (error) {
|
||||||
|
uni.hideLoading()
|
||||||
|
console.error('删除失败:', error)
|
||||||
|
uni.showToast({
|
||||||
|
title: '删除失败',
|
||||||
|
icon: 'error'
|
||||||
|
})
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
||||||
|
//获取字典数据
|
||||||
|
const getDictData = async () => {
|
||||||
|
try {
|
||||||
|
const [stateRes, typeRes] = await Promise.all([
|
||||||
|
getDicts("order_state"),
|
||||||
|
getDicts("dazhong_dingdan_type")
|
||||||
|
])
|
||||||
|
|
||||||
|
stateList.value = stateRes.data.map(item => {
|
||||||
|
return {
|
||||||
|
value: item.dictValue,
|
||||||
|
text: item.dictLabel
|
||||||
|
}
|
||||||
|
})
|
||||||
|
|
||||||
|
orderTypeList.value = typeRes.data
|
||||||
|
} catch (error) {
|
||||||
|
console.error('获取字典数据失败:', error)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
const handleDetail = (row) => {
|
||||||
|
proxy.$tab.navigateTo(`/pages/work/OrderManager/components/EditData?id=${row.saleid}`)
|
||||||
|
}
|
||||||
|
</script>
|
||||||
|
|
||||||
|
<style lang="scss" scoped>
|
||||||
|
:deep().uni-app-tag-span{
|
||||||
|
font-size:12px
|
||||||
|
}
|
||||||
|
button{font-size: 12px;margin:0 5px;}
|
||||||
|
.btn{
|
||||||
|
padding-left:6px;
|
||||||
|
padding-right: 6px;
|
||||||
|
line-height:2;
|
||||||
|
}
|
||||||
|
/* 操作按钮 */
|
||||||
|
.action-buttons {
|
||||||
|
display: flex;
|
||||||
|
justify-content: center;
|
||||||
|
}
|
||||||
|
</style>
|
||||||
@ -740,7 +740,7 @@ const toShowBucha = () => {
|
|||||||
.goods-header {
|
.goods-header {
|
||||||
background: #409eff;
|
background: #409eff;
|
||||||
color: white;
|
color: white;
|
||||||
padding: 10px 16px;
|
padding: 5px 8px;
|
||||||
display: flex;
|
display: flex;
|
||||||
align-items: center;
|
align-items: center;
|
||||||
gap: 12px;
|
gap: 12px;
|
||||||
|
|||||||
@ -448,7 +448,7 @@ const goCancel = () => {
|
|||||||
.goods-header {
|
.goods-header {
|
||||||
background: #409eff;
|
background: #409eff;
|
||||||
color: white;
|
color: white;
|
||||||
padding: 10px 16px;
|
padding: 5px 8px;
|
||||||
display: flex;
|
display: flex;
|
||||||
align-items: center;
|
align-items: center;
|
||||||
gap: 12px;
|
gap: 12px;
|
||||||
|
|||||||
File diff suppressed because it is too large
Load Diff
@ -26,7 +26,16 @@ export default {
|
|||||||
piaokoutype: "运费补差",
|
piaokoutype: "运费补差",
|
||||||
shortname: "MPT20",
|
shortname: "MPT20",
|
||||||
goodsname: "盐酸丙卡特罗片(美普清)20",
|
goodsname: "盐酸丙卡特罗片(美普清)20",
|
||||||
piaokou: 8.00
|
piaokou: 10000.01
|
||||||
|
},
|
||||||
|
{
|
||||||
|
piaokouid: 102,
|
||||||
|
goodsid: 3, // 对应盐酸丙卡特罗片(美普清)20
|
||||||
|
applydate: "2024-01-17",
|
||||||
|
piaokoutype: "运费补差",
|
||||||
|
shortname: "MPT20",
|
||||||
|
goodsname: "盐酸丙卡特罗片(美普清)20",
|
||||||
|
piaokou: 20000.02
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
piaokouid: 3,
|
piaokouid: 3,
|
||||||
|
|||||||
@ -1,9 +1,8 @@
|
|||||||
<template>
|
<template>
|
||||||
<view class="container">
|
<view class="container">
|
||||||
<view class="example">
|
<MBCard>
|
||||||
<uni-forms ref="baseForm" :modelValue="baseFormData" label-width="20vw">
|
<uni-forms ref="baseForm" :modelValue="queryParams">
|
||||||
|
<uni-forms-item label="货主">
|
||||||
<uni-forms-item label="生产单位">
|
|
||||||
<uni-data-select
|
<uni-data-select
|
||||||
v-model="queryParams.CompanyId"
|
v-model="queryParams.CompanyId"
|
||||||
:clear="true"
|
:clear="true"
|
||||||
@ -11,7 +10,6 @@
|
|||||||
text-field="deptName"
|
text-field="deptName"
|
||||||
value-field="deptId"
|
value-field="deptId"
|
||||||
@change="getTableData"
|
@change="getTableData"
|
||||||
|
|
||||||
/>
|
/>
|
||||||
</uni-forms-item>
|
</uni-forms-item>
|
||||||
<uni-forms-item label="状态">
|
<uni-forms-item label="状态">
|
||||||
@ -29,53 +27,27 @@
|
|||||||
placeholder="请输入合同编号"
|
placeholder="请输入合同编号"
|
||||||
@confirm="getTableData"/>
|
@confirm="getTableData"/>
|
||||||
</uni-forms-item>
|
</uni-forms-item>
|
||||||
<!-- <uni-forms-item label="合同编号" >
|
|
||||||
<view class="uni-form-item uni-column">
|
|
||||||
<input class="uni-input" focus placeholder="自动获得焦点" />
|
|
||||||
</view>
|
|
||||||
</uni-forms-item> -->
|
|
||||||
</uni-forms>
|
</uni-forms>
|
||||||
<button type="primary" @click="gotoNewAdd">新增</button>
|
|
||||||
</view>
|
|
||||||
|
|
||||||
<view v-if="filteredContracts.length === 0" class="no-data">
|
<button
|
||||||
<text>暂无匹配的合同数据</text>
|
type="primary"
|
||||||
</view>
|
@click="gotoNewAdd"
|
||||||
|
v-if="userType === '01' || userType === '02'"
|
||||||
<view v-else>
|
|
||||||
<uni-card
|
|
||||||
v-for="(contract, index) in filteredContracts"
|
|
||||||
:key="contract.saleid"
|
|
||||||
:class="index % 2 === 0 ? 'card-even' : 'card-odd'"
|
|
||||||
:title="contract.usernames"
|
|
||||||
@click="gotoDetail(contract)"
|
|
||||||
>
|
>
|
||||||
<uni-row class="demo-uni-row">
|
新增
|
||||||
<uni-col :span="12">
|
</button>
|
||||||
<view class="demo-uni-col dark">生产单位: {{ contract.companyName }}</view>
|
</MBCard>
|
||||||
</uni-col>
|
|
||||||
<uni-col :span="12">
|
<MBLoading v-if="loading"/>
|
||||||
<view class="demo-uni-col light">合同编号: {{ contract.contractcode }}</view>
|
<view v-else>
|
||||||
</uni-col>
|
<ListItem :items="tableData" />
|
||||||
</uni-row>
|
<MBPagination
|
||||||
<uni-row class="demo-uni-row">
|
v-if="total > 0"
|
||||||
<uni-col :span="12">
|
v-model:limit="paging.pageSize"
|
||||||
<view class="demo-uni-col dark">制单日期: {{ formatDate(contract.adddate) }}</view>
|
v-model:page="paging.pageNum"
|
||||||
</uni-col>
|
:total="total"
|
||||||
<uni-col :span="12">
|
@pagination="handleQuery"
|
||||||
<view class="demo-uni-col light">订单金额: {{ contract.contractmoney.toFixed(2) }}</view>
|
/>
|
||||||
</uni-col>
|
|
||||||
</uni-row>
|
|
||||||
<uni-row class="demo-uni-row">
|
|
||||||
<uni-col :span="12">
|
|
||||||
<view class="demo-uni-col dark">状态: {{ contract.stateText }}</view>
|
|
||||||
</uni-col>
|
|
||||||
<uni-col :span="12" style="display: flex;">
|
|
||||||
<view class="demo-uni-col light">订单类型:</view>
|
|
||||||
<dict-tag :options="orderTypeList" :value="contract.type" style="color: red;"/>
|
|
||||||
</uni-col>
|
|
||||||
</uni-row>
|
|
||||||
</uni-card>
|
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
</template>
|
</template>
|
||||||
@ -84,9 +56,17 @@
|
|||||||
import {listproductList, listsalemain} from "../../../api/orderManager/index.js"
|
import {listproductList, listsalemain} from "../../../api/orderManager/index.js"
|
||||||
import {computed, getCurrentInstance, onMounted, ref} from "vue"
|
import {computed, getCurrentInstance, onMounted, ref} from "vue"
|
||||||
import {getDicts} from "../../../api/system/dict/data.js"
|
import {getDicts} from "../../../api/system/dict/data.js"
|
||||||
// import DictTag from '@/components/dict-tag/dict-tag.vue';
|
|
||||||
import {useOrderManagerStore} from "../../../store/modules/orderManager.js"
|
import {useOrderManagerStore} from "../../../store/modules/orderManager.js"
|
||||||
// import { log } from "console"
|
|
||||||
|
import MBCard from "../../../components/MB/MBCard.vue";
|
||||||
|
import MBPagination from "../../../components/MB/MBPagination.vue";
|
||||||
|
import MBLoading from "../../../components/MB/MBLoading.vue";
|
||||||
|
import ListItem from "./ListItem.vue";
|
||||||
|
import { getUserProfile } from "@/api/system/user"
|
||||||
|
|
||||||
|
|
||||||
|
const userType = ref()
|
||||||
|
|
||||||
const {proxy} = getCurrentInstance()
|
const {proxy} = getCurrentInstance()
|
||||||
// 表单数据
|
// 表单数据
|
||||||
const baseFormData = ref({})
|
const baseFormData = ref({})
|
||||||
@ -94,11 +74,15 @@ const baseFormData = ref({})
|
|||||||
const orderTypeList = ref([])
|
const orderTypeList = ref([])
|
||||||
const paymentValue = ref(0)
|
const paymentValue = ref(0)
|
||||||
const companyValue = ref(0)
|
const companyValue = ref(0)
|
||||||
|
|
||||||
|
// 添加加载状态
|
||||||
|
const loading = ref(true)
|
||||||
|
const total = ref(0)
|
||||||
const paging = ref({
|
const paging = ref({
|
||||||
// 页码
|
// 页码
|
||||||
pageNum: 1,
|
pageNum: 1,
|
||||||
// 分页数量
|
// 分页数量
|
||||||
pageSize: 999,
|
pageSize: 2,
|
||||||
isAsc: 'descending',
|
isAsc: 'descending',
|
||||||
orderByColumn: 'adddate'
|
orderByColumn: 'adddate'
|
||||||
})
|
})
|
||||||
@ -107,47 +91,30 @@ const queryParams = ref({
|
|||||||
state: "0,1,-1,2,-2,3,-3,9,10,11,12,-12,13,-13,14,15,16",
|
state: "0,1,-1,2,-2,3,-3,9,10,11,12,-12,13,-13,14,15,16",
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
// 筛选选项
|
|
||||||
// const stateList = ref([
|
|
||||||
// { value: '0', text: "未提交" },
|
|
||||||
// { value: '1', text: "待商务审核" },
|
|
||||||
// { value: '-1', text: "商务退回" },
|
|
||||||
// { value: '2', text: "待财务审核" },
|
|
||||||
// { value: '-2', text: "财务退回" },
|
|
||||||
// { value:'3', text: "待审核" },
|
|
||||||
// { value: '-3', text: "审核退回" },
|
|
||||||
// { value: '9', text: "待推送分配" },
|
|
||||||
// { value: '10', text: "待牛力分配" },
|
|
||||||
// { value: '11', text: "牛力推送失败" },
|
|
||||||
// ])
|
|
||||||
const stateList = ref([])
|
const stateList = ref([])
|
||||||
const companyOptions = ref([])
|
const companyOptions = ref([])
|
||||||
|
|
||||||
// 合同数据
|
// 合同数据
|
||||||
const contracts = ref([])
|
const tableData = ref([])
|
||||||
|
|
||||||
// 过滤后的合同数据
|
|
||||||
const filteredContracts = computed(() => {
|
|
||||||
let result = contracts.value
|
|
||||||
|
|
||||||
// 根据生产单位筛选
|
|
||||||
if (companyValue.value === 1) {
|
|
||||||
result = result.filter(contract => contract.companyName.includes('浙江'))
|
|
||||||
} else if (companyValue.value === 2) {
|
|
||||||
result = result.filter(contract => contract.companyName.includes('广东'))
|
|
||||||
}
|
|
||||||
|
|
||||||
// 可以根据支付方式添加更多筛选逻辑
|
|
||||||
|
|
||||||
return result
|
|
||||||
})
|
|
||||||
|
|
||||||
// 初始化数据
|
// 初始化数据
|
||||||
onMounted(() => {
|
onMounted(async () => {
|
||||||
getDictData()
|
try {
|
||||||
getTableData()
|
loading.value = true
|
||||||
getDeptLists()
|
await getDictData()
|
||||||
|
await getDeptLists()
|
||||||
|
await getUser()
|
||||||
|
await getTableData()
|
||||||
|
} finally {
|
||||||
|
loading.value = false
|
||||||
|
}
|
||||||
})
|
})
|
||||||
|
function getUser() {
|
||||||
|
getUserProfile().then(response => {
|
||||||
|
userType.value = response.data.userType
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
||||||
// 格式化日期
|
// 格式化日期
|
||||||
function formatDate(dateString) {
|
function formatDate(dateString) {
|
||||||
@ -156,49 +123,55 @@ function formatDate(dateString) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
//获取字典数据
|
//获取字典数据
|
||||||
const getDictData = () => {
|
const getDictData = async () => {
|
||||||
getDicts("order_state").then(res => {
|
try {
|
||||||
console.log('order_state', res.data)
|
const [stateRes, typeRes] = await Promise.all([
|
||||||
stateList.value = res.data.map(item => {
|
getDicts("order_state"),
|
||||||
|
getDicts("dazhong_dingdan_type")
|
||||||
|
])
|
||||||
|
stateList.value = stateRes.data.map(item => {
|
||||||
return {
|
return {
|
||||||
value: item.dictValue,
|
value: item.dictValue,
|
||||||
text: item.dictLabel
|
text: item.dictLabel
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
})
|
|
||||||
getDicts("dazhong_dingdan_type").then(res => {
|
|
||||||
console.log('dazhong_dingdan_type', res.data)
|
|
||||||
orderTypeList.value = res.data
|
|
||||||
})
|
|
||||||
|
|
||||||
|
orderTypeList.value = typeRes.data
|
||||||
|
} catch (error) {
|
||||||
|
console.error('获取字典数据失败:', error)
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
//获取列表数据
|
//获取列表数据
|
||||||
const getTableData = () => {
|
const getTableData = async () => {
|
||||||
|
try {
|
||||||
console.log(queryParams.value)
|
loading.value = true
|
||||||
listsalemain(queryParams.value, paging.value).then(res => {
|
const data = await listsalemain(queryParams.value, paging.value)
|
||||||
|
total.value = data.total
|
||||||
contracts.value = res.rows
|
tableData.value = data.rows
|
||||||
// total.value = res.total;
|
} catch (error) {
|
||||||
});
|
console.error('获取数据失败:', error)
|
||||||
|
} finally {
|
||||||
|
loading.value = false
|
||||||
}
|
}
|
||||||
const getDeptLists = () => {
|
}
|
||||||
listproductList().then(res => {
|
|
||||||
|
const getDeptLists = async () => {
|
||||||
|
try {
|
||||||
|
const res = await listproductList()
|
||||||
companyOptions.value = res.data.map(item => {
|
companyOptions.value = res.data.map(item => {
|
||||||
return {
|
return {
|
||||||
value: item.deptId,
|
value: item.deptId,
|
||||||
text: item.deptName
|
text: item.deptName
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
console.log('companyOptions.value', companyOptions.value)
|
} catch (error) {
|
||||||
});
|
console.error('获取部门列表失败:', error)
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// 筛选合同
|
// 筛选合同
|
||||||
function filterContracts(e) {
|
function filtertableData(e) {
|
||||||
console.log("筛选条件变化:", e)
|
console.log("筛选条件变化:", e)
|
||||||
// 计算属性会自动更新,无需额外操作
|
// 计算属性会自动更新,无需额外操作
|
||||||
}
|
}
|
||||||
@ -211,9 +184,6 @@ const handleInput = (e) => {
|
|||||||
// 跳转到详情页
|
// 跳转到详情页
|
||||||
function gotoDetail(contract) {
|
function gotoDetail(contract) {
|
||||||
console.log("查看合同详情:", contract)
|
console.log("查看合同详情:", contract)
|
||||||
// proxy.$tab.navigateTo('/pages/work/yonghu/detail')
|
|
||||||
// proxy.$tab.navigateTo(`/pages/work/yonghu/detail?saleid=${contract.saleid}`)
|
|
||||||
// proxy.$tab.navigateTo('pages/work/OrderManager/OrderDetail')
|
|
||||||
//存储要传的值到pinia
|
//存储要传的值到pinia
|
||||||
useOrderManagerStore().addOrder(contract)
|
useOrderManagerStore().addOrder(contract)
|
||||||
console.log('数据', useOrderManagerStore().orders)
|
console.log('数据', useOrderManagerStore().orders)
|
||||||
@ -226,7 +196,6 @@ function gotoDetail(contract) {
|
|||||||
url: "/pages/work/OrderManager/components/LookData"
|
url: "/pages/work/OrderManager/components/LookData"
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
const gotoNewAdd = () => {
|
const gotoNewAdd = () => {
|
||||||
@ -234,14 +203,43 @@ const gotoNewAdd = () => {
|
|||||||
url: "/pages/work/OrderManager/components/NewAdd"
|
url: "/pages/work/OrderManager/components/NewAdd"
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
const handleQuery = async () => {
|
||||||
|
try {
|
||||||
|
loading.value = true
|
||||||
|
const data = await listsalemain(queryParams.value, paging.value)
|
||||||
|
total.value = data.total
|
||||||
|
tableData.value = data.rows
|
||||||
|
} catch (error) {
|
||||||
|
console.error('获取数据失败:', error)
|
||||||
|
} finally {
|
||||||
|
loading.value = false
|
||||||
|
}
|
||||||
|
}
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
<style lang="scss" scoped>
|
<style lang="scss" scoped>
|
||||||
|
/* 加载动画容器 */
|
||||||
|
.loading-container {
|
||||||
|
display: flex;
|
||||||
|
flex-direction: column;
|
||||||
|
justify-content: center;
|
||||||
|
align-items: center;
|
||||||
|
padding: 40px 0;
|
||||||
|
min-height: 300px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.loading-text {
|
||||||
|
margin-top: 10px;
|
||||||
|
color: #666;
|
||||||
|
font-size: 14px;
|
||||||
|
}
|
||||||
|
|
||||||
.custom-input {
|
.custom-input {
|
||||||
border: 1px solid #ccc;
|
border: 1px solid #ccc;
|
||||||
border-radius: 4px;
|
border-radius: 4px;
|
||||||
padding: 5px;
|
padding: 5px;
|
||||||
height: 35px;
|
height: 35px;
|
||||||
|
font-size: 12px;
|
||||||
}
|
}
|
||||||
|
|
||||||
.container {
|
.container {
|
||||||
|
|||||||
@ -1 +1 @@
|
|||||||
第一次vue3,提交,提交提交。我从git上修改了
|
第一次vue3,提交,提交提交。我从git上修改了,测试修改一下
|
||||||
Loading…
x
Reference in New Issue
Block a user