Skip to content
项目
群组
代码片段
帮助
正在加载...
帮助
提交反馈
为 GitLab 提交贡献
登录
切换导航
P
pica.cloud.web-education-admin
项目
项目
详情
动态
版本
周期分析
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
统计图
成员
成员
收起侧边栏
Close sidebar
动态
分支图
统计图
提交
打开侧边栏
com.pica.cloud.education.frontend
pica.cloud.web-education-admin
提交
bdb39f4b
提交
bdb39f4b
编写于
6月 20, 2020
作者:
kai.wang
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
修改逻辑
上级
2d52f18a
变更
3
隐藏空白字符变更
内嵌
并排
正在显示
3 个修改的文件
包含
47 行增加
和
42 行删除
+47
-42
baseinfo.vue
src/components/yqrange/baseinfo.vue
+8
-9
organzation.vue
src/components/yqrange/organzation.vue
+13
-11
create-range.vue
src/views/yqrange/create-range.vue
+26
-22
未找到文件。
src/components/yqrange/baseinfo.vue
浏览文件 @
bdb39f4b
...
...
@@ -18,9 +18,9 @@
<i
class=
"el-icon-delete"
></i>
</div>
<div
class=
"limit-text"
>
<p>
尺寸:48*48
</p>
<p>
限制大小: 500kb
</p>
<p>
支持.jpg,.png格式
</p>
<p></p>
<p>
分辨率160*160
</p>
<p>
支持.jp
e
g,.png格式
</p>
</div>
</el-upload>
</el-form-item>
...
...
@@ -128,7 +128,6 @@
if (!this.formData.headUrl){
this.uploadImgMessage1 = true;
}
debugger
this.$refs[formName].validate(valid => {
if (valid&&this.formData.headUrl!="") {
flag = true;
...
...
@@ -173,10 +172,10 @@
image.src = theFile.target.result;
image.onload = function () {
let _this = this;
if (_this.width != fileLimit.width || _this.height != fileLimit.height) {
// if (false) {
vm.$message.error("
图片尺寸不符合规范,请根据规范上传图片
");
} else {
//
if (_this.width != fileLimit.width || _this.height != fileLimit.height) {
//
// if (false) {
//
vm.$message.error("
图片尺寸不符合规范,请根据规范上传图片
");
//
} else {
openLoading(vm);
doUpload(vm, file, getFilePath(file, null), "
preview4
", "
progress1
", 1).then(function (path) {
closeLoading(vm);
...
...
@@ -194,7 +193,7 @@
};
vm.$message.success("
上传成功
");
});
}
//
}
};
};
return isJPG && isLt2M;
...
...
src/components/yqrange/organzation.vue
浏览文件 @
bdb39f4b
<
template
>
<el-tabs
v-model=
"activeName"
>
<el-form
:inline=
"true"
:model=
"formOrganization"
class=
"demo-form-inline"
>
<el-form
:inline=
"true"
:model=
"formOrganization"
class=
"demo-form-inline"
>
<el-form-item
label
>
<el-cascader
size=
"small"
ref=
"cascaderRegion"
:options=
"optionsRegion"
:props=
"props"
v-model=
"formOrganization.administrativeIdList"
@
change=
"handleChangeRegion"
filterable
change-on-select
...
...
@@ -46,7 +46,7 @@
</el-tabs>
</
template
>
<
script
>
import
{
openLoading
,
closeLoading
}
from
"../../utils/utils"
;
import
{
openLoading
,
closeLoading
}
from
"../../utils/utils"
;
import
{
doUpload
,
getFilePath
}
from
"../../utils/qiniu-util"
;
import
*
as
operationData
from
"../../utils/operation"
;
import
{
getCircleProvincesReq
,
getMemberSelectOrgReq
,
getMemberSelectOrgOptionReq
}
from
'@/utils/yqrange/rangeApi'
;
...
...
@@ -54,7 +54,7 @@
export
default
{
name
:
"organzation"
,
props
:
{
form
d
ata
:
{
form
D
ata
:
{
type
:
Object
,
default
:
()
=>
{
return
{}
...
...
@@ -102,6 +102,7 @@
currentOrganization
:
1
,
totalOrganization
:
10
,
pageSizeOrganization
:
2
,
activeName
:
""
,
formOrganization
:
{
name
:
""
,
administrativeId
:
"0"
,
...
...
@@ -113,19 +114,22 @@
},
}
},
crea
ted
()
{
vm
=
this
;
//
debugger
const
{
enterType
,
id
}
=
this
.
$route
.
query
;
this
.
circleId
=
id
;
moun
ted
()
{
debugger
//
const { enterType, id } = this.$route.query;
this
.
circleId
=
vm
.
formData
.
id
;
this
.
initRange
();
//Idtype:1,内部 2.外部
vm
.
idType
=
localStorage
.
getItem
(
"storageIdType"
);
console
.
log
(
"this.idType:"
+
vm
.
idType
);
},
created
()
{
vm
=
this
;
},
methods
:
{
initRange
()
{
let
circleId
=
this
.
circleI
d
;
let
circleId
=
this
.
formData
.
i
d
;
this
.
getRegionOption
();
this
.
listLevels
();
this
.
getOrganization
();
...
...
@@ -200,7 +204,6 @@
},
//机构table中勾选一排
selectAllOrganization
(
selection
)
{
debugger
let
setList
=
[];
let
selectList
=
[];
for
(
let
i
=
0
;
i
<
vm
.
tableOrganization
.
length
;
i
++
)
{
...
...
@@ -213,7 +216,6 @@
}
let
intersect
=
operationData
.
getIntersect
(
setList
,
selectList
);
let
typeStatus
=
0
;
debugger
if
(
intersect
.
length
>
0
)
{
typeStatus
=
1
;
}
...
...
src/views/yqrange/create-range.vue
浏览文件 @
bdb39f4b
...
...
@@ -18,11 +18,11 @@
</el-row>
<div
class=
"first-step"
v-if=
"active === 0"
>
<p
class=
"p-title"
>
基础信息
</p>
<base-info
:formData=
"formData"
@
returnTypeData=
"returnTypeData"
@
returnIsNext=
"returnIsNext"
ref=
'child'
>
<base-info
:formData=
"formData"
@
returnTypeData=
"returnTypeData"
@
returnIsNext=
"returnIsNext"
ref=
"child"
>
</base-info>
</div>
<div
class=
"second-step"
v-else-if=
"active === 1"
>
<organzation></organzation>
<organzation
:formData=
"formData"
></organzation>
</div>
</div>
</div>
...
...
@@ -33,7 +33,7 @@
import
{
openLoading
,
closeLoading
}
from
"../../utils/utils"
;
import
BaseInfo
from
'@/components/yqrange/baseinfo.vue'
;
import
Organzation
from
'@/components/yqrange/organzation.vue'
;
import
{
getCircleInfoReq
,
getMemberSelectOrgSaveReq
}
from
'@/utils/yqrange/rangeApi'
;
import
{
getCircleInfoReq
,
getMemberSelectOrgSaveReq
}
from
'@/utils/yqrange/rangeApi'
;
export
default
{
name
:
"create-range"
,
components
:
{
...
...
@@ -51,14 +51,14 @@
//页面展示位置
stepData
:
[
true
,
false
],
formData
:
{
id
:
null
,
id
:
null
,
name
:
''
,
headUrl
:
''
,
imgUrl1More
:
{},
imgUrl2More
:
{},
introduce
:
''
,
dynamicFlag
:
''
,
idType
:
localStorage
.
getItem
(
"storageIdType"
)
idType
:
localStorage
.
getItem
(
"storageIdType"
)
}
}
},
...
...
@@ -69,7 +69,7 @@
const
{
enterType
,
id
}
=
this
.
$route
.
query
;
this
.
id
=
id
;
this
.
enterType
=
enterType
;
//edit
if
(
this
.
enterType
==
2
&&
this
.
id
!=
null
)
{
this
.
getCircleInfo
();
...
...
@@ -82,7 +82,7 @@
// debugger
this
.
$refs
.
child
.
submitForm
();
},
//完成
complete
()
{
console
.
log
(
this
.
formData
.
id
);
...
...
@@ -94,10 +94,10 @@
closeLoading
(
vm
);
if
(
res
.
code
==
"000000"
)
{
this
.
$message
.
success
(
'操作成功'
);
const
_this
=
this
;
setTimeout
(
function
()
{
_this
.
$router
.
go
(
-
1
)
},
2000
);
const
_this
=
this
;
setTimeout
(
function
()
{
_this
.
$router
.
go
(
-
1
)
},
2000
);
// vm.$router.push({ path: "yq-range" });
}
else
{
this
.
$message
(
res
.
message
);
...
...
@@ -105,23 +105,23 @@
}).
catch
(
err
=>
{
this
.
$message
.
error
(
'请求失败'
);
});
},
returnIsNext
(
flag
){
debugger
if
(
flag
==
true
)
{
},
// 修改编辑基础信息
returnIsNext
(
flag
)
{
if
(
flag
==
true
)
{
this
.
commitQuanziInfo
();
}
},
}
},
returnTypeData
(
item
)
{
this
.
formData
[
item
.
name
]
=
item
.
val
},
//获取圈子详情
getCircleInfo
()
{
//获取圈子详情
getCircleInfo
()
{
getCircleInfoReq
(
this
.
id
).
then
(
res
=>
{
// closeLoading(this);
if
(
res
.
code
==
"000000"
)
{
this
.
formData
=
{
...
this
.
formData
,
...
res
.
data
};
this
.
formData
=
{
...
this
.
formData
,
...
res
.
data
};
}
else
{
this
.
$message
(
res
.
message
);
}
...
...
@@ -136,8 +136,12 @@
vm
.
POST
(
"circle/circle/save"
,
req
).
then
(
res
=>
{
if
(
res
.
code
==
"000000"
)
{
// console.log(res);
this
.
active
=
1
console
.
log
(
this
.
$refs
);
vm
.
formData
.
id
=
res
.
data
;
this
.
active
=
1
;
this
.
stepData
=
[
false
,
true
];
}
else
{
//
}
...
...
写
预览
Markdown
格式
0%
请重试
or
附加一个文件
附加文件
取消
您添加了
0
人
到此讨论。请谨慎行事。
先完成此消息的编辑!
取消
想要评论请
注册
或
登录