Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
G
gdtel-gztel-school-center-ui
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
吴学德
gdtel-gztel-school-center-ui
Commits
5f234d6e
Commit
5f234d6e
authored
May 29, 2021
by
陈浩建
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
分销员(未完成,暂隐藏)
parent
3a1996a4
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
97 additions
and
44 deletions
+97
-44
src/views/school-center/userManager/PartnerManagement.vue
+96
-43
src/views/user/Login.vue
+1
-1
No files found.
src/views/school-center/userManager/PartnerManagement.vue
View file @
5f234d6e
...
@@ -99,8 +99,11 @@
...
@@ -99,8 +99,11 @@
<
template
slot=
"operation"
slot-scope=
"text,record"
>
<
template
slot=
"operation"
slot-scope=
"text,record"
>
<a
@
click=
"modifyfunction(record)"
>
编辑
</a>
<a
@
click=
"modifyfunction(record)"
>
编辑
</a>
<a-divider
type=
"vertical"
/>
<a-divider
type=
"vertical"
/>
<!--
<a
@
click=
"modifyfunction(record)"
>
分销员
</a>
-->
<a
@
click=
"modifyFXY(record)"
>
<!--
<a-divider
type=
"vertical"
/>
-->
<a-badge
:count=
"record.fxsCount"
type=
"info"
><span>
分销员
</span>
</a-badge>
</a>
<a-divider
type=
"vertical"
/>
<a-popconfirm
title=
"是否要删除此行?"
@
confirm=
"deleteUser(record.id)"
>
<a-popconfirm
title=
"是否要删除此行?"
@
confirm=
"deleteUser(record.id)"
>
<a>
删除
</a>
<a>
删除
</a>
</a-popconfirm>
</a-popconfirm>
...
@@ -193,7 +196,6 @@
...
@@ -193,7 +196,6 @@
</a-form-item>
</a-form-item>
</a-form>
</a-form>
</a-modal>
</a-modal>
<!--编辑----弹框-->
<!--编辑----弹框-->
<a-modal
:title=
"titleName"
:visible=
"modifyvisible"
@
ok=
"createfunctionOk"
@
cancel=
"createfunctionCancel"
html-type=
"submit"
width=
"720px"
>
<a-modal
:title=
"titleName"
:visible=
"modifyvisible"
@
ok=
"createfunctionOk"
@
cancel=
"createfunctionCancel"
html-type=
"submit"
width=
"720px"
>
<a-form
:form=
"Formtable"
>
<a-form
:form=
"Formtable"
>
...
@@ -273,7 +275,7 @@
...
@@ -273,7 +275,7 @@
<a-form-item
:labelCol=
"{span: 6}"
:style=
"leaderDisplay"
:wrapperCol=
"{span: 8, offset: 1}"
label=
"学子公司上级"
>
<a-form-item
:labelCol=
"{span: 6}"
:style=
"leaderDisplay"
:wrapperCol=
"{span: 8, offset: 1}"
label=
"学子公司上级"
>
<a-select
placeholder=
"请选择"
v-model=
"modifyForm.parentId"
>
<a-select
placeholder=
"请选择"
v-model=
"modifyForm.parentId"
>
<a-select-option
key=
""
>
请选择
</a-select-option>
<a-select-option
key=
""
>
请选择
</a-select-option>
<a-select-option
v-for=
"data in xzUserList"
:value=
"data.id"
>
<a-select-option
v-for=
"data in xzUserList"
:key=
"data.id"
:value=
"data.id"
>
{{ data.name}}
{{ data.name}}
</a-select-option>
</a-select-option>
</a-select>
</a-select>
...
@@ -290,12 +292,25 @@
...
@@ -290,12 +292,25 @@
</a-form-item>
</a-form-item>
</a-form>
</a-form>
</a-modal>
</a-modal>
<!--分销员----弹框-->
<a-modal
:title=
"titleName"
:visible=
"modifyvisibleFXY"
@
ok=
"createFXYOk"
@
cancel=
"createCancel"
html-type=
"submit"
width=
"720px"
>
<a-button
@
click=
"handleTabsAdd()"
style=
"margin-left: 8px"
icon=
"plus"
type=
"primary"
>
新增分销商
</a-button>
<a-button
@
click=
"handleTabRemove()"
style=
"margin-left: 8px"
icon=
"close"
type=
"primary"
>
删除当前分销商
</a-button>
<a-tabs
name=
"tab"
refs=
"tab"
>
<a-tab-pane
:key=
"item"
v-for=
"item in fxyList"
>
<span
slot=
"tab"
>
{{ modifyFormFXY.name+item }}
</span>
<div
id=
"qrcodeImg"
></div>
</a-tab-pane>
</a-tabs>
</a-modal>
</div>
</div>
</div>
</div>
</template>
</template>
<
script
>
<
script
>
import
STable
from
'@/components/table'
;
import
STable
from
'@/components/table'
import
QRCode
from
'qrcodejs2'
import
{
import
{
findByList
,
modify
,
getlistysm
,
getRoleList
,
findByList
,
modify
,
getlistysm
,
getRoleList
,
addPartner
,
getSubstList
,
getSchoolList
,
getXzUserList
,
addPartner
,
getSubstList
,
getSchoolList
,
getXzUserList
,
...
@@ -376,10 +391,14 @@
...
@@ -376,10 +391,14 @@
position
:
''
,
position
:
''
,
parentId
:
''
,
parentId
:
''
,
},
},
modifyvisibleFXY
:
false
,
FXYFormtable
:
this
.
$form
.
createForm
(
this
,
{
name
:
'FXYFormtable'
}),
modifyFormFXY
:{
modifyFormFXY
:{
id
:
""
,
id
:
""
,
name
:
""
,
fxs
:
""
,
fxs
:
""
,
},
},
fxyList
:[],
autoCompleteResult
:[],
autoCompleteResult
:[],
subNameList
:
[],
subNameList
:
[],
substList
:
[],
substList
:
[],
...
@@ -502,43 +521,6 @@
...
@@ -502,43 +521,6 @@
}
}
})
})
},
},
// 调整分销员
modifyFXY
(
data
)
{
this
.
modifyForm
.
id
=
data
.
id
this
.
titleName
=
"编辑"
this
.
modifyvisible
=
true
setTimeout
(()
=>
{
this
.
Formtable
.
setFieldsValue
({
phone
:
data
.
phone
,
schoolId
:
data
.
schoolId
,
name
:
data
.
name
,
account
:
data
.
account
,
idCard
:
data
.
idCard
,
sex
:
data
.
sex
,
grade
:
data
.
grade
,
ysm
:
data
.
ysm
,
})
if
(
data
.
schools
==
undefined
)
{
this
.
treeModelValue
=
[];
}
else
{
this
.
treeModelValue
=
data
.
schools
.
split
(
","
);
}
this
.
modifyForm
.
subName
=
data
.
substName
;
this
.
modifyForm
.
roleId
=
data
.
roleid
;
this
.
modifyForm
.
position
=
data
.
position
;
this
.
modifyForm
.
parentId
=
""
;
this
.
modifyForm
.
parentIds
=
""
;
this
.
recordId
=
data
.
parentId
;
this
.
changeSchool
(
data
.
schoolId
);
this
.
changePosition
(
2
);
this
.
$refs
.
tree2
.
setValue2
(
data
.
roleid
);
},
500
)
getlistysm
().
then
(
res
=>
{
if
(
res
.
state
==
"success"
)
{
this
.
autoCompleteResult
=
res
.
data
}
})
},
//提交表单
//提交表单
createfunctionOk
(){
createfunctionOk
(){
this
.
Formtable
.
validateFields
([
"account"
,
'phone'
,
'name'
,
"idCard"
,
'password'
,
'parentId'
,
'sex'
,
'schoolId'
,
'roleid'
,
'ysm'
],
{
force
:
true
},
(
err
,
values
)
=>
{
this
.
Formtable
.
validateFields
([
"account"
,
'phone'
,
'name'
,
"idCard"
,
'password'
,
'parentId'
,
'sex'
,
'schoolId'
,
'roleid'
,
'ysm'
],
{
force
:
true
},
(
err
,
values
)
=>
{
...
@@ -732,6 +714,31 @@
...
@@ -732,6 +714,31 @@
}
}
})
})
},
},
// TODO 调整分销员
modifyFXY
(
data
)
{
this
.
titleName
=
"分销员配置"
;
this
.
modifyFormFXY
.
id
=
data
.
id
;
this
.
modifyFormFXY
.
name
=
data
.
name
;
this
.
modifyFormFXY
.
fxs
=
data
.
fxs
this
.
fxyList
=
data
.
fxs
==
""
?[]:
data
.
fxs
.
split
(
","
);
this
.
modifyvisibleFXY
=
true
;
},
handleTabsAdd
(){
this
.
fxyList
.
length
if
(
this
.
fxyList
.
length
>=
5
){
this
.
$message
.
info
(
"分销商不得超过5个"
,
2
);
return
;
}
this
.
fxyList
.
push
(
""
);
},
handleTabRemove
(){
debugger
this
.
$refs
.
tab
},
createFXYOk
(){
this
.
modifyvisibleFXY
=
false
;
},
createCancel
(){
createCancel
(){
this
.
addUser
=
false
;
this
.
addUser
=
false
;
this
.
addFormtable
.
setFieldsValue
({
this
.
addFormtable
.
setFieldsValue
({
...
@@ -751,6 +758,11 @@
...
@@ -751,6 +758,11 @@
this
.
addForm
.
subName
=
''
;
this
.
addForm
.
subName
=
''
;
this
.
addForm
.
position
=
''
;
this
.
addForm
.
position
=
''
;
this
.
addForm
.
parentIds
=
''
;
this
.
addForm
.
parentIds
=
''
;
this
.
titleName
=
''
;
this
.
modifyvisibleFXY
=
false
;
this
.
modifyFormFXY
.
id
=
""
;
this
.
modifyFormFXY
.
name
=
""
;
this
.
modifyFormFXY
.
fxs
=
""
;
},
},
contentSelectCheck1
(
data
){
contentSelectCheck1
(
data
){
let
list
=
data
.
list
;
let
list
=
data
.
list
;
...
@@ -975,7 +987,45 @@
...
@@ -975,7 +987,45 @@
}
}
}
}
})
})
},
/*
newImage : function() {
// 生成图片
var imageBox = document.getElementById("imageBox")
var canvas = document.getElementById("canvas")
var cxt = canvas.getContext("2d")
canvas.width = document.getElementById("imageBox").clientWidth;
canvas.height = document.getElementById("imageBox").clientHeight;
//背景图
var img = new Image()
img.src = require('../../../assets/picture/hhr/qrcode.png');
img.setAttribute("crossOrigin", 'Anonymous')
img.onload = () => {
// 图片加载完成,才可处理
// 画图(这里画布与图片等宽高)
cxt.drawImage(img, 0, 0, canvas.width, canvas.height);
cxt.drawImage(this.img2, canvas.width*0.23, canvas.height*0.64);
//绘制完成,转为图片
setTimeout(function() { //在ios上无法在画完之后取到整个画布内容,加了个settimeout
let images = new Image();
images.src = canvas.toDataURL("image/png");
images.setAttribute("crossOrigin", 'Anonymous')
$('.canimg').attr('src', canvas.toDataURL("image/png"))
this.showBox = false;
}, 0)
}
}
},
convertCanvasToImage: function () {
let qrcode = document.getElementsByTagName("canvas")[0];
let img2 = new Image();
img2.src = qrcode.toDataURL("image/png");
this.img2 = img2;
}
*/
},
},
mounted
()
{
mounted
()
{
this
.
initSubstName
();
this
.
initSubstName
();
...
@@ -985,5 +1035,8 @@
...
@@ -985,5 +1035,8 @@
</
script
>
</
script
>
<
style
scoped
>
<
style
scoped
>
.demo-badge-alone
{
background
:
#5cb85c
!important
;
size
:
10px
;
}
</
style
>
</
style
>
src/views/user/Login.vue
View file @
5f234d6e
...
@@ -129,7 +129,7 @@ export default {
...
@@ -129,7 +129,7 @@ export default {
flag
:
false
,
flag
:
false
,
LeakProofModel
:
true
,
LeakProofModel
:
true
,
commitment
:
false
,
commitment
:
false
,
countNum
:
5
,
countNum
:
0
,
single
:
false
,
single
:
false
,
buttondata
:
"登录"
,
buttondata
:
"登录"
,
customActiveKey
:
"tab1"
,
customActiveKey
:
"tab1"
,
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment