Skip to content
Toggle navigation
Projects
Groups
Snippets
Help
glsx
/
gl_tape
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
0
Merge Requests
3
Pipelines
Wiki
Settings
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Commit 4bce0d03
authored
Oct 21, 2024
by
前端
Browse Files
Options
Browse Files
Tag
Download
Email Patches
Plain Diff
待提交
1 parent
ce0771ea
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
49 additions
and
93 deletions
.hbuilderx/launch.json
components/FinishStep.vue
components/HomeFrame/components/saveRecord.vue
mixin/click.js
utils/recordManager/interruptRecord.js
.hbuilderx/launch.json
View file @
4bce0d0
...
@@ -4,20 +4,24 @@
...
@@ -4,20 +4,24 @@
"version"
:
"0.0"
,
"version"
:
"0.0"
,
"configurations"
:
[
"configurations"
:
[
{
{
"app-plus"
:
{
"app-plus"
:
"launchtype"
:
"local"
{
},
"launchtype"
:
"local"
"default"
:
{
},
"launchtype"
:
"local"
"default"
:
},
{
"h5"
:
{
"launchtype"
:
"local"
"launchtype"
:
"local"
},
},
"h5"
:
"mp-weixin"
:
{
{
"launchtype"
:
"local"
"launchtype"
:
"local"
},
},
"provider"
:
"aliyun"
,
"mp-weixin"
:
"type"
:
"uniCloud"
{
"launchtype"
:
"local"
},
"provider"
:
"aliyun"
,
"type"
:
"uniCloud"
},
},
{
{
"playground"
:
"standard"
,
"playground"
:
"standard"
,
...
...
components/FinishStep.vue
View file @
4bce0d0
<
template
>
<
template
>
<view
class=
"step"
>
<view
class=
"step"
>
<MessageBox
<MessageBox
ref=
"formRef"
@
cancel=
"cancel"
@
confirm=
"submit"
:cancelBtnText=
"`$
{step == 1 ? '取消' : '上一步'}`" :confirmBtnText="`${sceneType == 0 ? (step == 1 ? '下一步' : '完成接待') : '完成接待'}`" :title="`${step == 1 ? '客户信息完善' : '结果反馈'}`" :popupW="820" :maxHeight="820" :isAutoClose="false">
ref=
"formRef"
@
cancel=
"cancel"
@
confirm=
"submit"
:cancelBtnText=
"`$
{step == 1? '取消' : '上一步'}`"
:confirmBtnText="`${sceneType == 0 ?step == 1? '下一步' : '完成接待': '完成接待'}`"
:title="`${step == 1? '客户信息完善' : '结果反馈'}`"
:popupW="820"
:maxHeight="820"
:isAutoClose="false"
>
<view
name=
"content"
>
<view
name=
"content"
>
<template
v-if=
"step == 1"
>
<template
v-if=
"step == 1"
>
<template
v-if=
"!check(true)"
>
<template
v-if=
"!check(true)"
>
<view
<view
class=
"error-tip"
v-if=
"errorTip"
>
以下信息不能为空,请完善信息后保存
</view>
class=
"error-tip"
<view
class=
"pop-tips"
v-else
>
{{
tips
}}
</view>
v-if=
"errorTip"
>
以下信息不能为空,请完善信息后保存
</view>
<view
class=
"pop-tips"
v-else
>
{{
tips
}}
</view>
</
template
>
</
template
>
<view
class=
"form"
>
<view
class=
"form"
>
<
template
v-for=
"(i, index) in formObject"
>
<
template
v-for=
"(i, index) in formObject"
>
<view
<view
class=
"form-item"
:key=
"index"
>
class=
"form-item"
<view
:class=
"['label',
{ required: i.required }]">
{{
i
.
label
}}
</view>
:key=
"index"
<view
:class=
"['value',
{ error: showError(i.key)
&&
i.required }, { disabled: customerType == 0 || i.disabled }]">
>
<view
:class=
"['label',
{required:i.required}]">
{{
i
.
label
}}
</view>
<view
:class=
"['value',
{ error: showError(i.key)
&&
i.required },{disabled:customerType == 0 || i.disabled}]">
<template
v-if=
"i.type == 'input'"
>
<template
v-if=
"i.type == 'input'"
>
<input
<input
:type=
"i.inputType"
:maxlength=
"i.maxlength"
v-model=
"formData[i.key]"
class=
"input"
:placeholder=
"i.placeholder"
:disabled=
"customerType == 0"
@
input=
"inputCustomer"
placeholder-style=
"color:#c9c9c9;"
/>
:type=
"i.inputType"
:maxlength=
"i.maxlength"
v-model=
"formData[i.key]"
class=
"input"
:placeholder=
"i.placeholder"
:disabled=
"customerType == 0"
@
input=
"inputCustomer"
placeholder-style=
"color:#c9c9c9;"
/>
</
template
>
</
template
>
<
template
v-else
>
<
template
v-else
>
<view
<view
:class=
"['select', `$
{formData[i.key] ? '' : 'placeholder'}`]" @click="showPopup(i)">
:class=
"['select', `$
{formData[i.key]? '' : 'placeholder'}`]"
@click="showPopup(i)"
>
{{
formData
[
i
.
key
]
||
i
.
placeholder
}}
{{
formData
[
i
.
key
]
||
i
.
placeholder
}}
<uni-icons
<uni-icons
class=
"arrow"
type=
"down"
:size=
"16"
></uni-icons>
class=
"arrow"
type=
"down"
:size=
"16"
></uni-icons>
</view>
</view>
</
template
>
</
template
>
</view>
</view>
...
@@ -64,42 +29,25 @@
...
@@ -64,42 +29,25 @@
<
template
v-else
>
<
template
v-else
>
<view
class=
"pop-tips"
>
请完善本次接待结果
</view>
<view
class=
"pop-tips"
>
请完善本次接待结果
</view>
<view
class=
"choose-box"
>
<view
class=
"choose-box"
>
<template
v-for=
"(i,index) in resultList"
>
<template
v-for=
"(i, index) in resultList"
>
<view
<view
:class=
"['choose-item', `$
{i.status == receptionStatus ? (i.status == 1 ? 'success' : 'error') : ''}`]" :key="index" @click="chooseResult(i.status)">
:class=
"['choose-item', `$
{i.status == receptionStatus ? i.status == 1 ? 'success' : 'error' : ''}`]"
<view
:class=
"['sprite-icon', `icon-face-$
{i.status == receptionStatus ? `${i.icon}-active` : i.icon}`]">
</view>
:key="index"
{{
i
.
text
}}
@click="chooseResult(i.status)"
>
<view
:class=
"['sprite-icon' , `icon-face-$
{i.status == receptionStatus ? `${i.icon}-active` : i.icon }`]">
</view>
{{
i
.
text
}}
</view>
</view>
</
template
>
</
template
>
</view>
</view>
</template>
</template>
</view>
</view>
</MessageBox>
</MessageBox>
<car-brands
<car-brands
ref=
"carBrandListVisible"
@
select=
"handleSelect($event, 'carBrandListVisible')"
/>
ref=
"carBrandListVisible"
<employee
ref=
"employeeBoxVisible"
@
select=
"handleSelect($event, 'employeeBoxVisible')"
/>
@
select=
"handleSelect($event,'carBrandListVisible')"
<uni-popup
ref=
"successRef"
type=
"message"
>
/>
<uni-popup-message
type=
"success"
message=
"数据保存成功"
:duration=
"1500"
></uni-popup-message>
<employee
ref=
"employeeBoxVisible"
@
select=
"handleSelect($event,'employeeBoxVisible')"
/>
<uni-popup
ref=
"successRef"
type=
"message"
>
<uni-popup-message
type=
"success"
message=
"数据保存成功"
:duration=
"1500"
></uni-popup-message>
</uni-popup>
</uni-popup>
</view>
</view>
</template>
</template>
<
script
type=
'text/ecmascript-6'
>
<
script
type=
"text/ecmascript-6"
>
import
Employee
from
'@/components/Employee.vue'
import
Employee
from
'@/components/Employee.vue'
import
CarBrands
from
'@/components/CarBrands.vue'
import
CarBrands
from
'@/components/CarBrands.vue'
import
{
mapMutations
}
from
"vuex"
;
import
{
mapMutations
}
from
"vuex"
;
...
@@ -305,7 +253,6 @@ export default {
...
@@ -305,7 +253,6 @@ export default {
},
},
success
(
receptionStatus
)
{
success
(
receptionStatus
)
{
this
.
$refs
.
successRef
.
open
();
this
.
$refs
.
successRef
.
open
();
this
.
setReceptionStatus
(
receptionStatus
);
this
.
$emit
(
'submit'
,
receptionStatus
)
this
.
$emit
(
'submit'
,
receptionStatus
)
},
},
inputCustomer
()
{
inputCustomer
()
{
...
@@ -346,12 +293,13 @@ export default {
...
@@ -346,12 +293,13 @@ export default {
},
},
chooseResult
(
val
)
{
chooseResult
(
val
)
{
this
.
receptionStatus
=
val
this
.
receptionStatus
=
val
this
.
setReceptionStatus
(
val
);
}
}
}
}
}
}
</
script
>
</
script
>
<
style
scoped
lang=
'scss'
>
<
style
scoped
lang=
"scss"
>
.pop-tips
{
.pop-tips
{
background
:
rgba
(
44
,
102
,
247
,
0.1
);
background
:
rgba
(
44
,
102
,
247
,
0.1
);
color
:
#2c66f7
;
color
:
#2c66f7
;
...
@@ -470,4 +418,4 @@ export default {
...
@@ -470,4 +418,4 @@ export default {
border-color
:
#f247241
a
;
border-color
:
#f247241
a
;
}
}
}
}
</
style
>
\ No newline at end of file
\ No newline at end of file
</
style
>
components/HomeFrame/components/saveRecord.vue
View file @
4bce0d0
...
@@ -115,7 +115,8 @@ export default {
...
@@ -115,7 +115,8 @@ export default {
},
},
mounted
()
{
mounted
()
{
this
.
customerInfo
=
utils
.
deepClone
(
this
.
customerInfoVal
)
this
.
customerInfo
=
utils
.
deepClone
(
this
.
customerInfoVal
)
const
i
=
this
.
receptionList
.
findIndex
(
e
=>
e
.
value
==
this
.
customerInfo
.
receptionStatus
)
console
.
log
(
this
.
customerInfo
)
const
i
=
this
.
receptionList
.
findIndex
(
e
=>
e
.
value
===
this
.
customerInfo
.
receptionStatus
)
this
.
$set
(
this
.
customerInfo
,
'receptionStatus'
,
i
==
-
1
?
''
:
this
.
receptionList
[
i
].
label
)
this
.
$set
(
this
.
customerInfo
,
'receptionStatus'
,
i
==
-
1
?
''
:
this
.
receptionList
[
i
].
label
)
},
},
methods
:
{
methods
:
{
...
...
mixin/click.js
View file @
4bce0d0
...
@@ -158,7 +158,8 @@ export default {
...
@@ -158,7 +158,8 @@ export default {
this
.
setAudioInfo
({
audioList
:
[],
audioStatus
:
'start'
})
this
.
setAudioInfo
({
audioList
:
[],
audioStatus
:
'start'
})
recorderManager
.
onStart
(()
=>
{
recorderManager
.
onStart
(()
=>
{
setTimeout
(()
=>
{
setTimeout
(()
=>
{
interruptRecord
.
addPreRecords
()
const
params
=
this
.
getParams
(
this
.
$store
.
state
.
user
.
customerInfo
,
this
.
booksList
,
this
.
receptionStatus
)
interruptRecord
.
addPreRecords
(
params
)
},
1000
)
},
1000
)
})
})
recorderManager
.
start
({
recorderManager
.
start
({
...
...
utils/recordManager/interruptRecord.js
View file @
4bce0d0
...
@@ -2,17 +2,19 @@
...
@@ -2,17 +2,19 @@
* @Author: 前端 qianduan01@didihu.com.cn
* @Author: 前端 qianduan01@didihu.com.cn
* @Date: 2024-10-14 17:38:35
* @Date: 2024-10-14 17:38:35
* @LastEditors: 前端 qianduan01@didihu.com.cn
* @LastEditors: 前端 qianduan01@didihu.com.cn
* @LastEditTime: 2024-10-18 1
6:46:07
* @LastEditTime: 2024-10-18 1
8:09:15
* @FilePath: \gl-tape\utils\recordManager\interruptRecord.js
* @FilePath: \gl-tape\utils\recordManager\interruptRecord.js
* @Description: 这是默认设置,请设置`customMade`, 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE
* @Description: 这是默认设置,请设置`customMade`, 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE
*/
*/
import
RecordManager
from
'../RecordManager.js'
import
RecordManager
from
'../RecordManager.js'
import
utils
from
'@/utils/utils.js'
import
utils
from
'@/utils/utils.js'
import
{
storageApi
}
from
'../cache'
import
{
storageApi
}
from
'../cache'
//
import store from '@/store'
import
store
from
'@/store'
class
InterruptRecord
extends
RecordManager
{
class
InterruptRecord
extends
RecordManager
{
constructor
()
{
constructor
()
{
super
()
super
()
const
records
=
this
.
getRecords
()
store
.
dispatch
(
'audio/setPerRecordNumber'
,
records
.
length
)
// console.log(store)
// console.log(store)
// storageApi.removeRecords('preRecordList')
// storageApi.removeRecords('preRecordList')
// storageApi.removeRecords('preRecordId')
// storageApi.removeRecords('preRecordId')
...
@@ -54,10 +56,9 @@ class InterruptRecord extends RecordManager {
...
@@ -54,10 +56,9 @@ class InterruptRecord extends RecordManager {
* @param {string} name - 录音文件目录名
* @param {string} name - 录音文件目录名
* @returns {void} - 此函数不返回任何值
* @returns {void} - 此函数不返回任何值
*/
*/
async
addPreRecords
()
{
async
addPreRecords
(
params
)
{
console
.
log
(
storageApi
.
getRecords
(
'preRecordId'
),
6666
)
console
.
log
(
storageApi
.
getRecords
(
'preRecordId'
),
6666
)
if
(
storageApi
.
getRecords
(
'preRecordId'
))
{
if
(
storageApi
.
getRecords
(
'preRecordId'
))
{
console
.
log
(
888
)
this
.
addPreAudio
()
this
.
addPreAudio
()
return
return
}
}
...
@@ -71,6 +72,7 @@ class InterruptRecord extends RecordManager {
...
@@ -71,6 +72,7 @@ class InterruptRecord extends RecordManager {
console
.
log
(
ids
,
'id'
)
console
.
log
(
ids
,
'id'
)
this
.
records
=
{
this
.
records
=
{
id
,
id
,
...
params
,
audioPath
:
[
audioPath
]
audioPath
:
[
audioPath
]
}
}
const
records
=
this
.
getRecords
()
||
[]
const
records
=
this
.
getRecords
()
||
[]
...
...
Write
Preview
Markdown
is supported
Attach a file
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 post a comment