File tree Expand file tree Collapse file tree 1 file changed +50
-0
lines changed
src/Console/extend-stubs/src/Components Expand file tree Collapse file tree 1 file changed +50
-0
lines changed Original file line number Diff line number Diff line change
1
+ <template >
2
+ <div class =" form-page" >
3
+ <el-card shadow =" never" class =" form-card" >
4
+ <el-form :model =" formData" ref =" ruleForm" >
5
+ <div class =" form-bottom-actions" >
6
+ <div ></div >
7
+ <div >
8
+ <el-button
9
+ class =" submit-btn"
10
+ type =" primary"
11
+ @click =" submitForm('ruleForm')"
12
+ >{{ isEdit ? "立即修改" : "立即创建" }}
13
+ </el-button >
14
+ <el-button class =" submit-btn" @click =" $router.go(-1)"
15
+ >返回
16
+ </el-button
17
+ >
18
+ </div >
19
+ </div >
20
+ </el-form >
21
+ </el-card >
22
+ </div >
23
+ </template >
24
+ <script >
25
+ export default {
26
+ props: {
27
+ attrs: Object
28
+ },
29
+ data () {
30
+ return {
31
+ isEdit: false ,
32
+ formData: {}
33
+ };
34
+ },
35
+ methods: {
36
+ submitForm (formName ) {
37
+ this .$refs [formName].validate (valid => {
38
+ if (valid) {
39
+ } else {
40
+ return false ;
41
+ }
42
+ });
43
+ },
44
+ resetForm (formName ) {
45
+ this .$refs [formName].resetFields ();
46
+ }
47
+ }
48
+ };
49
+ </script >
50
+ <style lang="scss"></style >
You can’t perform that action at this time.
0 commit comments