Преглед изворни кода

销售报表新增销售字段,快手报表修改日期格式

朱鑫波 пре 4 година
родитељ
комит
c3c2017852

+ 2 - 2
src/views/modules/Statistics/KSAccountReport.vue

@@ -741,7 +741,7 @@ export default {
           endDate:this.dateValue[1].format('YYYY-MM-DD')
         })
         if(this.accountId.length==1  &&  this.dateValue[0].format('YYYY.MM.DD')!=this.dateValue[1].format('YYYY.MM.DD')){
-            this.target='stat_Datetime',
+            this.target='statDate',
             this.order='asc'
         }else{
             this.target='cost',
@@ -1222,7 +1222,7 @@ export default {
                   this.target=sorter.columnKey;
               }else{
                 if(this.accountId.length==1  &&  this.dateValue[0].format('YYYY.MM.DD')!=this.dateValue[1].format('YYYY.MM.DD')){
-                    this.target='stat_Datetime',
+                    this.target='statDate',
                     this.order='asc'
                 }else{
                     this.target='cost',

+ 9 - 0
src/views/modules/Statistics/xiaoshouStatistics.vue

@@ -477,6 +477,15 @@
       align: 'center',
     },
     {
+      title: '销售',
+      dataIndex: 'saleName',
+      scopedSlots: {
+        customRender: 'saleName'
+      },
+      align: 'center',
+    },
+    
+    {
       title: '时间',
       dataIndex: 'statDate',
       // width:200,

+ 88 - 6
src/views/playerPart/playerList.vue

@@ -1,6 +1,6 @@
 <template>
   <div class="playerList">
-    <div class="top">
+    <!-- <div class="top">
       <div class="playBody">
         <div class="box">
           <div
@@ -34,7 +34,33 @@
           </div>
         </div>
       </div>
-    </div>
+    </div> -->
+
+    <a-card :bordered="false">
+      <a-button @click="addModules" style="margin: 0 0 15px 0" type="primary">新增模板</a-button>
+      <div>
+        <a-table
+          ref="table"
+          size="middle"
+          bordered
+          rowKey="id"
+          :columns="columns"
+          :dataSource="dataSource"
+          :loading="loading"
+        >
+          <span slot="action" slot-scope="text, record">
+            <a @click="preview(record)">预览</a>
+
+            <a-divider type="vertical" />
+
+            <a-popconfirm title="确定删除吗?" @confirm="() => handleDelete(record.id)">
+              <a>删除</a>
+            </a-popconfirm>
+          </span>
+        </a-table>
+      </div>
+      <!-- table区域-end -->
+    </a-card>
     <div class="previewBody" v-if="previewBody">
       <div class="content">
         <div class="content-inner">
@@ -50,9 +76,9 @@
 </template>
 
 <script>
+import { getAction, postAction } from '../../api/manage'
 import playerList from './playerData'
-
-console.log(playerList)
+import { mapGetters } from 'vuex'
 
 export default {
   data() {
@@ -61,13 +87,48 @@ export default {
       previewBody: false,
       playerSrc: '',
       previewVisible: false,
+      loading: false,
+      dataSource: [],
+      columns: [
+        {
+          title: '试玩名称',
+          align: 'center',
+          dataIndex: 'fileName',
+        },
+        {
+          title: '试玩分类',
+          align: 'center',
+          dataIndex: 'fileType',
+        },
+        {
+          title: '上传时间',
+          align: 'center',
+          dataIndex: 'createTime',
+        },
+        {
+          title: '操作',
+          dataIndex: 'action',
+          align: 'center',
+          scopedSlots: {
+            customRender: 'action',
+          },
+        },
+      ],
     }
   },
   methods: {
+    ...mapGetters(['nickname', 'avatar', 'userInfo']),
     preview(item) {
       console.log(item)
-      this.previewBody = true
-      this.playerSrc = item.link
+
+      getAction('/shiwan/shiwanFileUpload/selectListByParentId', { id: item.id }).then((res) => {
+        if (res.success) {
+          this.previewBody = true
+          this.playerSrc = res.result.filter((i) => {
+            return i.fileSuffix == 'html'
+          })[0].fileUrl
+        }
+      })
     },
     closePreview() {
       this.previewBody = false
@@ -75,6 +136,27 @@ export default {
     handleCancel() {
       this.previewVisible = false
     },
+    addModules() {},
+    handleDelete(item) {
+      postAction('/shiwan/shiwanFileUpload/edit', { id: item, fileStatus: '0' }).then((res) => {
+        if (res.success) {
+          this.getPlayableList()
+        }
+      })
+    },
+    getPlayableList() {
+      getAction('/shiwan/shiwanFileUpload/list', {
+        pageNo: 1,
+        pageSize: 1000,
+      }).then((res) => {
+        if (res.success) {
+          this.dataSource = res.result.records
+        }
+      })
+    },
+  },
+  mounted() {
+    this.getPlayableList()
   },
 }
 </script>

+ 2 - 2
vue.config.js

@@ -81,11 +81,11 @@ module.exports = {
         // target: 'http://192.168.1.94:8080', //请求本地 需要jeecg-boot后台项目  赵西安
 
 
-         target: 'http://api.tjyourong.com.cn', //请求本地 需要jeecg-boot后台项目
+        //  target: 'http://api.tjyourong.com.cn', //请求本地 需要jeecg-boot后台项目
         // target: 'https://trac.tjyourong.com.cn', //请求本地 需要jeecg-boot后台项目
         // target: 'http://39.106.184.70:8088/', //请求本地 需要jeecg-boot后台项目
         //  target: 'http://adsp.tjyourong.com.cn/', //请求本地 需要jeecg-boot后台项目
-        // target: 'http://192.168.1.251/', //请求本地 需要jeecg-boot后台项目
+        target: 'http://192.168.1.251/', //请求本地 需要jeecg-boot后台项目
         // target:'http://118.24.244.213:8804',