Browse Source

平台-区域管理

gzb
wangzhonglu 9 months ago
parent
commit
53c0b85587

+ 12
- 2
src/views/platformSection/regionManage/adminManage.vue View File

28
           </div>
28
           </div>
29
           <DropdownMenu
29
           <DropdownMenu
30
             slot="list"
30
             slot="list"
31
-            style="width: 200px"
31
+            style="width: 150px"
32
             @mousedown.native.stop
32
             @mousedown.native.stop
33
             @click.native.stop
33
             @click.native.stop
34
           >
34
           >
38
             ></CustomTree>
38
             ></CustomTree>
39
           </DropdownMenu>
39
           </DropdownMenu>
40
         </Dropdown>
40
         </Dropdown>
41
+        <Select
42
+          v-model="searchForm.state"
43
+          @on-change="searchList()"
44
+          style="margin-right: 10px; width: 150px"
45
+        >
46
+          <Option :value="0">所有状态</Option>
47
+          <Option :value="1">启用</Option>
48
+          <Option :value="2">禁用</Option>
49
+        </Select>
41
         <Input
50
         <Input
42
           v-model="searchForm.name"
51
           v-model="searchForm.name"
43
           placeholder="请输入名称"
52
           placeholder="请输入名称"
180
         dropList: [],
189
         dropList: [],
181
         areaname: "",
190
         areaname: "",
182
         areaid: null,
191
         areaid: null,
192
+        state: 0,
183
         page: 1,
193
         page: 1,
184
         size: 10,
194
         size: 10,
185
         list: [],
195
         list: [],
429
     align-items: center;
439
     align-items: center;
430
     .search_drop {
440
     .search_drop {
431
       margin-right: 10px;
441
       margin-right: 10px;
432
-      width: 200px;
442
+      width: 150px;
433
     }
443
     }
434
   }
444
   }
435
 }
445
 }

+ 60
- 47
src/views/platformSection/regionManage/regionManage.vue View File

2
   <div class="main_root">
2
   <div class="main_root">
3
     <div class="search_header">
3
     <div class="search_header">
4
       <Input
4
       <Input
5
-        v-model="searchForm.name"
5
+        v-model="searchForm.regionName"
6
         placeholder="请输入区域名称"
6
         placeholder="请输入区域名称"
7
         search
7
         search
8
         @on-search="searchList()"
8
         @on-search="searchList()"
45
     <Modal
45
     <Modal
46
       class="modal1"
46
       class="modal1"
47
       :mask-closable="false"
47
       :mask-closable="false"
48
-      v-model="areaInfo.show"
49
-      :title="areaInfo.id ? '编辑' : '新建'"
48
+      v-model="regionInfo.show"
49
+      title="新建"
50
     >
50
     >
51
       <Form
51
       <Form
52
         ref="addForm"
52
         ref="addForm"
53
-        :model="areaInfo"
53
+        :model="regionInfo"
54
         :rules="rules"
54
         :rules="rules"
55
         :label-width="100"
55
         :label-width="100"
56
         inline
56
         inline
57
       >
57
       >
58
-        <FormItem label="区域名称" prop="areaname" style="width: 100%">
58
+        <FormItem label="区域名称" prop="regionName" style="width: 100%">
59
           <Input
59
           <Input
60
-            v-model="areaInfo.areaname"
60
+            v-model="regionInfo.regionName"
61
             placeholder="请输入区域名称"
61
             placeholder="请输入区域名称"
62
           ></Input>
62
           ></Input>
63
         </FormItem>
63
         </FormItem>
67
           style="width: calc(50% - 10px)"
67
           style="width: calc(50% - 10px)"
68
         >
68
         >
69
           <Input
69
           <Input
70
-            v-model="areaInfo.admin"
70
+            v-model="regionInfo.admin.aname"
71
             placeholder="请输入管理员名称"
71
             placeholder="请输入管理员名称"
72
           ></Input>
72
           ></Input>
73
         </FormItem>
73
         </FormItem>
77
           style="width: calc(50% - 10px)"
77
           style="width: calc(50% - 10px)"
78
         >
78
         >
79
           <Input
79
           <Input
80
-            v-model="areaInfo.loginname"
80
+            v-model="regionInfo.admin.loginname"
81
             placeholder="请输入登录账号"
81
             placeholder="请输入登录账号"
82
           ></Input>
82
           ></Input>
83
         </FormItem>
83
         </FormItem>
84
-        <FormItem label="密码" prop="pwd" style="width: calc(50% - 10px)">
85
-          <Input v-model="areaInfo.pwd" placeholder="请输入密码"></Input>
84
+        <FormItem label="密码" prop="loginpwd" style="width: calc(50% - 10px)">
85
+          <Input
86
+            v-model="regionInfo.admin.loginpwd"
87
+            placeholder="请输入密码"
88
+          ></Input>
86
         </FormItem>
89
         </FormItem>
87
-        <FormItem label="确认密码" prop="pwd1" style="width: calc(50% - 10px)">
88
-          <Input v-model="areaInfo.pwd1" placeholder="请输入确认密码"></Input>
90
+        <FormItem
91
+          label="确认密码"
92
+          prop="loginpwd1"
93
+          style="width: calc(50% - 10px)"
94
+        >
95
+          <Input
96
+            v-model="regionInfo.admin.loginpwd1"
97
+            placeholder="请输入确认密码"
98
+          ></Input>
89
         </FormItem>
99
         </FormItem>
90
         <FormItem label="手机号码" prop="phone" style="width: calc(50% - 10px)">
100
         <FormItem label="手机号码" prop="phone" style="width: calc(50% - 10px)">
91
-          <Input v-model="areaInfo.phone" placeholder="请输入手机号码"></Input>
101
+          <Input
102
+            v-model="regionInfo.admin.phone"
103
+            placeholder="请输入手机号码"
104
+          ></Input>
92
         </FormItem>
105
         </FormItem>
93
         <FormItem
106
         <FormItem
94
           label="短信验证码"
107
           label="短信验证码"
97
         >
110
         >
98
           <Input
111
           <Input
99
             style="width: calc(100% - 102px)"
112
             style="width: calc(100% - 102px)"
100
-            v-model="areaInfo.code"
113
+            v-model="regionInfo.msgcode"
101
             placeholder="请输入短信验证码"
114
             placeholder="请输入短信验证码"
102
           ></Input>
115
           ></Input>
103
           <div class="code_btn disabled">获取验证码</div>
116
           <div class="code_btn disabled">获取验证码</div>
104
         </FormItem>
117
         </FormItem>
105
       </Form>
118
       </Form>
106
       <div slot="footer">
119
       <div slot="footer">
107
-        <Button @click="areaInfo.show = false">取消</Button>
120
+        <Button @click="regionInfo.show = false">取消</Button>
108
         <Button @click="saveAddInfo()" type="primary">保存</Button>
121
         <Button @click="saveAddInfo()" type="primary">保存</Button>
109
       </div>
122
       </div>
110
     </Modal>
123
     </Modal>
135
     return {
148
     return {
136
       date_format,
149
       date_format,
137
       searchForm: {
150
       searchForm: {
138
-        name: "",
151
+        regionName: "",
139
         page: 1,
152
         page: 1,
140
         size: 10,
153
         size: 10,
141
         list: [],
154
         list: [],
142
         total: 0
155
         total: 0
143
       },
156
       },
144
-      // 新建/编辑
145
-      areaInfo: {
157
+      // 新建
158
+      regionInfo: {
146
         show: false,
159
         show: false,
147
-        id: null,
148
-        areaname: "",
149
-        admin: "",
150
-        loginname: "",
151
-        pwd: "",
152
-        pwd1: "",
153
-        phone: "",
154
-        code: ""
160
+        regionName: "",
161
+        admin: {
162
+          aname: "",
163
+          loginname: "",
164
+          loginpwd: "",
165
+          loginpwd1: "",
166
+          phone: ""
167
+        }
155
       },
168
       },
156
       // 查看
169
       // 查看
157
       viewInfo: {
170
       viewInfo: {
158
         show: false,
171
         show: false,
159
-        areaname: "",
172
+        regionName: "",
160
         list: [],
173
         list: [],
161
         columns: [
174
         columns: [
162
           {
175
           {
183
         ]
196
         ]
184
       },
197
       },
185
       rules: {
198
       rules: {
186
-        areaname: [
199
+        regionName: [
187
           {
200
           {
188
             required: true,
201
             required: true,
189
             message: "请输入区域名称",
202
             message: "请输入区域名称",
235
         },
248
         },
236
         {
249
         {
237
           title: "区域名称",
250
           title: "区域名称",
238
-          key: "areaname",
251
+          key: "regionName",
239
           align: "center"
252
           align: "center"
240
         },
253
         },
241
         {
254
         {
295
     getList() {
308
     getList() {
296
       this.searchForm.list = [
309
       this.searchForm.list = [
297
         {
310
         {
298
-          id: 1,
299
-          areaname: "区域一",
311
+          regionid: 1,
312
+          regionName: "区域一",
300
           createname: "区域一",
313
           createname: "区域一",
301
           createtime: 1710838418,
314
           createtime: 1710838418,
302
           updatename: "区域一",
315
           updatename: "区域一",
303
           updatetime: 1710838430
316
           updatetime: 1710838430
304
         },
317
         },
305
         {
318
         {
306
-          id: 2,
307
-          areaname: "区域二",
319
+          regionid: 2,
320
+          regionName: "区域二",
308
           createname: "区域一",
321
           createname: "区域一",
309
           createtime: 1710838418,
322
           createtime: 1710838418,
310
           updatename: "区域一",
323
           updatename: "区域一",
311
           updatetime: 1710838430
324
           updatetime: 1710838430
312
         },
325
         },
313
         {
326
         {
314
-          id: 3,
315
-          areaname: "区域三",
327
+          regionid: 3,
328
+          regionName: "区域三",
316
           createname: "区域一",
329
           createname: "区域一",
317
           createtime: 1710838418,
330
           createtime: 1710838418,
318
           updatename: "区域一",
331
           updatename: "区域一",
323
     },
336
     },
324
     // 新建
337
     // 新建
325
     toAdd() {
338
     toAdd() {
326
-      this.areaInfo.show = true;
327
-      this.areaInfo.areaname = "";
328
-      this.areaInfo.admin = "";
329
-      this.areaInfo.loginname = "";
330
-      this.areaInfo.pwd = "";
331
-      this.areaInfo.pwd1 = "";
332
-      this.areaInfo.phone = "";
333
-      this.areaInfo.code = "";
339
+      this.regionInfo.show = true;
340
+      this.regionInfo.regionName = "";
341
+      this.regionInfo.admin = "";
342
+      this.regionInfo.loginname = "";
343
+      this.regionInfo.pwd = "";
344
+      this.regionInfo.pwd1 = "";
345
+      this.regionInfo.phone = "";
346
+      this.regionInfo.code = "";
334
     },
347
     },
335
     // 保存新建
348
     // 保存新建
336
     saveAddInfo() {
349
     saveAddInfo() {
337
-      this.areaInfo.show = false;
350
+      this.regionInfo.show = false;
338
     },
351
     },
339
     // 进入
352
     // 进入
340
     toEnter() {
353
     toEnter() {
346
     // 查看
359
     // 查看
347
     toView() {
360
     toView() {
348
       this.viewInfo.show = true;
361
       this.viewInfo.show = true;
349
-      this.viewInfo.areaname = "河南星火燎原软件科技有限公司";
362
+      this.viewInfo.regionName = "河南星火燎原软件科技有限公司";
350
       this.viewInfo.list = [
363
       this.viewInfo.list = [
351
         {
364
         {
352
           admin: "周文彦",
365
           admin: "周文彦",
362
     },
375
     },
363
     // 编辑
376
     // 编辑
364
     toEdit(row) {
377
     toEdit(row) {
365
-      this.areaInfo.show = true;
366
-      this.areaInfo.id = row.id;
378
+      this.regionInfo.show = true;
379
+      this.regionInfo.regionid = row.regionid;
367
     },
380
     },
368
     // 删除
381
     // 删除
369
     toDel() {
382
     toDel() {

Loading…
Cancel
Save