From a67acbd55451349df089e4d9aa3cb748e225b05b Mon Sep 17 00:00:00 2001
From: wangting <675591594@qq.com>
Date: 星期一, 28 十月 2024 15:27:05 +0800
Subject: [PATCH] 密级管理,修改操作类型

---
 Source/plt-web/plt-web-ui/src/views/authority/secure/classification/index.vue |   22 +++++++++++++++-------
 Source/plt-web/plt-web-ui/src/views/systemModel/businessModel/index.vue       |   10 +++++-----
 Source/plt-web/plt-web-ui/src/api/authority/secure/classification.js          |   16 ++++++++++++++++
 Source/plt-web/plt-web-ui/src/views/systemModel/mangeModel/index.vue          |   12 ++++++------
 4 files changed, 42 insertions(+), 18 deletions(-)

diff --git a/Source/plt-web/plt-web-ui/src/api/authority/secure/classification.js b/Source/plt-web/plt-web-ui/src/api/authority/secure/classification.js
new file mode 100644
index 0000000..df84d01
--- /dev/null
+++ b/Source/plt-web/plt-web-ui/src/api/authority/secure/classification.js
@@ -0,0 +1,16 @@
+import request from '@/router/axios';
+
+export function getSecretGradeConfig(params) {
+  return request({
+    url: "/api/secretGradeController/getSecretGradeConfig",
+    method: "get",
+    params
+  });
+}
+export const saveSecretGrade = (params) => {
+  return request({
+    url: '/api/secretGradeController/saveSecretGrade',
+    method: 'post',
+    params: params
+  })
+}
diff --git a/Source/plt-web/plt-web-ui/src/views/authority/secure/classification/index.vue b/Source/plt-web/plt-web-ui/src/views/authority/secure/classification/index.vue
index d87b584..ddebd32 100644
--- a/Source/plt-web/plt-web-ui/src/views/authority/secure/classification/index.vue
+++ b/Source/plt-web/plt-web-ui/src/views/authority/secure/classification/index.vue
@@ -7,7 +7,7 @@
 </template>
 
 <script>
-import {deleteLog, getPeroid, savePeriod} from "@/api/system/log/logBasic";
+import {getSecretGradeConfig, saveSecretGrade} from "@/api/authority/secure/classification";
 
 export default {
   name: "index",
@@ -36,18 +36,26 @@
     }
   },
   created() {
-    this.getPeroid()
+    this.getSecretGradeConfig()
   },
   methods:{
-    getPeroid:function (){
-      getPeroid().then(res => {
-        //this.form=res.data.data;
+    getSecretGradeConfig:function (){
+      getSecretGradeConfig().then(res => {
+        if(res.data.obj.userSecuritySwith){
+          this.form.type=[0]
+        }
+        if(res.data.obj.ipSecuritySwith){
+          this.form.type.push(1)
+        }
       }).catch(error => {
       })
     },
     saveHandler:function (form,done){
-      debugger;
-      savePeriod({'type':this.form.type}).then(res => {
+      const params={
+        userSecuritySwith:this.form.type.includes(0),
+        ipSecuritySwith:this.form.type.includes(1)
+      }
+      saveSecretGrade(params).then(res => {
         if (res.data.success) {
           this.$message.success('淇濆瓨鎴愬姛')
         }
diff --git a/Source/plt-web/plt-web-ui/src/views/systemModel/businessModel/index.vue b/Source/plt-web/plt-web-ui/src/views/systemModel/businessModel/index.vue
index ef5069c..b04332e 100644
--- a/Source/plt-web/plt-web-ui/src/views/systemModel/businessModel/index.vue
+++ b/Source/plt-web/plt-web-ui/src/views/systemModel/businessModel/index.vue
@@ -139,7 +139,7 @@
       append-to-body="true"
       class="avue-dialog"
       title="鎿嶄綔鍒嗙被"
-      width="60%"
+      width="500px"
     >
       <avue-crud
         ref="methodsCrud"
@@ -148,11 +148,10 @@
         :table-loading="methodsLoading"
         @row-click="rowMethodsClickHandler"
         @selection-change="selectMethodsChange">
-
       </avue-crud>
       <span slot="footer" class="dialog-footer">
-         <el-button @click="methodsVisble = false">鍙� 娑�</el-button>
          <el-button type="primary" @click="methodsSaveClickHandler">淇� 瀛�</el-button>
+         <el-button @click="methodsVisble = false">鍙� 娑�</el-button>
         </span>
     </el-dialog>
     <!--瀵煎叆    -->
@@ -193,6 +192,7 @@
         addBtn: false,
         menu: false,
         height: 500,
+        header:false,
         column: [
           {
             label: '鎿嶄綔鍒嗙被',
@@ -408,10 +408,10 @@
     // 澧炲姞鎿嶄綔绫诲瀷
     addMethodsClickHandler() {
       this.methodsLoading = true;
-      getSysModelTreeMenuByPID({parentId: 'sysOptionNode'}).then(res => {
+      getSysModelTreeMenuByPID({parentId: 'operateNode'}).then(res => {
         if (res.data.code === 200 && res.data.data.length>0) {
           this.methodsVisble = true;
-          const data = res.data.data[0].children;
+          const data = res.data.data;
           this.methodsData = data;
           this.methodsLoading = false;
         }else {
diff --git a/Source/plt-web/plt-web-ui/src/views/systemModel/mangeModel/index.vue b/Source/plt-web/plt-web-ui/src/views/systemModel/mangeModel/index.vue
index 6a8f5e5..5f7d4ac 100644
--- a/Source/plt-web/plt-web-ui/src/views/systemModel/mangeModel/index.vue
+++ b/Source/plt-web/plt-web-ui/src/views/systemModel/mangeModel/index.vue
@@ -139,7 +139,7 @@
       append-to-body="true"
       class="avue-dialog"
       title="鎿嶄綔鍒嗙被"
-      width="60%"
+      width="500px"
     >
       <avue-crud
         ref="methodsCrud"
@@ -148,11 +148,10 @@
         :table-loading="methodsLoading"
         @row-click="rowMethodsClickHandler"
         @selection-change="selectMethodsChange">
-
       </avue-crud>
       <span slot="footer" class="dialog-footer">
-         <el-button @click="methodsVisble = false">鍙� 娑�</el-button>
          <el-button type="primary" @click="methodsSaveClickHandler">淇� 瀛�</el-button>
+         <el-button @click="methodsVisble = false">鍙� 娑�</el-button>
         </span>
     </el-dialog>
     <!--瀵煎叆    -->
@@ -193,6 +192,7 @@
         addBtn: false,
         menu: false,
         height: 500,
+        header:false,
         column: [
           {
             label: '鎿嶄綔鍒嗙被',
@@ -411,10 +411,10 @@
     // 澧炲姞鎿嶄綔绫诲瀷
     addMethodsClickHandler() {
       this.methodsLoading = true;
-      getSysModelTreeMenuByPID({parentId: 'sysOptionNode'}).then(res => {
+      getSysModelTreeMenuByPID({parentId: 'operateNode'}).then(res => {
         if (res.data.code === 200 && res.data.data.length>0) {
           this.methodsVisble = true;
-          const data = res.data.data[0].children;
+          const data = res.data.data;
           this.methodsData = data;
           this.methodsLoading = false;
         }else {
@@ -441,7 +441,7 @@
           this.methodsVisble = false;
           this.$message.success(res.data.msg);
           this.form.childType = null;
-          this.refresh = Math.random(); // 鍒锋柊宸︿晶鏍�
+          this.handleRefreshTree('add')
         }
       })
     },

--
Gitblit v1.9.3