guhongwei 1 tahun lalu
induk
melakukan
a3f0fa17b1

+ 11 - 0
package-lock.json

@@ -9,6 +9,7 @@
       "version": "0.0.0",
       "version": "0.0.0",
       "dependencies": {
       "dependencies": {
         "@element-plus/icons-vue": "^2.1.0",
         "@element-plus/icons-vue": "^2.1.0",
+        "@stomp/stompjs": "^7.0.0",
         "@wangeditor/editor": "^5.1.23",
         "@wangeditor/editor": "^5.1.23",
         "@wangeditor/editor-for-vue": "^1.0.2",
         "@wangeditor/editor-for-vue": "^1.0.2",
         "animate.css": "^4.1.1",
         "animate.css": "^4.1.1",
@@ -647,6 +648,11 @@
       "integrity": "sha512-sXo/qW2/pAcmT43VoRKOJbDOfV3cYpq3szSVfIThQXNt+E4DfKj361vaAt3c88U5tPUxzEswam7GW48PJqtKAg==",
       "integrity": "sha512-sXo/qW2/pAcmT43VoRKOJbDOfV3cYpq3szSVfIThQXNt+E4DfKj361vaAt3c88U5tPUxzEswam7GW48PJqtKAg==",
       "dev": true
       "dev": true
     },
     },
+    "node_modules/@stomp/stompjs": {
+      "version": "7.0.0",
+      "resolved": "https://registry.npmjs.org/@stomp/stompjs/-/stompjs-7.0.0.tgz",
+      "integrity": "sha512-fGdq4wPDnSV/KyOsjq4P+zLc8MFWC3lMmP5FBgLWKPJTYcuCbAIrnRGjB7q2jHZdYCOD5vxLuFoKIYLy5/u8Pw=="
+    },
     "node_modules/@transloadit/prettier-bytes": {
     "node_modules/@transloadit/prettier-bytes": {
       "version": "0.0.7",
       "version": "0.0.7",
       "resolved": "https://registry.npmjs.org/@transloadit/prettier-bytes/-/prettier-bytes-0.0.7.tgz",
       "resolved": "https://registry.npmjs.org/@transloadit/prettier-bytes/-/prettier-bytes-0.0.7.tgz",
@@ -6035,6 +6041,11 @@
       "integrity": "sha512-sXo/qW2/pAcmT43VoRKOJbDOfV3cYpq3szSVfIThQXNt+E4DfKj361vaAt3c88U5tPUxzEswam7GW48PJqtKAg==",
       "integrity": "sha512-sXo/qW2/pAcmT43VoRKOJbDOfV3cYpq3szSVfIThQXNt+E4DfKj361vaAt3c88U5tPUxzEswam7GW48PJqtKAg==",
       "dev": true
       "dev": true
     },
     },
+    "@stomp/stompjs": {
+      "version": "7.0.0",
+      "resolved": "https://registry.npmjs.org/@stomp/stompjs/-/stompjs-7.0.0.tgz",
+      "integrity": "sha512-fGdq4wPDnSV/KyOsjq4P+zLc8MFWC3lMmP5FBgLWKPJTYcuCbAIrnRGjB7q2jHZdYCOD5vxLuFoKIYLy5/u8Pw=="
+    },
     "@transloadit/prettier-bytes": {
     "@transloadit/prettier-bytes": {
       "version": "0.0.7",
       "version": "0.0.7",
       "resolved": "https://registry.npmjs.org/@transloadit/prettier-bytes/-/prettier-bytes-0.0.7.tgz",
       "resolved": "https://registry.npmjs.org/@transloadit/prettier-bytes/-/prettier-bytes-0.0.7.tgz",

+ 1 - 0
package.json

@@ -13,6 +13,7 @@
   },
   },
   "dependencies": {
   "dependencies": {
     "@element-plus/icons-vue": "^2.1.0",
     "@element-plus/icons-vue": "^2.1.0",
+    "@stomp/stompjs": "^7.0.0",
     "@wangeditor/editor": "^5.1.23",
     "@wangeditor/editor": "^5.1.23",
     "@wangeditor/editor-for-vue": "^1.0.2",
     "@wangeditor/editor-for-vue": "^1.0.2",
     "animate.css": "^4.1.1",
     "animate.css": "^4.1.1",

+ 22 - 22
src/main.ts

@@ -1,37 +1,37 @@
-import { createApp } from 'vue'
-import { createPinia } from 'pinia'
-import App from './App.vue'
-import router from './router'
+import { createApp } from 'vue';
+import { createPinia } from 'pinia';
+import App from './App.vue';
+import router from './router';
 // 样式
 // 样式
-import '@/assets/main.css'
+import '@/assets/main.css';
 // 动画
 // 动画
-import 'animate.css'
+import 'animate.css';
 // element
 // element
-import ElementPlus from 'element-plus'
-import 'element-plus/dist/index.css'
-import locale from 'element-plus/lib/locale/lang/zh-cn'
-import * as ElementPlusIconsVue from '@element-plus/icons-vue'
+import ElementPlus from 'element-plus';
+import 'element-plus/dist/index.css';
+import locale from 'element-plus/lib/locale/lang/zh-cn';
+import * as ElementPlusIconsVue from '@element-plus/icons-vue';
 // 图标
 // 图标
-import '@common/src/assets/icon/iconfont.css'
+import '@common/src/assets/icon/iconfont.css';
 // moment
 // moment
-import moment from 'moment'
+import moment from 'moment';
 // lodash
 // lodash
 // import _ from 'lodash';
 // import _ from 'lodash';
 
 
 // 组件
 // 组件
-import frameComponents from '@/components/index'
-const app = createApp(App)
-app.use(createPinia())
-app.use(router)
-app.use(ElementPlus, { locale })
+import frameComponents from '@/components/index';
+const app = createApp(App);
+app.use(createPinia());
+app.use(router);
+app.use(ElementPlus, { locale });
 for (const [key, component] of Object.entries(ElementPlusIconsVue)) {
 for (const [key, component] of Object.entries(ElementPlusIconsVue)) {
-  app.component(key, component)
+  app.component(key, component);
 }
 }
-app.config.globalProperties.$moment = moment
+app.config.globalProperties.$moment = moment;
 
 
 for (const componentItme in frameComponents) {
 for (const componentItme in frameComponents) {
-  app.component(componentItme, frameComponents[componentItme])
+  app.component(componentItme, frameComponents[componentItme]);
 }
 }
-app.config.globalProperties.$limit = parseInt(import.meta.env.VITE_APP_PAGE_SIZE) || 10
+app.config.globalProperties.$limit = parseInt(import.meta.env.VITE_APP_PAGE_SIZE) || 10;
 
 
-app.mount('#app')
+app.mount('#app');

+ 0 - 0
src/util/stomp.ts


+ 19 - 2
src/views/spatentadmin/info/index.vue

@@ -16,7 +16,8 @@
           <cButton @toAdd="toAdd()">
           <cButton @toAdd="toAdd()">
             <template #custom>
             <template #custom>
               <el-button type="primary" @click="toImport">批量导入</el-button>
               <el-button type="primary" @click="toImport">批量导入</el-button>
-              <el-button type="primary">批量下载</el-button>
+              <el-button type="primary" @click="toExport">专利下载</el-button>
+              <el-button type="primary" @click="toDownload">专利下载列表</el-button>
               <el-button type="primary" @click="toAlloca">批量分配</el-button>
               <el-button type="primary" @click="toAlloca">批量分配</el-button>
               <el-button type="danger" @click="todelMany">批量删除</el-button>
               <el-button type="danger" @click="todelMany">批量删除</el-button>
               <!-- <el-button type="danger" @click="toTouch">一键删除</el-button> -->
               <!-- <el-button type="danger" @click="toTouch">一键删除</el-button> -->
@@ -51,6 +52,12 @@
         <el-col :span="24" class="dialog_thr" v-else-if="dialog.type == '3'">
         <el-col :span="24" class="dialog_thr" v-else-if="dialog.type == '3'">
           <component :is="cDelmany" :list="selectList" @toClose="toClose"></component>
           <component :is="cDelmany" :list="selectList" @toClose="toClose"></component>
         </el-col>
         </el-col>
+        <el-col :span="24" class="dialog_four" v-else-if="dialog.type == '4'">
+          <component :is="cExport" @toClose="toClose"></component>
+        </el-col>
+        <el-col :span="24" class="dialog_four" v-else-if="dialog.type == '5'">
+          <component :is="cDownload"></component>
+        </el-col>
       </template>
       </template>
     </cDialog>
     </cDialog>
   </div>
   </div>
@@ -60,6 +67,9 @@
 import cImport from './parts/c-import.vue';
 import cImport from './parts/c-import.vue';
 import cAlloca from './parts/c-alloca.vue';
 import cAlloca from './parts/c-alloca.vue';
 import cDelmany from './parts/c-delmany.vue';
 import cDelmany from './parts/c-delmany.vue';
+import cExport from './parts/c-export.vue';
+import cDownload from './parts/c-download.vue';
+
 import _ from 'lodash';
 import _ from 'lodash';
 import type { Ref } from 'vue';
 import type { Ref } from 'vue';
 import { ref, onMounted, getCurrentInstance } from 'vue';
 import { ref, onMounted, getCurrentInstance } from 'vue';
@@ -111,7 +121,7 @@ let termList: Ref<any> = ref([]);
 let typeList: Ref<any> = ref([]);
 let typeList: Ref<any> = ref([]);
 
 
 // 弹框
 // 弹框
-const dialog: Ref<any> = ref({ title: '批量导入', show: false, type: '1' });
+const dialog: Ref<any> = ref({ title: '批量导入', show: true, type: '5' });
 // 批量分配
 // 批量分配
 const selectList: Ref<any> = ref([]);
 const selectList: Ref<any> = ref([]);
 
 
@@ -197,6 +207,13 @@ const todelMany = () => {
     ElMessage({ type: `warning`, message: `请选择需要批量删除的专利` });
     ElMessage({ type: `warning`, message: `请选择需要批量删除的专利` });
   }
   }
 };
 };
+// 专利下载
+const toExport = () => {
+  dialog.value = { title: '专利下载', show: true, type: '4' };
+};
+const toDownload = () => {
+  dialog.value = { title: '下载列表', show: true, type: '5' };
+};
 // 关闭弹框
 // 关闭弹框
 const toClose = () => {
 const toClose = () => {
   selectList.value = [];
   selectList.value = [];

+ 38 - 0
src/views/spatentadmin/info/parts/c-download.vue

@@ -0,0 +1,38 @@
+<template>
+  <div id="c-download">
+    <el-row>
+      <el-col :span="24" class="main" v-loading="loading">
+        <cTable :fields="fields" :opera="[]" :list="list" @query="search" :usePage="false"> </cTable>
+      </el-col>
+    </el-row>
+  </div>
+</template>
+
+<script setup lang="ts">
+// 基础
+import type { Ref } from 'vue';
+import { onMounted, ref } from 'vue';
+
+// 接口
+import { MissionStore } from '@common/src/stores/mission';
+import type { IQueryResult } from '@/util/types.util';
+const missionAxios = MissionStore();
+
+// 加载中
+const loading: Ref<any> = ref(false);
+
+const list: Ref<any> = ref([]);
+const fields: Ref<any> = ref([{ label: '文件', model: 'name' }]);
+
+// 请求
+onMounted(async () => {
+  loading.value = true;
+  search();
+  loading.value = false;
+});
+const search = async () => {
+  let res: IQueryResult = await missionAxios.query({});
+  console.log(res);
+};
+</script>
+<style scoped lang="scss"></style>

+ 95 - 0
src/views/spatentadmin/info/parts/c-export.vue

@@ -0,0 +1,95 @@
+<template>
+  <div id="c-export">
+    <el-row>
+      <el-col :span="24" class="main" v-loading="loading">
+        <el-col :span="24" class="one">
+          <cForm :span="24" :fields="fields" :form="form" :rules="{}" @save="toSave" label-width="auto">
+            <template #file>
+              <el-checkbox v-for="i in modelList" :key="i.model" :label="i">{{ i.label }}</el-checkbox>
+            </template>
+          </cForm>
+        </el-col>
+      </el-col>
+    </el-row>
+  </div>
+</template>
+
+<script setup lang="ts">
+// 基础
+import type { Ref } from 'vue';
+import { onMounted, ref } from 'vue';
+import { ElMessage } from 'element-plus';
+
+// 接口
+import { PatentStore } from '@common/src/stores/patent/patent';
+import type { IQueryResult } from '@/util/types.util';
+const patentAxios = PatentStore();
+
+const emit = defineEmits(['toClose']);
+
+// 加载中
+const loading: Ref<any> = ref(false);
+
+const form: Ref<any> = ref({ file: [] });
+const fields: Ref<any> = ref([{ label: '导出列', model: 'file', type: 'checkbox' }]);
+
+// 字典
+const modelList: Ref<any> = ref([
+  { label: '申请号', model: 'create_number' },
+  { label: '申请日', model: 'create_date' },
+  { label: '公开(公告)号', model: 'success_number' },
+  { label: '公开(公告)日', model: 'success_date' },
+  { label: '发明人', model: 'inventor' },
+  { label: '代理机构', model: 'agent' },
+  { label: '代理人', model: 'agent_personal' },
+  { label: '摘要(中文)', model: 'abstract' },
+  { label: '发明人地址', model: 'address' },
+  { label: '标题(中文)', model: 'name' },
+  { label: '申请人', model: 'apply_personal' },
+  { label: '专利有效性', model: 'term' },
+  { label: '专利类型', model: 'type' },
+  { label: '公开国别', model: 'nationality' },
+  { label: 'IPC主分类', model: 'ipc_type' },
+  { label: '当前法律状态', model: 'onlegal_status' },
+  { label: '法律状态', model: 'legal_status' },
+  { label: '法律文书日期', model: 'law_date' },
+  { label: '当前权利人', model: 'on_obligee' },
+  { label: '申请人地址(其他)', model: 'apply_address' },
+  { label: '申请人(其他)', model: 'apply_other' },
+  { label: '法律文书编号', model: 'law_num' },
+  { label: '首次公开日', model: 'first_opendate' },
+  { label: '授权公告日', model: 'empower_date' },
+  { label: '失效日', model: 'lose_date' },
+  { label: '实质审查生效日', model: 'examine_date' },
+  { label: '发明(设计)人(其他)', model: 'invention_design' },
+  { label: '链接到incoPat', model: 'incopat_link' },
+  { label: '首项权利要求', model: 'first_ask' },
+  { label: '第一申请人', model: 'first_apply' },
+  { label: '中国申请人地市', model: 'apply_city' },
+  { label: '工商统一社会信用代码', model: 'business_code' },
+  { label: '工商注册地址', model: 'business_address' },
+  { label: '第一发明人', model: 'first_inventor' },
+  { label: '合享价值度', model: 'shared_value' },
+  { label: '技术稳定性', model: 'techol_stable' },
+  { label: '技术先进性', model: 'techol_advanced' },
+  { label: 'PCT国际申请号', model: 'pct_apply' },
+  { label: 'PCT国际公布号', model: 'pct_publish' },
+  { label: '首页附图(压缩图)', model: 'file' }
+]);
+
+// 请求
+onMounted(async () => {
+  loading.value = true;
+  loading.value = false;
+});
+const toSave = async (data) => {
+  let res: IQueryResult = await patentAxios.pexport(data);
+  if (res.errcode == '0') {
+    ElMessage({ message: '下载', type: 'success' });
+    emit('toClose');
+  } else {
+    ElMessage({ message: `${res.errmsg}`, type: 'error' });
+  }
+};
+</script>
+<style scoped lang="scss"></style>

+ 2 - 2
vite.config.ts

@@ -20,12 +20,12 @@ export default defineConfig(({ mode }) => {
           target: 'http://broadcast.waityou24.cn'
           target: 'http://broadcast.waityou24.cn'
         },
         },
         '/zkzx/v2/api': {
         '/zkzx/v2/api': {
-          target: 'http://192.168.1.113:12001',
+          target: 'http://192.168.1.113:12001', //169.254.16.148
           changeOrigin: true,
           changeOrigin: true,
           ws: false
           ws: false
         },
         },
         '/zkzx/v2/patent/api': {
         '/zkzx/v2/patent/api': {
-          target: 'http://192.168.1.113:12002',
+          target: 'http://192.168.1.113:12002', //169.254.16.148
           changeOrigin: true,
           changeOrigin: true,
           ws: false
           ws: false
         }
         }