Commit ce1de2616dbf6cbd95c84a13838cdd89881c1603

Authored by monkeyhouyi
1 parent b4af9364

专项行动

src/api/baseData/externalAssistance.js 0 → 100644
  1 +// 外协信息
  2 +import request from "@/utils/request";
  3 +
  4 +// 获取公司信息列表
  5 +export async function getExternalAssistanceList() {
  6 + return await request({
  7 + url: '/extend/systeminformation/GetExternalAssistanceList',
  8 + method: 'get',
  9 + });
  10 +}
0 11 \ No newline at end of file
... ...
src/assets/style/common.scss
... ... @@ -73,6 +73,8 @@ a {
73 73 line-height: 30px;
74 74 .label {
75 75 color: #000;
  76 + text-align: right;
  77 + padding: 0 5px;
76 78 &.w-100 {
77 79 width: 100px;
78 80 }
... ...
src/store/modules/meta.js
... ... @@ -6,12 +6,15 @@ import { getSystemTypeList } from "@/api/common";
6 6 import { getAreaSelect } from "@/api/baseData/area";
7 7 // 系统分类
8 8 import { getSystemClassSelect } from "@/api/baseData/systemClass";
  9 +// 外协列表
  10 +import { getExternalAssistanceList } from "@/api/baseData/externalAssistance"
9 11  
10 12 const meta = {
11 13 state: {
12 14 system: '', // 系统类型
13 15 area: '', // 系统类型
14 16 systemClass: {},
  17 + externalAssistanceList: '', // 外协
15 18 },
16 19  
17 20 mutations: {
... ... @@ -24,6 +27,9 @@ const meta = {
24 27 SET_SYSTEM_CLASS: (state, {key, data}) => {
25 28 state.systemClass[key] = data;
26 29 },
  30 + SET_EXTERNALASSISTANCE_CLASS: (state, data) => {
  31 + state.externalAssistanceList = data;
  32 + },
27 33 },
28 34  
29 35 actions: {
... ... @@ -42,6 +48,12 @@ const meta = {
42 48 resolve(res.data)
43 49 }).catch(error => { reject(error) })
44 50 break;
  51 + case 'externalAssistance':
  52 + getExternalAssistanceList().then(res => {
  53 + commit('SET_EXTERNALASSISTANCE_CLASS', res.data)
  54 + resolve(res.data)
  55 + }).catch(error => { reject(error) })
  56 + break;
45 57  
46 58 default:
47 59 break;
... ...
src/store/modules/user.js
... ... @@ -18,6 +18,7 @@ const user = {
18 18 userInfo: {},
19 19 menuList: [],
20 20 socket: '',
  21 + islader: false,
21 22 },
22 23  
23 24 mutations: {
... ... @@ -50,7 +51,10 @@ const user = {
50 51 },
51 52 SET_MENULIST: (state, menuList) => {
52 53 state.menuList = menuList
53   - }
  54 + },
  55 + SET_ISLADER: (state, islader) => {
  56 + state.islader = islader
  57 + },
54 58 },
55 59  
56 60 actions: {
... ... @@ -187,6 +191,8 @@ const user = {
187 191 commit('SET_AVATAR', avatar)
188 192 commit('SET_ADDRESS', userInfo.loginIPAddressName)
189 193 commit('SET_USERINFO', userInfo)
  194 + // 是否为市级领导
  195 + commit('SET_ISLADER', userInfo.organizeId == '580547494862128389')
190 196 commit('SET_MENULIST', menuList)
191 197 resolve(routerList)
192 198 }).catch(error => {
... ...
src/views/DisposalSuggestions/Form.vue
... ... @@ -129,7 +129,7 @@
129 129 computed: {
130 130 isSHILevel() {
131 131 // 判断角色是否为‘市级办公室’
132   - return this.$store.state.user.userInfo.organizeId == '580547494862128389';
  132 + return this.$store.state.user.islader;
133 133 },
134 134 },
135 135 watch: {},
... ...
src/views/baseSpecialAction/Form.vue
... ... @@ -28,7 +28,7 @@
28 28 </el-input>
29 29 </el-form-item>
30 30 </el-col>
31   - <el-col :span="23" v-if="ncc.hasFormP('title')">
  31 + <el-col :span="23" v-if="ncc.hasFormP('title') && !dataForm.id">
32 32 <el-form-item label="标题" prop="title">
33 33 <el-input
34 34 v-model="dataForm.title"
... ... @@ -40,7 +40,14 @@
40 40 </el-input>
41 41 </el-form-item>
42 42 </el-col>
43   - <el-col :span="23" v-if="ncc.hasFormP('annex')">
  43 + <el-col :span="23" v-if="ncc.hasFormP('content') && !dataForm.id">
  44 + <el-form-item label="内容" prop="content">
  45 + <el-input v-model="dataForm.content" placeholder="请输入" show-word-limit :style="{ width: '100%' }"
  46 + type="textarea" :autosize="{ minRows: 4, maxRows: 4 }">
  47 + </el-input>
  48 + </el-form-item>
  49 + </el-col>
  50 + <el-col :span="23" v-if="ncc.hasFormP('annex') && !dataForm.id">
44 51 <el-form-item label="附件" prop="annex">
45 52 <NCC-UploadFz
46 53 v-model="dataForm.annex"
... ... @@ -52,7 +59,7 @@
52 59 </NCC-UploadFz>
53 60 </el-form-item>
54 61 </el-col>
55   - <el-col :span="23" v-if="ncc.hasFormP('communicationArea')">
  62 + <el-col :span="23" v-if="ncc.hasFormP('communicationArea') && dataForm.id">
56 63 <el-form-item label="传达区域" prop="communicationArea">
57 64 <el-checkbox-group v-model="dataForm.communicationArea" :style="{}">
58 65 <el-checkbox
... ... @@ -63,21 +70,43 @@
63 70 >
64 71 </el-checkbox-group>
65 72 <div style="margin-top: 10px">
66   - <el-button size="mini" @click="selectAreaAll">全选</el-button>
67   - <el-button size="mini" @click="closeAreaAll">反选</el-button>
  73 + <el-button size="mini" @click="selectAreaAll('area')">全选</el-button>
  74 + <el-button size="mini" @click="closeAreaAll('area')">反选</el-button>
68 75 </div>
69 76 </el-form-item>
70 77 </el-col>
71   - <el-col :span="23" v-if="ncc.hasFormP('communicationArea')">
72   - <el-form-item label="传达外协" prop="communicationArea">
73   - <el-checkbox-group v-model="dataForm.communicationArea" :style="{}">
  78 + <el-col :span="23" v-if="ncc.hasFormP('communicationOut') && dataForm.id">
  79 + <el-form-item label="传达外协" prop="communicationOut">
  80 + <el-checkbox-group v-model="dataForm.communicationOut" :style="{}">
74 81 <el-checkbox
75   - v-for="(item, index) in communicationAreaOptions"
  82 + v-for="(item, index) in communicationOutOptions"
76 83 :key="index"
77 84 :label="item.id"
78 85 >{{ item.fullName }}</el-checkbox
79 86 >
80 87 </el-checkbox-group>
  88 + <div style="margin-top: 10px">
  89 + <el-button size="mini" @click="selectAreaAll">全选</el-button>
  90 + <el-button size="mini" @click="closeAreaAll">反选</el-button>
  91 + </div>
  92 + </el-form-item>
  93 + </el-col>
  94 + <el-col :span="23" v-if="ncc.hasFormP('relationId') && dataForm.id">
  95 + <el-form-item label="填报表单" prop="relationId">
  96 + <el-select v-model="dataForm.relationId" placeholder="请选择专项行动填报表单" style="margin-right: 10px;width: 300px;">
  97 + <el-option v-for="item in BaseList" :key="item.id" :label="item.fullName" :value="item.id">
  98 + </el-option>
  99 + </el-select>
  100 + <el-button size="mini" type="text" @click="dialogVisible = true">没有找到表单?点击设计表单</el-button>
  101 + </el-form-item>
  102 + </el-col>
  103 + <el-col :span="23" v-if="ncc.hasFormP('deadline') && dataForm.id">
  104 + <el-form-item label="截止日期" prop="deadline">
  105 + <el-date-picker
  106 + v-model="dataForm.deadline"
  107 + type="date"
  108 + placeholder="选择截止日期">
  109 + </el-date-picker>
81 110 </el-form-item>
82 111 </el-col>
83 112 </el-form>
... ... @@ -88,6 +117,15 @@
88 117 >确 定</el-button
89 118 >
90 119 </span>
  120 + <el-dialog class="zxDialog" title="专项行动表单设计" :visible.sync="dialogVisible" fullscreen @close="handleClose" :modal="false">
  121 + <iframe
  122 + :src="nestedPageUrl"
  123 + width="100%"
  124 + :height="viewportHeight - 58 + 'px'"
  125 + frameborder="0"
  126 + allowfullscreen>
  127 + </iframe>
  128 + </el-dialog>
91 129 </el-dialog>
92 130 </template>
93 131 <script>
... ... @@ -111,11 +149,14 @@ export default {
111 149 releaseTime: undefined,
112 150 annex: [],
113 151 communicationArea: [],
  152 + communicationOut: [],
114 153 state: undefined,
115 154 creatorUserId: undefined,
116 155 creatorTime: undefined,
117 156 lastModifyUserId: undefined,
118 157 lastModifyTime: undefined,
  158 + deadline: undefined,
  159 + relationId: undefined
119 160 },
120 161 rules: {
121 162 specialActionType: [
... ... @@ -132,35 +173,96 @@ export default {
132 173 trigger: "blur",
133 174 },
134 175 ],
  176 + deadline: [
  177 + {
  178 + required: true,
  179 + message: "请输入截止日期",
  180 + trigger: "change",
  181 + }
  182 + ]
135 183 },
136 184 areaOptions: [],
137   - communicationAreaOptions: [],
  185 + communicationOutOptions: [],
  186 + BaseList:[],
  187 + viewportHeight: 0,
  188 + nestedPageUrl:"http://8.130.38.56:8043/old/#/onlineDev/webDesign/indexNew",
  189 + dialogVisible: false,
138 190 };
139 191 },
140 192 computed: {},
141 193 watch: {},
142 194 created() {
143 195 this.initAreaTypeList();
  196 + this.initCommunicationOutOptions();
  197 + this.updateViewportHeight();
  198 + this.getDataForm();
  199 + // 监听窗口大小变化事件
  200 + window.addEventListener('resize', this.updateViewportHeight);
144 201 },
145 202 mounted() {},
  203 + beforeDestroy() {
  204 + // 移除窗口大小变化事件监听器
  205 + window.removeEventListener('resize', this.updateViewportHeight);
  206 + },
146 207 methods: {
  208 + updateViewportHeight() {
  209 + // 获取页面显示高度
  210 + this.viewportHeight = window.innerHeight || document.documentElement.clientHeight;
  211 + },
  212 + handleClose() {
  213 + // 这里是对话框关闭后需要执行的代码
  214 + this.getDataForm();
  215 + // 例如,你可以在这里添加任何其他的逻辑
  216 + },
  217 + //查询表单
  218 + getDataForm() {
  219 + request({
  220 + url: "/visualdev/Base?type=1",
  221 + method: "get",
  222 + }).then((res) => {
  223 + this.BaseList = res.data.list[0].children;
  224 + console.log(this.BaseList)
  225 + });
  226 + },
147 227 async initAreaTypeList() {
148 228 let list = this.$store.state.meta.area;
149 229 !list && (list = await this.$store.dispatch("getTypeListByCode", "area"));
150 230 this.areaOptions = list;
151 231 },
152   - selectAreaAll() {
153   - this.dataForm.communicationArea = this.areaOptions.map(
154   - (option) => option.id
155   - );
  232 + async initCommunicationOutOptions() {
  233 + let list = this.$store.state.meta.externalAssistanceList;
  234 + !list && (list = await this.$store.dispatch("getTypeListByCode", "externalAssistance"));
  235 + this.communicationOutOptions = list;
156 236 },
157   - closeAreaAll() {
158   - this.dataForm.communicationArea = this.areaOptions
159   - .filter(
160   - (option) => !this.dataForm.communicationArea.includes(option.id)
161   - )
162   - .map((option) => option.id);
  237 + // 全选
  238 + selectAreaAll(type) {
  239 + if(type == 'area') {
  240 + this.dataForm.communicationArea = this.areaOptions.map(
  241 + (option) => option.id
  242 + );
  243 + } else {
  244 + this.dataForm.communicationOut = this.communicationOutOptions.map(
  245 + (option) => option.id
  246 + );
  247 + }
163 248 },
  249 + // 反选
  250 + closeAreaAll(type) {
  251 + if(type == 'area') {
  252 + this.dataForm.communicationArea = this.areaOptions
  253 + .filter(
  254 + (option) => !this.dataForm.communicationArea.includes(option.id)
  255 + )
  256 + .map((option) => option.id);
  257 + } else {
  258 + this.dataForm.communicationOut = this.communicationOutOptions
  259 + .filter(
  260 + (option) => !this.dataForm.communicationOut.includes(option.id)
  261 + )
  262 + .map((option) => option.id);
  263 + }
  264 + },
  265 +
164 266 goBack() {
165 267 this.$emit("refresh");
166 268 },
... ... @@ -170,27 +272,18 @@ export default {
170 272 this.isDetail = isDetail || false;
171 273 this.$nextTick(() => {
172 274 this.$refs["elForm"].resetFields();
173   - if (this.dataForm.id) {
174   - request({
175   - url: "/Extend/BaseSpecialAction/" + this.dataForm.id,
176   - method: "get",
177   - }).then((res) => {
178   - this.dataForm = res.data;
179   - if (!this.dataForm.annex) this.dataForm.annex = [];
180   - if (!this.dataForm.communicationArea)
181   - this.dataForm.communicationArea = [];
182   - });
183   - }
184 275 });
185 276 },
186 277 dataFormSubmit() {
187 278 this.$refs["elForm"].validate((valid) => {
188 279 if (valid) {
189 280 if (!this.dataForm.id) {
  281 + let {title, content} = this.dataForm;
  282 + // 新增
190 283 request({
191 284 url: `/Extend/BaseSpecialAction`,
192 285 method: "post",
193   - data: this.dataForm,
  286 + data: { title, content },
194 287 }).then((res) => {
195 288 this.$message({
196 289 message: res.msg,
... ... @@ -202,8 +295,9 @@ export default {
202 295 });
203 296 });
204 297 } else {
  298 + // 发布任务
205 299 request({
206   - url: "/Extend/BaseSpecialAction/" + this.dataForm.id,
  300 + url: "/Extend/BaseSpecialAction/Release",
207 301 method: "PUT",
208 302 data: this.dataForm,
209 303 }).then((res) => {
... ... @@ -224,3 +318,10 @@ export default {
224 318 },
225 319 };
226 320 </script>
  321 +<style lang="scss" scoped>
  322 +.el-dialog__wrapper.zxDialog {
  323 + :deep(.el-dialog__body) {
  324 + max-height: unset;
  325 + }
  326 +}
  327 +</style>
... ...
src/views/baseSpecialAction/index.vue
... ... @@ -8,33 +8,21 @@
8 8 <el-form @submit.native.prevent size="mini">
9 9 <el-col :span="6">
10 10 <el-form-item label="">
11   - <el-input
12   - v-model="query.title"
13   - placeholder="标题"
14   - clearable
15   - />
  11 + <el-input v-model="query.title" placeholder="标题" clearable/>
16 12 </el-form-item>
17 13 </el-col>
18 14 <el-col :span="6">
19 15 <el-form-item label="">
20   - <el-input
21   - v-model="query.state"
22   - placeholder="状态"
23   - clearable
24   - />
  16 + <el-select v-model="query.state" placeholder="请选择状态" clearable>
  17 + <el-option label="已发布" value="已发布"></el-option>
  18 + <el-option label="未发布" value="未发布"></el-option>
  19 + </el-select>
25 20 </el-form-item>
26 21 </el-col>
27 22 <el-col :span="6">
28 23 <el-form-item>
29   - <el-button
30   - type="primary"
31   - icon="el-icon-search"
32   - @click="search()"
33   - >查询</el-button
34   - >
35   - <el-button icon="el-icon-refresh-right" @click="reset()"
36   - >重置</el-button
37   - >
  24 + <el-button type="primary" icon="el-icon-search" @click="search()">查询</el-button>
  25 + <el-button icon="el-icon-refresh-right" @click="reset()">重置</el-button>
38 26 </el-form-item>
39 27 </el-col>
40 28 </el-form>
... ... @@ -45,94 +33,46 @@
45 33 <div class="NCC-common-layout-main NCC-flex-main">
46 34 <div class="NCC-common-head">
47 35 <div>
48   - <el-button
49   - type="primary"
50   - icon="el-icon-plus"
51   - @click="addOrUpdateHandle()"
52   - size="mini"
53   - >新增</el-button
54   - >
  36 + <el-button type="primary" icon="el-icon-plus" @click="addOrUpdateHandle()" size="mini" >新增</el-button>
55 37 </div>
56 38 </div>
57 39 <NCC-table v-loading="listLoading" :data="list">
58 40 <el-table-column prop="id" label="主键" align="left" show-overflow-tooltip/>
59 41 <el-table-column prop="title" label="标题" align="left" show-overflow-tooltip/>
60   - <el-table-column
61   - prop="releaseTime"
62   - label="发布时间"
63   - align="left"
64   - show-overflow-tooltip
65   - />
66   - <el-table-column
67   - label="传达区域"
68   - prop="communicationArea"
69   - align="left"
70   - show-overflow-tooltip
71   - >
72   - <template slot-scope="scope">{{
73   - scope.row.communicationArea
74   - | dynamicText(communicationAreaOptions)
75   - }}</template>
  42 + <el-table-column prop="state" label="状态" align="left" show-overflow-tooltip/>
  43 + <el-table-column prop="creatorTime" label="发布时间" align="left" :formatter="ncc.tableDateFormat" show-overflow-tooltip/>
  44 + <el-table-column label="传达区域" prop="communicationArea" align="left" show-overflow-tooltip>
  45 + <template slot-scope="scope">{{ JSON.parse(scope.row.communicationArea) | dynamicText(communicationAreaOptions) }}</template>
76 46 </el-table-column>
77   - <el-table-column
78   - label="传达外协"
79   - prop="communicationArea"
80   - align="left"
81   - show-overflow-tooltip
82   - >
83   - <template slot-scope="scope">{{
84   - scope.row.communicationArea
85   - | dynamicText(communicationAreaOptions)
86   - }}</template>
  47 + <el-table-column label="传达外协" prop="communicationOut" align="left" show-overflow-tooltip>
  48 + <template slot-scope="scope">{{ JSON.parse(scope.row.communicationOut) | dynamicText(communicationOutOptions) }}</template>
87 49 </el-table-column>
88   - <el-table-column
89   - prop="creatorUserId"
90   - show-overflow-tooltip
91   - label="创建用户"
92   - align="left"
93   - />
94   - <el-table-column label="操作" fixed="right" width="100">
  50 + <el-table-column prop="deadline" label="截止日期" align="left" :formatter="ncc.tableDateFormat" show-overflow-tooltip/>
  51 + <el-table-column prop="creatorUserId" show-overflow-tooltip label="创建用户" align="left"/>
  52 + <el-table-column label="操作" fixed="right" width="130">
95 53 <template slot-scope="scope">
96   - <el-button
97   - type="text"
98   - @click="addOrUpdateHandle(scope.row.id)"
99   - >编辑</el-button
100   - >
101   - <el-button
102   - type="text"
103   - @click="handleDel(scope.row.id)"
104   - class="NCC-table-delBtn"
105   - >删除</el-button
106   - >
  54 + <el-button type="text" @click="addOrUpdateHandle(scope.row.id)">发布任务</el-button>
  55 + <el-button type="text" @click="toDetail(scope.row)" v-if="scope.row.state == '已发布'">行动情况</el-button>
107 56 </template>
108 57 </el-table-column>
109 58 </NCC-table>
110   - <pagination
111   - :total="total"
112   - :page.sync="listQuery.currentPage"
113   - :limit.sync="listQuery.pageSize"
114   - @pagination="initData"
115   - />
  59 + <pagination :total="total" :page.sync="listQuery.currentPage" :limit.sync="listQuery.pageSize" @pagination="initData"/>
116 60 </div>
117 61 </div>
118 62 <NCC-Form v-if="formVisible" ref="NCCForm" @refresh="refresh" />
119   - <ExportBox
120   - v-if="exportBoxVisible"
121   - ref="ExportBox"
122   - @download="download"
123   - />
  63 + <ExportBox v-if="exportBoxVisible" ref="ExportBox" @download="download"/>
  64 + <InfoForm v-if="InfoFormVisible" ref="InfoForm" @refresh="InfoFormVisible = false"/>
124 65 </div>
125 66 </div>
126 67 </div>
127 68 </template>
128 69 <script>
129 70 import request from "@/utils/request";
130   -import { getDictionaryDataSelector } from "@/api/systemData/dictionary";
131 71 import NCCForm from "./Form";
132 72 import ExportBox from "./ExportBox";
133   -import { previewDataInterface } from "@/api/systemData/dataInterface";
  73 +import InfoForm from "./infoForm.vue";
134 74 export default {
135   - components: { NCCForm, ExportBox },
  75 + components: { NCCForm, ExportBox, InfoForm },
136 76 data() {
137 77 return {
138 78 query: {
... ... @@ -141,7 +81,6 @@ export default {
141 81 },
142 82 list: [],
143 83 listLoading: false,
144   - multipleSelection: [],
145 84 total: 0,
146 85 listQuery: {
147 86 currentPage: 1,
... ... @@ -151,33 +90,32 @@ export default {
151 90 },
152 91 formVisible: false,
153 92 exportBoxVisible: false,
154   - columnList: [
155   - { prop: "id", label: "主键" },
156   - { prop: "specialActionType", label: "类型" },
157   - { prop: "title", label: "标题" },
158   - { prop: "releaseTime", label: "发布时间" },
159   - { prop: "communicationArea", label: "传达区域" },
160   - { prop: "state", label: "状态" },
161   - { prop: "creatorUserId", label: "创建用户" },
162   - { prop: "creatorTime", label: "创建时间" },
163   - { prop: "lastModifyUserId", label: "修改用户" },
164   - { prop: "lastModifyTime", label: "修改时间" },
165   - { prop: "content", label: "内容" },
166   - ],
167   - specialActionTypeOptions: [],
  93 + InfoFormVisible: false,
168 94 communicationAreaOptions: [],
  95 + communicationOutOptions: [],
169 96 };
170 97 },
171   - computed: {},
172 98 created() {
  99 + this.initAreaTypeList();
  100 + this.initCommunicationOutOptions();
173 101 this.initData()
174   - this.getspecialActionTypeOptions();
175 102 },
  103 + computed: {
  104 + isSHILevel() {
  105 + // 判断角色是否为‘市级办公室’
  106 + return this.$store.state.user.islader;
  107 + },
  108 + },
176 109 methods: {
177   - getspecialActionTypeOptions() {
178   - getDictionaryDataSelector("576310654982423813").then((res) => {
179   - this.specialActionTypeOptions = res.data.list;
180   - });
  110 + async initAreaTypeList() {
  111 + let list = this.$store.state.meta.area;
  112 + !list && (list = await this.$store.dispatch("getTypeListByCode", "area"));
  113 + this.communicationAreaOptions = list;
  114 + },
  115 + async initCommunicationOutOptions() {
  116 + let list = this.$store.state.meta.externalAssistanceList;
  117 + !list && (list = await this.$store.dispatch("getTypeListByCode", "externalAssistance"));
  118 + this.communicationOutOptions = list;
181 119 },
182 120 initData() {
183 121 this.listLoading = true;
... ... @@ -193,46 +131,35 @@ export default {
193 131 query[key] = _query[key];
194 132 }
195 133 }
  134 + // 市级专项行动列表
196 135 request({
197   - url: `/Extend/BaseSpecialAction`,
  136 + url: '/Extend/BaseSpecialAction',
198 137 method: "GET",
199   - data: query,
  138 + params: query,
200 139 }).then((res) => {
201 140 this.list = res.data.list;
  141 + // console.log(this.list, 'list');
202 142 this.total = res.data.pagination.total;
203 143 this.listLoading = false;
204 144 });
205 145 },
206   - handleDel(id) {
207   - this.$confirm("此操作将永久删除该数据, 是否继续?", "提示", {
208   - type: "warning",
209   - })
210   - .then(() => {
211   - request({
212   - url: `/Extend/BaseSpecialAction/${id}`,
213   - method: "DELETE",
214   - }).then((res) => {
215   - this.$message({
216   - type: "success",
217   - message: res.msg,
218   - onClose: () => {
219   - this.initData();
220   - },
221   - });
222   - });
223   - })
224   - .catch(() => {});
225   - },
  146 +
226 147 addOrUpdateHandle(id, isDetail) {
227 148 this.formVisible = true;
228 149 this.$nextTick(() => {
229 150 this.$refs.NCCForm.init(id, isDetail);
230 151 });
231 152 },
  153 + toDetail(row) {
  154 + this.InfoFormVisible = true;
  155 + this.$nextTick(() => {
  156 + this.$refs.InfoForm.init(row);
  157 + });
  158 + },
232 159 exportData() {
233 160 this.exportBoxVisible = true;
234 161 this.$nextTick(() => {
235   - this.$refs.ExportBox.init(this.columnList);
  162 + this.$refs.ExportBox.init(this.list);
236 163 });
237 164 },
238 165 download(data) {
... ...
src/views/baseSpecialAction/infoForm.vue 0 → 100644
  1 +<template>
  2 + <!-- 专项行动填报情况 -->
  3 + <el-dialog
  4 + title="行动情况"
  5 + :close-on-click-modal="false"
  6 + :visible.sync="visible"
  7 + class="NCC-dialog NCC-dialog_center"
  8 + lock-scroll
  9 + width="70%"
  10 + >
  11 + <el-row :gutter="15" style="height: 65vh">
  12 + <el-col :span="24" style="margin-bottom: 20px;">
  13 + <el-col :span="12" class="form-item">
  14 + <div class="label w-100">行动标题:</div>
  15 + <div>{{ form.title }}</div>
  16 + </el-col>
  17 + <el-col :span="12" class="form-item">
  18 + <div class="label w-100">截止日期:</div>
  19 + <div>{{ ncc.dateFormat(form.deadline) }}</div>
  20 + </el-col>
  21 + </el-col>
  22 + <el-col :span="24" style="height: calc(100% - 100px);">
  23 + <el-table :data="tableData" style="width: 100%" v-loading="loading" stripe>
  24 + <el-table-column type="index" width="50" />
  25 + <el-table-column prop="originName" label="部门名称" />
  26 + <el-table-column prop="state" label="状态" />
  27 + </el-table>
  28 + <pagination :total="total" :page.sync="listQuery.currentPage" :limit.sync="listQuery.pageSize" @pagination="initList"/>
  29 + </el-col>
  30 + </el-row>
  31 + <span slot="footer" class="dialog-footer">
  32 + <el-button @click="close">取 消</el-button>
  33 + </span>
  34 + </el-dialog>
  35 +</template>
  36 +<script>
  37 +import request from "@/utils/request";
  38 +export default {
  39 + components: {},
  40 + props: [],
  41 + data() {
  42 + return {
  43 + loading: false,
  44 + visible: false,
  45 + tableData: [{}],
  46 + listQuery: {
  47 + currentPage: 1,
  48 + pageSize: 20,
  49 + },
  50 + total: 0,
  51 + form: {},
  52 + };
  53 + },
  54 + computed: {},
  55 + watch: {},
  56 + created() {},
  57 + mounted() {},
  58 + methods: {
  59 + close() {
  60 + this.form = {};
  61 + this.$emit("refresh");
  62 + },
  63 + init(row) {
  64 + this.form = row;
  65 + this.visible = true;
  66 + this.loading = true;
  67 + this.$nextTick(() => {
  68 + this.initList();
  69 + })
  70 + },
  71 + initList() {
  72 + request({
  73 + url: `/Extend/BaseSpecialActionInfo/GetListById`,
  74 + method: "GET",
  75 + params: {
  76 + ...this.listQuery,
  77 + specialActionId: this.form.id,
  78 + },
  79 + }).then((res) => {
  80 + this.tableData = res.data.list;
  81 + this.total = res.data.pagination.total;
  82 + this.loading = false;
  83 + });
  84 + }
  85 + },
  86 +};
  87 +</script>
  88 +<style lang="scss" scoped>
  89 +.NCC-dialog {
  90 + :deep(.el-pagination__total) {
  91 + color: #606266;
  92 + }
  93 + :deep(.el-pagination__jump) {
  94 + color: #606266;
  95 + }
  96 +}
  97 +</style>
... ...
src/views/baseSpecialhandle/index.vue 0 → 100644
  1 +<template>
  2 + <div class="baseSpecialAction item-box common-info-box">
  3 + <div class="item-title">专项行动处理</div>
  4 + <div class="item-body">
  5 + <div class="NCC-common-layout">
  6 + <div class="NCC-common-layout-center">
  7 + <el-row class="NCC-common-search-box" :gutter="16">
  8 + <el-form @submit.native.prevent size="mini">
  9 + <el-col :span="6">
  10 + <el-form-item label="">
  11 + <el-input v-model="query.title" placeholder="标题" clearable/>
  12 + </el-form-item>
  13 + </el-col>
  14 + <el-col :span="6">
  15 + <el-form-item label="">
  16 + <el-select v-model="query.state" placeholder="请选择状态" clearable>
  17 + <el-option label="已填写" value="已填写"></el-option>
  18 + <el-option label="未填写" value="未填写"></el-option>
  19 + </el-select>
  20 + </el-form-item>
  21 + </el-col>
  22 + <el-col :span="6">
  23 + <el-form-item>
  24 + <el-button type="primary" icon="el-icon-search" @click="search()">查询</el-button>
  25 + <el-button icon="el-icon-refresh-right" @click="reset()">重置</el-button>
  26 + </el-form-item>
  27 + </el-col>
  28 + </el-form>
  29 + <div class="NCC-common-search-box-right">
  30 + <el-button type="primary" icon="el-icon-download" size="mini" @click="exportData()">导出</el-button>
  31 + </div>
  32 + </el-row>
  33 + <div class="NCC-common-layout-main NCC-flex-main">
  34 + <NCC-table v-loading="listLoading" :data="list">
  35 + <el-table-column prop="id" label="主键" align="left" show-overflow-tooltip/>
  36 + <el-table-column prop="title" label="标题" align="left" show-overflow-tooltip/>
  37 + <el-table-column prop="state" label="状态" align="left" show-overflow-tooltip/>
  38 + <el-table-column prop="deadline" label="截止日期" align="left" :formatter="ncc.tableDateFormat" show-overflow-tooltip/>
  39 + <el-table-column label="操作" fixed="right" width="130">
  40 + <template slot-scope="scope">
  41 + <el-button type="text" @click="toFillForm(scope.row)">处理</el-button>
  42 + </template>
  43 + </el-table-column>
  44 + </NCC-table>
  45 + <pagination :total="total" :page.sync="listQuery.currentPage" :limit.sync="listQuery.pageSize" @pagination="initData"/>
  46 + </div>
  47 + </div>
  48 + </div>
  49 + </div>
  50 + <el-dialog title="专项行动处理" :visible.sync="dialogVisible" fullscreen :modal="false">
  51 + <iframe
  52 + :src="nestedPageUrl"
  53 + width="100%"
  54 + :height="viewportHeight - 58 + 'px'"
  55 + frameborder="0"
  56 + allowfullscreen>
  57 + </iframe>
  58 + </el-dialog>
  59 + </div>
  60 + </template>
  61 + <script>
  62 + import request from "@/utils/request";
  63 + export default {
  64 + components: { },
  65 + data() {
  66 + return {
  67 + query: {
  68 + title: undefined,
  69 + state: undefined,
  70 + },
  71 + list: [],
  72 + listLoading: false,
  73 + total: 0,
  74 + listQuery: {
  75 + currentPage: 1,
  76 + pageSize: 20,
  77 + sort: "desc",
  78 + sidx: "",
  79 + },
  80 + communicationAreaOptions: [],
  81 + communicationOutOptions: [],
  82 + dialogVisible: false,
  83 + nestedPageUrl: '',
  84 + viewportHeight: 0,
  85 + };
  86 + },
  87 + created() {
  88 + this.updateViewportHeight();
  89 + this.initData()
  90 + // 监听窗口大小变化事件
  91 + window.addEventListener('resize', this.updateViewportHeight);
  92 + },
  93 + beforeDestroy() {
  94 + // 移除窗口大小变化事件监听器
  95 + window.removeEventListener('resize', this.updateViewportHeight);
  96 + },
  97 + computed: {
  98 + isSHILevel() {
  99 + // 判断角色是否为‘市级办公室’
  100 + return this.$store.state.user.islader;
  101 + },
  102 + },
  103 + methods: {
  104 + updateViewportHeight() {
  105 + // 获取页面显示高度
  106 + this.viewportHeight = window.innerHeight || document.documentElement.clientHeight;
  107 + },
  108 + initData() {
  109 + this.listLoading = true;
  110 + let _query = {
  111 + ...this.listQuery,
  112 + ...this.query,
  113 + };
  114 + let query = {};
  115 + for (let key in _query) {
  116 + if (Array.isArray(_query[key])) {
  117 + query[key] = _query[key].join();
  118 + } else {
  119 + query[key] = _query[key];
  120 + }
  121 + }
  122 + request({
  123 + url: '/Extend/BaseSpecialAction/getCurrentUserSpecialAction',
  124 + method: "GET",
  125 + params: query,
  126 + }).then((res) => {
  127 + this.list = res.data.list;
  128 + this.total = res.data.pagination.total;
  129 + this.listLoading = false;
  130 + });
  131 + },
  132 + toFillForm(row) {
  133 + this.dialogVisible = true;
  134 + this.nestedPageUrl = `http://8.130.38.56:8043/old/#/previewModel?isPreview=1&id=${row.originId}`;
  135 + request({
  136 + url: '/visualdev/Base',
  137 + method: "GET",
  138 + data: {type: 1},
  139 + }).then((res) => {
  140 + this.BaseList = res.data.list[0].children.find(v => v.category == row.originId);
  141 +
  142 + res.data.
  143 + console.log(res);
  144 + });
  145 + },
  146 +
  147 + exportData() {
  148 + this.exportBoxVisible = true;
  149 + this.$nextTick(() => {
  150 + this.$refs.ExportBox.init(this.list);
  151 + });
  152 + },
  153 + download(data) {
  154 + let query = { ...data, ...this.listQuery, ...this.query };
  155 + request({
  156 + url: `/Extend/BaseSpecialAction/Actions/Export`,
  157 + method: "GET",
  158 + data: query,
  159 + }).then((res) => {
  160 + if (!res.data.url) return;
  161 + window.location.href = this.define.comUrl + res.data.url;
  162 + this.$refs.ExportBox.visible = false;
  163 + this.exportBoxVisible = false;
  164 + });
  165 + },
  166 + search() {
  167 + this.listQuery = {
  168 + currentPage: 1,
  169 + pageSize: 20,
  170 + sort: "desc",
  171 + sidx: "",
  172 + };
  173 + this.initData();
  174 + },
  175 + refresh(isrRefresh) {
  176 + this.formVisible = false;
  177 + if (isrRefresh) this.reset();
  178 + },
  179 + reset() {
  180 + for (let key in this.query) {
  181 + this.query[key] = undefined;
  182 + }
  183 + this.listQuery = {
  184 + currentPage: 1,
  185 + pageSize: 20,
  186 + sort: "desc",
  187 + sidx: "",
  188 + };
  189 + this.initData();
  190 + },
  191 + },
  192 + };
  193 + </script>
  194 + <style scoped lang="scss">
  195 + .common-info-box {
  196 + :deep(.el-table__body-wrapper.is-scrolling-none) {
  197 + height: calc(100% - 47px);
  198 + overflow-y: scroll;
  199 + }
  200 + }
  201 + </style>
  202 +
0 203 \ No newline at end of file
... ...
src/views/overView/Overview.vue
... ... @@ -2,8 +2,8 @@
2 2 <div class="overview">
3 3 <el-row :gutter="20">
4 4 <el-col :span="16">
5   - <div class="item-box todo" v-if="isSHILevel">
6   - <div class="item-title">任务待办</div>
  5 + <div class="item-box todo">
  6 + <div class="item-title">事件中心</div>
7 7 <div class="item-body">
8 8 <template>
9 9 <el-table :data="todoTableData" style="width: 100%" stripe>
... ... @@ -47,8 +47,12 @@
47 47 </template>
48 48 </div>
49 49 </div>
50   - <div class="item-box earmarked" :style="`height: calc(${isSHILevel ? '50vh - 115px' : '100vh - 205px'});`">
51   - <!-- :style=`"height: ${isSHILevel ? calc(50vh - 115px) : calc(100vh - 205px)};"` -->
  50 + <!--<div
  51 + class="item-box earmarked"
  52 + :style="`height: calc(${
  53 + isSHILevel ? '50vh - 115px' : '100vh - 205px'
  54 + });`"
  55 + >
52 56 <div class="item-title">专项行动</div>
53 57 <div class="item-body">
54 58 <el-row :gutter="6" class="item-one-list">
... ... @@ -80,7 +84,7 @@
80 84 </el-col>
81 85 </el-row>
82 86 </div>
83   - </div>
  87 + </div>-->
84 88 </el-col>
85 89 <el-col :span="8">
86 90 <!-- <div class="item-box tip">
... ... @@ -105,10 +109,19 @@
105 109 </div>
106 110 </div> -->
107 111 <div class="item-box msg">
108   - <div class="item-title">通知公告</div>
  112 + <div class="item-title">
  113 + <div class="left">通知公告</div>
  114 + <el-tooltip effect="dark" content="刷新" placement="top">
  115 + <el-link
  116 + icon="icon-ym icon-ym-Refresh NCC-common-head-icon"
  117 + :underline="false"
  118 + @click="resetMsg()"
  119 + />
  120 + </el-tooltip>
  121 + </div>
109 122 <div class="item-body">
110 123 <template>
111   - <el-table :data="todoTableData" style="width: 100%" stripe>
  124 + <el-table :data="msgList" style="width: 100%" stripe>
112 125 <el-table-column
113 126 prop="teskName"
114 127 label="内容"
... ... @@ -137,33 +150,39 @@ import {
137 150 areaObj,
138 151 chObj,
139 152 } from "@/assets/mockdata/demodata.json";
140   -import { computed } from 'vue';
  153 +import { computed } from "vue";
141 154 export default {
142 155 name: "Overview",
143 156 data() {
144 157 return {
145 158 todoTableData: [],
  159 + msgList: [],
146 160 tipTableData: [],
147 161 aimList: [],
148   - }
  162 + };
149 163 },
150 164 created() {
151   - this.getTodoList();
  165 + this.getMsgList();
152 166 this.getTipList();
153 167 this.getAimList();
154 168 },
155 169 computed: {
156 170 isSHILevel() {
157 171 // 判断角色是否为‘市级办公室’
158   - return this.$store.state.user.userInfo.organizeId == '580547494862128389';
  172 + return this.$store.state.user.islader;
159 173 },
160 174 },
161 175 methods: {
162   - getTodoList() {
  176 + getMsgList() {
163 177 for (let index = 0; index < 10; index++) {
  178 + this.msgList.push(todoObj);
164 179 this.todoTableData.push(todoObj);
165 180 }
166 181 },
  182 + resetMsg() {
  183 + this.msgList = [];
  184 + this.getMsgList();
  185 + },
167 186 getTipList() {
168 187 for (let index = 0; index < 10; index++) {
169 188 this.tipTableData.push(tipObj);
... ... @@ -179,7 +198,6 @@ export default {
179 198 }
180 199 },
181 200 },
182   -
183 201 };
184 202 </script>
185 203 <style scoped lang="scss">
... ... @@ -190,12 +208,12 @@ export default {
190 208 background-color: rgba(244, 244, 245, 0.38);
191 209 margin-bottom: 15px;
192 210 &.todo {
193   - height: calc(50vh - 115px);
  211 + height: calc(100vh - 210px);
194 212 }
195   - &.earmarked {
  213 + //&.earmarked {
196 214 // height: calc(50vh - 115px);
197   - margin-bottom: 0;
198   - }
  215 + //margin-bottom: 0;
  216 + //}
199 217 // &.tip {
200 218 // height: calc(50vh - 60px);
201 219 // }
... ... @@ -204,10 +222,16 @@ export default {
204 222 margin-bottom: 0;
205 223 }
206 224 .item-title {
  225 + display: flex;
  226 + justify-content: space-between;
  227 + align-items: center;
207 228 color: rgba(255, 255, 255, 1);
208 229 font-size: 16px;
209 230 line-height: 23px;
210 231 padding: 10px;
  232 + .el-link.el-link--default {
  233 + color: #fff !important;
  234 + }
211 235 }
212 236 .item-body {
213 237 height: calc(100% - 68px);
... ...