소스 검색

修改bug

chenrui 1 년 전
부모
커밋
acec2e9da9
2개의 변경된 파일14개의 추가작업 그리고 8개의 파일을 삭제
  1. 11 0
      src/api/product.js
  2. 3 8
      src/views/productManagement/newProduct/list.vue

+ 11 - 0
src/api/product.js

@@ -11,6 +11,17 @@ export const productList = (params) => {
     method: 'post'
   })
 }
+// 产品上线信息列表
+export const queryOnlinePageList = (params) => {
+  const url = `/productLog/queryOnlinePage/${params.pageNo}/${params.pageSize}`
+  delete params.pageNo
+  delete params.pageSize
+  return axios({
+    url: url,
+    data: params,
+    method: 'post'
+  })
+}
 //  产品 列表 已定过价的 分页
 export const productPricedList = (params) => {
   const url = `/product/queryPricedPage/${params.pageNo}/${params.pageSize}`

+ 3 - 8
src/views/productManagement/newProduct/list.vue

@@ -64,10 +64,6 @@
         <template slot="auditTimeTit">
           {{ $route.params.onlineFalg=='1'?'上':'下' }}线时间
         </template>
-        <!-- 上/下线时间 内容 -->
-        <template slot="auditTime" slot-scope="text, record">
-          {{ ($route.params.onlineFalg=='1'&&$route.params.type=="onlineInfo")?record.onlineAuditTime:record.auditTime }}
-        </template>
         <!-- 产品分类 -->
         <template slot="productType" slot-scope="text, record">
           <span v-if="record.productTypeName2 || record.productTypeName3">{{ record.productTypeName2 }} {{ record.productTypeName3 ? '>' : '' }} {{ record.productTypeName3 }}</span>
@@ -88,7 +84,7 @@
 </template>
 <script>
 import { commonMixin } from '@/utils/mixin'
-import { queryNewProductPage, productList } from '@/api/product'
+import { queryNewProductPage, queryOnlinePageList } from '@/api/product'
 import { STable, VSelect } from '@/components'
 import ProductBrand from '@/views/common/productBrand.js'
 import productTypeAll from '@/views/common/productTypeAll.js'
@@ -126,7 +122,7 @@ export default {
       ],
       columns: [
         { title: '序号', dataIndex: 'no', width: 50, align: 'center' },
-        { slots: { title: 'auditTimeTit' }, scopedSlots: { customRender: 'auditTime' }, width: 140, align: 'center' },
+        { slots: { title: 'auditTimeTit' }, dataIndex: 'auditTime', width: 140, align: 'center',customRender: function (text) { return text || '--' } },
         { title: '产品品牌', dataIndex: 'productBrandName', width: 120, align: 'center', customRender: function (text) { return text || '--' } },
         { title: '产品分类', scopedSlots: { customRender: 'productType' }, width: 140, align: 'center' },
         { title: '产品名称', dataIndex: 'name', align: 'center', ellipsis: true, customRender: function (text) { return text || '--' } },
@@ -139,9 +135,8 @@ export default {
       loadData: parameter => {
         this.disabled = true
         this.spinning = true
-        const ajaxName = this.$route.params.type == 'onlineInfo' ? productList : queryNewProductPage
+        const ajaxName = this.$route.params.type == 'onlineInfo' ? queryOnlinePageList : queryNewProductPage
         if (this.$route.params.type == 'onlineInfo') {
-          this.queryParam.state = 'ONLINE'
           if (this.queryParam.beginDate || this.queryParam.endDate) {
             this.queryParam.onlineFalg = 1
             this.queryParam.newProductDateScope = 9999