guhongwei vor 4 Jahren
Ursprung
Commit
f65771ea0e

+ 0 - 178
src/views/adminCenter/company/备份/policy/detail.vue

@@ -1,178 +0,0 @@
-<template>
-  <div id="detail">
-    <el-row>
-      <el-col :span="24" class="main">
-        <el-col :span="24" class="one">
-          <el-col :span="24" class="top">
-            <el-button type="primary" size="mini" @click="back">返回</el-button>
-          </el-col>
-          <el-col :span="24" class="down">
-            <el-form :model="form" :rules="rules" ref="form" label-width="100px">
-              <el-col :span="12" class="text">
-                <el-form-item label="服务类型">
-                  <el-radio-group v-model="form.type">
-                    <el-radio v-for="(i, index) in typeList" :key="index" :label="i">{{ i }}</el-radio>
-                  </el-radio-group>
-                </el-form-item>
-              </el-col>
-              <el-col :span="12" class="text">
-                <el-form-item label="申请单位" prop="company">
-                  <el-input v-model="form.company" placeholder="请输入申请单位"></el-input>
-                </el-form-item>
-              </el-col>
-              <el-col :span="12" class="text">
-                <el-form-item label="申请人" prop="apply_personal">
-                  <el-input v-model="form.apply_personal" placeholder="请输入申请人"></el-input>
-                </el-form-item>
-              </el-col>
-              <el-col :span="12" class="text">
-                <el-form-item label="联系电话" prop="phone">
-                  <el-input v-model="form.phone" placeholder="请输入联系电话"></el-input>
-                </el-form-item>
-              </el-col>
-              <el-col :span="24" class="text">
-                <el-form-item label="法人复印件" prop="qyfr">
-                  <e-upload url="/files/cysci/qyfr_file/upload" :limit="1" v-model="form.qyfr" type="text"></e-upload>
-                </el-form-item>
-              </el-col>
-              <el-col :span="24" class="text">
-                <el-form-item label="企业营业执照" prop="yyzz">
-                  <e-upload url="/files/cysci/yyzz_file/upload" :limit="1" v-model="form.yyzz" type="text"></e-upload>
-                </el-form-item>
-              </el-col>
-              <el-col :span="24" class="text">
-                <el-form-item label="企业利润表" prop="qylr">
-                  <e-upload url="/files/cysci/qylr_file/upload" :limit="1" v-model="form.qylr" type="text"></e-upload>
-                </el-form-item>
-              </el-col>
-              <el-col :span="24" class="text">
-                <el-form-item label="申领状态" prop="status">
-                  <el-radio-group v-model="form.status" disabled>
-                    <el-radio v-for="(i, index) in statusList" :key="index" :label="i.value">{{ i.label }}</el-radio>
-                  </el-radio-group>
-                </el-form-item>
-              </el-col>
-              <el-col :span="24" class="text">
-                <el-form-item label="申领意见" prop="desc">
-                  <el-input v-model="form.desc" type="textarea" :autosize="{ minRows: 4, maxRows: 6 }" show-word-limit disabled></el-input>
-                </el-form-item>
-              </el-col>
-              <el-col :span="24" class="formBtn" v-if="form.status == ''">
-                <el-button type="danger" size="mini" @click="back">取消申领</el-button>
-                <el-button type="primary" size="mini" @click="onSubmit('form')">提交资料</el-button>
-              </el-col>
-            </el-form>
-          </el-col>
-        </el-col>
-      </el-col>
-    </el-row>
-  </div>
-</template>
-
-<script>
-const _ = require('lodash');
-const { policyType, policyStatus } = require('@common/dict/index');
-import { mapState, createNamespacedHelpers } from 'vuex';
-const { mapActions: policy } = createNamespacedHelpers('policy');
-export default {
-  name: 'detail',
-  props: {},
-  components: {},
-  data: function () {
-    return {
-      form: {
-        qyfr: [],
-        yyzz: [],
-        qylr: [],
-        status: '',
-      },
-      rules: {},
-      typeList: policyType,
-      statusList: policyStatus,
-    };
-  },
-  created() {
-    if (this.id) this.search();
-  },
-  methods: {
-    ...policy(['fetch', 'create']),
-    async search() {
-      const res = await this.fetch(this.id);
-      if (this.$checkRes(res)) {
-        this.$set(this, `form`, res.data);
-      }
-    },
-    onSubmit(formName) {
-      this.$refs[formName].validate(async (valid) => {
-        if (valid) {
-          let data = this.form;
-          data.status = '0';
-          let res = await this.create(data);
-          if (this.$checkRes(res)) {
-            this.$message({
-              message: '政策服务申报成功,请耐心等待结果',
-              type: 'success',
-            });
-            this.back();
-          }
-        } else {
-          console.log('error submit!!');
-          return false;
-        }
-      });
-    },
-    back() {
-      this.$router.push({ path: '/adminCenter/company/policy' });
-    },
-  },
-  computed: {
-    ...mapState(['user']),
-    id() {
-      return this.$route.query.id;
-    },
-  },
-  metaInfo() {
-    return { title: this.$route.meta.title };
-  },
-  watch: {
-    test: {
-      deep: true,
-      immediate: true,
-      handler(val) {},
-    },
-  },
-};
-</script>
-
-<style lang="less" scoped>
-.main {
-  border-radius: 10px;
-  box-shadow: 0 0 5px #cccccc;
-  padding: 20px;
-  .one {
-    .top {
-      text-align: right;
-      margin: 0 0 15px 0;
-    }
-    .down {
-      .text {
-        border-bottom: 1px dashed #333;
-      }
-      /deep/.el-form-item {
-        padding: 20px 10px;
-        margin: 0;
-      }
-      /deep/.el-input__inner {
-        border: 1px solid #333;
-      }
-      .formBtn {
-        text-align: center;
-        padding: 15px 0;
-      }
-    }
-  }
-}
-.main:hover {
-  box-shadow: 0 0 5px #409eff;
-}
-</style>

+ 0 - 104
src/views/adminCenter/company/备份/policy/index.vue

@@ -1,104 +0,0 @@
-<template>
-  <div id="index">
-    <el-row>
-      <el-col :span="24" class="main">
-        <el-col :span="24" class="one">
-          <data-table :fields="fields" :opera="opera" :data="list" :total="total" @query="search" @view="toView">
-            <template #selfbtn>
-              <el-button type="primary" size="mini" @click="toAdd">申请政策服务</el-button>
-            </template>
-            <template #options="{ item }">
-              <template v-if="item.prop === 'type'">
-                <el-option v-for="(i, index) in typeList" :key="`type-${index}`" :label="i" :value="i"></el-option>
-              </template>
-            </template>
-          </data-table>
-        </el-col>
-      </el-col>
-    </el-row>
-  </div>
-</template>
-
-<script>
-const { policyType, policyStatus } = require('@common/dict/index');
-import { mapState, createNamespacedHelpers } from 'vuex';
-const { mapActions: policy } = createNamespacedHelpers('policy');
-export default {
-  name: 'index',
-  props: {},
-  components: {},
-  data: function () {
-    return {
-      list: [],
-      total: 0,
-      opera: [
-        {
-          label: '查看',
-          method: 'view',
-        },
-      ],
-      fields: [
-        { label: '申请单位', prop: 'company' },
-        { label: '申请类型', prop: 'type', filter: 'select' },
-        { label: '申请人', prop: 'apply_personal' },
-        { label: '联系电话', prop: 'phone' },
-        {
-          label: '审核状态',
-          prop: 'status',
-          format: (i) => {
-            const r = policyStatus.find((f) => f.value === i);
-            if (r) return r.label;
-            else return '';
-          },
-        },
-      ],
-      typeList: policyType,
-    };
-  },
-  created() {
-    this.search();
-  },
-  methods: {
-    ...policy(['query', 'delete']),
-    async search({ skip = 0, limit = 10, ...info } = {}) {
-      const res = await this.query({ skip, limit, ...info });
-      if (this.$checkRes(res)) {
-        this.$set(this, `list`, res.data);
-        this.$set(this, `total`, res.total);
-      }
-    },
-    // 申请政策服务
-    toAdd() {
-      this.$router.push({ path: '/adminCenter/company/policy/detail' });
-    },
-    // 查看政策服务
-    toView({ data }) {
-      this.$router.push({ path: '/adminCenter/company/policy/detail', query: { id: data._id } });
-    },
-  },
-  computed: {
-    ...mapState(['user']),
-  },
-  metaInfo() {
-    return { title: this.$route.meta.title };
-  },
-  watch: {
-    test: {
-      deep: true,
-      immediate: true,
-      handler(val) {},
-    },
-  },
-};
-</script>
-
-<style lang="less" scoped>
-.main {
-  border-radius: 10px;
-  box-shadow: 0 0 5px #cccccc;
-  padding: 20px;
-}
-.main:hover {
-  box-shadow: 0 0 5px #409eff;
-}
-</style>

+ 0 - 144
src/views/adminCenter/company/备份/ticket/detail.vue

@@ -1,144 +0,0 @@
-<template>
-  <div id="detail">
-    <el-row>
-      <el-col :span="24" class="main">
-        <el-col :span="24" class="one">
-          <el-col :span="24" class="top">
-            <el-button type="primary" size="mini" @click="back">返回</el-button>
-          </el-col>
-          <el-col :span="24" class="down">
-            <el-form :model="form" :rules="rules" ref="form" label-width="100px">
-              <el-form-item label="法人复印件" prop="qyfr">
-                <e-upload url="/files/cysci/qyfr_file/upload" :limit="1" v-model="form.qyfr" type="text"></e-upload>
-              </el-form-item>
-              <el-form-item label="企业营业执照" prop="yyzz">
-                <e-upload url="/files/cysci/yyzz_file/upload" :limit="1" v-model="form.yyzz" type="text"></e-upload>
-              </el-form-item>
-              <el-form-item label="企业利润表" prop="qylr">
-                <e-upload url="/files/cysci/qylr_file/upload" :limit="1" v-model="form.qylr" type="text"></e-upload>
-              </el-form-item>
-              <el-col :span="24" class="formBtn">
-                <el-button type="danger" size="mini" @click="back">取消申请</el-button>
-                <el-button type="primary" size="mini" @click="onSubmit('form')">提交申请</el-button>
-              </el-col>
-            </el-form>
-          </el-col>
-        </el-col>
-      </el-col>
-    </el-row>
-  </div>
-</template>
-
-<script>
-const _ = require('lodash');
-import { mapState, createNamespacedHelpers } from 'vuex';
-const { mapActions: ticket } = createNamespacedHelpers('ticket');
-export default {
-  name: 'detail',
-  props: {},
-  components: {},
-  data: function () {
-    return {
-      form: {
-        qyfr: [],
-        yyzz: [],
-        qylr: [],
-      },
-      rules: {},
-    };
-  },
-  async created() {
-    if (this.id) await this.search();
-  },
-  methods: {
-    ...ticket(['fetch', 'create', 'update']),
-    async search() {
-      let res = await this.fetch(this.id);
-      if (this.$checkRes(res)) {
-        console.log(res.data);
-        // this.$set(this, `form`, res.data);
-      }
-    },
-    onSubmit(formName) {
-      this.$refs[formName].validate(async (valid) => {
-        if (valid) {
-          const obj = { user_id: this.user._id };
-          const material = this.resetData();
-          if (material.length < 3) {
-            this.$message.error('缺少所需资料');
-            return;
-          }
-          obj.material = material;
-          if (obj.id) {
-            console.log('修改');
-          } else {
-            let res = await this.create(obj);
-            if (this.$checkRes(res)) {
-              this.$message({
-                message: '创新券服务申报成功,请耐心等待结果',
-                type: 'success',
-              });
-              this.back();
-            }
-          }
-        } else {
-          console.log('error submit!!');
-          return false;
-        }
-      });
-    },
-    resetData() {
-      let data = _.cloneDeep(this.form);
-      const arr = ['qyfr', 'yyzz', 'qylr'];
-      const res = [];
-      for (const key of arr) {
-        const e = data[key];
-        if (e.length <= 0) continue;
-        const head = _.head(e);
-        res.push(head);
-      }
-      return res;
-    },
-    // 返回
-    back() {
-      this.$router.push({ path: '/adminCenter/company/ticket' });
-    },
-  },
-  computed: {
-    ...mapState(['user']),
-    id() {
-      return this.$route.query.id;
-    },
-    status() {
-      return this.$route.query.status;
-    },
-  },
-  metaInfo() {
-    return { title: this.$route.meta.title };
-  },
-  watch: {
-    test: {
-      deep: true,
-      immediate: true,
-      handler(val) {},
-    },
-  },
-};
-</script>
-
-<style lang="less" scoped>
-.main {
-  border-radius: 10px;
-  box-shadow: 0 0 5px #cccccc;
-  padding: 20px;
-  .one {
-    .top {
-      text-align: right;
-      margin: 0 0 15px 0;
-    }
-  }
-}
-.main:hover {
-  box-shadow: 0 0 5px #409eff;
-}
-</style>

+ 0 - 151
src/views/adminCenter/company/备份/ticket/index.vue

@@ -1,151 +0,0 @@
-<template>
-  <div id="index">
-    <el-row>
-      <el-col :span="24" class="main">
-        <el-col :span="24" class="one">
-          <el-col :span="24" class="down">
-            <el-tabs v-model="active" type="border-card" @tab-click="change">
-              <el-tab-pane label="资质审查中" name="0">
-                <data-table :fields="fields" :opera="opera" :data="list" :total="total" @view="toView" @edit="toEdit">
-                  <template #selfbtn>
-                    <el-button type="primary" size="mini" @click="toAdd">申领创新券服务</el-button>
-                  </template>
-                </data-table>
-              </el-tab-pane>
-              <el-tab-pane label="资质审查失败" name="-1">
-                <data-table :fields="fields" :opera="opera" :data="list" :total="total" @view="toView" @edit="toEdit"> </data-table>
-              </el-tab-pane>
-              <el-tab-pane label="企业准备订单" name="1">
-                <data-table :fields="fields" :opera="opera" :data="list" :total="total" @view="toView" @edit="toEdit"> </data-table>
-              </el-tab-pane>
-              <el-tab-pane label="信息资料审查中" name="2">
-                <data-table :fields="fields" :opera="opera" :data="list" :total="total" @view="toView" @edit="toEdit"> </data-table>
-              </el-tab-pane>
-              <el-tab-pane label="信息资料审查失败" name="-3"
-                ><data-table :fields="fields" :opera="opera" :data="list" :total="total" @view="toView" @edit="toEdit"> </data-table
-              ></el-tab-pane>
-              <el-tab-pane label="企业订单入库" name="3">
-                <data-table :fields="fields" :opera="opera" :data="list" :total="total" @view="toView" @edit="toEdit"> </data-table>
-              </el-tab-pane>
-              <el-tab-pane label="创新券领取成功" name="4">
-                <data-table :fields="fields" :opera="opera" :data="list" :total="total" @view="toView"> </data-table
-              ></el-tab-pane>
-            </el-tabs>
-          </el-col>
-        </el-col>
-      </el-col>
-    </el-row>
-  </div>
-</template>
-
-<script>
-const moment = require('moment');
-import { mapState, createNamespacedHelpers } from 'vuex';
-const { mapActions: ticket } = createNamespacedHelpers('ticket');
-
-export default {
-  name: 'index',
-  props: {},
-  components: {},
-  data: function () {
-    return {
-      active: '0',
-      list: [],
-      total: 0,
-      opera: [
-        {
-          label: '查看',
-          method: 'view',
-        },
-        {
-          label: '编辑申请/上传合同',
-          method: 'edit',
-          display: (item) => {
-            return item.status == '-1' || item.status == '1' || item.status == '-3' || item.status == '3';
-          },
-        },
-      ],
-      fields: [
-        { label: '申领企业', prop: 'name', filter: true },
-        { label: '申领时间', prop: 'meta.createdAt', format: (i) => moment(i).format('YYYY-MM-DD HH:mm:ss') },
-        {
-          label: '申领状态',
-          prop: 'status',
-          format: (i) => {
-            if (i == '0') return '资质审查中';
-            else if (i == '1') return '企业准备订单';
-            else if (i == '-1') return '资质审查失败';
-            else if (i == '2') return '信息资料审查中';
-            else if (i == '3') return '企业订单入库';
-            else if (i == '-3') return '信息资料审查失败';
-            else if (i == '4') return '创新券领取成功';
-          },
-        },
-      ],
-    };
-  },
-  async created() {
-    await this.search();
-  },
-  methods: {
-    ...ticket(['query']),
-    // 查询
-    async search({ skip = 0, limit = 10, ...info } = {}) {
-      info.user_id = this.user.id;
-      if (this.active) info.status = this.active;
-      let res = await this.query({ skip, limit, ...info });
-      if (this.$checkRes(res)) {
-        this.$set(this, `list`, res.data);
-        this.$set(this, `total`, res.total);
-      }
-    },
-    // 选择tabs
-    change(tab) {
-      this.$set(this, `active`, tab.name);
-      this.search();
-    },
-    // 申领
-    toAdd() {
-      this.$router.push({ path: '/adminCenter/company/ticket/detail' });
-    },
-    // 查看资料
-    toView({ data }) {
-      this.$router.push({ path: '/adminCenter/company/ticket/info', query: { id: data._id, status: data.status } });
-    },
-    // 修改申请
-    toEdit({ data }) {
-      this.$router.push({ path: '/adminCenter/company/ticket/update', query: { id: data._id, status: data.status } });
-    },
-  },
-  computed: {
-    ...mapState(['user']),
-  },
-  metaInfo() {
-    return { title: this.$route.meta.title };
-  },
-  watch: {
-    test: {
-      deep: true,
-      immediate: true,
-      handler(val) {},
-    },
-  },
-};
-</script>
-
-<style lang="less" scoped>
-.main {
-  border-radius: 10px;
-  box-shadow: 0 0 5px #cccccc;
-  padding: 20px;
-  .one {
-    .top {
-      text-align: right;
-      margin: 0 0 15px 0;
-    }
-  }
-}
-.main:hover {
-  box-shadow: 0 0 5px #409eff;
-}
-</style>

+ 0 - 190
src/views/adminCenter/company/备份/ticket/info.vue

@@ -1,190 +0,0 @@
-<template>
-  <div id="info">
-    <el-row>
-      <el-col :span="24" class="main">
-        <el-col :span="24" class="one">
-          <el-col :span="24" class="top">
-            <el-button type="primary" size="mini" @click="back">返回</el-button>
-          </el-col>
-          <el-col :span="24" class="down">
-            <el-col :span="24" class="text">
-              <el-col :span="2" class="left"> 企业名称:</el-col>
-              <el-col :span="22" class="right">
-                {{ data.name }}
-              </el-col>
-            </el-col>
-            <el-col :span="24" class="text">
-              <el-col :span="2" class="left"> 申领时间:</el-col>
-              <el-col :span="22" class="right">
-                {{ getDate(data.meta) }}
-              </el-col>
-            </el-col>
-            <el-col :span="24" class="text">
-              <el-col :span="2" class="left"> 资质资料:</el-col>
-              <el-col :span="20" class="right">
-                <el-col :span="4" v-for="(i, index) in data.material" :key="`material-${index}`">
-                  <img v-if="isImg(i.url)" :src="i.url" width="150px" height="150px" @click="toOpen(i.url)" />
-                  <el-link v-else :key="`material-${index}`" type="primary" @click="toOpen(i.url)"> <i class="el-icon-view"></i> {{ i.name }} </el-link>
-                </el-col>
-              </el-col>
-            </el-col>
-            <el-col :span="24" class="text">
-              <el-col :span="2" class="left"> 审核资料:</el-col>
-              <el-col :span="20" class="right">
-                <el-col :span="4" v-for="(i, index) in data.medium_material" :key="`medium_material-${index}`">
-                  <img v-if="isImg(i.url)" :src="i.url" width="150px" height="150px" @click="toOpen(i.url)" />
-                  <el-link v-else type="primary" @click="toOpen(i.url)"> <i class="el-icon-view"></i> {{ i.name }} </el-link>
-                </el-col>
-              </el-col>
-            </el-col>
-            <el-col :span="24" class="text">
-              <el-col :span="2" class="left"> 合同资料:</el-col>
-              <el-col :span="20" class="right">
-                <el-col :span="4" v-for="(i, index) in data.contract" :key="`contract-${index}`">
-                  <img v-if="isImg(i.url)" :src="i.url" width="150px" height="150px" @click="toOpen(i.url)" />
-                  <el-link v-else type="primary" @click="toOpen(i.url)"> <i class="el-icon-view"></i> {{ i.name }} </el-link>
-                </el-col>
-              </el-col>
-            </el-col>
-            <el-col :span="24" class="text">
-              <el-col :span="2" class="left"> 审核状态:</el-col>
-              <el-col :span="22" class="right">
-                {{ getStatus(data.status) }}
-              </el-col>
-            </el-col>
-            <el-col :span="24" class="text">
-              <el-col :span="24" class="left"> 审核意见:</el-col>
-              <el-col :span="24" class="right desc">
-                <el-timeline>
-                  <el-timeline-item v-for="(item, index) in descList" :key="index" :timestamp="item.create_time" placement="top">
-                    <el-card>
-                      <p>{{ item.desc }}</p>
-                    </el-card>
-                  </el-timeline-item>
-                </el-timeline>
-              </el-col>
-            </el-col>
-          </el-col>
-        </el-col>
-      </el-col>
-    </el-row>
-  </div>
-</template>
-
-<script>
-const moment = require('moment');
-import { mapState, createNamespacedHelpers } from 'vuex';
-const { mapActions: ticket } = createNamespacedHelpers('ticket');
-
-export default {
-  name: 'info',
-  props: {},
-  components: {},
-  data: function () {
-    return {
-      data: {},
-      imgList: ['jpg', 'jpeg', 'png', 'bmp', 'gif'],
-      // 意见列表
-      descList: [],
-    };
-  },
-  async created() {
-    if (this.id) await this.search();
-  },
-  methods: {
-    ...ticket(['fetch', 'record']),
-    async search() {
-      let res = await this.fetch(this.id);
-      if (this.$checkRes(res)) {
-        this.$set(this, `data`, res.data);
-      }
-      res = await this.record({ ticket_id: this.id, status: this.status });
-      if (this.$checkRes(res)) {
-        this.$set(this, `descList`, res.data);
-      }
-    },
-    // 返回
-    back() {
-      this.$router.push({ path: '/adminCenter/company/ticket' });
-    },
-    getDate(date) {
-      if (date) {
-        let newDate = moment(date.createdAt).format('YYYY-MM-DD');
-        if (newDate) return newDate;
-      }
-    },
-    toOpen(url) {
-      window.open(url);
-    },
-    isImg(url) {
-      const arr = url.split('.');
-      const suffix = _.last(arr);
-      return this.imgList.includes(suffix);
-    },
-    getStatus(i) {
-      if (i == '0') return '资质审查中';
-      else if (i == '1') return '企业准备订单';
-      else if (i == '-1') return '资质审查失败';
-      else if (i == '2') return '信息资料审查中';
-      else if (i == '3') return '企业订单入库';
-      else if (i == '-3') return '信息资料审查失败';
-      else if (i == '4') return '创新券领取成功';
-    },
-  },
-  computed: {
-    ...mapState(['user']),
-    id() {
-      return this.$route.query.id;
-    },
-    status() {
-      return this.$route.query.status;
-    },
-  },
-  metaInfo() {
-    return { title: this.$route.meta.title };
-  },
-  watch: {
-    test: {
-      deep: true,
-      immediate: true,
-      handler(val) {},
-    },
-  },
-};
-</script>
-
-<style lang="less" scoped>
-.main {
-  border-radius: 10px;
-  box-shadow: 0 0 5px #cccccc;
-  padding: 20px;
-  .one {
-    .top {
-      text-align: right;
-      margin: 0 0 15px 0;
-    }
-    .down {
-      .text {
-        padding: 10px 0;
-        border-bottom: 1px dashed #333;
-        .left {
-          text-align: left;
-        }
-        .right {
-          img {
-            width: 200px;
-            height: 200px;
-            border: 1px solid #ccc;
-          }
-        }
-        .desc {
-          margin: 10px 0 0 0;
-        }
-      }
-    }
-  }
-}
-.main:hover {
-  box-shadow: 0 0 5px #409eff;
-}
-</style>

+ 0 - 343
src/views/adminCenter/company/备份/ticket/update.vue

@@ -1,343 +0,0 @@
-<template>
-  <div id="update">
-    <el-row>
-      <el-col :span="24" class="main">
-        <el-col :span="24" class="one">
-          <el-col :span="24" class="top">
-            <el-button type="primary" size="mini" @click="back">返回</el-button>
-          </el-col>
-          <el-col :span="24" class="down">
-            <el-form :model="form" :rules="rules" ref="form" label-width="100px">
-              <el-col :span="24" class="name">
-                <el-form-item label="企业名称" prop="name">
-                  <el-input v-model="form.name" disabled></el-input>
-                </el-form-item>
-              </el-col>
-              <el-col :span="24" class="down_1">
-                <el-col :span="24" class="down_1text"><span>企业资质资料</span></el-col>
-                <el-col :span="24" class="file">
-                  <el-form-item label="法人复印件" prop="qyfr">
-                    <e-upload url="/files/cysci/qyfr_file/upload" :limit="1" v-model="form.qyfr" type="text"></e-upload>
-                  </el-form-item>
-                </el-col>
-                <el-col :span="24" class="file">
-                  <el-form-item label="企业营业执照" prop="yyzz">
-                    <e-upload url="/files/cysci/yyzz_file/upload" :limit="1" v-model="form.yyzz" type="text"></e-upload>
-                  </el-form-item>
-                </el-col>
-                <el-col :span="24" class="file">
-                  <el-form-item label="企业利润表" prop="qylr">
-                    <e-upload url="/files/cysci/qylr_file/upload" :limit="1" v-model="form.qylr" type="text"></e-upload>
-                  </el-form-item>
-                </el-col>
-              </el-col>
-              <el-col :span="24" class="down_1" v-if="form.status != '-1'">
-                <el-col :span="24" class="down_1text"><span>企业准备订单</span></el-col>
-                <el-col :span="24" class="file">
-                  <el-form-item label="选择中介">
-                    <el-select v-model="form.mechanism_id" placeholder="">
-                      <el-option v-for="item in mechanismList" :key="item.id" :label="item.name" :value="item.id"> </el-option>
-                    </el-select>
-                  </el-form-item>
-                </el-col>
-                <el-col :span="24" class="file">
-                  <el-form-item label="法人复印件" prop="qyfr1">
-                    <e-upload url="/files/cysci/qyfr1_file/upload" :limit="1" v-model="form.qyfr1" type="text"></e-upload>
-                  </el-form-item>
-                </el-col>
-                <el-col :span="24" class="file">
-                  <el-form-item label="企业营业执照" prop="yyzz1">
-                    <e-upload url="/files/cysci/yyzz1_file/upload" :limit="1" v-model="form.yyzz1" type="text"></e-upload>
-                  </el-form-item>
-                </el-col>
-                <el-col :span="24" class="file">
-                  <el-form-item label="企业利润表" prop="qylr1">
-                    <e-upload url="/files/cysci/qylr1_file/upload" :limit="1" v-model="form.qylr1" type="text"></e-upload>
-                  </el-form-item>
-                </el-col>
-              </el-col>
-              <el-col :span="24" class="down_1" v-if="form.status == '3'">
-                <el-col :span="24" class="down_1text"><span>合同资料上传</span></el-col>
-                <el-col :span="24" class="file">
-                  <el-form-item label="上传合同" prop="contract">
-                    <e-upload
-                      url="/files/cysci/contract_file/upload"
-                      :limit="2"
-                      v-model="form.contract"
-                      type="text"
-                      :remove="fileRemove"
-                      :extra="{ user_id: user._id }"
-                    ></e-upload>
-                  </el-form-item>
-                </el-col>
-              </el-col>
-              <el-col :span="24" class="formBtn">
-                <el-button type="danger" size="mini" @click="back">取消申请</el-button>
-                <el-button type="primary" size="mini" @click="onSubmit('form')">提交申请</el-button>
-              </el-col>
-            </el-form>
-          </el-col>
-        </el-col>
-      </el-col>
-    </el-row>
-  </div>
-</template>
-
-<script>
-const _ = require('lodash');
-import { mapState, createNamespacedHelpers } from 'vuex';
-const { mapActions: ticket } = createNamespacedHelpers('ticket');
-const { mapActions: mechanism } = createNamespacedHelpers('mechanism');
-export default {
-  name: 'update',
-  props: {},
-  components: {},
-  data: function () {
-    return {
-      form: {},
-      rules: {},
-      // 中介机构
-      mechanismList: [],
-    };
-  },
-  async created() {
-    await this.searchOther();
-    if (this.id) await this.search();
-  },
-  methods: {
-    ...ticket(['fetch', 'update']),
-    ...mechanism(['query']),
-    async search() {
-      let res = await this.fetch(this.id);
-      if (this.$checkRes(res)) {
-        res.data.qyfr = res.data.material.length > 0 ? [res.data.material[0]] : [];
-        res.data.yyzz = res.data.material.length > 0 ? [res.data.material[1]] : [];
-        res.data.qylr = res.data.material.length > 0 ? [res.data.material[2]] : [];
-        res.data.qyfr1 = res.data.medium_material.length > 0 ? [res.data.medium_material[0]] : [];
-        res.data.yyzz1 = res.data.medium_material.length > 0 ? [res.data.medium_material[1]] : [];
-        res.data.qylr1 = res.data.medium_material.length > 0 ? [res.data.medium_material[2]] : [];
-        this.$set(this, `form`, res.data);
-      }
-    },
-    onSubmit(formName) {
-      this.$refs[formName].validate(async (valid) => {
-        if (valid) {
-          if (this.status == '-1') {
-            this.oneSubmit();
-          } else if (this.status == '1') {
-            this.twoSubmit();
-          } else if (this.status == '-3') {
-            this.thrSubmit();
-          } else if (this.status == '3') {
-            this.fourSubmit();
-          }
-        } else {
-          console.log('error submit!!');
-          return false;
-        }
-      });
-    },
-    // 状态为-1时
-    async oneSubmit() {
-      const material = this.oneMap();
-      if (material.length < 3) {
-        this.$message.error('缺少所需资料');
-        return;
-      }
-      const data = this.form;
-      data.material = material;
-      data.status = '0';
-      let res = await this.update(data);
-      if (this.$checkRes(res)) {
-        this.$message({
-          message: '创新券重申成功,请耐心等待结果',
-          type: 'success',
-        });
-        this.back();
-      }
-    },
-    // 状态为1时
-    async twoSubmit() {
-      const material = this.oneMap();
-      const medium_material = this.twoMap();
-      if (material.length < 3) {
-        this.$message.error('缺少所需资料');
-        return;
-      }
-      if (medium_material.length < 3) {
-        this.$message.error('缺少所需资料');
-        return;
-      }
-      const data = this.form;
-      data.material = material;
-      data.medium_material = medium_material;
-      data.status = '2';
-      let res = await this.update(data);
-      if (this.$checkRes(res)) {
-        this.$message({
-          message: '创新券信息资料提交成功,请耐心等待结果',
-          type: 'success',
-        });
-        this.back();
-      }
-    },
-    // 状态为-3时
-    async thrSubmit() {
-      const material = this.oneMap();
-      const medium_material = this.twoMap();
-      if (material.length < 3) {
-        this.$message.error('缺少所需资料');
-        return;
-      }
-      if (medium_material.length < 3) {
-        this.$message.error('缺少所需资料');
-        return;
-      }
-      const data = this.form;
-      data.material = material;
-      data.medium_material = medium_material;
-      data.status = '2';
-      let res = await this.update(data);
-      if (this.$checkRes(res)) {
-        this.$message({
-          message: '创新券信息资料提交成功,请耐心等待结果',
-          type: 'success',
-        });
-        this.back();
-      }
-    },
-    // 状态为3时
-    async fourSubmit() {
-      const material = this.oneMap();
-      const medium_material = this.twoMap();
-      if (material.length < 3) {
-        this.$message.error('缺少所需资料');
-        return;
-      }
-      if (medium_material.length < 3) {
-        this.$message.error('缺少所需资料');
-        return;
-      }
-      const data = this.form;
-      data.material = material;
-      data.medium_material = medium_material;
-      data.status = '3';
-      let res = await this.update(data);
-      if (this.$checkRes(res)) {
-        this.$message({
-          message: '创新券合同资料提交成功,请耐心等待结果',
-          type: 'success',
-        });
-        this.back();
-      }
-    },
-    oneMap() {
-      let data = _.cloneDeep(this.form);
-      const arr = ['qyfr', 'yyzz', 'qylr'];
-      const res = [];
-      for (const key of arr) {
-        const e = data[key];
-        if (e.length <= 0) continue;
-        const head = _.head(e);
-        res.push(head);
-      }
-      return res;
-    },
-    twoMap() {
-      let data = _.cloneDeep(this.form);
-      const arr = ['qyfr1', 'yyzz1', 'qylr1'];
-      const res = [];
-      for (const key of arr) {
-        const e = data[key];
-        if (e.length <= 0) continue;
-        const head = _.head(e);
-        res.push(head);
-      }
-      return res;
-    },
-    // 返回
-    back() {
-      this.$router.push({ path: '/adminCenter/company/ticket' });
-    },
-    // 查询其他
-    async searchOther() {
-      let res = await this.query();
-      if (this.$checkRes(res)) {
-        this.$set(this, `mechanismList`, res.data);
-      }
-    },
-    // 删除合同之前判断
-    fileRemove(file) {
-      if (file.user_id === this.user._id) {
-        return { result: true };
-      } else {
-        return { result: false, msg: '不允许删除自己上传以外的合同' };
-      }
-    },
-  },
-  computed: {
-    ...mapState(['user']),
-    id() {
-      return this.$route.query.id;
-    },
-    status() {
-      return this.$route.query.status;
-    },
-  },
-  metaInfo() {
-    return { title: this.$route.meta.title };
-  },
-  watch: {
-    test: {
-      deep: true,
-      immediate: true,
-      handler(val) {},
-    },
-  },
-};
-</script>
-
-<style lang="less" scoped>
-.main {
-  border-radius: 10px;
-  box-shadow: 0 0 5px #cccccc;
-  padding: 20px;
-  .one {
-    .top {
-      text-align: right;
-      margin: 0 0 15px 0;
-    }
-    .down {
-      .name {
-        border-bottom: 1px dashed #ccc;
-        margin: 0 0 10px 0;
-      }
-      .down_1 {
-        border-bottom: 1px dashed #ccc;
-        margin: 0 0 10px 0;
-        .down_1text {
-          font-weight: bold;
-          margin: 0 0 10px 0;
-          span {
-            display: inline-block;
-            background-color: #242f42;
-            color: #fff;
-            padding: 8px;
-            border-radius: 10px;
-          }
-        }
-        .file {
-          border: 1px dashed #ccc;
-          padding: 10px 50% 10px 0;
-        }
-      }
-      .formBtn {
-        text-align: center;
-      }
-    }
-  }
-}
-.main:hover {
-  box-shadow: 0 0 5px #409eff;
-}
-</style>

+ 0 - 159
src/views/adminCenter/ticket备份/detail.vue

@@ -1,159 +0,0 @@
-<template>
-  <div id="detail">
-    <el-form ref="form" label-width="150px">
-      <el-row type="flex" justify="space-between" style="padding: 10px">
-        <el-col :span="2">
-          <el-button type="primary" size="mini" @click="toFlow">查看意见</el-button>
-        </el-col>
-        <el-col :span="2">
-          <el-button type="primary" size="mini" @click="toBack">返回</el-button>
-        </el-col>
-      </el-row>
-      <el-form-item label="企业名称">{{ data.name }}</el-form-item>
-      <el-form-item label="资料">
-        <template #label>
-          <el-row>
-            <el-col :span="24">资料</el-col>
-            <el-col :span="24">(图片点击放大)</el-col>
-          </el-row>
-        </template>
-        <el-row :gutter="10">
-          <el-col :span="4" v-for="(i, index) in data.material" :key="`material-${index}`">
-            <img v-if="isImg(i.url)" :src="i.url" width="150px" height="150px" @click="toOpen(i.url)" />
-            <el-link v-else :key="`material-${index}`" type="primary" @click="toOpen(i.url)"> <i class="el-icon-view"></i> {{ i.name }} </el-link>
-          </el-col>
-        </el-row>
-      </el-form-item>
-      <template v-if="statusData !== '0' && statusData !== '1' && statusData !== '-1'">
-        <el-form-item label="中介机构审核资料">
-          <template #label>
-            <el-row>
-              <el-col :span="24">中介机构审核资料</el-col>
-              <el-col :span="24">(图片点击放大)</el-col>
-            </el-row>
-          </template>
-          <el-row :gutter="10">
-            <el-col :span="4" v-for="(i, index) in data.medium_material" :key="`medium_material-${index}`">
-              <img v-if="isImg(i.url)" :src="i.url" width="150px" height="150px" @click="toOpen(i.url)" />
-              <el-link v-else type="primary" @click="toOpen(i.url)"> <i class="el-icon-view"></i> {{ i.name }} </el-link>
-            </el-col>
-          </el-row>
-        </el-form-item>
-        <el-form-item label="合同" v-if="statusData !== '0' && statusData !== '1' && statusData !== '-1' && statusData !== '2' && statusData !== '-3'">
-          <template #label>
-            <el-row>
-              <el-col :span="24">合同</el-col>
-              <el-col :span="24">(图片点击放大)</el-col>
-            </el-row>
-          </template>
-          <el-row :gutter="10">
-            <el-col :span="4" v-for="(i, index) in data.contract" :key="`contract-${index}`">
-              <img v-if="isImg(i.url)" :src="i.url" width="150px" height="150px" @click="toOpen(i.url)" />
-              <el-link v-else type="primary" @click="toOpen(i.url)"> <i class="el-icon-view"></i> {{ i.name }} </el-link>
-            </el-col>
-          </el-row>
-        </el-form-item>
-      </template>
-      <el-form-item label="审核意见" v-if="statusData === '0' || statusData === '3'">
-        <el-input v-model="form.desc" placeholder="请填写审核意见" type="textarea" :autosize="{ maxRows: 5, minRows: 3 }"></el-input>
-      </el-form-item>
-      <el-form-item label="审核" v-if="statusData === '0'">
-        <el-radio-group v-model="form.status">
-          <el-radio label="1">通过</el-radio>
-          <el-radio label="-1">拒绝</el-radio>
-        </el-radio-group>
-      </el-form-item>
-      <el-row type="flex" justify="space-around">
-        <el-col :span="2">
-          <el-button v-if="statusData === '0'" type="primary" @click="toStatus()" :disabled="!form.status">保存审核结果</el-button>
-          <el-button v-if="statusData === '3'" type="primary" @click="toStatus('4')">确认</el-button>
-        </el-col>
-      </el-row>
-    </el-form>
-    <el-dialog title="意见" :visible.sync="dialog" :destroy-on-close="true">
-      <flow :id="data._id"></flow>
-    </el-dialog>
-  </div>
-</template>
-
-<script>
-const _ = require('lodash');
-// import flow from './flow.vue';
-import { mapState, createNamespacedHelpers } from 'vuex';
-const { mapActions: ticket } = createNamespacedHelpers('ticket');
-export default {
-  name: 'detail',
-  props: {},
-  components: { flow },
-  data: function () {
-    return {
-      data: {
-        material: [],
-        medium_material: [],
-        contract: [],
-      },
-      imgList: ['jpg', 'jpeg', 'png', 'bmp', 'gif'],
-      form: {},
-      dialog: false,
-    };
-  },
-  created() {
-    if (this.id) this.search();
-  },
-  methods: {
-    ...ticket(['fetch', 'status']),
-    async search() {
-      const res = await this.fetch(this.id);
-      if (this.$checkRes(res)) {
-        this.$set(this, `data`, res.data);
-      }
-    },
-    isImg(url) {
-      const arr = url.split('.');
-      const suffix = _.last(arr);
-      return this.imgList.includes(suffix);
-    },
-    toOpen(url) {
-      window.open(url);
-    },
-    async toStatus(status) {
-      const dup = _.cloneDeep(this.form);
-      dup.opera_id = this.user._id;
-      dup.id = this.data._id;
-      if (status) dup.status = status;
-      const res = await this.status(dup);
-      if (this.$checkRes(res, '审核成功', res.errmsg || '审核失败')) {
-        this.toBack();
-      }
-    },
-    toBack() {
-      this.$router.push(`/adminCenter/ticket`);
-    },
-    toFlow() {
-      this.dialog = true;
-    },
-  },
-  computed: {
-    ...mapState(['user', 'menuParams']),
-    pageTitle() {
-      return `${this.$route.meta.title}`;
-    },
-    statusData() {
-      return this.$route.query.status;
-    },
-    id() {
-      return this.$route.query.id;
-    },
-  },
-  metaInfo() {
-    return { title: this.$route.meta.title };
-  },
-};
-</script>
-
-<style lang="less" scoped>
-/deep/.el-dialog__body {
-  height: 500px;
-  overflow-y: auto;
-}
-</style>

+ 0 - 71
src/views/adminCenter/ticket备份/flow.vue

@@ -1,71 +0,0 @@
-<template>
-  <div id="flow">
-    <el-card v-for="(i, index) in list" :key="`flow-${index}`" style="margin: 10px">
-      <template #header>
-        <el-row type="flex" :gutter="10" justify="space-between">
-          <el-col :span="8">{{ getStep(i) }}</el-col>
-          <el-col :span="5">{{ getTime(i) }}</el-col>
-        </el-row>
-      </template>
-      意见:
-      <p>{{ i.desc }}</p>
-    </el-card>
-  </div>
-</template>
-
-<script>
-const moment = require('moment');
-import { mapState, createNamespacedHelpers } from 'vuex';
-const { mapActions: ticket } = createNamespacedHelpers('ticket');
-export default {
-  name: 'flow',
-  props: { id: { type: String, required: true } },
-  components: {},
-  data: function () {
-    return {
-      list: [],
-      status: [
-        { value: '0', label: '申请' },
-        { value: '1', label: '资质审核成功' },
-        { value: '-1', label: '资质审查失败' },
-        { value: '2', label: '企业填写资料完成,信息资料审查中' },
-        { value: '3', label: '中介机构审核成功' },
-        { value: '-3', label: '信息资料审查失败' },
-        { value: '4', label: '创新劵领取成功' },
-      ],
-    };
-  },
-  created() {
-    this.search();
-  },
-  methods: {
-    ...ticket(['record']),
-    async search() {
-      const res = await this.record({ ticket_id: this.id });
-      if (this.$checkRes(res)) {
-        this.$set(this, `list`, res.data);
-      }
-    },
-    getStep(data) {
-      const { status } = data;
-      const r = this.status.find((f) => f.value === status);
-      if (r) return r.label;
-      else return '未知步骤';
-    },
-    getTime(data) {
-      return moment(_.get(data, 'meta.createdAt')).format('YYYY-MM-DD HH:mm:ss');
-    },
-  },
-  computed: {
-    ...mapState(['user', 'menuParams']),
-    pageTitle() {
-      return `${this.$route.meta.title}`;
-    },
-  },
-  metaInfo() {
-    return { title: this.$route.meta.title };
-  },
-};
-</script>
-
-<style lang="less" scoped></style>

+ 0 - 78
src/views/adminCenter/ticket备份/list.vue

@@ -1,78 +0,0 @@
-<template>
-  <div id="list">
-    <data-table :fields="fields" :opera="opera" :data="list" :total="total" @query="search" @edit="toEdit"> </data-table>
-  </div>
-</template>
-
-<script>
-const moment = require('moment');
-const { ticketType } = require('@common/dict/index');
-import { mapState, createNamespacedHelpers } from 'vuex';
-const { mapActions: ticket } = createNamespacedHelpers('ticket');
-export default {
-  name: 'list',
-  props: {
-    status: { type: String, default: '0' },
-  },
-  components: {},
-  data: function () {
-    return {
-      list: [],
-      total: 0,
-      opera: [
-        {
-          label: '审核',
-          method: 'edit',
-          display: (i) => i.status === '0' || i.status === '3',
-        },
-        {
-          label: '查看',
-          method: 'edit',
-          display: (i) => i.status !== '0' && i.status !== '3',
-        },
-      ],
-      fields: [
-        { label: '企业', prop: 'name', filter: true },
-        { label: '申请时间', prop: 'meta.createdAt', format: (i) => moment(i).format('YYYY-MM-DD HH:mm:ss') },
-        {
-          label: '状态',
-          prop: 'status',
-          format: (i) => {
-            const r = ticketType.find((f) => f.value === i);
-            if (r) return r.label;
-            else return '';
-          },
-        },
-      ],
-    };
-  },
-  created() {
-    this.search();
-  },
-  methods: {
-    ...ticket(['query', 'delete']),
-    async search({ skip = 0, limit = 10, ...info } = {}) {
-      const res = await this.query({ skip, limit, ...info, status: this.status });
-      if (this.$checkRes(res)) {
-        this.$set(this, `list`, res.data || [{}]);
-        this.$set(this, `total`, res.total);
-      }
-      this.loading = false;
-    },
-    toEdit({ data }) {
-      this.$router.push({ path: '/adminCenter/ticket/detail', query: { id: data._id, status: data.status } });
-    },
-  },
-  computed: {
-    ...mapState(['user', 'menuParams']),
-    pageTitle() {
-      return `${this.$route.meta.title}`;
-    },
-  },
-  metaInfo() {
-    return { title: this.$route.meta.title };
-  },
-};
-</script>
-
-<style lang="less" scoped></style>

+ 0 - 46
src/views/adminCenter/ticket备份/status.vue

@@ -1,46 +0,0 @@
-<template>
-  <div id="status">
-    <el-tabs type="border-card" v-model="active">
-      <el-tab-pane v-for="(i, index) in tabs" :key="`tabs-${index}`" :label="i.label" :name="i.status" :lazy="true">
-        <list :status="i.status"></list>
-      </el-tab-pane>
-    </el-tabs>
-  </div>
-</template>
-
-<script>
-import list from './list.vue';
-import { mapState, createNamespacedHelpers } from 'vuex';
-export default {
-  name: 'status',
-  props: {},
-  components: { list },
-  data: function () {
-    return {
-      active: '0',
-      tabs: [
-        { label: '资质审查中', status: '0' },
-        { label: '企业准备订单', status: '1' },
-        { label: '信息资料审查中', status: '2' },
-        { label: '订单入库', status: '3' },
-        { label: '创新券领取成功', status: '4' },
-        { label: '资质审查失败', status: '-1' },
-        { label: '信息资料审查失败', status: '-3' },
-      ],
-    };
-  },
-  created() {},
-  methods: {},
-  computed: {
-    ...mapState(['user', 'menuParams']),
-    pageTitle() {
-      return `${this.$route.meta.title}`;
-    },
-  },
-  metaInfo() {
-    return { title: this.$route.meta.title };
-  },
-};
-</script>
-
-<style lang="less" scoped></style>