Compare commits
6 Commits
38eb6c221d
...
ab55d14f26
| Author | SHA1 | Date | |
|---|---|---|---|
| ab55d14f26 | |||
| 132514fe3d | |||
| 9cb7af2141 | |||
| 0de6841538 | |||
| 37c9ee3e0a | |||
| d84e20e561 |
@ -1,472 +1,50 @@
|
|||||||
import request from '@/utils/request'
|
import request from '@/utils/request'
|
||||||
|
|
||||||
|
|
||||||
// 获取当前商业用户票扣列表
|
|
||||||
// 相当于补差/bussiness/salemain/piAoKouLiSt
|
|
||||||
export function salemainpiAoKouList(data) {
|
|
||||||
return request({
|
|
||||||
url: '/bussiness/salemain/piAoKouLiSt',
|
|
||||||
method: 'post',
|
|
||||||
data: data,
|
|
||||||
isEncrypt: false
|
|
||||||
})
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
// 点击新增的时候先调用检查质保协议
|
|
||||||
export function salemaincheckQa(data) {
|
|
||||||
return request({
|
|
||||||
url: '/bussiness/salemain/checkQa',
|
|
||||||
method: 'post',
|
|
||||||
data: data,
|
|
||||||
isEncrypt: false
|
|
||||||
})
|
|
||||||
}
|
|
||||||
|
|
||||||
// 查询订单列表--商业用户
|
|
||||||
export function listsalemain(data,query) {
|
|
||||||
return request({
|
|
||||||
url: '/bussiness/salemain/list',
|
|
||||||
method: 'post',
|
|
||||||
data: data,
|
|
||||||
params: query,
|
|
||||||
isEncrypt: false
|
|
||||||
})
|
|
||||||
}
|
|
||||||
// 查询订单列表内部用户
|
|
||||||
export function listsalemainNB(data,query) {
|
|
||||||
return request({
|
|
||||||
url: '/bussiness/salemain/sysOrderList',
|
|
||||||
method: 'post',
|
|
||||||
data: data,
|
|
||||||
params: query,
|
|
||||||
isEncrypt: false
|
|
||||||
})
|
|
||||||
}
|
|
||||||
|
|
||||||
// 查询详细
|
|
||||||
export function salemainDetail(salemainId) {
|
|
||||||
return request({
|
|
||||||
url: '/bussiness/salemain/info?id=' + salemainId,
|
|
||||||
method: 'get',
|
|
||||||
isEncrypt: false
|
|
||||||
})
|
|
||||||
}
|
|
||||||
|
|
||||||
// 新增
|
|
||||||
export function addsalemain(data) {
|
|
||||||
return request({
|
|
||||||
url: '/bussiness/salemain/add',
|
|
||||||
method: 'post',
|
|
||||||
data: data,
|
|
||||||
isEncrypt: false
|
|
||||||
})
|
|
||||||
}
|
|
||||||
|
|
||||||
// 修改
|
|
||||||
export function updatesalemain(data) {
|
|
||||||
return request({
|
|
||||||
url: '/bussiness/salemain/edit',
|
|
||||||
method: 'post',
|
|
||||||
data: data,
|
|
||||||
isEncrypt: false
|
|
||||||
})
|
|
||||||
}
|
|
||||||
|
|
||||||
// 删除
|
|
||||||
export function delsalemain(id) {
|
|
||||||
return request({
|
|
||||||
url: '/bussiness/salemain/remove?ids=' +id,
|
|
||||||
method: 'post',
|
|
||||||
isEncrypt: false
|
|
||||||
})
|
|
||||||
}
|
|
||||||
|
|
||||||
// 查询商务审批列表
|
// 查询商务审批列表
|
||||||
export function mangerList(data,query) {
|
export const mangerList = (data, query) => {
|
||||||
return request({
|
return request({
|
||||||
|
method: 'post',
|
||||||
url: '/bussiness/salemain/mangerList',
|
url: '/bussiness/salemain/mangerList',
|
||||||
method: 'post',
|
|
||||||
data: data,
|
data: data,
|
||||||
params: query,
|
params: query,
|
||||||
isEncrypt: false
|
|
||||||
})
|
|
||||||
}
|
|
||||||
|
|
||||||
// 查询商务审批列表-张梦洁
|
|
||||||
export function specialMangerList(data,query) {
|
|
||||||
return request({
|
|
||||||
url: '/bussiness/salemain/specialMangerList',
|
|
||||||
method: 'post',
|
|
||||||
data: data,
|
|
||||||
params: query,
|
|
||||||
isEncrypt: false
|
|
||||||
})
|
|
||||||
}
|
|
||||||
|
|
||||||
// 查询商务审批-商务经理额度
|
|
||||||
export function getManagerCreditLine(query) {
|
|
||||||
return request({
|
|
||||||
url: '/bussiness/salemain/getManagerCreditLine',
|
|
||||||
method: 'post',
|
|
||||||
params: query,
|
|
||||||
isEncrypt: false
|
|
||||||
})
|
|
||||||
}
|
|
||||||
// 查询商务审批-商务经理额度
|
|
||||||
export function getAreaCreditLine(query) {
|
|
||||||
return request({
|
|
||||||
url: '/bussiness/salemain/getAreaCreditLine',
|
|
||||||
method: 'post',
|
|
||||||
params: query,
|
|
||||||
isEncrypt: false
|
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
// 商务经理审批时获取详情,下面的商品列表
|
// 商务经理审批时获取详情,下面的商品列表
|
||||||
export function businessManagerReviewGoodsList(salemainId) {
|
export const businessManagerReviewGoodsList = (salemainId) => {
|
||||||
return request({
|
return request({
|
||||||
url: '/bussiness/businessgoods/businessManagerReviewGoodsList?saleId=' + salemainId,
|
|
||||||
method: 'post',
|
method: 'post',
|
||||||
isEncrypt: false
|
url: '/bussiness/businessgoods/businessManagerReviewGoodsList',
|
||||||
|
params: {
|
||||||
|
saleId: salemainId
|
||||||
|
}
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
// 审批时获取详情-分开获取数据。分上面订单数据和下面商品数据。此接口为上面的订单数据
|
// 审批时获取详情-分开获取数据。分上面订单数据和下面商品数据。此接口为上面的订单数据
|
||||||
export function salemainDetailSWJL(query) {
|
export const salemainDetailSWJL = (query) => {
|
||||||
return request({
|
return request({
|
||||||
url: '/bussiness/salemain/detail?id=' + query.salemainId + '&isThisMonth=' + query.isThisMonth,
|
|
||||||
method: 'get',
|
method: 'get',
|
||||||
isEncrypt: false
|
url: '/bussiness/salemain/detail',
|
||||||
|
params: query
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
// 商务审批-审核
|
// 商务审批-审核
|
||||||
export function managerConfirm(data) {
|
export const managerConfirm = (query) => {
|
||||||
return request({
|
return request({
|
||||||
url: '/bussiness/salemain/managerConfirm?saleIds=' + data.saleIds + '&actionType=' + data.actionType,
|
|
||||||
method: 'post',
|
method: 'post',
|
||||||
isEncrypt: false
|
url: '/bussiness/salemain/managerConfirm',
|
||||||
|
params: query
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
// 商务审批-回退
|
// 商务审批-回退
|
||||||
export function managerRefuse(data) {
|
export const managerRefuse = (query) => {
|
||||||
return request({
|
return request({
|
||||||
url: '/bussiness/salemain/managerRefuse?saleIds=' + data.saleIds + '&actionType=' + data.actionType,
|
|
||||||
method: 'post',
|
method: 'post',
|
||||||
isEncrypt: false
|
url: '/bussiness/salemain/managerRefuse',
|
||||||
})
|
params: query
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
// 查询财务审批列表
|
|
||||||
export function financeList(data,query) {
|
|
||||||
return request({
|
|
||||||
url: '/bussiness/salemain/financeList',
|
|
||||||
method: 'post',
|
|
||||||
data: data,
|
|
||||||
params: query,
|
|
||||||
isEncrypt: false
|
|
||||||
})
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
// 财务审批-审核
|
|
||||||
export function financeConfirm(data) {
|
|
||||||
return request({
|
|
||||||
url: '/bussiness/salemain/financeConfirm?saleIds=' + data.saleIds,
|
|
||||||
method: 'post',
|
|
||||||
isEncrypt: false
|
|
||||||
})
|
|
||||||
}
|
|
||||||
|
|
||||||
// 财务审批-回退
|
|
||||||
export function financeConfirmRefuse(data) {
|
|
||||||
return request({
|
|
||||||
url: '/bussiness/salemain/financeConfirmRefuse?saleIds=' + data.saleIds,
|
|
||||||
method: 'post',
|
|
||||||
isEncrypt: false
|
|
||||||
})
|
|
||||||
}
|
|
||||||
|
|
||||||
// 订单审核-列表
|
|
||||||
export function orderList(data,query) {
|
|
||||||
return request({
|
|
||||||
url: '/bussiness/salemain/orderList',
|
|
||||||
method: 'post',
|
|
||||||
data: data,
|
|
||||||
params: query,
|
|
||||||
isEncrypt: false
|
|
||||||
})
|
|
||||||
}
|
|
||||||
|
|
||||||
// 订单审核-推送至OA-----state表示是否强制推送至OA,1是强制,0是不强制。
|
|
||||||
export function orderReviewSendOa(data) {
|
|
||||||
return request({
|
|
||||||
url: '/bussiness/salemain/orderReviewSendOa?saleIds=' + data.saleIds + '&companyId=' + data.companyId + '&state=0',
|
|
||||||
method: 'post',
|
|
||||||
isEncrypt: false
|
|
||||||
})
|
|
||||||
}
|
|
||||||
// 订单审核-强制推送至OA
|
|
||||||
export function orderReviewSendOaQZ(data) {
|
|
||||||
return request({
|
|
||||||
url: '/bussiness/salemain/orderReviewSendOa?saleIds=' + data.saleIds + '&companyId=' + data.companyId + '&state=1'+ '&psw=' + data.psw,
|
|
||||||
method: 'post',
|
|
||||||
isEncrypt: false,
|
|
||||||
|
|
||||||
})
|
|
||||||
}
|
|
||||||
|
|
||||||
// 订单审核-强制推送至分配
|
|
||||||
export function orderReviewForceOaToFenPei(data) {
|
|
||||||
return request({
|
|
||||||
// url: '/bussiness/salemain/orderReviewForceOa',
|
|
||||||
// 上面这个接口是参数用body里面传递的
|
|
||||||
url: '/bussiness/salemain/orderReviewForceOa?id=' + data.saleIds + '&psw=' + data.psw,
|
|
||||||
method: 'post',
|
|
||||||
// data:data,
|
|
||||||
// isEncrypt: true
|
|
||||||
})
|
|
||||||
}
|
|
||||||
|
|
||||||
// 订单审核-审核
|
|
||||||
export function orderReview(saleIds) {
|
|
||||||
return request({
|
|
||||||
url: '/bussiness/salemain/orderReview?ids=' + saleIds,
|
|
||||||
method: 'post',
|
|
||||||
isEncrypt: false
|
|
||||||
})
|
|
||||||
}
|
|
||||||
|
|
||||||
// 订单审核-回退
|
|
||||||
export function orderReviewBack(saleIds) {
|
|
||||||
return request({
|
|
||||||
url: '/bussiness/salemain/orderReviewBack?id=' + saleIds ,
|
|
||||||
method: 'post',
|
|
||||||
isEncrypt: false
|
|
||||||
})
|
|
||||||
}
|
|
||||||
|
|
||||||
// 账期审核
|
|
||||||
export function periodAudit(data) {
|
|
||||||
return request({
|
|
||||||
url: '/bussiness/salemain/periodAudit?ids=' + data,
|
|
||||||
method: 'post',
|
|
||||||
isEncrypt: false
|
|
||||||
})
|
|
||||||
}
|
|
||||||
|
|
||||||
// 额度审核
|
|
||||||
export function creditReview(data) {
|
|
||||||
return request({
|
|
||||||
url: '/bussiness/salemain/creditReview?ids=' + data,
|
|
||||||
method: 'post',
|
|
||||||
isEncrypt: false
|
|
||||||
})
|
|
||||||
}
|
|
||||||
|
|
||||||
// 更换仓库列表
|
|
||||||
export function changeWarehouseList(data) {
|
|
||||||
return request({
|
|
||||||
url: '/bussiness/salemain/changeWarehouseList?id=' + data ,
|
|
||||||
method: 'post',
|
|
||||||
isEncrypt: false
|
|
||||||
})
|
|
||||||
}
|
|
||||||
|
|
||||||
// 更换仓库
|
|
||||||
export function changeWarehouse(data) {
|
|
||||||
return request({
|
|
||||||
url: '/bussiness/salemain/changeWarehouse?ids=' + data.ids + '&wareHouseId=' + data.wareHouseId,
|
|
||||||
method: 'post',
|
|
||||||
isEncrypt: false
|
|
||||||
})
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
// 销售订单操作日志
|
|
||||||
export function salemainlogList(data,query) {
|
|
||||||
return request({
|
|
||||||
url: '/bussiness/salemainlog/list',
|
|
||||||
method: 'post',
|
|
||||||
data:data,
|
|
||||||
params: query,
|
|
||||||
isEncrypt: false
|
|
||||||
})
|
|
||||||
}
|
|
||||||
|
|
||||||
// 查询订单分配列表
|
|
||||||
export function disOrderListsalemain(data,query) {
|
|
||||||
return request({
|
|
||||||
url: '/bussiness/salemain/disOrderList',
|
|
||||||
method: 'post',
|
|
||||||
data: data,
|
|
||||||
params: query,
|
|
||||||
isEncrypt: false
|
|
||||||
})
|
|
||||||
}
|
|
||||||
|
|
||||||
// 订单分配-推送牛力(待推送分配状态推送至牛力状态)
|
|
||||||
export function SendNiuLi(id) {
|
|
||||||
return request({
|
|
||||||
url: '/bussiness/salemain/SendNiuLi?id=' + id,
|
|
||||||
method: 'post',
|
|
||||||
isEncrypt: false
|
|
||||||
})
|
|
||||||
}
|
|
||||||
|
|
||||||
// 订单分配-数量查询
|
|
||||||
export function disOrderGetDataNiuLi(data,query) {
|
|
||||||
return request({
|
|
||||||
url: '/bussiness/salemain/disOrderGetDataNiuLi',
|
|
||||||
method: 'post',
|
|
||||||
data: data,
|
|
||||||
params: query,
|
|
||||||
isEncrypt: false
|
|
||||||
})
|
|
||||||
}
|
|
||||||
|
|
||||||
// 查询订单分配详细--上面部分
|
|
||||||
export function disOrderDetail(salemainId) {
|
|
||||||
return request({
|
|
||||||
url: '/bussiness/salemain/disOrderDetail?id=' + salemainId,
|
|
||||||
method: 'post',
|
|
||||||
isEncrypt: false
|
|
||||||
})
|
|
||||||
}
|
|
||||||
|
|
||||||
// 查询订单分配列表--下面部分
|
|
||||||
export function disOrderDisDetailList(salemainId) {
|
|
||||||
return request({
|
|
||||||
url: '/bussiness/salemain/disOrderDisDetailList?saleId=' + salemainId,
|
|
||||||
method: 'post',
|
|
||||||
isEncrypt: false
|
|
||||||
})
|
|
||||||
}
|
|
||||||
|
|
||||||
// 查询订单分配库存列表--双击后的列表
|
|
||||||
export function disOrderStockList(data) {
|
|
||||||
return request({
|
|
||||||
url: '/bussiness/salemain/disOrderStockList?saleId=' + data.saleId + '&goodsId=' + data.goodsId + '&warehouseId=' + data.warehouseId,
|
|
||||||
method: 'post',
|
|
||||||
isEncrypt: false
|
|
||||||
})
|
|
||||||
}
|
|
||||||
//订单分配--添加
|
|
||||||
export function disOrderSave(data) {
|
|
||||||
return request({
|
|
||||||
url: '/bussiness/salemain/disOrderSave',
|
|
||||||
method: 'post',
|
|
||||||
data: data,
|
|
||||||
isEncrypt: false
|
|
||||||
})
|
|
||||||
}
|
|
||||||
//订单分配--提交
|
|
||||||
export function disOrderSubmit(data) {
|
|
||||||
return request({
|
|
||||||
url: '/bussiness/salemain/disOrderSubmit',
|
|
||||||
method: 'post',
|
|
||||||
data: data,
|
|
||||||
isEncrypt: false
|
|
||||||
})
|
|
||||||
}
|
|
||||||
|
|
||||||
//订单分配--回退
|
|
||||||
export function disOrderReturn(data) {
|
|
||||||
return request({
|
|
||||||
url: '/bussiness/salemain/disOrderReturn',
|
|
||||||
method: 'post',
|
|
||||||
data: data,
|
|
||||||
isEncrypt: false
|
|
||||||
})
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
// 发货管理-工厂列表
|
|
||||||
export function factoryList(data,query) {
|
|
||||||
return request({
|
|
||||||
url: '/bussiness/salemain/factoryList',
|
|
||||||
method: 'post',
|
|
||||||
data: data,
|
|
||||||
params: query,
|
|
||||||
isEncrypt: false
|
|
||||||
})
|
|
||||||
}
|
|
||||||
|
|
||||||
// 发货管理-三方列表
|
|
||||||
export function thirdList(data,query) {
|
|
||||||
return request({
|
|
||||||
url: '/bussiness/salemain/thirdList',
|
|
||||||
method: 'post',
|
|
||||||
data: data,
|
|
||||||
params: query,
|
|
||||||
isEncrypt: false
|
|
||||||
})
|
|
||||||
}
|
|
||||||
|
|
||||||
// 发货管理-数量查询
|
|
||||||
export function factoryGroupList(saleIds) {
|
|
||||||
return request({
|
|
||||||
url: '/bussiness/salemain/factoryGroupList?saleIds=' + saleIds,
|
|
||||||
method: 'post',
|
|
||||||
isEncrypt: false
|
|
||||||
})
|
|
||||||
}
|
|
||||||
|
|
||||||
// 发货管理-获取页面详情-上面部分
|
|
||||||
export function DeliverDetail(saleId) {
|
|
||||||
return request({
|
|
||||||
url: '/bussiness/salemain/DeliverDetail?saleId=' + saleId,
|
|
||||||
method: 'post',
|
|
||||||
isEncrypt: false
|
|
||||||
})
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
// 发货管理-获取页面列表-下面
|
|
||||||
export function DeliverDetailList(saleId) {
|
|
||||||
return request({
|
|
||||||
url: '/bussiness/salemain/DeliverDetailList?saleId=' + saleId,
|
|
||||||
method: 'post',
|
|
||||||
isEncrypt: false
|
|
||||||
})
|
|
||||||
}
|
|
||||||
|
|
||||||
// 发货管理-回退
|
|
||||||
export function DeliverBack(saleId) {
|
|
||||||
return request({
|
|
||||||
url: '/bussiness/salemain/DeliverBack?saleId=' + saleId,
|
|
||||||
method: 'post',
|
|
||||||
isEncrypt: false
|
|
||||||
})
|
|
||||||
}
|
|
||||||
// 发货管理-确认发货
|
|
||||||
export function DeliverSubmit(data) {
|
|
||||||
return request({
|
|
||||||
url: '/bussiness/salemain/DeliverSubmit?saleId=' + data.saleid + '&ckexecdate=' + data.ckexecdate,
|
|
||||||
method: 'post',
|
|
||||||
isEncrypt: false
|
|
||||||
})
|
|
||||||
}
|
|
||||||
|
|
||||||
// 发货管理-实际发货清单
|
|
||||||
export function getSaleDisDetail(saleid) {
|
|
||||||
return request({
|
|
||||||
url: '/bussiness/salemain/getSaleDisDetail?saleId=' + saleid,
|
|
||||||
method: 'post',
|
|
||||||
isEncrypt: false
|
|
||||||
})
|
|
||||||
}
|
|
||||||
// 发货管理-发票单
|
|
||||||
export function getInvoiceList(saleid) {
|
|
||||||
return request({
|
|
||||||
url: '/bussiness/salemain/getInvoiceList?saleId=' + saleid,
|
|
||||||
method: 'post',
|
|
||||||
isEncrypt: false
|
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|||||||
@ -5,6 +5,8 @@
|
|||||||
:class="index % 2 === 0 ? 'card-even' : 'card-odd'"
|
:class="index % 2 === 0 ? 'card-even' : 'card-odd'"
|
||||||
:extra="item.contractcode"
|
:extra="item.contractcode"
|
||||||
:title="item.usernames"
|
:title="item.usernames"
|
||||||
|
style="margin: 0;margin-bottom: 20px"
|
||||||
|
@click="handleDetail(item)"
|
||||||
>
|
>
|
||||||
<view class="context">
|
<view class="context">
|
||||||
<view class="label">
|
<view class="label">
|
||||||
@ -29,7 +31,7 @@
|
|||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script setup>
|
<script setup>
|
||||||
import {defineOptions, defineProps} from 'vue'
|
import {defineOptions, defineProps, getCurrentInstance} from 'vue'
|
||||||
import UniCard from "../../../uni_modules/uni-card/components/uni-card/uni-card.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 {formatDate} from "../../../uni_modules/uni-dateformat/components/uni-dateformat/date-format";
|
||||||
|
|
||||||
@ -37,22 +39,14 @@ defineOptions({
|
|||||||
name: 'ListItem'
|
name: 'ListItem'
|
||||||
})
|
})
|
||||||
|
|
||||||
|
const {proxy} = getCurrentInstance()
|
||||||
|
|
||||||
const props = defineProps(['items'])
|
const props = defineProps(['items'])
|
||||||
|
|
||||||
|
const handleDetail = (raw) => {
|
||||||
|
proxy.$tab.navigateTo(`/pages/work/BusinessApproval/OrderDetail?id=${raw.saleid}`)
|
||||||
|
}
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
<style lang="scss" scoped>
|
<style lang="scss" scoped>
|
||||||
.context {
|
|
||||||
display: grid;
|
|
||||||
grid-template-columns: repeat(2, minmax(0, 1fr));
|
|
||||||
gap: 10px;
|
|
||||||
font-size: 12px;
|
|
||||||
line-height: 20px;
|
|
||||||
|
|
||||||
.label {
|
|
||||||
display: flex;
|
|
||||||
gap: 6px;
|
|
||||||
font-size: 12px;
|
|
||||||
line-height: 20px;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
</style>
|
</style>
|
||||||
@ -1,472 +1,199 @@
|
|||||||
<template>
|
<template>
|
||||||
<view class="order-detail-container">
|
|
||||||
<!-- <view class="page-title">查看详细信息</view> -->
|
|
||||||
|
|
||||||
<!-- 基础信息区域 -->
|
<view>
|
||||||
<view class="info-section">
|
<uni-section
|
||||||
<uni-row class="info-grid">
|
:sub-title="queryParams.contractcode"
|
||||||
<uni-col >
|
:title="queryParams.user_name"
|
||||||
<view class="label">商业公司: {{contract.user_name}} </view>
|
padding="0 0 5px 10px"
|
||||||
</uni-col>
|
style="margin-bottom: 20px"
|
||||||
|
/>
|
||||||
|
|
||||||
</uni-row>
|
<MBCard style="margin: 15px">
|
||||||
<uni-row class="info-grid">
|
<view class="context">
|
||||||
<uni-col :span="12">
|
<view class="label">
|
||||||
<view class="label">制单日期:{{ contract.adddate}}</view>
|
<text>制单日期:</text>
|
||||||
</uni-col>
|
<text>{{ queryParams.adddate }}</text>
|
||||||
<uni-col :span="12">
|
|
||||||
<view class="label">合同编号:{{ contract.contractcode }}</view>
|
|
||||||
</uni-col>
|
|
||||||
</uni-row>
|
|
||||||
<uni-row class="info-grid">
|
|
||||||
<uni-col :span="12">
|
|
||||||
<view class="label">订单金额:{{ contract.contractmoney }}</view>
|
|
||||||
</uni-col>
|
|
||||||
<uni-col :span="12">
|
|
||||||
<view class="label">补差金额:{{ contract.user_name }}</view>
|
|
||||||
</uni-col>
|
|
||||||
</uni-row>
|
|
||||||
|
|
||||||
<uni-row class="info-grid">
|
|
||||||
<uni-col :span="12">
|
|
||||||
<view class="label">支付方式:{{ contract.ispaynow }}</view>
|
|
||||||
</uni-col>
|
|
||||||
<uni-col :span="12">
|
|
||||||
<view class="label">联系方式:{{ contract.ispaynow }}</view>
|
|
||||||
</uni-col>
|
|
||||||
</uni-row>
|
|
||||||
<uni-row class="info-grid">
|
|
||||||
<uni-col :span="12">
|
|
||||||
<view class="label required">*执行月份:</view>
|
|
||||||
<view class="select-container">
|
|
||||||
<uni-data-select
|
|
||||||
v-model="executionMonth"
|
|
||||||
:localdata="monthOptions"
|
|
||||||
popup-class="month-popup"
|
|
||||||
></uni-data-select>
|
|
||||||
</view>
|
</view>
|
||||||
</uni-col>
|
<view class="label">
|
||||||
<uni-col :span="12">
|
<text>支付方式:</text>
|
||||||
<view class="label">折后订单金额:{{ contract.piaokous }}</view>
|
<text>{{ queryParams.ispaynow }}</text>
|
||||||
</uni-col>
|
</view>
|
||||||
</uni-row>
|
<view class="label">
|
||||||
<uni-row class="info-grid">
|
<text>联系方式:</text>
|
||||||
<uni-col :span="12">
|
<text>{{ queryParams.phonenumber }}</text>
|
||||||
<view class="label">本月商务额度:{{ contract.contractmoney }}</view>
|
</view>
|
||||||
</uni-col>
|
<view class="label">
|
||||||
<uni-col :span="12">
|
<text>订单金额:</text>
|
||||||
<view class="label">本月商务可用:{{ contract.contractmoney }}</view>
|
<text>{{ formatPrice(queryParams.contractmoney) }}</text>
|
||||||
</uni-col>
|
</view>
|
||||||
</uni-row>
|
<view class="label">
|
||||||
<uni-row class="info-grid">
|
<text>补差金额:</text>
|
||||||
<uni-col :span="12">
|
<text>{{ formatPrice(queryParams.piaokou) }}</text>
|
||||||
<view class="label">本月大区额度:{{ contract.contractmoney }}</view>
|
</view>
|
||||||
</uni-col>
|
<view class="label">
|
||||||
<uni-col :span="12">
|
<text>折后订单金额:</text>
|
||||||
<view class="label">本月大区可用:{{ contract.contractmoney }}</view>
|
<text>{{ formatPrice(queryParams.piaokous) }}</text>
|
||||||
</uni-col>
|
|
||||||
</uni-row>
|
|
||||||
<uni-row class="info-grid">
|
|
||||||
<uni-col :span="12">
|
|
||||||
<view class="label">收货地址:{{ contract.place }}</view>
|
|
||||||
</uni-col>
|
|
||||||
|
|
||||||
</uni-row>
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
</view>
|
</view>
|
||||||
|
|
||||||
<!-- 商品信息区域 -->
|
<view class="label">
|
||||||
<view class="goods-section">
|
<text>本月商务额度:</text>
|
||||||
<view class="section-title">商品信息</view>
|
<text>{{ formatPrice(queryParams.budgetmoney1 ?? 0) }}</text>
|
||||||
|
</view>
|
||||||
<view v-if="goodsList.length === 0" class="no-data">
|
<view class="label">
|
||||||
暂无商品数据
|
<text>本月商务可用:</text>
|
||||||
|
<text>{{ formatPrice(queryParams.CAN ?? 0) }}</text>
|
||||||
|
</view>
|
||||||
|
<view class="label">
|
||||||
|
<text>本月大区额度:</text>
|
||||||
|
<text>{{ formatPrice(queryParams.budgetmoney_area ?? 0) }}</text>
|
||||||
|
</view>
|
||||||
|
<view class="label">
|
||||||
|
<text>本月大区可用:</text>
|
||||||
|
<text>{{ formatPrice(queryParams.CAN_area ?? 0) }}</text>
|
||||||
|
</view>
|
||||||
|
<view class="label">
|
||||||
|
<text>执行月份:</text>
|
||||||
|
<DictSelect v-model="queryParams.actionType" dict="dazhong_thismonthornext" disabled/>
|
||||||
|
</view>
|
||||||
</view>
|
</view>
|
||||||
|
|
||||||
<view v-else class="goods-double-column">
|
|
||||||
<view
|
<view
|
||||||
v-for="(goods, index) in goodsList"
|
style="display: flex;gap: 4px;font-size: 14px;color: #666;margin-bottom: 4px;font-weight: 500;flex-direction: column;">
|
||||||
:key="index"
|
<view style="width: 100px">收货地址:</view>
|
||||||
class="goods-item"
|
<view>{{ queryParams.place }}</view>
|
||||||
|
</view>
|
||||||
|
</MBCard>
|
||||||
|
|
||||||
|
<uni-section class="mb-10" padding="0 0 5px 10px" title="商品信息"/>
|
||||||
|
|
||||||
|
<uni-card
|
||||||
|
v-for="item in queryParams.goods"
|
||||||
|
:key="item.goodsname"
|
||||||
|
:title="item.goodsname"
|
||||||
>
|
>
|
||||||
<view class="goods-header">
|
<view class="context">
|
||||||
<text class="serial-number">{{ index + 1 }}</text>
|
<view class="label">
|
||||||
<text class="goods-name">{{ goods.goodsname }}</text>
|
<text>件装数:</text>
|
||||||
|
<text>{{ item.packingnum }}</text>
|
||||||
|
</view>
|
||||||
|
<view class="label">
|
||||||
|
<text>供应参考价:</text>
|
||||||
|
<text>{{ item.invoiceprice }}</text>
|
||||||
|
</view>
|
||||||
|
<view class="label">
|
||||||
|
<text>前三月平均数:</text>
|
||||||
|
<text>{{ item.mon3 }}</text>
|
||||||
|
</view>
|
||||||
|
<view class="label">
|
||||||
|
<text>采购数量:</text>
|
||||||
|
<text>{{ item.goodsnum }}</text>
|
||||||
|
</view>
|
||||||
|
<view class="label">
|
||||||
|
<text>小计:</text>
|
||||||
|
<text>{{ formatPrice(item.allmoney) }}</text>
|
||||||
|
</view>
|
||||||
|
<view class="label">
|
||||||
|
<text>使用票扣:</text>
|
||||||
|
<text>{{ formatPrice(item.piaokou) }}</text>
|
||||||
|
</view>
|
||||||
|
<view class="label">
|
||||||
|
<text>税率:</text>
|
||||||
|
<text>{{ item.taxrate }}</text>
|
||||||
|
</view>
|
||||||
|
</view>
|
||||||
|
</uni-card>
|
||||||
|
|
||||||
|
|
||||||
|
<view style="display: flex;margin: 0 15px;justify-content: space-between;">
|
||||||
|
<uni-tag
|
||||||
|
style="font-size: 20px;line-height: 28px;font-weight: bold;padding: 5px 25px;"
|
||||||
|
text="回退"
|
||||||
|
type="success"
|
||||||
|
@click="handleCallBack"
|
||||||
|
/>
|
||||||
|
<uni-tag
|
||||||
|
style="font-size: 20px;line-height: 28px;font-weight: bold;padding: 5px 25px;"
|
||||||
|
text="审核"
|
||||||
|
type="primary"
|
||||||
|
@click="handleSubmit"
|
||||||
|
/>
|
||||||
</view>
|
</view>
|
||||||
|
|
||||||
<view class="goods-content">
|
|
||||||
<!-- 件装数和供应参考价在一行 -->
|
|
||||||
<uni-row class="info-row">
|
|
||||||
<uni-col :span="12" class="info-pair">
|
|
||||||
<view class="label">件装数:{{ goods.packingnum }}</view>
|
|
||||||
<!-- <view class="value">{{ goods.packCount }}</view> -->
|
|
||||||
</uni-col>
|
|
||||||
<uni-col :span="12" class="info-pair">
|
|
||||||
<view class="label">供应参考价:{{ goods.invoiceprice }}</view>
|
|
||||||
<!-- <view class="value">{{ goods.referencePrice }}</view> -->
|
|
||||||
</uni-col>
|
|
||||||
</uni-row>
|
|
||||||
|
|
||||||
<!-- 前三月平均数和采购数量在一行 -->
|
|
||||||
<uni-row class="info-row">
|
|
||||||
<uni-col :span="12" class="info-pair">
|
|
||||||
<view class="label">前三月平均数:{{ goods.mon3 }}</view>
|
|
||||||
<!-- <view class="value">{{ goods.average }}</view> -->
|
|
||||||
</uni-col>
|
|
||||||
<uni-col :span="12" class="info-pair">
|
|
||||||
<view class="label">采购数量:{{ goods.goodsnum }}</view>
|
|
||||||
<!-- <view class="value quantity">{{ goods.quantity }}</view> -->
|
|
||||||
</uni-col>
|
|
||||||
</uni-row>
|
|
||||||
|
|
||||||
<!-- 小计和使用票扣在一行 -->
|
|
||||||
<uni-row class="info-row">
|
|
||||||
<uni-col :span="12" class="info-pair">
|
|
||||||
<view class="label">小计:{{ goods.allmoney }}</view>
|
|
||||||
<!-- <view class="value total">{{ goods.subtotal }}</view> -->
|
|
||||||
</uni-col>
|
|
||||||
<uni-col :span="12" class="info-pair">
|
|
||||||
<view class="label">使用票扣:{{ goods.piaokou }}</view>
|
|
||||||
<!-- <view class="value">{{ goods.ticketDeduction }}</view> -->
|
|
||||||
</uni-col>
|
|
||||||
</uni-row>
|
|
||||||
|
|
||||||
<!-- 税率单独一行 -->
|
|
||||||
<uni-row class="info-row">
|
|
||||||
<uni-col :span="12" class="info-pair">
|
|
||||||
<view class="label">税率:{{ goods.taxrate }}</view>
|
|
||||||
<!-- <view class="value">{{ goods.taxRate }}</view> -->
|
|
||||||
</uni-col>
|
|
||||||
<uni-col :span="12" class="info-pair empty"></uni-col>
|
|
||||||
</uni-row>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
|
|
||||||
<!-- 操作按钮 -->
|
|
||||||
<view class="action-buttons">
|
|
||||||
<button @click="goBack" class="btn btn-secondary">回退</button>
|
|
||||||
<button @click="review" class="btn btn-primary">审核</button>
|
|
||||||
</view>
|
|
||||||
</view>
|
</view>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script setup>
|
<script setup>
|
||||||
import { onMounted, ref } from 'vue'
|
import {getCurrentInstance, onMounted, ref} from 'vue'
|
||||||
import { contractData,goodsData } from './detailData.js'
|
import {onLoad} from '@dcloudio/uni-app'
|
||||||
|
import {
|
||||||
|
businessManagerReviewGoodsList,
|
||||||
|
managerConfirm,
|
||||||
|
managerRefuse,
|
||||||
|
salemainDetailSWJL
|
||||||
|
} from "../../../api/BusinessApproval";
|
||||||
|
import UniCard from "../../../uni_modules/uni-card/components/uni-card/uni-card.vue";
|
||||||
|
import UniTag from "../../../uni_modules/uni-tag/components/uni-tag/uni-tag.vue";
|
||||||
|
import {formatPrice} from "../../../utils/utils";
|
||||||
|
import DictSelect from "../../../components/DictSelect/DictSelect.vue";
|
||||||
|
import MBCard from "../../../components/MB/MBCard.vue";
|
||||||
|
|
||||||
// 基础信息
|
const id = ref('')
|
||||||
const contract = ref({})
|
const queryParams = ref({})
|
||||||
|
|
||||||
const monthOptions = ref([
|
|
||||||
{ value: 0, text: '本月执行' },
|
|
||||||
{ value: 1, text: '下月执行' }
|
|
||||||
])
|
|
||||||
onMounted(()=>{
|
|
||||||
contract.value = contractData.data[0]
|
|
||||||
console.log(contract.value)
|
|
||||||
goodsList.value = goodsData.data
|
|
||||||
|
|
||||||
|
const {proxy} = getCurrentInstance()
|
||||||
|
|
||||||
|
onLoad((options) => {
|
||||||
|
id.value = options.id
|
||||||
})
|
})
|
||||||
// 商品列表数据
|
|
||||||
const goodsList = ref([
|
|
||||||
])
|
|
||||||
|
|
||||||
// 操作方法
|
onMounted(async () => {
|
||||||
const goBack = () => {
|
const actionType = new Date().getDate() < 25 ? '1' : '0'
|
||||||
console.log("回退操作")
|
const {data} = await salemainDetailSWJL({
|
||||||
// 成功提示 (类似 ElMessage.success)
|
id: id.value,
|
||||||
uni.showToast({
|
isThisMonth: actionType
|
||||||
title: '回退成功!',
|
})
|
||||||
icon: 'success',
|
queryParams.value = data[0]
|
||||||
duration: 2000
|
|
||||||
});
|
const {data: goods} = await businessManagerReviewGoodsList(id.value)
|
||||||
|
queryParams.value = {
|
||||||
|
...queryParams.value,
|
||||||
|
actionType: actionType,
|
||||||
|
goods: goods
|
||||||
|
}
|
||||||
|
})
|
||||||
|
|
||||||
|
|
||||||
|
const handleCallBack = () => {
|
||||||
|
managerRefuse({
|
||||||
|
saleIds: queryParams.value.saleid,
|
||||||
|
actionType: queryParams.value.actionType
|
||||||
|
}).then(() => {
|
||||||
|
proxy.$modal.msgSuccess('回退成功!');
|
||||||
|
proxy.$tab.navigateTo('/pages/work/BusinessApproval/index')
|
||||||
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
const review = () => {
|
const handleSubmit = () => {
|
||||||
console.log("审核操作")
|
const orderAmount = parseFloat(queryParams.value.contractmoney || 0);
|
||||||
// 成功提示 (类似 ElMessage.success)
|
const swAvailable = parseFloat(queryParams.value.CAN || 0);
|
||||||
uni.showToast({
|
const dqAvailable = parseFloat(queryParams.value.CAN_area || 0);
|
||||||
title: '审核成功!',
|
|
||||||
icon: 'success',
|
if (orderAmount > swAvailable) {
|
||||||
duration: 2000
|
proxy.$modal.msgError(`订单金额 ${orderAmount} 大于本月商务可用额度 ${swAvailable}`);
|
||||||
});
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
const cancel = () => {
|
if (orderAmount > dqAvailable) {
|
||||||
console.log("取消操作")
|
proxy.$modal.msgError(`订单金额 ${orderAmount} 大于本月大区可用额度 ${dqAvailable}`);
|
||||||
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
managerConfirm({
|
||||||
|
saleIds: queryParams.value.saleid,
|
||||||
|
actionType: queryParams.value.actionType
|
||||||
|
}).then(() => {
|
||||||
|
proxy.$modal.msgSuccess('审核成功!');
|
||||||
|
proxy.$tab.navigateTo('/pages/work/BusinessApproval/index')
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
<style lang="scss" scoped>
|
|
||||||
.order-detail-container {
|
|
||||||
padding: 16px;
|
|
||||||
background-color: #f5f5f5;
|
|
||||||
min-height: 100vh;
|
|
||||||
}
|
|
||||||
|
|
||||||
.page-title {
|
|
||||||
text-align: center;
|
|
||||||
margin-bottom: 24px;
|
|
||||||
color: #333;
|
|
||||||
font-size: 18px;
|
|
||||||
font-weight: 600;
|
|
||||||
padding: 12px 0;
|
|
||||||
background: #fff;
|
|
||||||
border-radius: 12px;
|
|
||||||
box-shadow: 0 2px 8px rgba(0,0,0,0.1);
|
|
||||||
}
|
|
||||||
|
|
||||||
/* 基础信息网格布局 */
|
|
||||||
.info-section {
|
|
||||||
background: #fff;
|
|
||||||
border-radius: 12px;
|
|
||||||
padding: 16px;
|
|
||||||
margin-bottom: 20px;
|
|
||||||
box-shadow: 0 2px 8px rgba(0,0,0,0.1);
|
|
||||||
}
|
|
||||||
|
|
||||||
.info-grid {
|
|
||||||
:deep(.uni-row) {
|
|
||||||
display: flex;
|
|
||||||
flex-wrap: wrap;
|
|
||||||
|
|
||||||
}
|
|
||||||
.info-value {
|
|
||||||
font-size: 15px;
|
|
||||||
color: #333;
|
|
||||||
font-weight: 500;
|
|
||||||
display: flex;
|
|
||||||
justify-content: flex-end;
|
|
||||||
|
|
||||||
}
|
|
||||||
|
|
||||||
margin-bottom: 20rpx;
|
|
||||||
margin-top: 20rpx;
|
|
||||||
}
|
|
||||||
|
|
||||||
.info-item {
|
|
||||||
margin-bottom: 12px;
|
|
||||||
}
|
|
||||||
|
|
||||||
.label {
|
|
||||||
font-size: 14px;
|
|
||||||
color: #666;
|
|
||||||
margin-bottom: 4px;
|
|
||||||
font-weight: 500;
|
|
||||||
}
|
|
||||||
|
|
||||||
.required::after {
|
|
||||||
content: '*';
|
|
||||||
color: #f56c6c;
|
|
||||||
margin-left: 2px;
|
|
||||||
}
|
|
||||||
|
|
||||||
// .info-value {
|
|
||||||
// font-size: 15px;
|
|
||||||
// color: #333;
|
|
||||||
// font-weight: 500;
|
|
||||||
// display: flex;
|
|
||||||
// justify-content: flex-end;
|
|
||||||
|
|
||||||
// }
|
|
||||||
|
|
||||||
.amount {
|
|
||||||
color: #f56c6c;
|
|
||||||
font-weight: 600;
|
|
||||||
}
|
|
||||||
|
|
||||||
.select-container {
|
|
||||||
width: 100%;
|
|
||||||
}
|
|
||||||
|
|
||||||
:deep(.uni-data-select__text) {
|
|
||||||
padding: 8px 12px;
|
|
||||||
border: 1px solid #ddd;
|
|
||||||
border-radius: 8px;
|
|
||||||
background-color: #fff;
|
|
||||||
}
|
|
||||||
|
|
||||||
:deep(.month-popup) {
|
|
||||||
min-width: 120px;
|
|
||||||
}
|
|
||||||
|
|
||||||
/* 商品信息区域 */
|
|
||||||
.goods-section {
|
|
||||||
background: #fff;
|
|
||||||
border-radius: 12px;
|
|
||||||
padding: 16px;
|
|
||||||
margin-bottom: 20px;
|
|
||||||
box-shadow: 0 2px 8px rgba(0,0,0,0.1);
|
|
||||||
}
|
|
||||||
|
|
||||||
.section-title {
|
|
||||||
font-size: 16px;
|
|
||||||
color: #333;
|
|
||||||
margin: 0 0 16px 0;
|
|
||||||
padding-bottom: 8px;
|
|
||||||
border-bottom: 1px solid #eee;
|
|
||||||
font-weight: 600;
|
|
||||||
}
|
|
||||||
|
|
||||||
.no-data {
|
|
||||||
text-align: center;
|
|
||||||
color: #999;
|
|
||||||
padding: 40px 0;
|
|
||||||
font-size: 14px;
|
|
||||||
}
|
|
||||||
|
|
||||||
/* 商品双栏布局 */
|
|
||||||
.goods-double-column {
|
|
||||||
display: flex;
|
|
||||||
flex-direction: column;
|
|
||||||
gap: 12px;
|
|
||||||
}
|
|
||||||
|
|
||||||
.goods-item {
|
|
||||||
border: 1px solid #eee;
|
|
||||||
border-radius: 12px;
|
|
||||||
overflow: hidden;
|
|
||||||
background: #fafafa;
|
|
||||||
}
|
|
||||||
|
|
||||||
.goods-header {
|
|
||||||
background: #409eff;
|
|
||||||
color: white;
|
|
||||||
padding: 10px 16px;
|
|
||||||
display: flex;
|
|
||||||
align-items: center;
|
|
||||||
gap: 12px;
|
|
||||||
}
|
|
||||||
|
|
||||||
.serial-number {
|
|
||||||
display: inline-flex;
|
|
||||||
align-items: center;
|
|
||||||
justify-content: center;
|
|
||||||
width: 20px;
|
|
||||||
height: 20px;
|
|
||||||
background: rgba(255,255,255,0.2);
|
|
||||||
border-radius: 50%;
|
|
||||||
font-size: 12px;
|
|
||||||
font-weight: 600;
|
|
||||||
}
|
|
||||||
|
|
||||||
.goods-name {
|
|
||||||
font-size: 15px;
|
|
||||||
font-weight: 600;
|
|
||||||
flex: 1;
|
|
||||||
}
|
|
||||||
|
|
||||||
/* 商品内容区域 */
|
|
||||||
.goods-content {
|
|
||||||
padding: 12px 16px;
|
|
||||||
}
|
|
||||||
|
|
||||||
.info-row {
|
|
||||||
display: flex;
|
|
||||||
margin-bottom: 8px;
|
|
||||||
}
|
|
||||||
|
|
||||||
.info-pair {
|
|
||||||
flex: 1;
|
|
||||||
padding: 0 8px;
|
|
||||||
}
|
|
||||||
|
|
||||||
.info-pair .label {
|
|
||||||
font-size: 14px;
|
|
||||||
color: #666;
|
|
||||||
margin-bottom: 2px;
|
|
||||||
}
|
|
||||||
|
|
||||||
.info-pair .value {
|
|
||||||
font-size: 14px;
|
|
||||||
color: #333;
|
|
||||||
font-weight: 500;
|
|
||||||
text-align: right;
|
|
||||||
}
|
|
||||||
|
|
||||||
.quantity {
|
|
||||||
color: #409eff;
|
|
||||||
font-weight: 600;
|
|
||||||
}
|
|
||||||
|
|
||||||
.total {
|
|
||||||
color: #f56c6c;
|
|
||||||
font-weight: 600;
|
|
||||||
}
|
|
||||||
|
|
||||||
.empty {
|
|
||||||
visibility: hidden;
|
|
||||||
}
|
|
||||||
|
|
||||||
/* 操作按钮 */
|
|
||||||
.action-buttons {
|
|
||||||
display: flex;
|
|
||||||
justify-content: center;
|
|
||||||
gap: 12px;
|
|
||||||
padding: 16px 0;
|
|
||||||
background: #fff;
|
|
||||||
border-radius: 12px;
|
|
||||||
box-shadow: 0 2px 8px rgba(0,0,0,0.1);
|
|
||||||
}
|
|
||||||
|
|
||||||
.btn {
|
|
||||||
padding: 12px 24px;
|
|
||||||
border: none;
|
|
||||||
border-radius: 8px;
|
|
||||||
font-size: 15px;
|
|
||||||
font-weight: 500;
|
|
||||||
cursor: pointer;
|
|
||||||
min-width: 80px;
|
|
||||||
text-align: center;
|
|
||||||
flex: 1;
|
|
||||||
}
|
|
||||||
|
|
||||||
.btn-primary {
|
|
||||||
background: #409eff;
|
|
||||||
color: white;
|
|
||||||
}
|
|
||||||
|
|
||||||
.btn-secondary {
|
|
||||||
background: #67c23a;
|
|
||||||
color: white;
|
|
||||||
}
|
|
||||||
|
|
||||||
.btn-outline {
|
|
||||||
background: #fff;
|
|
||||||
color: #333;
|
|
||||||
border: 1px solid #ddd;
|
|
||||||
}
|
|
||||||
|
|
||||||
/* 响应式设计 */
|
|
||||||
@media (max-width: 768px) {
|
|
||||||
.order-detail-container {
|
|
||||||
padding: 12px;
|
|
||||||
}
|
|
||||||
|
|
||||||
.info-item {
|
|
||||||
margin-bottom: 10px;
|
|
||||||
}
|
|
||||||
|
|
||||||
.info-pair {
|
|
||||||
padding: 0 4px;
|
|
||||||
}
|
|
||||||
|
|
||||||
.action-buttons {
|
|
||||||
flex-direction: column;
|
|
||||||
}
|
|
||||||
|
|
||||||
.btn {
|
|
||||||
width: 100%;
|
|
||||||
margin-bottom: 8px;
|
|
||||||
}
|
|
||||||
|
|
||||||
.btn:last-child {
|
|
||||||
margin-bottom: 0;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
</style>
|
|
||||||
@ -22,46 +22,12 @@
|
|||||||
@pagination="handleQuery"
|
@pagination="handleQuery"
|
||||||
/>
|
/>
|
||||||
</view>
|
</view>
|
||||||
<!-- <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">-->
|
|
||||||
<!-- <view class="demo-uni-col dark">生产单位: {{ contract.companyName }}</view>-->
|
|
||||||
<!-- </uni-col>-->
|
|
||||||
<!-- <uni-col :span="12">-->
|
|
||||||
<!-- <view class="demo-uni-col light">合同编号: {{ contract.contractcode }}</view>-->
|
|
||||||
<!-- </uni-col>-->
|
|
||||||
<!-- </uni-row>-->
|
|
||||||
<!-- <uni-row class="demo-uni-row">-->
|
|
||||||
<!-- <uni-col :span="12">-->
|
|
||||||
<!-- <view class="demo-uni-col dark">制单日期: {{ formatDate(contract.adddate) }}</view>-->
|
|
||||||
<!-- </uni-col>-->
|
|
||||||
<!-- <uni-col :span="12">-->
|
|
||||||
<!-- <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">-->
|
|
||||||
<!-- <view class="demo-uni-col light">区域: {{ contract.areaName }}</view>-->
|
|
||||||
<!-- </uni-col>-->
|
|
||||||
<!-- </uni-row>-->
|
|
||||||
<!-- </uni-card>-->
|
|
||||||
<!-- </view>-->
|
|
||||||
</view>
|
</view>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script setup>
|
<script setup>
|
||||||
|
|
||||||
import {computed, getCurrentInstance, onMounted, ref} from "vue"
|
import {getCurrentInstance, onMounted, ref} from "vue"
|
||||||
import {contractData} from "./data.js"
|
|
||||||
import UniForms from "../../../uni_modules/uni-forms/components/uni-forms/uni-forms.vue";
|
import UniForms from "../../../uni_modules/uni-forms/components/uni-forms/uni-forms.vue";
|
||||||
import UniFormsItem from "../../../uni_modules/uni-forms/components/uni-forms-item/uni-forms-item.vue";
|
import UniFormsItem from "../../../uni_modules/uni-forms/components/uni-forms-item/uni-forms-item.vue";
|
||||||
import DictSelect from "../../../components/DictSelect/DictSelect.vue";
|
import DictSelect from "../../../components/DictSelect/DictSelect.vue";
|
||||||
@ -102,132 +68,5 @@ onMounted(async () => {
|
|||||||
await handleQuery()
|
await handleQuery()
|
||||||
})
|
})
|
||||||
|
|
||||||
|
|
||||||
// ===========================================================================================
|
|
||||||
|
|
||||||
// 表单数据
|
|
||||||
const baseFormData = ref({})
|
|
||||||
const paymentValue = ref('')
|
|
||||||
const companyValue = ref(0)
|
|
||||||
|
|
||||||
// 筛选选项
|
|
||||||
const paymentOptions = ref([
|
|
||||||
{value: 0, text: "全部支付方式"},
|
|
||||||
{value: 1, text: "账期支付"},
|
|
||||||
{value: 2, text: "预付款"}
|
|
||||||
])
|
|
||||||
|
|
||||||
const companyOptions = ref([
|
|
||||||
{value: 0, text: "全部生产单位"},
|
|
||||||
{value: 1, text: "浙江大冢制药有限公司"},
|
|
||||||
{value: 2, text: "广东大冢制药有限公司"}
|
|
||||||
])
|
|
||||||
|
|
||||||
// 合同数据
|
|
||||||
const contracts = 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(() => {
|
|
||||||
contracts.value = contractData.rows
|
|
||||||
})
|
|
||||||
|
|
||||||
// 格式化日期
|
|
||||||
function formatDate(dateString) {
|
|
||||||
if (!dateString) return '未知日期'
|
|
||||||
return dateString.split(' ')[0]
|
|
||||||
}
|
|
||||||
|
|
||||||
// 筛选合同
|
|
||||||
function filterContracts(e) {
|
|
||||||
console.log("筛选条件变化:", e)
|
|
||||||
// 计算属性会自动更新,无需额外操作
|
|
||||||
}
|
|
||||||
|
|
||||||
// 跳转到详情页
|
|
||||||
function gotoDetail(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/BusinessApproval/OrderDetail')
|
|
||||||
}
|
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
<style lang="scss" scoped>
|
|
||||||
.container {
|
|
||||||
padding: 10px;
|
|
||||||
background-color: #f5f7fa;
|
|
||||||
min-height: 100vh;
|
|
||||||
}
|
|
||||||
|
|
||||||
.example {
|
|
||||||
padding: 10px;
|
|
||||||
background: #fff;
|
|
||||||
border-radius: 8px;
|
|
||||||
margin-bottom: 15px;
|
|
||||||
box-shadow: 0 2px 6px rgba(0, 0, 0, 0.05);
|
|
||||||
}
|
|
||||||
|
|
||||||
:deep(.uni-section .uni-section-header) {
|
|
||||||
padding: 0;
|
|
||||||
}
|
|
||||||
|
|
||||||
:deep(.uni-card) {
|
|
||||||
padding: 0 !important;
|
|
||||||
margin: 10px 0 !important;
|
|
||||||
border-radius: 8px;
|
|
||||||
box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
|
|
||||||
}
|
|
||||||
|
|
||||||
:deep(.uni-card__content) {
|
|
||||||
padding: 12px !important;
|
|
||||||
}
|
|
||||||
|
|
||||||
.demo-uni-row {
|
|
||||||
padding: 5px 0;
|
|
||||||
font-size: 14px;
|
|
||||||
}
|
|
||||||
|
|
||||||
.demo-uni-col {
|
|
||||||
padding: 2px 0;
|
|
||||||
|
|
||||||
&.dark {
|
|
||||||
color: #333;
|
|
||||||
font-weight: 500;
|
|
||||||
}
|
|
||||||
|
|
||||||
&.light {
|
|
||||||
color: #666;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
.card-even {
|
|
||||||
border-left: 4px solid #2979ff;
|
|
||||||
}
|
|
||||||
|
|
||||||
.card-odd {
|
|
||||||
border-left: 4px solid #19be6b;
|
|
||||||
}
|
|
||||||
|
|
||||||
.no-data {
|
|
||||||
text-align: center;
|
|
||||||
padding: 40px 0;
|
|
||||||
color: #999;
|
|
||||||
font-size: 16px;
|
|
||||||
}
|
|
||||||
</style>
|
|
||||||
File diff suppressed because one or more lines are too long
3
utils/utils.js
Normal file
3
utils/utils.js
Normal file
@ -0,0 +1,3 @@
|
|||||||
|
export const formatPrice = (value) => {
|
||||||
|
return Number(value).toFixed(2)
|
||||||
|
}
|
||||||
Loading…
x
Reference in New Issue
Block a user