| 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496 |
- <template>
- <view class="app-content">
- <view v-if="!$util.isEmpty(detailInfo)" class="info-content_box">
- <view class="title"> 供货商 </view>
- <view class="address-des_bx content-box">
- <view>
- <view> {{ detailInfo.supplierName }} {{ detailInfo.supplierMobile }} </view>
- <view class="">
- {{ detailInfo.supplierAddress}}
- </view>
- </view>
- <view>
- <i @click="callUp(detailInfo.supplierMobile)" class="iconfont icondianhua1" ></i>
- </view>
- </view>
- <view class="title"> 单据信息 </view>
- <view class="bills-info_box content-box">
- <view class="order-info_box">
- <view>订单日期:</view>
- <view>{{ detailInfo.addTime }}</view>
- </view>
- <view class="order-info_box">
- <view>订单编码:</view>
- <view>{{ detailInfo.orderSn }}</view>
- <view class="price">
- <button @click="copy(detailInfo.orderSn)" class="admin-button-com default" > 复制 </button>
- </view>
- </view>
- <view class="order-info_box">
- <view>入库人员:</view>
- <view>{{ detailInfo.adminName }}</view>
- </view>
- <view class="order-info_box">
- <view>入库日期:</view>
- <view>{{ detailInfo.entryTime }}</view>
- </view>
- <view class="order-info_box">
- <view>状态:</view>
- <view>{{
- detailInfo.status==1?'待付款'
- :detailInfo.status==2?'待配送'
- :detailInfo.status==3?'配送中'
- :detailInfo.status==4?'已签收'
- :detailInfo.status==5?'已入库'
- :detailInfo.status==6?'已取消'
- :'已退款'
- }}</view>
- </view>
- <view v-if="detailInfo.refund == 2" class="order-info_box">
- <view>累计退款:</view>
- <view style="color:red;font-weight:bold;font-size:30upx;">{{parseFloat(detailInfo.tkPrice)}}</view>
- <view class="price" v-if="detailInfo.refund==2">
- <text @click="pageTo({url: '/pagesPurchase/refundList',query: {orderSn: detailInfo.orderSn}})" style="font-weight:normal;color:#3385FF;">退款记录</text>
- </view>
- </view>
- </view>
- <view class="bills-info_box content-box" style="margin-top:18upx;">
- <view class="order-info_box" v-if="detailInfo.debt == 1">
- <view>结算状态:</view>
- <view style="color:red;">欠款</view>
- <view class="price">
-
- <text @click="goToClear(detailInfo)" style="font-weight:normal;color:#3385FF;">查看全部欠款</text>
- </view>
- </view>
- <view class="order-info_box" v-else>
- <view>结算状态:</view>
- <view v-if="detailInfo.clearId > 0">已结清</view>
- <view class="price" v-if="detailInfo.clearId > 0">
- <button @click="pageTo({url: '/admin/clear/info',query: {id: detailInfo.clearId}})" class="admin-button-com">查看结账单</button>
- </view>
- <view v-if="detailInfo.clearId == 0">--</view>
- </view>
- </view>
- <view class="title">
- 商品信息
- <text @click="printAllLabel(detailInfo)" style="float:right;font-weight:normal;color:#3385FF;">打全部标签</text>
- <text @click="goRefund(detailInfo)" style="float:right;font-weight:normal;color:#3385FF;margin-right:60upx;">申请退款</text>
- </view>
- <view class="module-com content-box">
- <view class="commodity-view">
- <view class="commodity-list">
- <view v-for="(s, idx) in detailInfo.itemInfo" :key="idx" class="commodity-item" @click="pageTo({ url: '/admin/item/detail?id='+s.productId })" >
- <image class="item-icon" :src="s.cover" alt="" />
- <view class="item-info">
- <view class="info-line">
- <text class="item-name">{{ s.name }}</text>
- <text class="item-price">
- <text class="unit">¥</text>
- <text class="price">{{ s.bigPrice ? parseFloat(s.bigPrice) : 0 }}</text>
- </text>
- </view>
- <view class="info-line">
- <text class="item-type" style="color:#3385FF;" @click.stop="printLabel(s)">打标签</text>
- <text class="item-count">{{ parseFloat(s.itemNum) }}扎</text>
- </view>
- </view>
- </view>
- </view>
- <view class="summary-bar">
- <view class="operate-view" ></view>
- <view class="describe-view">
- 共{{ detailInfo.kind || 0 }}种,<text v-if="Number(detailInfo.bigNum)>0">{{ detailInfo.bigNum }}扎</text><text v-if="Number(detailInfo.smallNum)>0">{{detailInfo.smallNum}}支</text>,
- 合计 ¥<text class="price">{{ detailInfo.price ? parseFloat(detailInfo.price) : 0 }}</text>
- </view>
- </view>
- </view>
- </view>
- <view class="content-box price-detail">
- <div class="module-com input-line-wrap">
- <tui-list-cell class="line-cell" :hover="false">
- <div class="tui-title">运费支付</div>
- <div class="detail-price_box" style="font-size: 28upx;">{{detailInfo.yfPayWay==1?'寄付':'到付'}}</div>
- </tui-list-cell>
- <tui-list-cell class="line-cell" :hover="false">
- <div class="tui-title">打包费</div>
- <div class="detail-price_box" style="font-size: 28upx;">¥{{ detailInfo.packingCharge?parseFloat(detailInfo.packingCharge):0 }}</div>
- </tui-list-cell>
- <tui-list-cell v-if="detailInfo.yfPayWay==1" class="line-cell" :hover="false">
- <div class="tui-title">短途运费</div>
- <div class="detail-price_box" style="font-size: 28upx;">¥{{ detailInfo.shortCharge?parseFloat(detailInfo.shortCharge):0 }}</div>
- </tui-list-cell>
- <tui-list-cell v-if="detailInfo.yfPayWay==1" class="line-cell" :hover="false">
- <div class="tui-title">长途运费</div>
- <div class="detail-price_box" style="font-size: 28upx;">¥{{ detailInfo.longCharge?parseFloat(detailInfo.longCharge):0 }}</div>
- </tui-list-cell>
- </div>
- </view>
- <view class="content-box price-detail">
- <div class="module-com input-line-wrap">
- <tui-list-cell class="line-cell" :hover="false">
- <div class="tui-title">总金额</div>
- <div class="detail-price_box" style="font-size: 30upx;">¥{{ detailInfo.prePrice ? parseFloat(detailInfo.prePrice) : 0 }}</div>
- </tui-list-cell>
- <tui-list-cell v-if="detailInfo.refundPrice > 0" class="line-cell" :hover="false">
- <div class="tui-title">退款金额</div>
- <div class="detail-price_box" style="font-size: 28upx">-¥{{ detailInfo.tkPrice ? parseFloat(detailInfo.tkPrice) : 0 }}</div>
- </tui-list-cell>
- <tui-list-cell v-if="detailInfo.discountAmount > 0" class="line-cell" :hover="false">
- <div class="tui-title">减免</div>
- <div class="detail-price_box" style="font-size: 30upx;">¥{{ detailInfo.discountAmount ? parseFloat(detailInfo.discountAmount) : 0 }}</div>
- </tui-list-cell>
- <tui-list-cell class="line-cell" :hover="false">
- <div class="tui-title">实际金额</div>
- <div class="detail-price_box red" style="font-size: 30upx;">¥{{ detailInfo.realPrice ? parseFloat(detailInfo.realPrice) : 0 }}</div>
- </tui-list-cell>
- </div>
- </view>
- <view class="content-box price-detail">
- <div class="module-com input-line-wrap">
- <tui-list-cell class="line-cell" :hover="false">
- <div class="tui-title">备注</div>
- <textarea style="height: 130upx;width:350upx;" @focus="detailInfo.remark=''" v-model="detailInfo.remark" placeholder="这里写备注"/>
- <button class="admin-button-com blue mini-btn" @click="modifyRemark(item)" >修改</button>
- </tui-list-cell>
- </div>
- </view>
- <view class="content-box price-detail">
- <div class="module-com input-line-wrap">
- <tui-list-cell v-if="detailInfo.yfPayWay==2" class="line-cell" :hover="false">
- <div class="tui-title">短途运费</div>
- <div class="detail-price_box" style="font-size: 28upx;">¥{{ detailInfo.shortCharge?parseFloat(detailInfo.shortCharge):0 }}</div>
- </tui-list-cell>
- <tui-list-cell v-if="detailInfo.yfPayWay==2" class="line-cell" :hover="false">
- <div class="tui-title">长途运费</div>
- <div class="detail-price_box" style="font-size: 28upx;">¥{{ detailInfo.longCharge?parseFloat(detailInfo.longCharge):0 }}</div>
- </tui-list-cell>
- <tui-list-cell class="line-cell" :hover="false">
- <div class="tui-title">提货费</div>
- <div class="detail-price_box" style="font-size: 28upx;">¥{{ detailInfo.pickCharge?parseFloat(detailInfo.pickCharge):0 }}</div>
- </tui-list-cell>
- <tui-list-cell class="line-cell" :hover="false">
- <div class="tui-title">本地运费</div>
- <div class="detail-price_box" style="font-size: 28upx;">¥{{ detailInfo.localCharge?parseFloat(detailInfo.localCharge):0 }}</div>
- </tui-list-cell>
- <tui-list-cell class="line-cell" :hover="false">
- <div class="tui-title">总费用</div>
- <div class="detail-price_box" style="font-size: 30upx;">¥{{ detailInfo.totalFreight?parseFloat(detailInfo.totalFreight):0 }}</div>
- </tui-list-cell>
- <tui-list-cell class="line-cell" :hover="false">
- <div class="tui-title">总重量</div>
- <div class="detail-price_box" style="font-size: 30upx;">¥{{ detailInfo.totalWeight?parseFloat(detailInfo.totalWeight):0 }}</div>
- </tui-list-cell>
- <tui-list-cell class="line-cell" :hover="false">
- <div class="tui-title">每公斤运费</div>
- <div class="detail-price_box" style="font-size: 30upx;">¥{{ detailInfo.avgKgWeight?parseFloat(detailInfo.avgKgWeight):0 }}</div>
- </tui-list-cell>
- </div>
- </view>
- </view>
- </view>
- </template>
- <script>
- import { getPurchaseDetailApi,updateRemark,printAll,printItem } from "@/api/purchase";
- import productMins from "@/mixins/product";
- import TuiListCell from "@/components/plugin/list-cell";
- export default {
- name: "info",
- components: {
- TuiListCell
- },
- mixins: [productMins],
- data() {
- return {
- selectJobType: "order_change",
- autoLoad: false,
- stepActive: 0,
- form: {
- name: ""
- },
- detailInfo: {},
- loading: false
- };
- },
- methods: {
- goRefund(info){
- this.$util.pageTo({url:'/pagesPurchase/refund?orderSn='+info.orderSn})
- },
- printLabel(item){
- let that = this
- that.$util.confirmModal({content:'确认打印'},() => {
- printItem({id:item.id}).then(res=>{
- if(res.code == 1){
- that.$msg(res.msg)
- }
- })
- })
- },
- printAllLabel(item){
- let that = this
- that.$util.confirmModal({content:'确认打印'},() => {
- printAll({orderSn:item.orderSn}).then(res=>{
- if(res.code == 1){
- that.$msg(res.msg)
- }
- })
- })
- },
- goToClear (item) {
- this.pageTo({
- url: '/pagesGys/details?id='+item.ghsId
- })
- },
- modifyRemark(){
- const self = this;
- let remark = this.detailInfo.remark
- updateRemark({id:this.detailInfo.id,remark:remark}).then((res) => {
- self.$msg(res.msg);
- })
- },
- copy(val) {
- const self = this;
- uni.setClipboardData({
- data: val,
- success: function() {
- self.$msg("复制成功");
- }
- });
- },
- callUp(mobile) {
- uni.makePhoneCall({
- phoneNumber: mobile
- });
- },
- async init() {
- const { orderSn } = this.option;
- if (!orderSn) {
- return;
- }
- const { data } = await getPurchaseDetailApi(orderSn);
- this.detailInfo = data;
- }
- }
- };
- </script>
- <style lang="scss" scoped>
- .info-content_box {
- padding: 0 20upx 100upx;
- & > .title {
- color: #666666;
- font-size: 28upx;
- font-weight: 600;
- padding: 30upx 3upx;
- }
- & .address-des_bx {
- display: flex;
- padding: 20upx 10upx 30upx 20upx;
- & > view:nth-child(1) {
- flex: 1;
- margin-top: 10upx;
- & > view:nth-child(1) {
- color: #333333;
- font-size: 32upx;
- font-weight: bold;
- }
- & > view:nth-child(2) {
- color: #666666;
- font-size: 28upx;
- font-weight: 400;
- margin-top: 20upx;
- }
- }
- & > view:nth-child(2) {
- display: flex;
- & .icondianhua1 {
- font-size: 50upx;
- color: #3385ff;
- margin-left: 0upx;
- }
- }
- }
- .bills-info_box {
- padding: 30upx 20upx 30upx;
- // border-bottom: 1upx solid #EEEEEE;
- & > .order-info_box {
- display: flex;
- align-items: center;
- font-size: 26upx;
- font-weight: 400;
- margin-bottom: 5upx;
- & > view:nth-child(1) {
- color: #999999;
- width: 135upx;
- text-align: right;
- }
- & > view:nth-child(2) {
- color: #333333;
- }
- & > .price {
- flex: 1;
- font-size: 30upx;
- color: #333333;
- display: flex;
- align-items: center;
- justify-content: flex-end;
- & .iconxiangyou {
- color: #999999;
- font-size: 25upx;
- margin-left: 12upx;
- }
- }
- }
- }
- .content-box {
- background-color: #ffffff;
- border-radius: 10upx;
- }
- .commodity-view {
- display: flex;
- flex-direction: column;
- .commodity-list {
- padding: 20upx;
- .commodity-item {
- display: flex;
- margin-bottom: 20upx;
- .item-icon {
- flex-shrink: 0;
- width: 140upx;
- height: 140upx;
- }
- .item-info {
- display: flex;
- flex-direction: column;
- justify-content: center;
- flex: 1;
- margin-left: 20upx;
- .info-line {
- margin-bottom: 20upx;
- display: flex;
- justify-content: space-between;
- align-items: flex-end;
- .item-name {
- color: #666;
- font-size: 28upx;
- }
- .item-price {
- color: #333;
- font-size: 22upx;
- .price {
- font-size: 32upx;
- font-weight: bold;
- }
- }
- .item-type {
- color: #999;
- font-size: 24upx;
- }
- .item-count {
- color: #666;
- font-size: 24upx;
- }
- }
- }
- }
- }
- .summary-bar {
- padding: 0 20upx;
- height: 90upx;
- display: flex;
- align-items: center;
- justify-content: space-between;
- border-top: 1upx solid #eeeeee;
- .operate-view {
- display: flex;
- align-items: center;
- color: #3385ff;
- font-size: 26upx;
- .iconfont {
- margin-right: 20upx;
- font-size: 40upx;
- }
- }
- .describe-view {
- display: flex;
- align-items: center;
- color: #333;
- font-size: 24upx;
- .price {
- font-weight: bold;
- font-size: 36upx;
- }
- }
- }
- }
- .shipping-address {
- display: flex;
- align-items: center;
- margin-top: 20upx;
- & > view:nth-child(1) {
- color: #999999;
- font-size: 28upx;
- font-weight: 400;
- display: inline-block;
- padding: 30upx 0 30upx 20upx;
- flex: 1;
- & > text {
- color: #333333;
- font-weight: 600;
- }
- }
- & > view:nth-child(2) {
- font-size: 60upx;
- color: #d6e7ff;
- margin-right: 10upx;
- }
- }
- .price-detail {
- margin-top: 20upx;
- margin-bottom: 20upx;
- }
- .detail-price_box {
- color: #333333;
- font-size: 22upx;
- text-align: right;
- flex: 1;
- font-weight: 600;
- &.red {
- color: #ff2842;
- }
- }
- }
- .app-footer {
- display: flex;
- align-items: center;
- justify-content: flex-end;
- & .admin-button-com {
- padding: 0;
- margin-right: 15upx;
- width: 140upx;
- height: 70upx;
- line-height: 70upx;
- text-align: center;
- color: #3385ff;
- border: 1upx solid #3385ff;
- &.active{
- color: #666666;
- border: 1upx solid #ccc;
- }
- }
- }
- </style>
|