c756b91b by 任超

chore:api文件夹整理

1 parent c385040e
1 import request from '@/utils/request' 1 import request from '@/utils/request'
2 import SERVER from './config' 2 import SERVER from './config'
3 3
4 class business { 4 class fjF100 {
5 // 宗海空间属性
6 async getZhK105ById (bsmSjsb) {
7 return request({
8 url: SERVER.SERVERAPI + '/rest/reg/ZhK105/detail',
9 method: 'get',
10 params: {
11 bsmSjsb: bsmSjsb
12 }
13 })
14 }
15 //用海状况
16 async getKtfZhYhzkById (bsmSjsb) {
17 return request({
18 url: SERVER.SERVERAPI + '/rest/reg/KtfZhYhzk/detail',
19 method: 'get',
20 params: {
21 bsmSjsb: bsmSjsb
22 }
23 })
24 }
25 // 宗海空间属性-修改
26 async updateZhK105 (data) {
27 return request({
28 url: SERVER.SERVERAPI + '/rest/reg/ZhK105/edit',
29 method: 'post',
30 data
31 })
32 }
33 //修改用海状况
34 async updateKtfZhYhzk (data) {
35 return request({
36 url: SERVER.SERVERAPI + '/rest/reg/KtfZhYhzk/edit',
37 method: 'post',
38 data
39 })
40 }
41 // 非结构化文档 5 // 非结构化文档
42 async getFjF100ById (bsmSjsb) { 6 async getFjF100ById (bsmSjsb) {
43 return request({ 7 return request({
...@@ -57,7 +21,5 @@ class business { ...@@ -57,7 +21,5 @@ class business {
57 data 21 data
58 }) 22 })
59 } 23 }
60
61
62 } 24 }
63 export default new business() 25 export default new fjF100()
...\ No newline at end of file ...\ No newline at end of file
......
1 import request from '@/utils/request'
2 import SERVER from './config'
3
4 class ktfZhYhzk {
5 //用海状况
6 async getKtfZhYhzkById (bsmSjsb) {
7 return request({
8 url: SERVER.SERVERAPI + '/rest/reg/KtfZhYhzk/detail',
9 method: 'get',
10 params: {
11 bsmSjsb: bsmSjsb
12 }
13 })
14 }
15 //修改用海状况
16 async updateKtfZhYhzk (data) {
17 return request({
18 url: SERVER.SERVERAPI + '/rest/reg/KtfZhYhzk/edit',
19 method: 'post',
20 data
21 })
22 }
23 }
24 export default new ktfZhYhzk()
...\ No newline at end of file ...\ No newline at end of file
1 import request from '@/utils/request'
2 import SERVER from './config'
3
4 class zhK105 {
5 // 宗海空间属性
6 async getZhK105ById (bsmSjsb) {
7 return request({
8 url: SERVER.SERVERAPI + '/rest/reg/ZhK105/detail',
9 method: 'get',
10 params: {
11 bsmSjsb: bsmSjsb
12 }
13 })
14 }
15
16 // 宗海空间属性-修改
17 async updateZhK105 (data) {
18 return request({
19 url: SERVER.SERVERAPI + '/rest/reg/ZhK105/edit',
20 method: 'post',
21 data
22 })
23 }
24
25 }
26 export default new zhK105()
...@@ -38,7 +38,7 @@ ...@@ -38,7 +38,7 @@
38 </template> 38 </template>
39 <script> 39 <script>
40 // 非结构化文档 40 // 非结构化文档
41 import business from '@/api/business' 41 import fjF100 from '@/api/fjF100'
42 import ruleMixin from '@/mixins/ruleMixin.js' 42 import ruleMixin from '@/mixins/ruleMixin.js'
43 export default { 43 export default {
44 mixins: [ruleMixin], 44 mixins: [ruleMixin],
...@@ -64,7 +64,7 @@ export default { ...@@ -64,7 +64,7 @@ export default {
64 methods: { 64 methods: {
65 async featchData () { 65 async featchData () {
66 try { 66 try {
67 let { result: res } = await business.getFjF100ById(this.bsmSjsb) 67 let { result: res } = await fjF100.getFjF100ById(this.bsmSjsb)
68 this.ruleForm = res 68 this.ruleForm = res
69 //this.featchRule() 69 //this.featchRule()
70 } catch (error) { 70 } catch (error) {
...@@ -74,7 +74,7 @@ export default { ...@@ -74,7 +74,7 @@ export default {
74 handleUpdateForm () { 74 handleUpdateForm () {
75 return new Promise(async (resolve) => { 75 return new Promise(async (resolve) => {
76 try { 76 try {
77 let res = await business.updateFjF100(this.ruleForm) 77 let res = await fjF100.updateFjF100(this.ruleForm)
78 // this.$refs['formList'].resetFields(); 78 // this.$refs['formList'].resetFields();
79 resolve(res.code) 79 resolve(res.code)
80 } catch (error) { 80 } catch (error) {
......
...@@ -31,8 +31,9 @@ ...@@ -31,8 +31,9 @@
31 用海面积: <br /> 31 用海面积: <br />
32 <p class="label-detail">(YHMJ)</p> 32 <p class="label-detail">(YHMJ)</p>
33 </span> 33 </span>
34 <el-input-number controls-position="right" :disabled="$store.state.business.Edit" v-model.number="ruleForm.YHMJ" type="number" 34 <el-input-number controls-position="right" :disabled="$store.state.business.Edit"
35 v-only-number="{ max: 999999, min: 1, precision: 2 }" placeholder="用海面积"></el-input-number> 35 v-model.number="ruleForm.YHMJ" type="number" v-only-number="{ max: 999999, min: 1, precision: 2 }"
36 placeholder="用海面积"></el-input-number>
36 </el-form-item> 37 </el-form-item>
37 </el-col> 38 </el-col>
38 </el-row> 39 </el-row>
...@@ -54,8 +55,9 @@ ...@@ -54,8 +55,9 @@
54 使用金额数: <br /> 55 使用金额数: <br />
55 <p class="label-detail">(SYJES)</p> 56 <p class="label-detail">(SYJES)</p>
56 </span> 57 </span>
57 <el-input-number controls-position="right" :disabled="$store.state.business.Edit" v-model.number="ruleForm.SYJES" type="number" 58 <el-input-number controls-position="right" :disabled="$store.state.business.Edit"
58 v-only-number="{ max: 999999, min: 0, precision: 2 }" placeholder="使用金额数"></el-input-number> 59 v-model.number="ruleForm.SYJES" type="number" v-only-number="{ max: 999999, min: 0, precision: 2 }"
60 placeholder="使用金额数"></el-input-number>
59 </el-form-item> 61 </el-form-item>
60 </el-col> 62 </el-col>
61 63
...@@ -75,7 +77,7 @@ ...@@ -75,7 +77,7 @@
75 </template> 77 </template>
76 <script> 78 <script>
77 // 用海状况 79 // 用海状况
78 import business from '@/api/business' 80 import ktfZhYhzk from '@/api/ktfZhYhzk'
79 import ruleMixin from '@/mixins/ruleMixin.js' 81 import ruleMixin from '@/mixins/ruleMixin.js'
80 export default { 82 export default {
81 mixins: [ruleMixin], 83 mixins: [ruleMixin],
...@@ -104,7 +106,7 @@ export default { ...@@ -104,7 +106,7 @@ export default {
104 methods: { 106 methods: {
105 async featchData () { 107 async featchData () {
106 try { 108 try {
107 let { result: res } = await business.getKtfZhYhzkById(this.bsmSjsb) 109 let { result: res } = await ktfZhYhzk.getKtfZhYhzkById(this.bsmSjsb)
108 this.ruleForm = res 110 this.ruleForm = res
109 //this.featchRule() 111 //this.featchRule()
110 } catch (error) { 112 } catch (error) {
...@@ -114,7 +116,7 @@ export default { ...@@ -114,7 +116,7 @@ export default {
114 handleUpdateForm () { 116 handleUpdateForm () {
115 return new Promise(async (resolve) => { 117 return new Promise(async (resolve) => {
116 try { 118 try {
117 let res = await business.updateKtfZhYhzk(this.ruleForm) 119 let res = await ktfZhYhzk.updateKtfZhYhzk(this.ruleForm)
118 // this.$refs['formList'].resetFields(); 120 // this.$refs['formList'].resetFields();
119 resolve(res.code) 121 resolve(res.code)
120 } catch (error) { 122 } catch (error) {
......
...@@ -71,7 +71,7 @@ ...@@ -71,7 +71,7 @@
71 </div> 71 </div>
72 </template> 72 </template>
73 <script> 73 <script>
74 import business from '@/api/business' 74 import zhK105 from '@/api/zhK105'
75 import ruleMixin from '@/mixins/ruleMixin.js' 75 import ruleMixin from '@/mixins/ruleMixin.js'
76 // 宗海变化情况 76 // 宗海变化情况
77 export default { 77 export default {
...@@ -101,7 +101,7 @@ export default { ...@@ -101,7 +101,7 @@ export default {
101 methods: { 101 methods: {
102 async featchData () { 102 async featchData () {
103 try { 103 try {
104 let { result: res } = await business.getZhK105ById(this.bsmSjsb) 104 let { result: res } = await zhK105.getZhK105ById(this.bsmSjsb)
105 this.ruleForm = res 105 this.ruleForm = res
106 //this.featchRule() 106 //this.featchRule()
107 } catch (error) { 107 } catch (error) {
...@@ -111,7 +111,7 @@ export default { ...@@ -111,7 +111,7 @@ export default {
111 handleUpdateForm () { 111 handleUpdateForm () {
112 return new Promise(async (resolve) => { 112 return new Promise(async (resolve) => {
113 try { 113 try {
114 let res = await business.updateZhK105(this.ruleForm) 114 let res = await zhK105.updateZhK105(this.ruleForm)
115 // this.$refs['formList'].resetFields(); 115 // this.$refs['formList'].resetFields();
116 resolve(res.code) 116 resolve(res.code)
117 } catch (error) { 117 } catch (error) {
......
...@@ -61,7 +61,7 @@ ...@@ -61,7 +61,7 @@
61 </template> 61 </template>
62 <script> 62 <script>
63 // 宗海空间属性 63 // 宗海空间属性
64 import business from '@/api/business' 64 import zhK105 from '@/api/zhK105'
65 import ruleMixin from '@/mixins/ruleMixin.js' 65 import ruleMixin from '@/mixins/ruleMixin.js'
66 export default { 66 export default {
67 mixins: [ruleMixin], 67 mixins: [ruleMixin],
...@@ -90,7 +90,7 @@ export default { ...@@ -90,7 +90,7 @@ export default {
90 methods: { 90 methods: {
91 async featchData () { 91 async featchData () {
92 try { 92 try {
93 let { result: res } = await business.getZhK105ById(this.bsmSjsb) 93 let { result: res } = await zhK105.getZhK105ById(this.bsmSjsb)
94 this.ruleForm = res 94 this.ruleForm = res
95 //this.featchRule() 95 //this.featchRule()
96 } catch (error) { 96 } catch (error) {
...@@ -100,7 +100,7 @@ export default { ...@@ -100,7 +100,7 @@ export default {
100 handleUpdateForm () { 100 handleUpdateForm () {
101 return new Promise(async (resolve) => { 101 return new Promise(async (resolve) => {
102 try { 102 try {
103 let res = await business.updateZhK105(this.ruleForm) 103 let res = await zhK105.updateZhK105(this.ruleForm)
104 // this.$refs['formList'].resetFields(); 104 // this.$refs['formList'].resetFields();
105 resolve(res.code) 105 resolve(res.code)
106 } catch (error) { 106 } catch (error) {
......
...@@ -109,7 +109,7 @@ export default { ...@@ -109,7 +109,7 @@ export default {
109 visualMap: { 109 visualMap: {
110 min: 0, 110 min: 0,
111 max: _this.max, 111 max: _this.max,
112 bottom: '20%', 112 bottom: '13%',
113 left: 50, 113 left: 50,
114 splitNumber: 6, 114 splitNumber: 6,
115 seriesIndex: [0], 115 seriesIndex: [0],
......