|
@@ -0,0 +1,323 @@
|
|
|
|
|
+<template>
|
|
|
|
|
+ <view class="app-content" style="background:white;">
|
|
|
|
|
+ <view class="billing_box_bg">
|
|
|
|
|
+ <view class="input-wrap">
|
|
|
|
|
+ <view style="padding:0upx 0upx 0upx 0upx;margin-right:10upx;" >
|
|
|
|
|
+ <button class="admin-button-com middle blue" @click="selectFlowerNumFn()">图片分类</button>
|
|
|
|
|
+ </view>
|
|
|
|
|
+ <view class="search-bar">
|
|
|
|
|
+ <app-search-module v-model="py" placeholder="输拼音首字母也可以搜" @input="searchFn"/>
|
|
|
|
|
+ </view>
|
|
|
|
|
+ <view style="padding:0 0upx 0 15upx;" >
|
|
|
|
|
+ <button class="admin-button-com middle blue" @click="refreshItem()">刷新</button>
|
|
|
|
|
+ </view>
|
|
|
|
|
+ <view style="padding:0 0upx 0 15upx;" >
|
|
|
|
|
+ <button class="admin-button-com middle blue" @click="pageTo({ url: '/admin/ptItem/itemList' })">添花材</button>
|
|
|
|
|
+ </view>
|
|
|
|
|
+ </view>
|
|
|
|
|
+ <view class="scroll-middle_bx">
|
|
|
|
|
+
|
|
|
|
|
+ <scroll-view scroll-y class="right-box" :scroll-into-view="scroll_into_view" scroll-with-animation="true"
|
|
|
|
|
+ @scroll="scrolling" lower-threshold="100" @scrolltolower="scrollBottom">
|
|
|
|
|
+
|
|
|
|
|
+ <block v-if="!$util.isEmpty(currentJhItemList)">
|
|
|
|
|
+ <view class="item_list_bx selectAll">
|
|
|
|
|
+ <view class="item_list_title"></view>
|
|
|
|
|
+ <view v-if="!$util.isEmpty(currentJhItemList)">
|
|
|
|
|
+ <template v-for="(productItem, productIndex) in currentJhItemList">
|
|
|
|
|
+ <view style="height:255upx" :key="productIndex">
|
|
|
|
|
+ <ItemStock :info="productItem" @moreAction="moreAction"
|
|
|
|
|
+ @doPrintLabel="doPrintLabel" @cancelDiscountFn="cancelDiscountFn" @cancelFullOff="cancelFullOff"
|
|
|
|
|
+ :ref="`productRef${productItem.id}`" @hideChangeFn="hideChangeFn"
|
|
|
|
|
+ @cancelPreSellFn="cancelPreSellFn" @breakSingleItem="breakSingleItem">
|
|
|
|
|
+ </ItemStock>
|
|
|
|
|
+ </view>
|
|
|
|
|
+ </template>
|
|
|
|
|
+ </view>
|
|
|
|
|
+ <view v-else>
|
|
|
|
|
+ <view style="height:260upx;text-align:center;color:#CCCCCC;position: relative;">
|
|
|
|
|
+ <view style="position: absolute;margin:auto;top:130upx;left:0;right:0;bottom:0;">暂无花材</view>
|
|
|
|
|
+ </view>
|
|
|
|
|
+ </view>
|
|
|
|
|
+ </view>
|
|
|
|
|
+ </block>
|
|
|
|
|
+ <block v-else>
|
|
|
|
|
+ <view style="width:100%">
|
|
|
|
|
+ <app-wrapper-empty title="加载中" :is-empty="$util.isEmpty(currentJhItemList)" />
|
|
|
|
|
+ </view>
|
|
|
|
|
+ </block>
|
|
|
|
|
+ </scroll-view>
|
|
|
|
|
+
|
|
|
|
|
+ </view>
|
|
|
|
|
+ </view>
|
|
|
|
|
+
|
|
|
|
|
+ <modal-module :show="printLabelShow" @click="dialogInputConfirm" :maskClosable="true" title="数量" padding="30rpx 30rpx" >
|
|
|
|
|
+ <template v-slot:content>
|
|
|
|
|
+ <div class="app-modal-input-wrap">
|
|
|
|
|
+ <div class="inp-list-line">
|
|
|
|
|
+ <div class="line-input">
|
|
|
|
|
+ <input type="number" ref="input" style="width:61.8%;text-align:center;" @blur="blur" :focus="printFocus" v-model="printNum" :adjust-position="false" class="inp-input" />
|
|
|
|
|
+ </div>
|
|
|
|
|
+ </div>
|
|
|
|
|
+ </div>
|
|
|
|
|
+ </template>
|
|
|
|
|
+ </modal-module>
|
|
|
|
|
+
|
|
|
|
|
+ <modal-module :show="breakShow" @click="breakConfirm" :maskClosable="true" title="拆散数量" padding="30rpx 30rpx" >
|
|
|
|
|
+ <template v-slot:content>
|
|
|
|
|
+ <div class="app-modal-input-wrap">
|
|
|
|
|
+ <div class="inp-list-line">
|
|
|
|
|
+ <div class="line-input">
|
|
|
|
|
+ <input type="number" ref="input" style="width:61.8%;text-align:center;" @blur="blur" :focus="breakFocus" v-model="breakNum" :adjust-position="false" class="inp-input" />
|
|
|
|
|
+ </div>
|
|
|
|
|
+ </div>
|
|
|
|
|
+ </div>
|
|
|
|
|
+ </template>
|
|
|
|
|
+ </modal-module>
|
|
|
|
|
+
|
|
|
|
|
+
|
|
|
|
|
+ <uni-popup ref="rightShowMore" background-color="#fff" type="center" :animation="true" class="class-popup-style">
|
|
|
|
|
+ <view style="display:flex;width:100vw;padding:20upx 20upx 40upx 20upx;height:auto;justify-content: space-between;align-items:center;flex-wrap:wrap;max-height:100vh;overflow:auto;">
|
|
|
|
|
+ <view style="width:100vw;"><button @click="costChange()">成本变动记录</button></view>
|
|
|
|
|
+ <view style="width:100vw;margin-top:8upx;"><button @click="priceChange()">价格变动记录</button></view>
|
|
|
|
|
+ <view style="width:100vw;margin-top:8upx;"><button @click="varietyManage()">多颜色</button></view>
|
|
|
|
|
+ <view style="width:100vw;margin-top:8upx;"><button @click="preSell()">预售</button></view>
|
|
|
|
|
+ <view style="width:100vw;margin-top:8upx;"><button @click="orderRecord()">下单记录</button></view>
|
|
|
|
|
+ <view style="width:100vw;margin-top:8upx;"><button @click="copyCreate()">复制新建</button></view>
|
|
|
|
|
+ <view style="width:100vw;margin-top:8upx;"><button @click="onStockChange()">路上库存变动</button></view>
|
|
|
|
|
+ <view style="width:100vw;margin-top:8upx;"><button @click="shareItem()">打开分享(批发)</button></view>
|
|
|
|
|
+ <view style="width:100vw;margin-top:8upx;"><button @click="getHdPosterFn()">分享海报(批发)</button></view>
|
|
|
|
|
+ <view style="width:100vw;margin-top:8upx;"><button @click="getSkPosterFn()">分享海报(零售)</button></view>
|
|
|
|
|
+ <view style="width:100vw;margin-top:8upx;"><button @click="ptAuth()">申请平台认证</button></view>
|
|
|
|
|
+ <view style="width:100vw;margin-top:8upx;"><button @click="delItem()">删除</button></view>
|
|
|
|
|
+ <view style="width:100vw;margin-top:30upx;"><button @click="closeRightShow()">取消</button></view>
|
|
|
|
|
+ </view>
|
|
|
|
|
+ </uni-popup>
|
|
|
|
|
+
|
|
|
|
|
+ <uni-popup ref="posterShow" background-color="#fff" type="center" :animation="true" class="class-popup-style">
|
|
|
|
|
+ <view style="display:flex;width:100vw;padding:20upx 20upx 40upx 20upx;height:auto;justify-content: space-between;align-items:center;flex-wrap:wrap;max-height:100vh;overflow:auto;">
|
|
|
|
|
+ <text style="position:absolute;right:50upx;top:10upx;font-size:70upx;" @click="closePoster()">×</text>
|
|
|
|
|
+ <view style="width:100%;text-align:center;margin-top:75upx;">
|
|
|
|
|
+ <image style="width:70%;margin:0 auto;border:1upx solid #CCCCCC;" :src="posterUrl" mode="widthFix"></image>
|
|
|
|
|
+ </view>
|
|
|
|
|
+ <view style="width:100%;margin-top:65upx;text-align:center;">
|
|
|
|
|
+ <button class="admin-button-com big blue" style="width:300upx;" @click="downloadImg">保存图片</button>
|
|
|
|
|
+ </view>
|
|
|
|
|
+ </view>
|
|
|
|
|
+ </uni-popup>
|
|
|
|
|
+
|
|
|
|
|
+ </view>
|
|
|
|
|
+ </template>
|
|
|
|
|
+ <script>
|
|
|
|
|
+ import AppSearchModule from "@/components/module/app-search";
|
|
|
|
|
+ import AppWrapperEmpty from "@/components/app-wrapper-empty";
|
|
|
|
|
+ import ItemStock from "./components/term";
|
|
|
|
|
+ import jhMins from "@/mixins/jh";
|
|
|
|
|
+ import { mapGetters } from "vuex";
|
|
|
|
|
+ import { getWeixinId } from "@/api/invite";
|
|
|
|
|
+ import { getJhItemList } from "@/api/jh";
|
|
|
|
|
+ import { print,cancelDiscountPrice,cancelPreSell } from '@/api/product';
|
|
|
|
|
+ import { getHdPoster,getSkPoster,breakItem,changeFrontHide,applyAuth } from '@/api/item'
|
|
|
|
|
+ import uniPopup from '@/uni_modules/uni-popup/components/uni-popup/uni-popup.vue';
|
|
|
|
|
+ import ModalModule from "@/components/plugin/modal"
|
|
|
|
|
+ export default {
|
|
|
|
|
+ name: "list",
|
|
|
|
|
+ components: {
|
|
|
|
|
+ AppSearchModule,
|
|
|
|
|
+ AppWrapperEmpty,
|
|
|
|
|
+ ItemStock,
|
|
|
|
|
+ uniPopup,
|
|
|
|
|
+ ModalModule
|
|
|
|
|
+ },
|
|
|
|
|
+ mixins: [jhMins],
|
|
|
|
|
+ data() {
|
|
|
|
|
+ return {
|
|
|
|
|
+ autoLoad: false,
|
|
|
|
|
+ selectJobType: "stock",
|
|
|
|
|
+ tabIndex: 0,
|
|
|
|
|
+ getAppIdList:{},
|
|
|
|
|
+ status:0,
|
|
|
|
|
+ delStatus:0,
|
|
|
|
|
+ printItemId:0,
|
|
|
|
|
+ printType:0,
|
|
|
|
|
+ printLabelShow:false,
|
|
|
|
|
+ printNum:'',
|
|
|
|
|
+ printFocus:false,
|
|
|
|
|
+ warning:0,
|
|
|
|
|
+ currentInfo:{},
|
|
|
|
|
+ posterUrl:'',
|
|
|
|
|
+ breakNum:'',
|
|
|
|
|
+ breakFocus:false,
|
|
|
|
|
+ breakShow:false,
|
|
|
|
|
+ classIndex: 0,
|
|
|
|
|
+ globalJhClassList:[],
|
|
|
|
|
+ currentJhItemList:[],
|
|
|
|
|
+ page:1,
|
|
|
|
|
+ currentJhId:0,
|
|
|
|
|
+ finishGetItem:0
|
|
|
|
|
+ };
|
|
|
|
|
+ },
|
|
|
|
|
+ computed:{
|
|
|
|
|
+ ...mapGetters(["getMyShopInfo","getLoginInfo"]),
|
|
|
|
|
+ ...mapGetters({ loginInfo: "getLoginInfo",dictInfo:"getDictionariesInfo" })
|
|
|
|
|
+ },
|
|
|
|
|
+ onLoad() {
|
|
|
|
|
+
|
|
|
|
|
+ let that = this
|
|
|
|
|
+ getWeixinId().then(res => {
|
|
|
|
|
+ that.getAppIdList = res.data
|
|
|
|
|
+ })
|
|
|
|
|
+ this.currentJhId = this.option.jhId ? this.option.jhId : 0
|
|
|
|
|
+ that.getListFn()
|
|
|
|
|
+
|
|
|
|
|
+ },
|
|
|
|
|
+ methods: {
|
|
|
|
|
+ getListFn(){
|
|
|
|
|
+ if(this.finishGetItem == 1){
|
|
|
|
|
+ return false
|
|
|
|
|
+ }
|
|
|
|
|
+ let that = this
|
|
|
|
|
+ getJhItemList({jhId:that.currentJhId,page:that.page}).then(res=>{
|
|
|
|
|
+ if(res.code == 1){
|
|
|
|
|
+ that.currentJhItemList = that.page == 1 ? res.data.list : that.currentJhItemList.concat(res.data.list)
|
|
|
|
|
+ if(res.data.moreData == 1){
|
|
|
|
|
+ that.page++
|
|
|
|
|
+ }else{
|
|
|
|
|
+ that.finishGetItem = 1
|
|
|
|
|
+ }
|
|
|
|
|
+ }
|
|
|
|
|
+ })
|
|
|
|
|
+ },
|
|
|
|
|
+ scrollBottom(){
|
|
|
|
|
+ this.getListFn()
|
|
|
|
|
+ },
|
|
|
|
|
+ scrolling(){
|
|
|
|
|
+
|
|
|
|
|
+ }
|
|
|
|
|
+ }
|
|
|
|
|
+ };
|
|
|
|
|
+ </script>
|
|
|
|
|
+
|
|
|
|
|
+ <style lang="scss" scoped>
|
|
|
|
|
+ .billing_box_bg {
|
|
|
|
|
+ height: 100%;
|
|
|
|
|
+ display: flex;
|
|
|
|
|
+ background:white;
|
|
|
|
|
+ flex-direction: column;
|
|
|
|
|
+ .input-wrap {
|
|
|
|
|
+ display: flex;
|
|
|
|
|
+ padding: 22upx 20upx 22upx 13upx;
|
|
|
|
|
+ .search-bar {
|
|
|
|
|
+ flex: 1;
|
|
|
|
|
+ }
|
|
|
|
|
+ .city-select {
|
|
|
|
|
+ display: flex;
|
|
|
|
|
+ flex-shrink: 0;
|
|
|
|
|
+ align-items: center;
|
|
|
|
|
+ margin-right: 15upx;
|
|
|
|
|
+ margin-left: 45upx;
|
|
|
|
|
+ background-color: #ffff;
|
|
|
|
|
+ .iconfont {
|
|
|
|
|
+ margin-left: 20upx;
|
|
|
|
|
+ font-size: 30upx;
|
|
|
|
|
+ }
|
|
|
|
|
+ }
|
|
|
|
|
+ }
|
|
|
|
|
+ .scroll-middle_bx {
|
|
|
|
|
+ flex: 1;
|
|
|
|
|
+ display: flex;
|
|
|
|
|
+ width: 100%;
|
|
|
|
|
+ height: 100%;
|
|
|
|
|
+ overflow: hidden;
|
|
|
|
|
+ }
|
|
|
|
|
+ .tab-view {
|
|
|
|
|
+ height: calc(100vh - 140upx);
|
|
|
|
|
+ width: 170upx;
|
|
|
|
|
+ flex-shrink: 0;
|
|
|
|
|
+ background-color: #f0f2f6;
|
|
|
|
|
+ .tab-bar-item {
|
|
|
|
|
+ position: relative;
|
|
|
|
|
+ width: 170upx;
|
|
|
|
|
+ height: 90upx;
|
|
|
|
|
+ box-sizing: border-box;
|
|
|
|
|
+ display: flex;
|
|
|
|
|
+ align-items: center;
|
|
|
|
|
+ justify-content: center;
|
|
|
|
|
+ font-size: 26upx;
|
|
|
|
|
+ color: #444;
|
|
|
|
|
+ font-weight: 400;
|
|
|
|
|
+ .tag {
|
|
|
|
|
+ display: flex;
|
|
|
|
|
+ padding: 0 20upx;
|
|
|
|
|
+ align-items: center;
|
|
|
|
|
+ position: absolute;
|
|
|
|
|
+ right: 0;
|
|
|
|
|
+ top: 0;
|
|
|
|
|
+ height: 32upx;
|
|
|
|
|
+ background: #ff2842;
|
|
|
|
|
+ border-radius: 16upx;
|
|
|
|
|
+ color: #fff;
|
|
|
|
|
+ font-size: 20upx;
|
|
|
|
|
+ }
|
|
|
|
|
+ &:last-child{
|
|
|
|
|
+ margin-bottom: 110upx;
|
|
|
|
|
+ }
|
|
|
|
|
+ }
|
|
|
|
|
+
|
|
|
|
|
+ .active {
|
|
|
|
|
+ position: relative;
|
|
|
|
|
+ color: $mainColor;
|
|
|
|
|
+ font-size: 26upx;
|
|
|
|
|
+ background: #fff;
|
|
|
|
|
+ }
|
|
|
|
|
+
|
|
|
|
|
+ .active::before {
|
|
|
|
|
+ content: "";
|
|
|
|
|
+ position: absolute;
|
|
|
|
|
+ border-left: 8upx solid $mainColor;
|
|
|
|
|
+ height: 100%;
|
|
|
|
|
+ left: 0;
|
|
|
|
|
+ }
|
|
|
|
|
+ }
|
|
|
|
|
+ .right-box {
|
|
|
|
|
+ height: calc(100vh - 140upx);
|
|
|
|
|
+ flex: 1;
|
|
|
|
|
+ box-sizing: border-box;
|
|
|
|
|
+ }
|
|
|
|
|
+ .item_list_bx {
|
|
|
|
|
+ padding: 40upx 16upx;
|
|
|
|
|
+ }
|
|
|
|
|
+ .item_list_title {
|
|
|
|
|
+ margin-bottom: 20upx;
|
|
|
|
|
+ font-size: 24upx;
|
|
|
|
|
+ font-weight: 600;
|
|
|
|
|
+ color: #666666;
|
|
|
|
|
+ }
|
|
|
|
|
+ .select-cmd_bx {
|
|
|
|
|
+ & .kc {
|
|
|
|
|
+ color: #999999;
|
|
|
|
|
+ font-size: 28upx;
|
|
|
|
|
+ font-weight: 400;
|
|
|
|
|
+ margin-bottom: 60upx;
|
|
|
|
|
+ text-align: center;
|
|
|
|
|
+ margin-top: 10upx;
|
|
|
|
|
+ }
|
|
|
|
|
+ & .num_bx {
|
|
|
|
|
+ display: flex;
|
|
|
|
|
+ align-items: center;
|
|
|
|
|
+ margin-bottom: 80upx;
|
|
|
|
|
+ & > input {
|
|
|
|
|
+ width: 212upx;
|
|
|
|
|
+ height: 80upx;
|
|
|
|
|
+ border: 1upx solid #dddddd;
|
|
|
|
|
+ border-radius: 4upx;
|
|
|
|
|
+ text-align: center;
|
|
|
|
|
+ margin-right: 24upx;
|
|
|
|
|
+ }
|
|
|
|
|
+ }
|
|
|
|
|
+ }
|
|
|
|
|
+ }
|
|
|
|
|
+ .class-popup-style{
|
|
|
|
|
+ z-index:999999;
|
|
|
|
|
+ }
|
|
|
|
|
+ </style>
|