Browse Source

Merge branch 'dev' of http://git.2weisou.com/liumin/NewZkgj into dev

dev
douzhuo 2 years ago
parent
commit
7fce743b77
3 changed files with 89 additions and 64 deletions
  1. +57
    -49
      pages/mine/details2.vue
  2. +2
    -4
      pages/mine/registerCode.vue
  3. +30
    -11
      pages/mine/registerForm.vue

+ 57
- 49
pages/mine/details2.vue View File

@@ -1544,54 +1544,61 @@
});
},
//确认加入常错词
Confirmtheexit() {
let reg = /^[0-9]+$/
if (reg.test(this.thewrongword)) {
this.$refs.uToast.show({
title: '错误词不能为纯数字',
type: 'warning',
})
} else {
if (this.thewrongword) {
if (this.reswrongword) {
let parames = {
customerId: this.customerId,
cupid: this.luyinList[this.csdFileindex].id,
wrongWord: this.thewrongword, //错误词
correctWord: this.reswrongword, //正确词
translateHtmlContent: this.messagelisy,
}
this.isshow2 = false;
let sas = this.textItself.replace(this.thewrongword, this.reswrongword)
this.dialogList[this.argtextindex1].message[this.argtextindex2].onebest = sas
this.dialogList.forEach(res => {
res.message.forEach(asd => {
asd.isshow = false;
})
})
this.$u.post("/corpus/addCorrectWord", parames).then(data => {
this.thewrongword = "";
this.reswrongword = "";
})
} else {
uni.showToast({
title: '正确值不能为空',
duration: 2000
});
return
}
} else {
uni.showToast({
title: '错误词不能为空',
duration: 2000
});
return
}
}
Confirmtheexit() {
if(this.reswrongword.length>8 || this.thewrongword.length>8){
this.$refs.uToast.show({
title: '正确词错误词不能超过8个字',
type: 'warning',
})
}else{
let reg = /^[0-9]+$/
if (reg.test(this.thewrongword)) {
this.$refs.uToast.show({
title: '错误词不能为纯数字',
type: 'warning',
})
} else {
if (this.thewrongword) {
if (this.reswrongword) {
let parames = {
customerId: this.customerId,
cupid: this.luyinList[this.csdFileindex].id,
wrongWord: this.thewrongword, //错误词
correctWord: this.reswrongword, //正确词
translateHtmlContent: this.messagelisy,
}
this.isshow2 = false;
let sas = this.textItself.replace(this.thewrongword, this.reswrongword)
this.dialogList[this.argtextindex1].message[this.argtextindex2].onebest = sas
this.dialogList.forEach(res => {
res.message.forEach(asd => {
asd.isshow = false;
})
})
this.$u.post("/corpus/addCorrectWord", parames).then(data => {
this.thewrongword = "";
this.reswrongword = "";
})
} else {
uni.showToast({
title: '正确值不能为空',
duration: 2000
});
return
}
} else {
uni.showToast({
title: '错误词不能为空',
duration: 2000
});
return
}
}
}
},
//取消加入常错词
Cancelout() {
@@ -1603,7 +1610,8 @@
})
},
//加入长错词
Oftenthewrongword() {
Oftenthewrongword() {
this.isNum = false;
this.reswrongword = "";
this.isshow2 = true;
let reg = /^[0-9]+$/


+ 2
- 4
pages/mine/registerCode.vue View File

@@ -16,19 +16,17 @@
return {
qrCodeUrl: "",
projectId:"",
projectName:"",
appid:"",
};
},
onShow() {
this.projectId = uni.getStorageSync('buildingID').id;
this.projectName = uni.getStorageSync('buildingID').name;
this.appid = uni.getAccountInfoSync().miniProgram.appId;
this.qrCodeUrl = domain.baseUrl;
},
methods: {
methods: {
down() {
let url = this.qrCodeUrl+'/customer/getQrCode?appid='+this.appid+'&page=pages/mine/registerForm&scene='+this.projectId+'&projectName='+this.projectName
let url = this.qrCodeUrl+'/customer/getQrCode?appid='+this.appid+'&page=pages/mine/registerForm&scene='+this.projectId
console.log(url)
uni.getImageInfo({
src:url,


+ 30
- 11
pages/mine/registerForm.vue View File

@@ -88,9 +88,12 @@
<text class="books" @click="openModel">《{{tit}}》</text>
</view>
</view>
<u-modal v-model="modelShow" @confirm="readOk" :title="tit" width="720rpx">
<view class="slot-content" style="padding: 20rpx;">
<rich-text :nodes="content"></rich-text>
<u-modal v-model="modelShow" :title="tit" width="720rpx" :mask-close-able="true" :show-confirm-button="false">
<view class="slot-content" style="padding:0 20rpx;">
<u-icon class="close" @click="readOk" name="close-circle" color="#CCCCCC" size="60"></u-icon>
<view class="cont">
<rich-text :nodes="content"></rich-text>
</view>
</view>
</u-modal>
@@ -131,7 +134,7 @@
projectId: '',
projectName: 'xxx',
version:"",
checked: false,
checked: true,
},
pname:"",
daitiReceptionobj: {},
@@ -144,10 +147,9 @@
};
},
onLoad(options) {
const sceneStr = decodeURIComponent(options.scene);
console.log(options)
this.parames.projectId = sceneStr
this.pname = options.projectName
const sceneStr = decodeURIComponent(options.scene);
this.parames.projectId = sceneStr
this.initFetch()
},
watch: {
@@ -179,16 +181,18 @@
url: config.service.privacyAgr,
method: "GET",
data:{
id:appid
id:appid,
projectId:this.parames.projectId
},
header: {
'content-type': 'application/json',
'Access-Token': uni.getStorageSync('weapp_session_login_data').token
},
success: (res) => {
this.content = res.data.data.content
this.content = res.data.data.content
this.tit = res.data.data.title
this.parames.version = res.data.data.version
this.parames.version = res.data.data.version
this.pname = res.data.data.projectName
}
})
},
@@ -197,6 +201,7 @@
},
readOk(){
this.parames.checked = true;
this.modelShow = false;
},
save() {
if(this.parames.checked == false){
@@ -291,7 +296,21 @@
}
};
</script>
<style lang="scss" scoped>
<style lang="scss" scoped>
/deep/ .u-model-title{
padding-top: 0 !important;
}
.slot-content{
position: relative;
.close{
position: absolute;
top: 0;
right: 0;
}
.cont{
padding: 80rpx 0;
}
}
.cented-box {
position: relative;
padding: 0 0 50rpx 0;


Loading…
Cancel
Save