Browse Source

修改bug

Qukatie 1 year ago
parent
commit
0be6dbba81

+ 8 - 0
src/api/basicData/inventoryAccount.js

@@ -113,3 +113,11 @@ export const AppPartsStockDataDetails = (params) => {
     }
   })
 }
+// 配件精灵
+export const productLaunchDetails = (data) => {
+  return request({
+    url: '/api/blade-sales-part/productLaunch/productLaunchDetails',
+    method: 'get',
+    params: data
+  })
+}

+ 56 - 0
src/router/views/index.js

@@ -3529,4 +3529,60 @@ export default [{
     component: () => import( /* webpackChunkName: "views" */ '@/views/tirePartsMall/financialManagement/salesAnalysis/index')
   }]
 },
+{
+  path: '/tirePartsMall/basicData/listingManagement/detail',
+  component: Layout,
+  hidden: true,
+  children: [{
+    path: '/tirePartsMall/basicData/listingManagement/detail',
+    name: '销售明细(L)',
+    meta: {
+      i18n: '/tirePartsMall/basicData/listingManagement/detail',
+      keepAlive: true,
+    },
+    component: () => import( /* webpackChunkName: "views" */ '@/views/tirePartsMall/basicData/listingManagement/detail')
+  }]
+},
+{
+  path: '/tirePartsMall/statisticAnalysis/generalLedgerReceivable/index',
+  component: Layout,
+  hidden: true,
+  children: [{
+    path: '/tirePartsMall/statisticAnalysis/generalLedgerReceivable/index',
+    name: '应收总账(月)',
+    meta: {
+      i18n: '/tirePartsMall/statisticAnalysis/generalLedgerReceivable/index',
+      keepAlive: true,
+    },
+    component: () => import( /* webpackChunkName: "views" */ '@/views/tirePartsMall/statisticAnalysis/generalLedgerReceivable/index')
+  }]
+},
+{
+  path: '/tirePartsMall/statisticAnalysis/generalLedgerPayable/index',
+  component: Layout,
+  hidden: true,
+  children: [{
+    path: '/tirePartsMall/statisticAnalysis/generalLedgerPayable/index',
+    name: '应付总账(月)',
+    meta: {
+      i18n: '/tirePartsMall/statisticAnalysis/generalLedgerPayable/index',
+      keepAlive: true,
+    },
+    component: () => import( /* webpackChunkName: "views" */ '@/views/tirePartsMall/statisticAnalysis/generalLedgerPayable/index')
+  }]
+},
+{
+  path: '/tirePartsMall/statisticAnalysis/profitLedger/index',
+  component: Layout,
+  hidden: true,
+  children: [{
+    path: '/tirePartsMall/statisticAnalysis/profitLedger/index',
+    name: '利润总账(月)',
+    meta: {
+      i18n: '/tirePartsMall/statisticAnalysis/profitLedger/index',
+      keepAlive: true,
+    },
+    component: () => import( /* webpackChunkName: "views" */ '@/views/tirePartsMall/statisticAnalysis/profitLedger/index')
+  }]
+},
 ]

+ 484 - 503
src/views/tirePartsMall/activity/detailsPage.vue

@@ -3,15 +3,14 @@
         <div class="customer-head">
             <div class="customer-back">
                 <el-button type="danger" style="border: none;background: none;color: red" icon="el-icon-arrow-left"
-                           @click="backToList">返回列表
+                    @click="backToList">返回列表
                 </el-button>
             </div>
             <div class="add-customer-btn">
-                <el-button v-if="form.status == 0 || form.status == 2"
-                           type="success" size="small" :disabled="!form.id"
-                           @click="releasefun" >发 布</el-button>
+                <el-button v-if="form.status == 0 || form.status == 2" type="success" size="small" :disabled="!form.id"
+                    @click="releasefun">发 布</el-button>
                 <el-button v-if="form.status == 1" type="warning" size="small" :disabled="!form.id"
-                           @click="releasefun" >撤销发布</el-button>
+                    @click="releasefun">撤销发布</el-button>
                 <el-button class="el-button--small-yh" type="primary" size="small" @click="editCustomer">保存数据</el-button>
             </div>
         </div>
@@ -21,7 +20,7 @@
                     <template slot="activePictures">
                         <div style="display: flex;align-items: center;justify-content: center;">
                             <el-input v-model="form.activePictures" :disabled="true" placeholder="请输入内容"></el-input>
-                            <el-button type="primary" size="small" icon="el-icon-edit" @click="addPicture" >上传</el-button>
+                            <el-button type="primary" size="small" icon="el-icon-edit" @click="addPicture">上传</el-button>
                         </div>
                     </template>
                 </avue-form>
@@ -29,55 +28,39 @@
         </div>
         <div style="margin-top: 10px">
             <trade-card title="详情">
-                <avue-crud :option="optionDetails" ref="optionDetailsRef" :data="form.activityItemsList"
-                           @selection-change="detailsMultiplechoice"
-                           @resetColumn="resetColumnTwo('optionDetailsRef', 'optionDetails', 'optionDetailsBack', 339.1)"
-                           @saveColumn="saveColumnTwo('optionDetailsRef', 'optionDetails', 'optionDetailsBack', 339.1)" >
+                <avue-crud :option="optionDetails" ref="crud" :data="form.activityItemsList"
+                    @selection-change="detailsMultiplechoice"
+                    @resetColumn="resetColumnTwo('crud', 'optionDetails', 'optionDetailsBack', 339.1)"
+                    @saveColumn="saveColumnTwo('crud', 'optionDetails', 'optionDetailsBack', 339.1)">
                     <template slot="menuLeft">
-                        <el-button icon="el-icon-plus" type="primary" size="small" @click="detailsAddButton" >添加数据</el-button>
-                        <el-button type="danger"
-                                   size="small"
-                                   icon="el-icon-delete"
-                                   plain
-                                   @click="multipleActivityitemsRemovefun">删 除
+                        <el-button icon="el-icon-plus" type="primary" size="small"
+                            @click="detailsAddButton">添加数据</el-button>
+                        <el-button type="danger" size="small" icon="el-icon-delete" plain
+                            @click="multipleActivityitemsRemovefun">删 除
                         </el-button>
                     </template>
                     <template slot-scope="{row,index}" slot="menu">
-                        <el-button
-                            type="text"
-                            size="small"
-                            @click="detailsRowCell(row,index)"
-                        >{{row.$cellEdit?'确认':'修改'}}</el-button>
-                        <el-button type="text" size="small" @click="activityitemsRemovefun(row,index)" >删除</el-button>
-                        <el-button type="text" size="small" @click="changingtheImage(row,index)" >换图</el-button>
+                        <el-button type="text" size="small" @click="detailsRowCell(row, index)">{{ row.$cellEdit ? '确认' :
+                            '修改' }}</el-button>
+                        <el-button type="text" size="small" @click="activityitemsRemovefun(row, index)">删除</el-button>
+                        <el-button type="text" size="small" @click="changingtheImage(row, index)">换图</el-button>
                     </template>
                 </avue-crud>
             </trade-card>
         </div>
 
-        <el-dialog title="商城数据" append-to-body v-dialog-drag :visible.sync="detailsVisible" width="80%" >
-            <assembly-details ref="assemblyDetails" @selectionDetails="selectionDetails" ></assembly-details>
+        <el-dialog title="商城数据" append-to-body v-dialog-drag :visible.sync="detailsVisible" width="80%">
+            <assembly-details ref="assemblyDetails" @selectionDetails="selectionDetails"></assembly-details>
             <span slot="footer" class="dialog-footer">
                 <el-button @click="detailsVisible = false">取 消</el-button>
                 <el-button type="primary" @click="popupConfirmation">确 定</el-button>
             </span>
         </el-dialog>
 
-        <el-dialog
-            title="上传附件"
-            append-to-body
-            :visible.sync="excelBox"
-            width="555px"
-            :close-on-click-modal="false"
-            v-dialog-drag >
-            <el-upload
-                class="upload-demo" drag
-                style="text-align: center"
-                ref="upload"
-                :action="action"
-                :headers="headers"
-                :on-success="onSuccess"
-                multiple >
+        <el-dialog title="上传附件" append-to-body :visible.sync="excelBox" width="555px" :close-on-click-modal="false"
+            v-dialog-drag>
+            <el-upload class="upload-demo" drag style="text-align: center" ref="upload" :action="action" :headers="headers"
+                :on-success="onSuccess" multiple>
                 <i class="el-icon-upload"></i>
                 <div class="el-upload__text">将文件拖到此处,或<em>点击上传</em></div>
                 <div class="el-upload__tip" slot="tip">
@@ -90,490 +73,488 @@
 
 <script>
 import assemblyDetails from "./assembly/assemblyDetails.vue";
-import {getToken} from "@/util/auth";
-import {activityDetail, activityitemsRemove, activitySubmit, activityUpdate} from "@/api/tirePartsMall/activity";
-    export default {
-        data(){
-            return {
-                optionForm:{
-                    menuBtn: false,
-                    span: 6,
-                    column: [{
-                        label: '活动名称',
-                        prop: "activityName",
-                        rules: [{
-                            required: true,
-                            message: " ",
-                            trigger: "blur"
-                        }]
-                    },{
-                        label: '开始日期',
-                        prop: "startDate",
-                        type: "date",
-                        format: "yyyy-MM-dd",
-                        valueFormat: "yyyy-MM-dd HH:mm:ss",
-                        rules: [{
-                            required: true,
-                            message: " ",
-                            trigger: "blur"
-                        }]
-                    },{
-                        label: '结束日期',
-                        prop: "endDate",
-                        type: "date",
-                        format: "yyyy-MM-dd",
-                        valueFormat: "yyyy-MM-dd HH:mm:ss",
-                        rules: [{
-                            required: true,
-                            message: " ",
-                            trigger: "blur"
-                        }]
-                    },{
-                        label: '最小购买',
+import { getToken } from "@/util/auth";
+import { activityDetail, activityitemsRemove, activitySubmit, activityUpdate } from "@/api/tirePartsMall/activity";
+export default {
+    data() {
+        return {
+            optionForm: {
+                menuBtn: false,
+                span: 6,
+                column: [{
+                    label: '活动名称',
+                    prop: "activityName",
+                    rules: [{
+                        required: true,
+                        message: " ",
+                        trigger: "blur"
+                    }]
+                }, {
+                    label: '开始日期',
+                    prop: "startDate",
+                    type: "date",
+                    format: "yyyy-MM-dd",
+                    valueFormat: "yyyy-MM-dd HH:mm:ss",
+                    rules: [{
+                        required: true,
+                        message: " ",
+                        trigger: "blur"
+                    }]
+                }, {
+                    label: '结束日期',
+                    prop: "endDate",
+                    type: "date",
+                    format: "yyyy-MM-dd",
+                    valueFormat: "yyyy-MM-dd HH:mm:ss",
+                    rules: [{
+                        required: true,
+                        message: " ",
+                        trigger: "blur"
+                    }]
+                }, {
+                    label: '最小购买',
+                    prop: "minQuantity",
+                    rules: [{
+                        required: true,
+                        message: " ",
+                        trigger: "blur"
+                    }]
+                }, {
+                    label: '最大购买',
+                    prop: "maxQuantity",
+                    rules: [{
+                        required: true,
+                        message: " ",
+                        trigger: "blur"
+                    }]
+                }, {
+                    label: '图片名称',
+                    prop: "activePictures",
+                    formslot: true,
+                    disabled: true,
+                    rules: [{
+                        required: true,
+                        message: " ",
+                        trigger: "blur"
+                    }]
+                }, {
+                    label: '图片地址',
+                    prop: "url",
+                    disabled: true,
+                    span: 12,
+                    rules: [{
+                        required: true,
+                        message: " ",
+                        trigger: "blur"
+                    }]
+                }, {
+                    label: '活动说明',
+                    prop: "activityDescription",
+                    span: 24,
+                    type: 'textarea',
+                    minRows: 2,
+                    rules: [{
+                        required: true,
+                        message: " ",
+                        trigger: "blur"
+                    }]
+                }]
+            },
+            form: {
+                minQuantity: 1, // 最小购买
+                activityItemsList: []
+            },
+            // 详情配置
+            optionDetails: {},
+            optionDetailsBack: {
+                height: 'auto',
+                calcHeight: 30,
+                tip: false,
+                searchShow: true,
+                searchMenuSpan: 6,
+                border: true,
+                index: true,
+                selection: true,
+                dialogClickModal: false,
+                addBtn: false,
+                viewBtn: false,
+                editBtn: false,
+                delBtn: false,
+                cancelBtn: false,
+                menuWidth: 120,
+                cellBtn: false,
+                addRowBtn: false,
+                rowKey: '$index',
+                column: [
+                    {
+                        label: "名称",
+                        prop: "cname",
+                        overHidden: true,
+                    },
+                    {
+                        label: "规格型号",
+                        prop: "specificationAndModel",
+                        overHidden: true,
+                    },
+                    {
+                        label: "花纹",
+                        prop: "brandItem",
+                        overHidden: true,
+                    },
+                    {
+                        label: "库存",
+                        prop: "inventory",
+                        overHidden: true,
+                    },
+                    {
+                        label: "最小购买数量",
                         prop: "minQuantity",
-                        rules: [{
-                            required: true,
-                            message: " ",
-                            trigger: "blur"
-                        }]
-                    },{
-                        label: '最大购买',
+                        overHidden: true,
+                        type: 'number',
+                        controls: false,
+                        cell: true,
+                        width: '100px',
+                    },
+                    {
+                        label: "最大购买数量",
                         prop: "maxQuantity",
-                        rules: [{
-                            required: true,
-                            message: " ",
-                            trigger: "blur"
-                        }]
-                    },{
-                        label: '图片名称',
-                        prop: "activePictures",
-                        formslot:true,
-                        disabled:true,
-                        rules: [{
-                            required: true,
-                            message: " ",
-                            trigger: "blur"
-                        }]
-                    },{
-                        label: '图片地址',
-                        prop: "url",
-                        disabled:true,
-                        span:12,
-                        rules: [{
-                            required: true,
-                            message: " ",
-                            trigger: "blur"
-                        }]
-                    },{
-                        label: '活动说明',
-                        prop: "activityDescription",
-                        span:24,
-                        type:'textarea',
-                        minRows: 2,
-                        rules: [{
-                            required: true,
-                            message: " ",
-                            trigger: "blur"
-                        }]
-                    }]
-                },
-                form:{
-                    minQuantity:1, // 最小购买
-                    activityItemsList:[]
-                },
-                // 详情配置
-                optionDetails:{},
-                optionDetailsBack:{
-                    height:'auto',
-                    calcHeight: 30,
-                    tip: false,
-                    searchShow: true,
-                    searchMenuSpan: 6,
-                    border: true,
-                    index: true,
-                    selection: true,
-                    dialogClickModal: false,
-                    addBtn:false,
-                    viewBtn:false,
-                    editBtn:false,
-                    delBtn:false,
-                    cancelBtn:false,
-                    menuWidth:120,
-                    cellBtn:false,
-                    addRowBtn:false,
-                    rowKey:'$index',
-                    column: [
-                        {
-                            label: "名称",
-                            prop: "cname",
-                            overHidden:true,
-                        },
-                        {
-                            label: "规格型号",
-                            prop: "specificationAndModel",
-                            overHidden:true,
-                        },
-                        {
-                            label: "花纹",
-                            prop: "brandItem",
-                            overHidden:true,
-                        },
-                        {
-                            label: "库存",
-                            prop: "inventory",
-                            overHidden:true,
-                        },
-                        {
-                            label: "最小购买数量",
-                            prop: "minQuantity",
-                            overHidden:true,
-                            type:'number',
-                            controls:false,
-                            cell: true,
-                            width:'100px',
-                        },
-                        {
-                            label: "最大购买数量",
-                            prop: "maxQuantity",
-                            overHidden:true,
-                            type:'number',
-                            controls:false,
-                            cell: true,
-                            width:'100px',
-                        },
-                        {
-                            label: "原售价1",
-                            prop: "priceOnePrimary",
-                            overHidden:true,
-                        },
-                        {
-                            label: "原售价2",
-                            prop: "priceTwoPrimary",
-                            overHidden:true,
-                        },
-                        {
-                            label: "原售价3",
-                            prop: "priceThreePrimary",
-                            overHidden:true,
-                        },
-                        {
-                            label: "原售价4",
-                            prop: "priceFourPrimary",
-                            overHidden:true,
-                        },
-                        {
-                            label: "促销价1",
-                            prop: "priceOne",
-                            overHidden:true,
-                            cell: true
-                        },
-                        {
-                            label: "促销价2",
-                            prop: "priceTwo",
-                            overHidden:true,
-                            cell: true
-                        },
-                        {
-                            label: "促销价3",
-                            prop: "priceThree",
-                            overHidden:true,
-                            cell: true
-                        },
-                        {
-                            label: "促销价4",
-                            prop: "priceFour",
-                            overHidden:true,
-                            cell: true
-                        },
-                        {
-                            label: "品牌名称",
-                            prop: "brandName",
-                            overHidden:true,
-                        },
+                        overHidden: true,
+                        type: 'number',
+                        controls: false,
+                        cell: true,
+                        width: '100px',
+                    },
+                    {
+                        label: "原售价1",
+                        prop: "priceOnePrimary",
+                        overHidden: true,
+                    },
+                    {
+                        label: "原售价2",
+                        prop: "priceTwoPrimary",
+                        overHidden: true,
+                    },
+                    {
+                        label: "原售价3",
+                        prop: "priceThreePrimary",
+                        overHidden: true,
+                    },
+                    {
+                        label: "原售价4",
+                        prop: "priceFourPrimary",
+                        overHidden: true,
+                    },
+                    {
+                        label: "促销价1",
+                        prop: "priceOne",
+                        overHidden: true,
+                        cell: true
+                    },
+                    {
+                        label: "促销价2",
+                        prop: "priceTwo",
+                        overHidden: true,
+                        cell: true
+                    },
+                    {
+                        label: "促销价3",
+                        prop: "priceThree",
+                        overHidden: true,
+                        cell: true
+                    },
+                    {
+                        label: "促销价4",
+                        prop: "priceFour",
+                        overHidden: true,
+                        cell: true
+                    },
+                    {
+                        label: "品牌名称",
+                        prop: "brandName",
+                        overHidden: true,
+                    },
 
-                        {
-                            label: "产地",
-                            prop: "placeProduction",
-                            overHidden:true,
-                            cell: true
-                        },
-                        {
-                            label: "防爆",
-                            prop: "explosionProof",
-                            type: 'select',
-                            dicData: [{
-                                label: '否',
-                                value: 0
-                            }, {
-                                label: '是',
-                                value: 1
-                            }],
-                            overHidden:true,
-                        },
-                        {
-                            label: "原厂",
-                            prop: "originalFactory",
-                            overHidden:true,
-                        },
-                        {
-                            label: "自修补",
-                            prop: "selfRecovery",
-                            overHidden:true,
-                        },
-                        // {
-                        //     label: "原价",
-                        //     prop: "originalPrice",
-                        //     overHidden:true,
-                        //     cell: true
-                        // },
-                        {
-                            label: "商品图片名称",
-                            prop: "goodsPictures",
-                            overHidden:true,
-                            width:'140px',
-                        },
-                        {
-                            label: "商品图片地址",
-                            prop: "url",
-                            overHidden:true,
-                            width:'140px',
-                        },
-                        {
-                            label: "备注",
-                            prop: "remarks",
-                            overHidden:true,
-                            cell: true
-                        },
-                    ]
-                },
-                detailsMultipleData:[], // 详情多选数据
-                detailsVisible:false, // 商城弹窗显示隐藏
-                selectionDetailsData:[], // 弹窗多选数据
-                excelBox:false, // 上传图片的弹窗
-                action: "/api/blade-resource/oss/endpoint/put-file",
-                headers: { "Blade-Auth": "Bearer " + getToken() },
-                detailsIndex:null, // 详情下标
+                    {
+                        label: "产地",
+                        prop: "placeProduction",
+                        overHidden: true,
+                        cell: true
+                    },
+                    {
+                        label: "防爆",
+                        prop: "explosionProof",
+                        type: 'select',
+                        dicData: [{
+                            label: '否',
+                            value: 0
+                        }, {
+                            label: '是',
+                            value: 1
+                        }],
+                        overHidden: true,
+                    },
+                    {
+                        label: "原厂",
+                        prop: "originalFactory",
+                        overHidden: true,
+                    },
+                    {
+                        label: "自修补",
+                        prop: "selfRecovery",
+                        overHidden: true,
+                    },
+                    // {
+                    //     label: "原价",
+                    //     prop: "originalPrice",
+                    //     overHidden:true,
+                    //     cell: true
+                    // },
+                    {
+                        label: "商品图片名称",
+                        prop: "goodsPictures",
+                        overHidden: true,
+                        width: '140px',
+                    },
+                    {
+                        label: "商品图片地址",
+                        prop: "url",
+                        overHidden: true,
+                        width: '140px',
+                    },
+                    {
+                        label: "备注",
+                        prop: "remarks",
+                        overHidden: true,
+                        cell: true
+                    },
+                ]
+            },
+            detailsMultipleData: [], // 详情多选数据
+            detailsVisible: false, // 商城弹窗显示隐藏
+            selectionDetailsData: [], // 弹窗多选数据
+            excelBox: false, // 上传图片的弹窗
+            action: "/api/blade-resource/oss/endpoint/put-file",
+            headers: { "Blade-Auth": "Bearer " + getToken() },
+            detailsIndex: null, // 详情下标
+        }
+    },
+    components: {
+        assemblyDetails
+    },
+    async created() {
+        this.optionDetails = await this.getColumnData(this.getColumnName(339.1), this.optionDetailsBack);
+    },
+    methods: {
+        // 从表单个删除
+        activityitemsRemovefun(row, index) {
+            if (row.id) {
+                activityitemsRemove(row.id).then(res => {
+                    this.$message.success('操作成功!')
+                })
             }
+            this.form.activityItemsList.splice(index, 1)
         },
-        components:{
-            assemblyDetails
-        },
-        async created() {
-            this.optionDetails = await this.getColumnData(this.getColumnName(339.1), this.optionDetailsBack);
-        },
-        methods:{
-            // 从表单个删除
-            activityitemsRemovefun(row,index){
-                if (row.id) {
-                    activityitemsRemove(row.id).then(res=>{
+        // 从表多个删除
+        multipleActivityitemsRemovefun() {
+            if (this.detailsMultipleData.length === 0) {
+                this.$message.warning("请选择至少一条数据");
+                return;
+            }
+            this.$confirm("确定将选择数据删除?", {
+                confirmButtonText: "确定",
+                cancelButtonText: "取消",
+                type: "warning"
+            }).then(() => {
+                let multiList = this.detailsMultipleData
+                let arr = this.form.activityItemsList
+                // 获取有id 的数据
+                const itemsWithId = multiList.filter(item => item.hasOwnProperty('id'));
+                let arrIds = itemsWithId.map(item => item.id) // 获取id 数据
+                // 把选中的删除掉
+                multiList.forEach((item) => {
+                    for (let index in arr) {
+                        if (JSON.stringify(item) == JSON.stringify(arr[index])) {
+                            arr.splice(Number(index), 1)
+                        }
+                    }
+                })
+                // 有id 的处理
+                if (itemsWithId.length != 0) {
+                    activityitemsRemove(arrIds.join(',')).then(res => {
                         this.$message.success('操作成功!')
                     })
                 }
-                this.form.activityItemsList.splice(index,1)
-            },
-            // 从表多个删除
-            multipleActivityitemsRemovefun(){
-                if (this.detailsMultipleData.length === 0) {
-                    this.$message.warning("请选择至少一条数据");
-                    return;
-                }
-                this.$confirm("确定将选择数据删除?", {
-                    confirmButtonText: "确定",
-                    cancelButtonText: "取消",
-                    type: "warning"
-                }).then(()=>{
-                        let multiList = this.detailsMultipleData
-                        let arr = this.form.activityItemsList
-                        // 获取有id 的数据
-                        const itemsWithId = multiList.filter(item => item.hasOwnProperty('id'));
-                        let arrIds = itemsWithId.map(item=>item.id) // 获取id 数据
-                        // 把选中的删除掉
-                        multiList.forEach((item)=>{
-                            for (let index in arr) {
-                                if (JSON.stringify(item) == JSON.stringify(arr[index])) {
-                                    arr.splice(Number(index),1)
-                                }
-                            }
-                        })
-                        // 有id 的处理
-                        if(itemsWithId.length != 0) {
-                            activityitemsRemove(arrIds.join(',')).then(res=>{
-                                this.$message.success('操作成功!')
-                            })
+            })
+        },
+        // 详情多选
+        detailsMultiplechoice(list) {
+            this.detailsMultipleData = list
+        },
+        // 发布
+        releasefun() {
+            if (this.form.status == 0 || this.form.status == 2) {
+                this.form.status = 1
+            } else if (this.form.status == 1) {
+                this.form.status = 2
+            }
+            activityUpdate(this.form).then(res => {
+                this.$message.success('操作成功')
+                this.activityDetailfun(this.form.id)
+            })
+        },
+        // 大保存
+        editCustomer() {
+            this.$refs["form"].validate((valid, done) => {
+                if (valid) {
+                    let sumText = '请输入'
+                    let maxnum = 0
+                    for (let item of this.form.activityItemsList) {
+                        if (!Number(item.priceOne)) {
+                            sumText += ` 序号${item.$index + 1}促销价1`
                         }
-                })
-            },
-            // 详情多选
-            detailsMultiplechoice(list){
-                this.detailsMultipleData = list
-            },
-            // 发布
-            releasefun(){
-                if (this.form.status == 0 || this.form.status == 2) {
-                    this.form.status = 1
-                }else if (this.form.status == 1) {
-                    this.form.status = 2
-                }
-                activityUpdate(this.form).then(res=>{
-                    this.$message.success('操作成功')
-                    this.activityDetailfun(this.form.id)
-                })
-            },
-            // 大保存
-            editCustomer(){
-                this.$refs["form"].validate((valid, done) => {
-                    if (valid) {
-                        let sumText = '请输入'
-                        let maxnum = 0
-                        for (let item of this.form.activityItemsList) {
-                            if (!Number(item.priceOne)) {
-                                sumText += ` 序号${item.$index + 1}促销价1`
-                            }
-                            if (!Number(item.priceTwo)) {
-                                sumText += ` 序号${item.$index + 1}促销价2`
-                            }
-                            if (!Number(item.priceThree)) {
-                                sumText += ` 序号${item.$index + 1}促销价3`
-                            }
-                            if (!Number(item.priceFour)) {
-                                sumText += ` 序号${item.$index + 1}促销价4`
-                            }
-                            maxnum += Number(item.maxQuantity)
+                        if (!Number(item.priceTwo)) {
+                            sumText += ` 序号${item.$index + 1}促销价2`
                         }
-                        if(sumText != '请输入') {
-                            this.$confirm(sumText, {
-                                confirmButtonText: "确定",
-                                cancelButtonText: "取消",
-                                type: "warning"
-                            })
-                            return;
+                        if (!Number(item.priceThree)) {
+                            sumText += ` 序号${item.$index + 1}促销价3`
                         }
-                        if (this.form.maxQuantity < maxnum) {
-                            return this.$message.warning('最大购买数量过大请重新修改')
+                        if (!Number(item.priceFour)) {
+                            sumText += ` 序号${item.$index + 1}促销价4`
                         }
-                        activitySubmit(this.form).then(res=>{
-                            this.$message.success('操作成功')
-                            this.activityDetailfun(res.data.data.id)
+                        maxnum += Number(item.maxQuantity)
+                    }
+                    if (sumText != '请输入') {
+                        this.$confirm(sumText, {
+                            confirmButtonText: "确定",
+                            cancelButtonText: "取消",
+                            type: "warning"
                         })
-                        done()
+                        return;
                     }
-                })
-            },
-            // 详情获取数据
-            activityDetailfun(id){
-                activityDetail(id).then(res=>{
-                    this.form = res.data.data
-                })
-            },
-            // 详情确认按钮
-            detailsRowCell(row,index){
-                if (row.$cellEdit) {
-                    this.$refs.optionDetailsRef.rowCancel(row,index)
-                }else {
-                    this.$refs.optionDetailsRef.rowCell(row, index)
-                }
-            },
-            // 图片上传
-            addPicture(){
-                this.excelBox = true
-            },
-            // 替换图片
-            changingtheImage(row,index){
-                this.detailsIndex = index
-                this.excelBox = true
-            },
-            //新增上传成功
-            onSuccess(response, file, fileList) {
-                if (this.detailsIndex) {
-                    this.$set(this.form.activityItemsList[this.detailsIndex],'goodsPictures',response.data.originalName)
-                    this.$set(this.form.activityItemsList[this.detailsIndex],'url',response.data.link)
-                }else {
-                    this.form.activePictures = response.data.originalName
-                    this.form.url = response.data.link
-                }
-                this.detailsIndex = null
-                this.excelBox = false;
-            },
-            // 弹窗多选回调
-            selectionDetails(list){
-                this.selectionDetailsData = list
-            },
-            // 弹窗确认
-            popupConfirmation(){
-                for (let item of this.selectionDetailsData) {
-                    this.form.activityItemsList.push({
-                        pid:this.form.id?this.form.id:null,
-                        cname:item.cname,
-                        specificationAndModel:item.specificationAndModel,
-                        inventory:item.inventory,
-                        goodsId:item.goodsId,
-                        priceOnePrimary:item.priceOne,
-                        priceTwoPrimary:item.priceTwo,
-                        priceThreePrimary:item.priceThree,
-                        priceFourPrimary:item.priceFour,
-                        brandId:item.brandId,
-                        brandName:item.brandName,
-                        brandItem:item.brandItem,
-                        placeProduction:null, // 产地
-                        explosionProof:item.explosionProof,
-                        originalFactory:item.originalFactory,
-                        selfRecovery:item.selfRecovery,
-                        minQuantity:1, // 最小购买数量
-                        maxQuantity:1, // 最大购买数量
-                        originalPrice:null, // 原价
-                        priceOne:null, // 促销价1
-                        priceTwo:null, // 促销价2
-                        priceThree:null, // 促销价3
-                        priceFour:null, // 促销价4
-                        goodsPictures:item.filesList.length > 0?item.filesList[0].fileName:'', // 商品图片名称
-                        url:item.filesList.length > 0?item.filesList[0].url:'',// 商品图片地址
-                        $cellEdit:true
+                    if (this.form.maxQuantity < maxnum) {
+                        return this.$message.warning('最大购买数量过大请重新修改')
+                    }
+                    activitySubmit(this.form).then(res => {
+                        this.$message.success('操作成功')
+                        this.activityDetailfun(res.data.data.id)
                     })
+                    done()
                 }
-                this.detailsVisible = false
-            },
-            // 详情添加商品
-            detailsAddButton(){
-                this.detailsVisible = true
-                let page = {pageSize: 20, currentPage: 1}
-                this.$nextTick(()=>{
-                    this.$refs.assemblyDetails.listAllPfun()
-                    this.$refs.assemblyDetails.onLoad(page)
+            })
+        },
+        // 详情获取数据
+        activityDetailfun(id) {
+            activityDetail(id).then(res => {
+                this.form = res.data.data
+            })
+        },
+        // 详情确认按钮
+        detailsRowCell(row, index) {
+            if (row.$cellEdit) {
+                row.$cellEdit = false
+            } else {
+                row.$cellEdit = true
+            }
+        },
+        // 图片上传
+        addPicture() {
+            this.excelBox = true
+        },
+        // 替换图片
+        changingtheImage(row, index) {
+            this.detailsIndex = index
+            this.excelBox = true
+        },
+        //新增上传成功
+        onSuccess(response, file, fileList) {
+            if (this.detailsIndex == null) {
+                this.form.activePictures = response.data.originalName
+                this.form.url = response.data.link
+            } else {
+                this.$set(this.form.activityItemsList[this.detailsIndex], 'goodsPictures', response.data.originalName)
+                this.$set(this.form.activityItemsList[this.detailsIndex], 'url', response.data.link)
+            }
+            this.detailsIndex = null
+            this.excelBox = false;
+        },
+        // 弹窗多选回调
+        selectionDetails(list) {
+            this.selectionDetailsData = list
+        },
+        // 弹窗确认
+        popupConfirmation() {
+            for (let item of this.selectionDetailsData) {
+                this.form.activityItemsList.push({
+                    pid: this.form.id ? this.form.id : null,
+                    cname: item.cname,
+                    specificationAndModel: item.specificationAndModel,
+                    inventory: item.inventory,
+                    goodsId: item.goodsId,
+                    priceOnePrimary: item.priceOne,
+                    priceTwoPrimary: item.priceTwo,
+                    priceThreePrimary: item.priceThree,
+                    priceFourPrimary: item.priceFour,
+                    brandId: item.brandId,
+                    brandName: item.brandName,
+                    brandItem: item.brandItem,
+                    placeProduction: null, // 产地
+                    explosionProof: item.explosionProof,
+                    originalFactory: item.originalFactory,
+                    selfRecovery: item.selfRecovery,
+                    minQuantity: 1, // 最小购买数量
+                    maxQuantity: 1, // 最大购买数量
+                    originalPrice: null, // 原价
+                    priceOne: null, // 促销价1
+                    priceTwo: null, // 促销价2
+                    priceThree: null, // 促销价3
+                    priceFour: null, // 促销价4
+                    goodsPictures: item.filesList.length > 0 ? item.filesList[0].fileName : '', // 商品图片名称
+                    url: item.filesList.length > 0 ? item.filesList[0].url : '',// 商品图片地址
+                    $cellEdit: true
                 })
+            }
+            this.detailsVisible = false
+        },
+        // 详情添加商品
+        detailsAddButton() {
+            this.detailsVisible = true
+            let page = { pageSize: 20, currentPage: 1 }
+            this.$nextTick(() => {
+                this.$refs.assemblyDetails.listAllPfun()
+                this.$refs.assemblyDetails.onLoad(page)
+            })
 
 
-            },
-            //自定义列保存
-            async saveColumnTwo(ref, option, optionBack, code) {
-                /**
-                 * 已定义全局方法,直接使用,saveColumnData保存列数据方法,参数传值(表格名称,当前表格的option数据)
-                 * 已定义全局方法,直接使用,getColumnName方法用来获取枚举值,参数根据自己定义的code值获取中文名
-                 * 一定要执行异步操作,要等接口成功返回,才能执行下一行代码
-                 */
-                const inSave = await this.saveColumnData(this.getColumnName(code), this[option]);
-                if (inSave) {
-                    this.$message.success("保存成功");
-                    //关闭窗口
-                    this.$refs[ref].$refs.dialogColumn.columnBox = false;
-                }
-            },
-            //自定义列重置
-            async resetColumnTwo(ref, option, optionBack, code) {
-                this[option] = this[optionBack];
-                const inSave = await this.delColumnData(this.getColumnName(code), this[optionBack]);
-                if (inSave) {
-                    this.$message.success("重置成功");
-                    this.$refs[ref].$refs.dialogColumn.columnBox = false;
-                }
-            },
-            // 返回列表
-            backToList() {
-                this.$emit("backToList");
+        },
+        //自定义列保存
+        async saveColumnTwo(ref, option, optionBack, code) {
+            /**
+             * 已定义全局方法,直接使用,saveColumnData保存列数据方法,参数传值(表格名称,当前表格的option数据)
+             * 已定义全局方法,直接使用,getColumnName方法用来获取枚举值,参数根据自己定义的code值获取中文名
+             * 一定要执行异步操作,要等接口成功返回,才能执行下一行代码
+             */
+            const inSave = await this.saveColumnData(this.getColumnName(code), this[option]);
+            if (inSave) {
+                this.$message.success("保存成功");
+                //关闭窗口
+                this.$refs[ref].$refs.dialogColumn.columnBox = false;
             }
+        },
+        //自定义列重置
+        async resetColumnTwo(ref, option, optionBack, code) {
+            this[option] = this[optionBack];
+            const inSave = await this.delColumnData(this.getColumnName(code), this[optionBack]);
+            if (inSave) {
+                this.$message.success("重置成功");
+                this.$refs[ref].$refs.dialogColumn.columnBox = false;
+            }
+        },
+        // 返回列表
+        backToList() {
+            this.$emit("backToList");
         }
     }
+}
 </script>
 
-<style scoped>
-
-</style>
+<style scoped></style>

+ 186 - 218
src/views/tirePartsMall/basicData/listingManagement/detail.vue

@@ -1,226 +1,194 @@
 <template>
-    <basic-container>
-      <avue-crud ref="crud" :data="dataList" :option="option" v-model="form" :search.sync="search" :table-loading="loading"
-        @saveColumn="saveColumn" @resetColumn="resetColumn" @search-change="searchChange" @current-change="currentChange"
-        @size-change="sizeChange" @refresh-change="refreshChange" @on-load="onLoad">
-        <template slot="billno" slot-scope="{ row, index }">
-          <span style="color: #409EFF;cursor: pointer" @click.stop="beforeOpenPage(row, index)">{{ row.billno }}</span>
-        </template>
-      </avue-crud>
-    </basic-container>
-  </template>
+  <basic-container>
+    <avue-crud ref="crud" :data="dataList" :option="option" v-model="form" :table-loading="loading">
+      <!-- <template slot="billno" slot-scope="{ row, index }">
+        <span style="color: #409EFF;cursor: pointer" @click.stop="beforeOpenPage(row, index)">{{ row.billno }}</span>
+      </template> -->
+    </avue-crud>
+  </basic-container>
+</template>
   
-  <script>
-  import option from "./config/detail.json";
-  import LTdetail from './config/LTdetail.json'
-  import {AppPartsStockDataDetails, stockDataDetails} from "@/api/basicData/inventoryAccount";
-  
-  export default {
-    name: "detail",
-    data() {
-      return {
-        option: {},
-        dataList: [],
-        form: {},
-        page: {
-          pageSize: 10,
-          pagerCount: 5,
-          total: 0,
-        },
-        search: {},
-        loading: false,
-        params: null,
-      }
-    },
-    async created() {
-      // this.option = option
-      console.log('打开了');
-      if (JSON.parse(localStorage.getItem('saber-tenantId')).content == 883868){
-          this.option = LTdetail;
-      }else {
-          this.option = await this.getColumnData(this.getColumnName(279), option);
-      }
-      this.$store.commit("DOMAS_IN_DETAIL");
-    },
-    activated() {
-      this.$store.commit("DOMAS_IN_DETAIL");
-      if (this.$route.query.type == 'JL'){
-          this.params = {
-              goodsId: this.$route.query.goodsId,
-              storageId: this.$route.query.stockId
+<script>
+import { productLaunchDetails } from "@/api/basicData/inventoryAccount";
+
+export default {
+  name: "detail",
+  data() {
+    return {
+      option: {
+        border: true,
+        align: 'center',
+        menuAlign: 'center',
+        header: false,
+        menu: false,
+        column: [
+          {
+            label: '业务编号',
+            prop: 'billno',
+            overHidden: true,
+          }, {
+            label: '商品名称',
+            prop: 'goodsName',
+            overHidden: true,
+          }, {
+            label: '状态',
+            prop: 'statusName',
+            overHidden: true,
+          }, {
+            label: '类型',
+            prop: 'bizTypeName',
+            overHidden: true,
+          }, {
+            label: '增加',
+            prop: 'addSendTotalNum',
+            overHidden: true,
+          }, {
+            label: '减少',
+            prop: 'subSendTotalNum',
+            overHidden: true,
           }
-      }else {
-          this.params = {
-              goodsId: this.$route.query.goodsId,
-              stockId: this.$route.query.stockId,
-              dot:this.$route.query.dot
-          }
-      }
-        this.onLoad(this.page)
-    },
-    methods: {
-      onLoad(page, params) {
-        if (!this.params) return
-        params = { ...params, ...this.params }
-        this.dataList.forEach(item => {
-          this.$refs.crud.toggleRowExpansion(item, false)
-        })
-        this.loading = true;
-        if (this.$route.query.type == 'JL') {
-            AppPartsStockDataDetails(params).then(res=>{
-                console.log(res)
-                this.dataList = res.data.data ? res.data.data : [];
-                this.page.total = res.data.data.total;
-                if (this.page.total) {
-                    this.option.height = window.innerHeight - 260;
-                }
-            }).finally(() => {
-                this.loading = false;
-            });
-        }else {
-            stockDataDetails(params)
-                .then(res => {
-                    console.log('res', res);
-                    this.dataList = res.data.data ? res.data.data : [];
-                    this.page.total = res.data.data.total;
-                    if (this.page.total) {
-                        this.option.height = window.innerHeight - 260;
-                    }
-                })
-                .finally(() => {
-                    this.loading = false;
-                });
-        }
-      },
-      searchChange(params, done) {
-        this.onLoad(this.page, params);
-        done();
+        ]
       },
-      currentChange(val) {
-        this.page.currentPage = val;
-      },
-      sizeChange(val) {
-        this.page.currentPage = 1;
-        this.page.pageSize = val;
-      },
-      refreshChange() {
-        this.dataList.forEach(item => {
-          this.$refs.crud.toggleRowExpansion(item, false)
-        })
-        this.page.currentPage = 1;
-        this.onLoad(this.page, this.search);
-      },
-      async saveColumn() {
-        const inSave = await this.saveColumnData(
-          this.getColumnName(279),
-          this.option
-        );
-        if (inSave) {
-          this.$message.success("保存成功");
-          //关闭窗口
-          this.$refs.crud.$refs.dialogColumn.columnBox = false;
-        }
-      },
-      async resetColumn() {
-        this.option = option;
-        const inSave = await this.delColumnData(
-          this.getColumnName(279),
-          option
-        );
-        if (inSave) {
-          this.$message.success("重置成功");
-          //关闭窗口
-          this.$refs.crud.$refs.dialogColumn.columnBox = false;
-        }
-      },
-      // 跳转
-      beforeOpenPage(row, index) {
-          if(row.bizTypeName == '盘点') {
-              console.log(this.$store.getters,139)
-              if (this.$store.getters.Inventory) {
-                  this.$alert("明细账已存在,请保存关闭明细账再进行操作", "温馨提示", {
-                      confirmButtonText: "确定",
-                      type: "warning",
-                      callback: action => {
-                          console.log(action);
-                      }
-                  });
-              }else {
-                  this.$router.$avueRouter.closeTag("/tirePartsMall/salesManagement/Inventory/index");
-                  this.$router.push({
-                      path: "/tirePartsMall/salesManagement/Inventory/index",
-                      query: {
-                          orderId: row.id
-                      },
-                  });
-              }
-          }else {
-              if (this.$store.getters.inboundAndOutbound) {
-                  this.$alert("明细账已存在,请保存关闭明细账再进行操作", "温馨提示", {
-                      confirmButtonText: "确定",
-                      type: "warning",
-                      callback: action => {
-                          console.log(action);
-                      }
-                  });
-              } else {
-                  if (row.bizTypeName == '出库') {
-                      this.$router.$avueRouter.closeTag("/tirePartsMall/salesManagement/outboundWorkOrder/index");
-                      this.$router.push({
-                          path: "/tirePartsMall/salesManagement/outboundWorkOrder/index",
-                          query: {
-                              id: row.id
-                          },
-                      });
-                  }else if (row.bizTypeName == '销售') {
-                      this.$router.$avueRouter.closeTag("/salesOrder/index");
-                      this.$router.push({
-                          path: "/salesOrder/index",
-                          query: {
-                              orderId: row.id
-                          },
-                      });
-                  } else if (row.bizTypeName == '采购') {
-                      this.$router.$avueRouter.closeTag("/purchaseOrder/index");
-                      this.$router.push({
-                          path: "/purchaseOrder/index",
-                          query: {
-                              orderId: row.id
-                          },
-                      });
-                  } else if (row.bizTypeName == '调出') {
-                      if (this.$store.getters.Allocateandtransfer) {
-                          this.$alert("调拨明细已存在,请保存关闭明细账再进行操作", "温馨提示", {
-                              confirmButtonText: "确定",
-                              type: "warning",
-                              callback: action => {
-                                  console.log(action);
-                              }
-                          });
-                      }else {
-                          this.$router.$avueRouter.closeTag("/tirePartsMall/salesManagement/outboundWorkOrderL/index");
-                          this.$router.push({
-                              path: "/tirePartsMall/salesManagement/outboundWorkOrderL/index",
-                              query: {
-                                  id: row.id
-                              },
-                          });
-                      }
-                  } else {
-                      this.$router.$avueRouter.closeTag("/tirePartsMall/purchasingManagement/warehouseEntryOrder/index");
-                      this.$router.push({
-                          path: "/tirePartsMall/purchasingManagement/warehouseEntryOrder/index",
-                          query: {
-                              id: row.id
-                          },
-                      });
-                  }
-              }
-          }
+      dataList: [],
+      form: {},
+      page: {
+        pageSize: 10,
+        pagerCount: 1,
+        total: 0,
       },
+      search: {},
+      loading: false,
+      params: null,
+    }
+  },
+  async created() {
+    this.params = {
+      goodsId: this.$route.query.goodsId,
+    }
+    this.onLoad()
+  },
+  methods: {
+    onLoad() {
+      this.loading = true;
+      productLaunchDetails(this.params).then(res => {
+        console.log(res)
+        this.dataList = res.data.data ? res.data.data : [];
+        this.option.height = window.innerHeight - 260;
+      }).finally(() => {
+        this.loading = false;
+      });
     },
-  }
-  </script>
+    // async saveColumn() {
+    //   const inSave = await this.saveColumnData(
+    //     this.getColumnName(279),
+    //     this.option
+    //   );
+    //   if (inSave) {
+    //     this.$message.success("保存成功");
+    //     //关闭窗口
+    //     this.$refs.crud.$refs.dialogColumn.columnBox = false;
+    //   }
+    // },
+    // async resetColumn() {
+    //   this.option = option;
+    //   const inSave = await this.delColumnData(
+    //     this.getColumnName(279),
+    //     option
+    //   );
+    //   if (inSave) {
+    //     this.$message.success("重置成功");
+    //     //关闭窗口
+    //     this.$refs.crud.$refs.dialogColumn.columnBox = false;
+    //   }
+    // },
+    // // 跳转
+    // beforeOpenPage(row, index) {
+    //   if (row.bizTypeName == '盘点') {
+    //     console.log(this.$store.getters, 139)
+    //     if (this.$store.getters.Inventory) {
+    //       this.$alert("明细账已存在,请保存关闭明细账再进行操作", "温馨提示", {
+    //         confirmButtonText: "确定",
+    //         type: "warning",
+    //         callback: action => {
+    //           console.log(action);
+    //         }
+    //       });
+    //     } else {
+    //       this.$router.$avueRouter.closeTag("/tirePartsMall/salesManagement/Inventory/index");
+    //       this.$router.push({
+    //         path: "/tirePartsMall/salesManagement/Inventory/index",
+    //         query: {
+    //           orderId: row.id
+    //         },
+    //       });
+    //     }
+    //   } else {
+    //     if (this.$store.getters.inboundAndOutbound) {
+    //       this.$alert("明细账已存在,请保存关闭明细账再进行操作", "温馨提示", {
+    //         confirmButtonText: "确定",
+    //         type: "warning",
+    //         callback: action => {
+    //           console.log(action);
+    //         }
+    //       });
+    //     } else {
+    //       if (row.bizTypeName == '出库') {
+    //         this.$router.$avueRouter.closeTag("/tirePartsMall/salesManagement/outboundWorkOrder/index");
+    //         this.$router.push({
+    //           path: "/tirePartsMall/salesManagement/outboundWorkOrder/index",
+    //           query: {
+    //             id: row.id
+    //           },
+    //         });
+    //       } else if (row.bizTypeName == '销售') {
+    //         this.$router.$avueRouter.closeTag("/salesOrder/index");
+    //         this.$router.push({
+    //           path: "/salesOrder/index",
+    //           query: {
+    //             orderId: row.id
+    //           },
+    //         });
+    //       } else if (row.bizTypeName == '采购') {
+    //         this.$router.$avueRouter.closeTag("/purchaseOrder/index");
+    //         this.$router.push({
+    //           path: "/purchaseOrder/index",
+    //           query: {
+    //             orderId: row.id
+    //           },
+    //         });
+    //       } else if (row.bizTypeName == '调出') {
+    //         if (this.$store.getters.Allocateandtransfer) {
+    //           this.$alert("调拨明细已存在,请保存关闭明细账再进行操作", "温馨提示", {
+    //             confirmButtonText: "确定",
+    //             type: "warning",
+    //             callback: action => {
+    //               console.log(action);
+    //             }
+    //           });
+    //         } else {
+    //           this.$router.$avueRouter.closeTag("/tirePartsMall/salesManagement/outboundWorkOrderL/index");
+    //           this.$router.push({
+    //             path: "/tirePartsMall/salesManagement/outboundWorkOrderL/index",
+    //             query: {
+    //               id: row.id
+    //             },
+    //           });
+    //         }
+    //       } else {
+    //         this.$router.$avueRouter.closeTag("/tirePartsMall/purchasingManagement/warehouseEntryOrder/index");
+    //         this.$router.push({
+    //           path: "/tirePartsMall/purchasingManagement/warehouseEntryOrder/index",
+    //           query: {
+    //             id: row.id
+    //           },
+    //         });
+    //       }
+    //     }
+    //   }
+    // },
+  },
+}
+</script>
   
-  <style scoped></style>
+<style scoped></style>
   

+ 12 - 1
src/views/tirePartsMall/basicData/listingManagement/index.vue

@@ -25,7 +25,7 @@
               </avue-ueditor>
             </template>
             <template slot-scope="{ row, index }" slot="inventory">
-              <span style="color: #409EFF;cursor: pointer" @click.stop="editOpen(row)">{{ row.inventory }}
+              <span style="color: #409EFF;cursor: pointer" @click.stop="storeInventoryOpen(row)">{{ row.inventory }}
               </span>
             </template>
             <template slot-scope="{type,size,row,index}" slot="menu">
@@ -992,6 +992,17 @@ export default {
         }, 1000);
       }
     },
+    //点击可用库存打开
+    storeInventoryOpen(row) {
+      this.$router.push({
+        path: "/tirePartsMall/basicData/listingManagement/detail",
+        query: {
+          goodsId: row.goodsId,
+          dot: row.dot
+        },
+      });
+
+    },
     //自定义列保存
     async saveColumnTwo(ref, option, optionBack, code) {
       /**

+ 4 - 4
src/views/tirePartsMall/purchaseService/Task/index.vue

@@ -153,7 +153,7 @@ export default {
           overHidden: true,
           props: {
             label: 'cname',
-            value: 'id'
+            value: 'cname'
           },
           dicUrl: '/api/blade-sales-part/corpsDesc/listAll?corpType=GYS',
         }
@@ -172,7 +172,7 @@ export default {
         // },
         // {
         //   label: '来源公司',
-        //   prop: "sourceCompanyName",
+        //   prop: "salesCompanyName",
         //   search: true,
         //   width: 100,
         //   overHidden: true,
@@ -199,14 +199,14 @@ export default {
         },
          {
           label: '库管',
-          prop: "stockClerkId",
+          prop: "stockClerkName",
           width: 100,
           cell:false,
           overHidden: true,
           type: 'select',
           props: {
             label: 'realName',
-            value: 'id'
+            value: 'realName'
           },
           dicUrl: '/api/blade-user/stockClerkList',
         },

+ 12 - 13
src/views/tirePartsMall/purchaseService/outStorage/index.vue

@@ -138,13 +138,13 @@ export default {
         column: [
           {
             label: '商品名称',
-            prop: 'goodsId',
+            prop: 'goodsName',
             disabled: true,
             width: 200,
             overHidden: true,
             props: {
               label: 'cname',
-              value: 'id'
+              value: 'cname'
             },
             dicUrl: '/api/blade-sales-part/goodsDesc/goodsListAll'
           }, {
@@ -154,13 +154,13 @@ export default {
             width: 100
           }, {
             label: '品牌',
-            prop: 'brandId',
+            prop: 'brandName',
             disabled: true,
             width: 100,
             overHidden: true,
             props: {
               label: 'cname',
-              value: 'id'
+              value: 'cname'
             },
             dicUrl: '/api/blade-sales-part/brandDesc/listAll?type=PP&enableOrNot=1'
           }, {
@@ -242,24 +242,24 @@ export default {
           }
         }, {
           label: '业务对象',
-          prop: "customerId",
+          prop: "customerName",
           search: true,
           overHidden: true,
           type: 'select',
           props: {
             label: 'cname',
-            value: 'id'
+            value: 'cname'
           },
           dicUrl: '/api/blade-sales-part/corpsDesc/listAll?corpType=GYS',
         }, {
           label: '仓库',
-          prop: "storageId",
+          prop: "storageName",
           search: true,
           overHidden: true,
           type: 'select',
           props: {
             label: 'cname',
-            value: 'id'
+            value: 'cname'
           },
           dicUrl: '/api/blade-sales-part/storageDesc/listAll',
         }
@@ -299,7 +299,6 @@ export default {
           overHidden: true,
           searchProp: "businesDateList",
           type: "date",
-          overHidden: true,
           search: true,
           width: 100,
           searchRange: true,
@@ -308,12 +307,12 @@ export default {
           valueFormat: "yyyy-MM-dd HH:mm:ss"
         }, {
           label: '库管',
-          prop: "stockClerkId",
+          prop: "stockClerkName",
           type: 'select',
           search: true,
           props: {
             label: 'realName',
-            value: 'id'
+            value: 'realName'
           },
           dicUrl: '/api/blade-user/stockClerkList',
           overHidden: true,
@@ -329,7 +328,7 @@ export default {
           dicUrl: "/api/blade-user/page?size=20&current=1&account={{key}}",
           props: {
             label: "account",
-            value: "id",
+            value: "account",
             res: 'data.records'
           }
         }, {
@@ -355,7 +354,7 @@ export default {
           dicUrl: "/api/blade-user/page?size=20&current=1&account={{key}}",
           props: {
             label: "account",
-            value: "id",
+            value: "account",
             res: 'data.records'
           }
         }, {

+ 1 - 1
src/views/tirePartsMall/purchaseService/returns/index.vue

@@ -245,7 +245,7 @@ export default {
             dicUrl: "/api/blade-user/page?size=20&current=1&account={{key}}",
             props: {
               label: "account",
-              value: "id",
+              value: "account",
               res: 'data.records'
             }
           },

+ 2 - 2
src/views/tirePartsMall/purchasingManagement/warehouseEntryOrder/index.vue

@@ -214,14 +214,14 @@ export default {
           ]
         }, {
           label: "业务对象",
-          prop: "customerId",
+          prop: "customerName",
           search: true,
           overHidden: true,
           filterable:true,
           type: 'select',
           props: {
             label: 'cname',
-            value: 'id'
+            value: 'cname'
           },
             dicData: [],
         }, {

+ 3 - 3
src/views/tirePartsMall/salesManagement/inboundTask/index.vue

@@ -153,7 +153,7 @@ export default {
           overHidden: true,
           props: {
             label: 'cname',
-            value: 'id'
+            value: 'cname'
           },
           dicUrl: '/api/blade-sales-part/corpsDesc/listAll?corpType=GYS',
         }
@@ -199,14 +199,14 @@ export default {
         },
          {
           label: '库管',
-          prop: "stockClerkId",
+          prop: "stockClerkName",
           width: 100,
           cell:false,
           overHidden: true,
           type: 'select',
           props: {
             label: 'realName',
-            value: 'id'
+            value: 'realName'
           },
           dicUrl: '/api/blade-user/stockClerkList',
         },

+ 4 - 4
src/views/tirePartsMall/salesManagement/outboundTask/index.vue

@@ -141,7 +141,7 @@ export default {
           overHidden: true,
           props: {
             label: 'cname',
-            value: 'id'
+            value: 'cname'
           },
           dicUrl: '/api/blade-sales-part/corpsDesc/listAll?corpType=KH',
         }
@@ -159,7 +159,7 @@ export default {
         },
         {
           label: '来源公司',
-          prop: "sourceCompanyName",
+          prop: "salesCompanyName",
           search: true,
           width: 100,
           overHidden: true,
@@ -186,14 +186,14 @@ export default {
         },
          {
           label: '库管',
-          prop: "stockClerkId",
+          prop: "stockClerkName",
           width: 100,
           cell:false,
           overHidden: true,
           type: 'select',
           props: {
             label: 'realName',
-            value: 'id'
+            value: 'realName'
           },
           dicUrl: '/api/blade-user/stockClerkList',
         },

+ 6 - 7
src/views/tirePartsMall/salesManagement/outboundWorkOrder/index.vue

@@ -242,26 +242,26 @@ export default {
           }
         }, {
           label: '业务对象',
-          prop: "customerId",
+          prop: "customerName",
           search: true,
           overHidden: true,
           filterable:true,
           type: 'select',
           props: {
             label: 'cname',
-            value: 'id'
+            value: 'cname'
           },
           dicUrl: '/api/blade-sales-part/corpsDesc/listAll?corpType=KH',
         }, {
           label: '仓库',
-          prop: "storageId",
+          prop: "storageName",
           search: true,
           overHidden: true,
           filterable:true,
           type: 'select',
           props: {
             label: 'cname',
-            value: 'id'
+            value: 'cname'
           },
           dicUrl: '/api/blade-sales-part/storageDesc/listAll',
         }
@@ -299,7 +299,6 @@ export default {
           overHidden: true,
           searchProp: "businesDateList",
           type: "date",
-          overHidden: true,
           search: true,
           width: 100,
           searchRange: true,
@@ -308,12 +307,12 @@ export default {
           valueFormat: "yyyy-MM-dd HH:mm:ss"
         }, {
           label: '库管',
-          prop: "stockClerkId",
+          prop: "stockClerkName",
           type: 'select',
           search: true,
           props: {
             label: 'realName',
-            value: 'id'
+            value: 'realName'
           },
           dicUrl: '/api/blade-user/stockClerkList',
           overHidden: true,

+ 4 - 4
src/views/tirePartsMall/salesService/Task/index.vue

@@ -140,7 +140,7 @@ export default {
           overHidden: true,
           props: {
             label: 'cname',
-            value: 'id'
+            value: 'cname'
           },
           dicUrl: '/api/blade-sales-part/corpsDesc/listAll?corpType=KH',
         }, 
@@ -158,7 +158,7 @@ export default {
         // },
         {
           label: '来源公司',
-          prop: "sourceCompanyName",
+          prop: "salesCompanyName",
           search: true,
           width: 100,
           overHidden: true,
@@ -185,14 +185,14 @@ export default {
         },
          {
           label: '库管',
-          prop: "stockClerkId",
+          prop: "stockClerkName",
           width: 100,
           cell:false,
           overHidden: true,
           type: 'select',
           props: {
             label: 'realName',
-            value: 'id'
+            value: 'realName'
           },
           dicUrl: '/api/blade-user/stockClerkList',
         },

+ 10 - 10
src/views/tirePartsMall/salesService/inStorage/index.vue

@@ -84,7 +84,7 @@ export default {
         column: [
           {
             label: '商品名称',
-            prop: 'goodsId',
+            prop: 'goodsName',
             width: 200,
             overHidden: true,
             disabled: false,
@@ -92,7 +92,7 @@ export default {
             type: 'select',
             props: {
               label: 'cname',
-              value: 'id'
+              value: 'cname'
             },
             dicUrl: '/api/blade-sales-part/goodsDesc/goodsListAll'
           },
@@ -127,14 +127,14 @@ export default {
             width: 140
           }, {
             label: "品牌",
-            prop: 'brandId',
+            prop: 'brandName',
             width: 100,
             overHidden: true,
             disabled: false,
             type: 'select',
             props: {
               label: 'cname',
-              value: 'id'
+              value: 'cname'
             },
             dicUrl: '/api/blade-sales-part/brandDesc/listAll?type=PP&enableOrNot=1'
           }, {
@@ -217,13 +217,13 @@ export default {
           ]
         }, {
           label: "业务对象",
-          prop: "customerId",
+          prop: "customerName",
           search: true,
           overHidden: true,
           type: 'select',
           props: {
             label: 'cname',
-            value: 'id'
+            value: 'cname'
           },
             dicData: [],
           // dicUrl: '/api/blade-sales-part/corpsDesc/listAll?corpType=GYS',
@@ -239,7 +239,7 @@ export default {
           dicUrl: "/api/blade-sales-part/storageDesc/listAll",
           props: {
             label: 'cname',
-            value: 'id'
+            value: 'cname'
           },
           // change:(data)=>{
           //   console.log(this.$refs.crud.DIC.storageName[0].salesCompanyId);
@@ -287,7 +287,7 @@ export default {
           type: 'select',
           props: {
             label: 'realName',
-            value: 'id'
+            value: 'realName'
           },
           dicUrl: '/api/blade-user/stockClerkList',
           // props: {
@@ -308,7 +308,7 @@ export default {
           dicUrl: "/api/blade-user/page?size=20&current=1&account={{key}}",
           props: {
             label: "account",
-            value: "id",
+            value: "account",
             res: 'data.records'
           }
         }, {
@@ -334,7 +334,7 @@ export default {
           dicUrl: "/api/blade-user/page?size=20&current=1&account={{key}}",
           props: {
             label: "account",
-            value: "id",
+            value: "account",
             res: 'data.records'
           }
         }, {

+ 1 - 1
src/views/tirePartsMall/salesService/returns/index.vue

@@ -134,7 +134,7 @@ export default {
             type: "select",
             props: {
               label: "name",
-              value: "name"
+              value: "id"
             },
             dicUrl: "/api/blade-user/client/getUserByRole",
             filterable: true,

+ 74 - 47
src/views/tirePartsMall/statisticAnalysis/generalLedgerReceivable/index.vue

@@ -4,7 +4,8 @@
       <avue-crud ref="crud" :option="option" :data="dataList" :page.sync="page" :search.sync="search"
         :cell-style="cellStyle" @search-change="searchChange" @current-change="currentChange" @size-change="sizeChange"
         @refresh-change="refreshChange" @on-load="onLoad" :table-loading="loading" @saveColumn="saveColumn"
-        @resetColumn="resetColumn" @search-criteria-switch="searchCriteriaSwitch" @search-reset="searchReset">
+        @resetColumn="resetColumn" @search-criteria-switch="searchCriteriaSwitch" @search-reset="searchReset"
+        >
         <template slot="menuLeft">
           <el-button type="info" icon="el-icon-printer" size="small" :loading="exportLoading" @click.stop="statement"
             v-if="false">报表打印</el-button>
@@ -21,9 +22,12 @@
         </template>
         <template slot="customerName" slot-scope="scope">
           <span style="color: #409EFF;cursor: pointer" @click.stop="beforeOpenPage(scope.row, scope.index)">{{
-              scope.row.customerName
+            scope.row.customerName
           }}</span>
         </template>
+        <template slot="whetherSettlementSearch">
+          <el-checkbox v-model="search.whetherSettlement" :true-label="1" :false-label="0"></el-checkbox>
+        </template>
       </avue-crud>
     </basic-container>
     <report-dialog :switchDialog="switchDialog" :searchValue="statementData" :reportName="'经销商-可用库存表'"
@@ -54,7 +58,9 @@ export default {
       switchDialog: false,
       statementData: {},
       form: {},
-      search: {},
+      search: {
+        whetherSettlement:0
+      },
       dataList: [],
       loading: false,
       detailData: {},
@@ -68,7 +74,8 @@ export default {
       defaultOption: {
         searchShow: true,
         align: "center",
-        searchSpan: 8,
+        searchSpan: 6,
+        searchMenuSpan: 24,
         border: true,
         index: true,
         addBtn: false,
@@ -92,7 +99,7 @@ export default {
           },
         ],
         searchIcon: true,
-        searchIndex: 2,
+        searchIndex: 3,
         menu: false,
         column: [
           {
@@ -101,12 +108,36 @@ export default {
             type: "select",
             search: true,
             overHidden: true,
+            filterable: true,
             props: {
               label: 'cname',
-              value: 'id'
+              value: 'cname'
             },
-            dicUrl: '/api/blade-sales-part/corpsDesc/listAll?cname={{key}}&corpType=KH&enableOrNot=0',
-
+            dicUrl: '/api/blade-sales-part/corpsDesc/listAll?cname={{key}}&corpType=KH&enableOrNot=1',
+          },
+          {
+            label: '业务员',
+            prop: "salerId",
+            search: true,
+            type: "select",
+            props: {
+              label: "name",
+              value: "id"
+            },
+            dicUrl: "/api/blade-user/client/getUserByRole",
+            filterable: true,
+            hide:true,
+          },
+          {
+            label: '业务员',
+            prop: "salerName",
+            overHidden: true,
+          },
+          {
+            label: "结清不显示",
+            prop: "whetherSettlement",
+            search: true,
+            hide: true
           },
           {
             label: "业务日期",
@@ -155,7 +186,7 @@ export default {
             prop: "outstandingAmount",
             search: false,
             overHidden: true,
-          }
+          },
         ],
       },
       // 仓库配置
@@ -173,13 +204,8 @@ export default {
       show: true,
     };
   },
-  filters: {
-    decimalFormat(num) {
-      return num ? Number(num).toFixed(2) : "0.00";
-    }
-  },
   async created() {
-      // this.option = this.defaultOption;
+    this.option = this.defaultOption;
     this.option = await this.getColumnData(this.getColumnName(284), this.defaultOption);
 
     this.getWorkDicts('brand').then(res => {
@@ -188,15 +214,11 @@ export default {
     gainUser().then(res => {
       this.userList = res.data.data;
     });
+    this.key++
     let i = 0;
     this.option.column.forEach(item => {
       if (item.search) i++
     })
-    if (i % 3 !== 0) {
-      const num = 3 - Number(i % 3)
-      this.option.searchMenuSpan = num * 8;
-      this.option.searchMenuPosition = "right";
-    }
   },
   methods: {
     cellStyle() {
@@ -311,31 +333,7 @@ export default {
     onClose(val) {
       this.switchDialog = val;
     },
-    //列保存触发
-    async saveColumn() {
-        const inSave = this.saveColumnData(this.getColumnName(284), this.option);
-      if (inSave) {
-        this.$nextTick(() => {
-          this.$refs.crud.doLayout();
-        });
-        this.$message.success("保存成功");
-        //关闭窗口
-        this.$refs.crud.$refs.dialogColumn.columnBox = false;
-      }
-    },
-    async resetColumn() {
-      this.option = this.defaultOption;
-      //   this.option = await this.getColumnData(this.getColumnName(284), this.defaultOption);
-      const inSave = await this.delColumnData(this.getColumnName(284), this.defaultOption);
-      if (inSave) {
-        this.$nextTick(() => {
-          this.$refs.crud.doLayout()
-        })
-        this.$message.success("重置成功");
-        //关闭窗口
-        this.$refs.crud.$refs.dialogColumn.columnBox = false;
-      }
-    },
+
     // 跳转到详情
     beforeOpenPage(row, index) {
       this.detailData = {
@@ -381,8 +379,8 @@ export default {
         window.open(
           `/api/blade-sales-part/order/statistics-export?${this.website.tokenHeader
           }=${getToken()}&type=0&businesDateList[0]=${this.search.businesDateList[0] == null || this.search.businesDateList[0] === undefined ? '' : this.search.businesDateList[0]
-          }&businesDateList[1]=${this.search.businesDateList[1] == null || this.search.businesDateList[1] === undefined  ? '' : this.search.businesDateList[1]
-          }&customerId=${this.search.customerName == null || this.search.customerName === undefined  ? '' : this.search.customerName}`
+          }&businesDateList[1]=${this.search.businesDateList[1] == null || this.search.businesDateList[1] === undefined ? '' : this.search.businesDateList[1]
+          }&customerId=${this.search.customerName == null || this.search.customerName === undefined ? '' : this.search.customerName}`
         );
       }).catch(() => {
         this.$message({
@@ -391,6 +389,31 @@ export default {
         });
       })
     },
+        //列保存触发
+        async saveColumn() {
+      const inSave = this.saveColumnData(this.getColumnName(284), this.option);
+      if (inSave) {
+        this.$nextTick(() => {
+          this.$refs.crud.doLayout();
+        });
+        this.$message.success("保存成功");
+        //关闭窗口
+        this.$refs.crud.$refs.dialogColumn.columnBox = false;
+      }
+    },
+    async resetColumn() {
+      this.option = this.defaultOption;
+      //   this.option = await this.getColumnData(this.getColumnName(284), this.defaultOption);
+      const inSave = await this.delColumnData(this.getColumnName(284), this.defaultOption);
+      if (inSave) {
+        this.$nextTick(() => {
+          this.$refs.crud.doLayout()
+        })
+        this.$message.success("重置成功");
+        //关闭窗口
+        this.$refs.crud.$refs.dialogColumn.columnBox = false;
+      }
+    },
   }
 };
 </script>
@@ -407,4 +430,8 @@ export default {
 .itemTable ::v-deep .el-table {
   width: 100%;
 }
+
+/deep/ .el-col-md-8 {
+  width: 24.33333%;
+}
 </style>