3254194295 3 gadi atpakaļ
vecāks
revīzija
cd48e71708

+ 32 - 0
src/api/report/check-job.js

@@ -17,6 +17,16 @@ export function getMonthReport (parameter) {
   })
 }
 
+export function getStoreMonthReport (parameter) {
+  return axios({
+    url: '/report/stores?' + stringify(parameter),
+    method: 'get',
+    headers: {
+      'Content-Type': 'application/json;charset=UTF-8'
+    }
+  })
+}
+
 /**
  * export file
  * parameter: { }
@@ -34,6 +44,17 @@ export function exportMonthReport (parameter) {
   })
 }
 
+export function exportMonthReport1 (parameter) {
+  return axios({
+    url: '/report/stores/export?' + stringify(parameter),
+    method: 'get',
+    headers: {
+      'Content-Type': 'application/json;charset=UTF-8'
+    },
+    responseType: 'blob'
+  })
+}
+
 /**
  * export file
  * parameter: { }
@@ -51,6 +72,17 @@ export function exportMonthReportMonth (parameter) {
   })
 }
 
+export function exportMonthReportMonth1 (parameter) {
+  return axios({
+    url: '/report/stores/export/in/month?' + stringify(parameter),
+    method: 'get',
+    headers: {
+      'Content-Type': 'application/json;charset=UTF-8'
+    },
+    responseType: 'blob'
+  })
+}
+
 /**
  * page func
  * parameter: { }

+ 10 - 0
src/api/sb/type.js

@@ -142,6 +142,16 @@ export function fetchSbTypeTree (parameter) {
   })
 }
 
+export function fetchStoreTypeTree (parameter) {
+  return axios({
+    url: '/report/stores/tree?' + stringify(parameter),
+    method: 'get',
+    headers: {
+      'Content-Type': 'application/json;charset=UTF-8'
+    }
+  })
+}
+
 /**
  * page func
  * parameter: { }

+ 1 - 0
src/router/generator-platform-routers.js

@@ -329,6 +329,7 @@ const constantRouterComponents = {
   'RepairReportSbInfoFee': () => import('@/views/dashboard/RepairReportSbInfoFee'), // 设备维修费用报表
   'RepairReportMttr': () => import('@/views/dashboard/RepairReportMttr'), // MTTR月统计报表
   'RepairReportFee': () => import('@/views/dashboard/RepairReportFee'), // 费用按月统计
+  'StoreReport1': () => import('@/views/dashboard/StoreReport1'), // 仓库报表
 
   // 自定义管理
   'CustomizeReport': () => import('@/views/customize/report/CustomizeReport') // 自定义报表

+ 373 - 0
src/views/dashboard/StoreReport1.vue

@@ -0,0 +1,373 @@
+<template>
+  <div class="page-header-index-wide">
+    <a-card title="仓库出库入库数据月统计报表" :loading="loading" v-show="visible" :bordered="false" :body-style="{padding: '0'}">
+      <div class="salesCard">
+        <a-tabs default-active-key="1" size="large" :tab-bar-style="{marginBottom: '24px', paddingLeft: '16px'}">
+          <div class="extra-wrapper" slot="tabBarExtraContent">
+            <a-row>
+              <a-col :md="3" :sm="24">
+                <a-month-picker
+                  style="margin-left: 8px"
+                  :default-value="moment(defaultStartMonth, monthFormat)"
+                  :format="monthFormat"
+                  v-model="queryParam.startMonth"
+                  placeholder="开始月份"
+                  @change="onStartChange" /></a-col>
+              <a-col :md="3" :sm="24">
+                <a-month-picker
+                  style="margin-left: 8px"
+                  :default-value="moment(defaultEndMonth, monthFormat)"
+                  :format="monthFormat"
+                  v-model="queryParam.endMonth"
+                  placeholder="结束月份"
+                  @change="onEndChange" /></a-col>
+
+              <a-col :md="6" :sm="24">
+                <a-tree-select
+                  style="width: 100%"
+                  :dropdownStyle="{ maxHeight: '400px', overflow: 'auto' }"
+                  :treeData="storeTreeData"
+                  :treeNodeFilterProp="'name'"
+                  :showSearch="true"
+                  v-decorator="['storeId']"
+                  v-model="queryParam.storeId"
+                  placeholder="仓库类型"
+                >
+                </a-tree-select>
+              </a-col>
+              <a-col :md="2" :sm="24">
+                <a-button style="margin-left: 8px" type="default" @click="getData()">查询</a-button>
+              </a-col>
+              <a-col :md="2" :sm="24">
+                <a-button style="margin-left: 8px" type="primary" @click="handlePrint()">打印</a-button>
+              </a-col>
+              <a-col :md="2" :sm="24">
+                <a-button style="margin-left: 8px" type="primary" @click="doExport()">导出</a-button>
+              </a-col>
+            </a-row>
+          </div>
+          <a-tab-pane loading="true" tab="图形统计" key="1">
+            <a-row>
+              <a-col :xl="24" :lg="24" :md="24" :sm="24" :xs="24">
+                <div style="padding: 10px">
+                  <div id="container"></div>
+                </div>
+              </a-col>
+            </a-row>
+          </a-tab-pane>
+          <a-tab-pane loading="true" tab="表格统计" key="2">
+            <a-row>
+              <a-col :xl="24" :lg="24" :md="24" :sm="24" :xs="24">
+                <div style="padding: 10px">
+                  <a-table
+                    bordered
+                    :data-source="chartsData"
+                    :columns="columns"
+                    tableLayout="auto"
+                    :scroll="{x: 1, y: BaseTool.Constant.scrollY }"
+                    rowKey="month">
+                    <span slot="action" slot-scope="record">
+                      <template>
+                        <a @click="handleView(record,1)">入库明细</a>
+                        <a-divider type="vertical" />
+                        <a @click="handleView(record,2)">出库明细</a>
+
+                        <a-divider type="vertical" />
+                        <a @click="doExportDetail(record,1)">导出入库明细</a>
+                        <a-divider type="vertical" />
+                        <a @click="doExportDetail(record,2)">导出出库明细</a>
+
+                      </template>
+                    </span>
+                  </a-table>
+                </div>
+              </a-col>
+            </a-row>
+          </a-tab-pane>
+        </a-tabs>
+      </div>
+    </a-card>
+    <print-in-store ref="basePrintModal" @ok="handleOk"/>
+    <detail-in-store-report ref="inStoreModal" @ok="handleOk"/>
+    <detail-out-store-report ref="outStoreModal" @ok="handleOk"/>
+  </div>
+</template>
+
+<script>
+import { getStoreMonthReport, exportMonthReport1, exportMonthReportMonth1 } from '@/api/report/check-job'
+import { Chart } from '@antv/g2'
+import PrintInStore from '@/views/dashboard/modules/PrintInStoreInAndOutReport'
+import DetailCheckJobReport from '@/views/dashboard/modules/DetailCheckJobReport'
+import DetailInStoreReport from '@/views/dashboard/modules/DetailInStoreReport'
+import DetailOutStoreReport from '@/views/dashboard/modules/DetailOutStoreReport'
+
+import moment from 'moment'
+import { fetchStoreTree } from '@/api/store/store'
+
+export default {
+  name: 'Analysis',
+  components: {
+    DetailOutStoreReport,
+    DetailInStoreReport,
+    PrintInStore,
+    Chart,
+    DetailCheckJobReport
+  },
+  props: {
+    title: {
+      type: String,
+      default: '仓库出库入库数据月统计报表'
+    }
+  },
+  data () {
+    return {
+      storeTreeData: [],
+      queryParam: {
+        startMonth: this.BaseTool.Moment().format(this.BaseTool.Date.PICKER_NORM_YEAR) + '-01-01',
+        endMonth: this.BaseTool.Moment().format(this.BaseTool.Date.PICKER_NORM_YEAR) + '-12-01',
+        storeId: null,
+        searchStartTime: null,
+        searchEndTime: null,
+        filter: this.filter
+      },
+      loading: false,
+      serverData: [],
+      sbLevelMap: {},
+      treeData: [],
+      monthFormat: 'YYYY-MM',
+      defaultStartMonth: this.BaseTool.Moment().format(this.BaseTool.Date.PICKER_NORM_YEAR) + '-01',
+      defaultEndMonth: this.BaseTool.Moment().format(this.BaseTool.Date.PICKER_NORM_YEAR) + '-12',
+      years: [],
+      levelMap: {},
+      visible: true,
+      chart: null, // 创建一个chart变量
+      chartsData: [],
+      // 表头
+      columns: [
+        {
+          title: '月份',
+          width: 180,
+          dataIndex: 'month'
+        },
+        {
+          title: '入库数量',
+          width: 120,
+          dataIndex: 'inStoreNum'
+        },
+        {
+          title: '出库数量',
+          width: 120,
+          dataIndex: 'outStoreNum'
+        },
+        {
+          title: '入库金额',
+          width: 120,
+          dataIndex: 'inStorePrice'
+        },
+        {
+          title: '出库金额',
+          width: 120,
+          dataIndex: 'outStorePrice'
+        },
+        {
+          title: '操作',
+          key: 'action',
+          width: '200px',
+          align: 'center',
+          scopedSlots: { customRender: 'action' }
+        }
+      ]
+    }
+  },
+  created () {
+    this.tableOption()
+    this.setTree()
+  },
+  mounted () {
+    this.$nextTick(function () {
+      this.getData()
+    })
+  },
+  methods: {
+    tableOption () {
+      if (!this.optionAlertShow) {
+        this.options = {
+          alert: { show: true, clear: () => { this.selectedRowKeys = [] } },
+          rowSelection: {
+            selectedRowKeys: this.selectedRowKeys,
+            onChange: this.onSelectChange,
+            getCheckboxProps: record => ({
+              props: {
+                disabled: true,
+                name: record.id
+              }
+            })
+          }
+        }
+        this.optionAlertShow = true
+      } else {
+        this.options = {
+          alert: false,
+          rowSelection: null
+        }
+        this.optionAlertShow = false
+      }
+    },
+    setTree () {
+      fetchStoreTree().then(res => {
+        this.storeTreeData = res.data
+      })
+    },
+    moment,
+    changeLevel (value) {
+      this.queryParam.standardLevel = value
+      this.getData()
+    },
+    onStartChange (date, dateString) {
+      this.$nextTick(() => {
+        this.queryParam.startMonth = this.BaseTool.Date.formatter(dateString + '-01', this.BaseTool.Date.PICKER_NORM_DATE_PATTERN)
+      })
+    },
+    onEndChange (date, dateString) {
+      this.queryParam.endMonth = this.BaseTool.Date.formatter(dateString + '-01', this.BaseTool.Date.PICKER_NORM_DATE_PATTERN)
+    },
+    getData () {
+      if (this.queryParam.startMonth == null) {
+        this.$message.error('请选择起始月份')
+        return
+      }
+      if (this.queryParam.endMonth == null) {
+        this.$message.error('请选择结束月份')
+        return
+      }
+      for (var i = 0; i < this.storeTreeData.length; i++) {
+        if (this.queryParam.storeId === this.storeTreeData[i].id) {
+          alert('立体仓和货架没有数据')
+          return
+        }
+      }
+      getStoreMonthReport(this.queryParam)
+        .then(res => {
+          this.chartsData = res.data
+
+          // 需要将数据分组:总数,完成数
+          const groupData = []
+          this.chartsData.forEach(function (data) {
+            groupData.push({ name: '入库数量', month: data.month + '', num: data.inStoreNum })
+            groupData.push({ name: '出库数量', month: data.month + '', num: data.outStoreNum })
+          })
+          this.getCharts('container', groupData)// 调用统计图
+        })
+    },
+    getCharts (id, data) {
+      this.chart && this.chart.destroy()// 防止点击搜索按钮新增一个
+      this.chart = new Chart({
+        container: 'container',
+        autoFit: true,
+        height: 400
+      })
+      this.chart.data(data)
+      this.chart.scale('num', {
+        nice: true
+      })
+      this.chart.tooltip({
+        showMarkers: false,
+        shared: true
+      })
+      this.chart.interval().position('month*num').color('name').adjust([
+        {
+          type: 'dodge',
+          marginRatio: 0
+        }
+      ])
+      this.chart.interaction('active-region')
+      this.chart.legend({
+        position: 'bottom'
+      })
+      this.chart.render()
+    },
+    doExport () {
+      const parameter = {
+        ...this.queryParam
+      }
+      exportMonthReport1(parameter).then(file => {
+        this.BaseTool.UPLOAD.downLoadExportExcel(file)
+      })
+    },
+    doExportDetail (record, number) {
+      const parameter = {
+        ...this.queryParam,
+        month: record.month,
+        year: record.year,
+        number: number
+      }
+      exportMonthReportMonth1(parameter).then(file => {
+        this.BaseTool.UPLOAD.downLoadExportExcel(file)
+      })
+    },
+    handlePrint (record) {
+      const modal = this.$refs.basePrintModal
+      this.visible = false
+      modal.base({ startMonth: this.queryParam.startMonth, endMonth: this.queryParam.endMonth, title: this.title, data: this.chartsData })
+    },
+    handleView (record, number) {
+      let modal
+      if (number === 1) {
+        modal = this.$refs.inStoreModal
+      } else {
+        modal = this.$refs.outStoreModal
+      }
+      console.log(record)
+      modal.base(record)
+    },
+    handleOk () {
+      this.visible = true
+    }
+  }
+}
+</script>
+
+<style lang="less" scoped>
+.extra-wrapper {
+  line-height: 55px;
+  padding-right: 24px;
+
+  .extra-item {
+    display: inline-block;
+    margin-right: 24px;
+
+    a {
+      margin-left: 24px;
+    }
+  }
+}
+
+.antd-pro-pages-dashboard-analysis-twoColLayout {
+  position: relative;
+  display: flex;
+  display: block;
+  flex-flow: row wrap;
+}
+
+.antd-pro-pages-dashboard-analysis-salesCard {
+  height: calc(100% - 24px);
+  /deep/ .ant-card-head {
+    position: relative;
+  }
+}
+
+.dashboard-analysis-iconGroup {
+  i {
+    margin-left: 16px;
+    color: rgba(0,0,0,.45);
+    cursor: pointer;
+    transition: color .32s;
+    color: black;
+  }
+}
+.analysis-salesTypeRadio {
+  position: absolute;
+  right: 54px;
+  bottom: 12px;
+}
+</style>

+ 179 - 0
src/views/dashboard/modules/DetailInStoreReport.vue

@@ -0,0 +1,179 @@
+<template>
+  <a-modal
+    :title="modalTitle"
+    :width="1200"
+    :visible="visible"
+    :confirmLoading="confirmLoading"
+    @cancel="handleCancel"
+  >
+    <title-divider title="入库明细列表" width="90px"></title-divider>
+    <a-table
+      bordered
+      :data-source="data"
+      :columns="columns"
+      :scroll="{x: 1000, y: BaseTool.Constant.scrollY}"
+      tableLayout="auto"
+      rowKey="id"
+    >
+      <span slot="action" slot-scope="record">
+        <template>
+          <a @click="handleView(record)">查看</a>
+        </template>
+      </span>
+      <span slot="status" slot-scope="text">
+        <badge
+          :text="BaseTool.Object.getField(statusMap,text)"
+          :status="DictCache.COLOR.REPAIR_APPLICATION_FORM_STATUS[text]" />
+      </span>
+    </a-table>
+    <template slot="footer">
+      <a-button :loading="confirmLoading" type="primary" @click="handleCancel()">返回</a-button>
+    </template>
+    <detail :check-type="2" ref="detailModal"/>
+  </a-modal>
+</template>
+
+<script>
+import DetailList from '@/components/tools/DetailList'
+import Detail from '@/views/check/checkjob/modules/Detail'
+import { fetchCheckJob } from '@/api/check/checkjob'
+
+const DetailListItem = DetailList.Item
+
+export default {
+  name: 'DetailRepairReport',
+  components: {
+    DetailList,
+    DetailListItem,
+    Detail
+  },
+  data () {
+    return {
+      confirmLoading: false,
+      mdl: {},
+      modalTitle: null,
+      visible: false,
+      // 下拉框map
+      typeMap: {},
+      statusMap: {},
+      model: {},
+      // 查询参数
+      queryParam: {
+        filter: this.filter,
+        searchType: this.searchType
+      },
+      // 表头
+      columns: [
+        {
+          title: '序号',
+          dataIndex: 'index',
+          checked: true,
+          width: '70px',
+          customRender: (text, record, index) => {
+            return `${index + 1}`
+          }
+        },
+        {
+          title: '入库单号',
+          dataIndex: 'inNo',
+          checked: true,
+          width: '150px'
+        },
+        {
+          title: '备件规格',
+          dataIndex: 'ggxh',
+          checked: true,
+          width: '200px'
+        },
+        {
+          title: '原厂编号',
+          dataIndex: 'initNo',
+          checked: true,
+          width: '150px'
+        },
+        {
+          title: '备件名称',
+          dataIndex: 'spareId',
+          width: '100px',
+          checked: true,
+          customRender: (text, record, index) => {
+            return record.spareName
+          }
+        },
+        {
+          title: '入库数量',
+          dataIndex: 'num',
+          checked: true,
+          width: '200px'
+        },
+        {
+          title: '入库单价',
+          dataIndex: 'price',
+          checked: true,
+          width: '150px',
+          customRender: (text, record, index) => {
+            return this.BaseTool.Amount.formatter(text)
+          }
+        },
+        {
+          title: '入库总价',
+          dataIndex: 'totalPrice',
+          checked: true,
+          width: '150px',
+          customRender: (text, record, index) => {
+            return this.BaseTool.Amount.formatter(text)
+          }
+        },
+        {
+          title: '入库日期',
+          dataIndex: 'createdTime',
+          checked: true,
+          width: '200px'
+        },
+        {
+          title: '入库仓库',
+          dataIndex: 'storeId',
+          checked: true,
+          width: '150px',
+          customRender: (text, record, index) => {
+            return record.storeName
+          }
+        }
+      ],
+      // 下拉框map
+      levelMap: {},
+      standardLevelMap: {},
+      sbStatusMap: {},
+      periodTypeMap: {},
+      data: []
+    }
+  },
+  created () {
+    // 下拉框map
+    this.statusMap = this.DictCache.getLabelByValueMapByType(this.DictCache.TYPE.CHECK_JOB_STATUS)
+    this.sbStatusMap = this.DictCache.getLabelByValueMapByType(this.DictCache.TYPE.YES_NO)
+    this.periodTypeMap = this.DictCache.getLabelByValueMapByType(this.DictCache.TYPE.CHECK_PLAN_PERIOD_TYPE)
+    this.levelMap = this.DictCache.getLabelByValueMapByType(this.DictCache.TYPE.SBINFO_LEVEL)
+    this.standardLevelMap = this.DictCache.getLabelByValueMapByType(this.DictCache.TYPE.CHECK_PLAN_LEVEL)
+  },
+  methods: {
+    base (record) {
+      this.visible = true
+      this.modalTitle = '详情'
+      this.model = record
+      this.data = record.inDetailList
+      console.log(this.data)
+    },
+    handleCancel () {
+      this.visible = false
+      this.confirmLoading = false
+    },
+    handleView (record) {
+      fetchCheckJob({ id: record.id }).then(res => {
+        const modal = this.$refs.detailModal
+        modal.base(res.data)
+      })
+    }
+  }
+}
+</script>

+ 178 - 0
src/views/dashboard/modules/DetailOutStoreReport.vue

@@ -0,0 +1,178 @@
+<template>
+  <a-modal
+    :title="modalTitle"
+    :width="1200"
+    :visible="visible"
+    :confirmLoading="confirmLoading"
+    @cancel="handleCancel"
+  >
+    <title-divider title="明细列表" width="90px"></title-divider>
+    <a-table
+      bordered
+      :data-source="data"
+      :columns="columns"
+      :scroll="{x: 1000, y: BaseTool.Constant.scrollY}"
+      tableLayout="auto"
+      rowKey="id"
+    >
+      <span slot="action" slot-scope="record">
+        <template>
+          <a @click="handleView(record)">查看</a>
+        </template>
+      </span>
+      <span slot="status" slot-scope="text">
+        <badge
+          :text="BaseTool.Object.getField(statusMap,text)"
+          :status="DictCache.COLOR.REPAIR_APPLICATION_FORM_STATUS[text]" />
+      </span>
+    </a-table>
+    <template slot="footer">
+      <a-button :loading="confirmLoading" type="primary" @click="handleCancel()">返回</a-button>
+    </template>
+    <detail :check-type="2" ref="detailModal"/>
+  </a-modal>
+</template>
+
+<script>
+import DetailList from '@/components/tools/DetailList'
+import Detail from '@/views/check/checkjob/modules/Detail'
+import { fetchCheckJob } from '@/api/check/checkjob'
+
+const DetailListItem = DetailList.Item
+
+export default {
+  name: 'DetailRepairReport',
+  components: {
+    DetailList,
+    DetailListItem,
+    Detail
+  },
+  data () {
+    return {
+      confirmLoading: false,
+      mdl: {},
+      modalTitle: null,
+      visible: false,
+      // 下拉框map
+      typeMap: {},
+      statusMap: {},
+      model: {},
+      // 查询参数
+      queryParam: {
+        filter: this.filter,
+        searchType: this.searchType
+      },
+      // 表头
+      columns: [
+        {
+          title: '序号',
+          dataIndex: 'index',
+          checked: true,
+          width: '70px',
+          customRender: (text, record, index) => {
+            return `${(this.$refs.table.localPagination.current - 1) * this.$refs.table.localPagination.pageSize + index + 1}`
+          }
+        },
+        {
+          title: '出库单号',
+          dataIndex: 'outNo',
+          checked: true,
+          width: '150px'
+        },
+        {
+          title: '备件规格',
+          dataIndex: 'ggxh',
+          checked: true,
+          width: '200px'
+        },
+        {
+          title: '原厂编号',
+          dataIndex: 'initNo',
+          checked: true,
+          width: '150px'
+        },
+        {
+          title: '备件名称',
+          dataIndex: 'spareId',
+          width: '100px',
+          checked: true,
+          customRender: (text, record, index) => {
+            return record.spareName
+          }
+        },
+        {
+          title: '出库数量',
+          dataIndex: 'num',
+          checked: true,
+          width: '200px'
+        },
+        {
+          title: '出库单价',
+          dataIndex: 'price',
+          checked: true,
+          width: '150px',
+          customRender: (text, record, index) => {
+            return this.BaseTool.Amount.formatter(text)
+          }
+        },
+        {
+          title: '出库总价',
+          dataIndex: 'totalPrice',
+          checked: true,
+          width: '150px',
+          customRender: (text, record, index) => {
+            return this.BaseTool.Amount.formatter(text)
+          }
+        },
+        {
+          title: '出库日期',
+          dataIndex: 'createdTime',
+          checked: true,
+          width: '200px'
+        },
+        {
+          title: '出库仓库',
+          dataIndex: 'storeId',
+          checked: true,
+          width: '150px',
+          customRender: (text, record, index) => {
+            return record.storeName
+          }
+        }
+      ],
+      // 下拉框map
+      levelMap: {},
+      standardLevelMap: {},
+      sbStatusMap: {},
+      periodTypeMap: {},
+      data: []
+    }
+  },
+  created () {
+    // 下拉框map
+    this.statusMap = this.DictCache.getLabelByValueMapByType(this.DictCache.TYPE.CHECK_JOB_STATUS)
+    this.sbStatusMap = this.DictCache.getLabelByValueMapByType(this.DictCache.TYPE.YES_NO)
+    this.periodTypeMap = this.DictCache.getLabelByValueMapByType(this.DictCache.TYPE.CHECK_PLAN_PERIOD_TYPE)
+    this.levelMap = this.DictCache.getLabelByValueMapByType(this.DictCache.TYPE.SBINFO_LEVEL)
+    this.standardLevelMap = this.DictCache.getLabelByValueMapByType(this.DictCache.TYPE.CHECK_PLAN_LEVEL)
+  },
+  methods: {
+    base (record) {
+      this.visible = true
+      this.modalTitle = '详情'
+      this.model = record
+      this.data = record.outDetailList
+    },
+    handleCancel () {
+      this.visible = false
+      this.confirmLoading = false
+    },
+    handleView (record) {
+      fetchCheckJob({ id: record.id }).then(res => {
+        const modal = this.$refs.detailModal
+        modal.base(res.data)
+      })
+    }
+  }
+}
+</script>

+ 231 - 0
src/views/dashboard/modules/PrintInStoreInAndOutReport.vue

@@ -0,0 +1,231 @@
+<template>
+  <div class="print-content" v-show="visible">
+    <a-row :gutter="48" slot="extra">
+      <a-col :md="48" :sm="48">
+        <span class="table-page-search-submitButtons" style="float: right">
+          <a-button type="primary" v-print="'#print-container2'" :disabled="disabled">打印</a-button>
+          <a-button style="margin-left: 8px" @click="handleCancel()">返回列表</a-button>
+        </span>
+      </a-col>
+    </a-row>
+    <div class="container" id="print-container2">
+      <div class="text-center" style="position:relative;font-size:20px;font-weight:bold">
+        乾元坤和<br/> 出库入库数据月统计报表
+      </div>
+      <div>
+        <div class="col-md-4 text-center" style="padding: 0">统计周期: {{ record.startMonth }} 至 {{ record.endMonth }}</div>
+      </div>
+      <table class="gridtable list">
+        <tbody>
+          <tr>
+            <td class="text-center">月份</td>
+            <td class="text-center">入库数量</td>
+            <td class="text-center">入库金额</td>
+            <td class="text-center">出库数量</td>
+            <td class="text-center">出库金额</td>
+          </tr>
+          <tr :key="index" v-for="(item,index) in items">
+            <td class="text-center">{{ item.month}}</td>
+            <td class="text-center">{{ item.inStoreNum }}</td>
+            <td class="text-center">{{ item.inStorePrice }}</td>
+            <td class="text-center">{{ item.outStoreNum }}</td>
+            <td class="text-center">{{ item.outStorePrice }}</td>
+          </tr>
+        </tbody>
+      </table>
+      <div class="row">
+      </div>
+    </div>
+  </div>
+</template>
+
+<script>
+import { formatDate } from '@/utils/util'
+
+export default {
+  name: 'PrintCheckJobReport',
+  components: { },
+  data () {
+    return {
+      visible: false,
+      disabled: true,
+      record: {},
+      count: 0,
+      items: [],
+      user: this.$store.getters.userInfo
+      // 下拉框map
+    }
+  },
+  props: {},
+  created () {
+    // 下拉框map
+  },
+  computed: {
+  },
+  methods: {
+    base (record) {
+      this.disabled = true
+      this.visible = true
+      this.record = record
+      this.items = record.data
+      console.log(this.items)
+      this.disabled = false
+    },
+    formatDateEn (value) {
+      return formatDate(new Date(value), 'yyyy-MM-dd')
+    },
+    handleCancel (values) {
+      this.visible = false
+      this.$emit('ok', values)
+    }
+  }
+}
+</script>
+<style media=print>
+/* 应用这个样式的在打印时隐藏 */
+.noPrint {
+  display: none;
+}
+
+/* 应用这个样式的,从那个标签结束开始另算一页,之后在遇到再起一页,以此类推 */
+.page {
+  page-break-after: always;
+}
+</style>
+<style>
+.print-content{
+  width: 1123px;
+  background-color: #fff;
+}
+
+#print-container2 * {
+  font-family: SimHei !important;
+  color: #333447;
+  line-height: 1.5;
+}
+
+.container {
+  width: 95%;
+  padding-right: 15px;
+  padding-left: 15px;
+  margin-right: auto;
+  margin-left: auto;
+}
+
+.col-xs-1, .col-sm-1, .col-md-1, .col-lg-1, .col-xs-2, .col-sm-2, .col-md-2, .col-lg-2, .col-xs-3, .col-sm-3, .col-md-3, .col-lg-3, .col-xs-4, .col-sm-4, .col-md-4, .col-lg-4, .col-xs-5, .col-sm-5, .col-md-5, .col-lg-5, .col-xs-6, .col-sm-6, .col-md-6, .col-lg-6, .col-xs-7, .col-sm-7, .col-md-7, .col-lg-7, .col-xs-8, .col-sm-8, .col-md-8, .col-lg-8, .col-xs-9, .col-sm-9, .col-md-9, .col-lg-9, .col-xs-10, .col-sm-10, .col-md-10, .col-lg-10, .col-xs-11, .col-sm-11, .col-md-11, .col-lg-11, .col-xs-12, .col-sm-12, .col-md-12, .col-lg-12 {
+  position: relative;
+  min-height: 1px;
+  padding-right: 15px;
+  padding-left: 15px;
+}
+
+.text-left {
+  text-align: left;
+}
+
+.text-right {
+  text-align: right;
+}
+
+.text-center {
+  text-align: center;
+}
+
+table.gridtable {
+  width: 100%;
+  font-family: verdana, arial, sans-serif;
+  font-size: 11px;
+  color: #333333;
+  border-width: 1px;
+  border-color: #666666;
+  border-collapse: collapse;
+}
+
+table.gridtable th {
+  border-width: 1px;
+  padding: 8px;
+  border-style: solid;
+  border-color: #666666;
+  background-color: #dedede;
+}
+
+table.gridtable td {
+  border-width: 1px;
+  padding: 8px;
+  border-style: solid;
+  border-color: #666666;
+  background-color: #ffffff;
+}
+
+table.content td {
+  height: 95px;
+}
+
+.row {
+  margin-right: -15px;
+  margin-left: -15px;
+}
+
+.container:before,
+.container:after,
+.row:before, .row:after {
+  display: table;
+  content: " ";
+}
+
+.container:after, .row:after {
+  clear: both;
+}
+
+.col-md-1, .col-md-2, .col-md-3, .col-md-4, .col-md-5, .col-md-6, .col-md-7, .col-md-8, .col-md-9, .col-md-10, .col-md-11, .col-md-12 {
+  float: left;
+}
+
+.col-md-12 {
+  width: 100%;
+}
+
+.col-md-11 {
+  width: 91.66666667%;
+}
+
+.col-md-10 {
+  width: 83.33333333%;
+}
+
+.col-md-9 {
+  width: 75%;
+}
+
+.col-md-8 {
+  width: 66.66666667%;
+}
+
+.col-md-7 {
+  width: 58.33333333%;
+}
+
+.col-md-6 {
+  width: 50%;
+}
+
+.col-md-5 {
+  width: 41.66666667%;
+}
+
+.col-md-4 {
+  width: 33.33333333%;
+}
+
+.col-md-3 {
+  width: 25%;
+}
+
+.col-md-2 {
+  width: 16.66666667%;
+}
+
+.col-md-1 {
+  width: 8.33333333%;
+}
+</style>

+ 2 - 2
src/views/repair/application-form/RepairApplicationForm.vue

@@ -210,7 +210,7 @@ export default {
           width: '120px',
           dataIndex: 'repairUserName'
         },
-      /*  {
+        /*  {
           title: '报修来源',
           checked: true,
           width: '100px',
@@ -218,7 +218,7 @@ export default {
           customRender: (text, record, index) => {
             return this.BaseTool.Object.getField(this.sourceMap, text)
           }
-        },*/
+        }, */
         {
           title: '工单类型',
           checked: true,

+ 2 - 2
src/views/repair/application-form/RepairCheckForm.vue

@@ -176,7 +176,7 @@ export default {
           width: '120px',
           dataIndex: 'repairUserName'
         },
-        /*{
+        /* {
           title: '报修来源',
           checked: true,
           width: '100px',
@@ -184,7 +184,7 @@ export default {
           customRender: (text, record, index) => {
             return this.BaseTool.Object.getField(this.sourceMap, text)
           }
-        },*/
+        }, */
         {
           title: '工单类型',
           checked: true,

+ 14 - 14
src/views/repair/form/MyRepairForm.vue

@@ -60,7 +60,7 @@
               && $auth('repair-forms-edit')"
             @click="handleEdit(record)" >维修</operation-button>
           <operation-button v-if="record.status< DictCache.VALUE.REPAIR_FORM_STATUS.YES_DEAL" @click="handleDispatching(record)" >转派</operation-button>
-         <!-- <operation-button
+          <!-- <operation-button
             v-if="$auth('repair-forms-add-fee')"
             @click="handleAddFee(record)" >维修费用</operation-button>
 
@@ -128,35 +128,35 @@ export default {
             return `${(this.$refs.table.localPagination.current - 1) * this.$refs.table.localPagination.pageSize + index + 1}`
           }
         },
-       // {
+        // {
         //  title: '报修单号',
         //  width: 150,
         //  checked: true,
         //  dataIndex: 'applicationNo'
-       // },
-        //{
+        // },
+        // {
         //  title: '维修单号',
         //  checked: true,
-         // dataIndex: 'no',
-         // width: 150
-       // },
+        // dataIndex: 'no',
+        // width: 150
+        // },
         {
           title: '设备名称',
           checked: true,
           width: 150,
           dataIndex: 'sbName'
         },
-       // {
+        // {
         //  title: '部件名称',
         //  dataIndex: 'partName',
         //  checked: true
-       // },
-        //{
-         // title: '报修人',
-         // width: 100,
+        // },
+        // {
+        // title: '报修人',
+        // width: 100,
         //  checked: true,
         //  dataIndex: 'repairUserName'
-       // },
+        // },
         {
           title: '报修来源',
           checked: true,
@@ -329,7 +329,7 @@ export default {
     handleAddPartUsed (record) {
       /* const modal = this.$refs.repairFeeModal
       modal.base(null, record) */
-      this.$refs.sparePartUsedSelectModal.base(record, { sbId: record.sbId,modelId: record.modelId })
+      this.$refs.sparePartUsedSelectModal.base(record, { sbId: record.sbId, modelId: record.modelId })
     },
     handleFinished (record) {
       finish(record).then(() => {

+ 14 - 14
src/views/repair/form/RepairForm.vue

@@ -60,7 +60,7 @@
               && $auth('repair-forms-edit')"
             @click="handleEdit(record)" >维修</operation-button>
           <operation-button v-if="record.status< DictCache.VALUE.REPAIR_FORM_STATUS.YES_DEAL" @click="handleDispatching(record)" >转派</operation-button>
-         <!-- <operation-button
+          <!-- <operation-button
             v-if="$auth('repair-forms-add-fee')"
             @click="handleAddFee(record)" >维修费用</operation-button>
 
@@ -127,35 +127,35 @@ export default {
             return `${(this.$refs.table.localPagination.current - 1) * this.$refs.table.localPagination.pageSize + index + 1}`
           }
         },
-       // {
+        // {
         //  title: '报修单号',
         //  width: 150,
         //  checked: true,
         //  dataIndex: 'applicationNo'
-       // },
-        //{
+        // },
+        // {
         //  title: '维修单号',
         //  checked: true,
-         // dataIndex: 'no',
-         // width: 150
-       // },
+        // dataIndex: 'no',
+        // width: 150
+        // },
         {
           title: '设备名称',
           checked: true,
           width: 150,
           dataIndex: 'sbName'
         },
-       // {
+        // {
         //  title: '部件名称',
         //  dataIndex: 'partName',
         //  checked: true
-       // },
-        //{
-         // title: '报修人',
-         // width: 100,
+        // },
+        // {
+        // title: '报修人',
+        // width: 100,
         //  checked: true,
         //  dataIndex: 'repairUserName'
-       // },
+        // },
         {
           title: '报修来源',
           checked: true,
@@ -328,7 +328,7 @@ export default {
     handleAddPartUsed (record) {
       /* const modal = this.$refs.repairFeeModal
       modal.base(null, record) */
-      this.$refs.sparePartUsedSelectModal.base(record, { sbId: record.sbId,modelId: record.modelId })
+      this.$refs.sparePartUsedSelectModal.base(record, { sbId: record.sbId, modelId: record.modelId })
     },
     handleFinished (record) {
       finish(record).then(() => {

+ 1 - 1
src/views/report/instoredetail/InStoreDetail.vue

@@ -269,7 +269,7 @@ export default {
     },
     doExport () {
       const parameter = {
-        ...this.queryParam,
+        ...this.queryParam
       }
       exportInStoreDetail(parameter).then(file => {
         this.BaseTool.UPLOAD.downLoadExportExcel(file)

+ 6 - 6
src/views/store/sparebackform/SpareBackForm.vue

@@ -120,10 +120,10 @@ export default {
             return this.BaseTool.Object.getField(this.typeMap, text)
           }
         },
-        //{
-         // title: '退库人',
-         // dataIndex: 'pickUserName'
-        //},
+        // {
+        // title: '退库人',
+        // dataIndex: 'pickUserName'
+        // },
         {
           title: '退库说明',
           dataIndex: 'reason'
@@ -244,8 +244,8 @@ export default {
     handleOk () {
       this.$refs.table.refresh()
     },
-    updateToInStore(id){
-      updateToInStore({id:id}).then(res => {
+    updateToInStore (id) {
+      updateToInStore({ id: id }).then(res => {
         this.$message.info('提交成功,等待仓库同意')
         this.$refs.table.refresh()
       })