Compare commits

5 Commits

Author SHA1 Message Date
1ade4bfbc6 feat(用户统计): “全部”不显示导出按钮 2026-04-01 14:35:22 +08:00
8c27f01d79 feat(统计业务): 添加课程名称查询条件 2026-04-01 14:34:43 +08:00
111174d324 feat(用户模块): 添加社会身份和证件照功能
- 在用户新增/修改表单中添加社会身份选择项,支持动态加载社会身份数据
- 增加证件照上传功能,允许用户上传和预览证件照片
- 更新表单数据结构,确保社会身份和证件照信息的保存与展示
- 在用户列表中添加社会身份列,提升用户信息的可视化
2026-04-01 10:19:49 +08:00
4d4c644b81 feat(心理论坛模块): 添加分类选择功能及数据加载
- 在新增/修改心理论坛表单中添加分类选择项,支持用户选择分类
- 更新表单验证规则,确保分类为必填项
- 实现分类数据的动态加载,优化用户体验
- 在心理论坛列表中添加分类列,支持分类信息的展示
2026-03-30 09:10:42 +08:00
0506cbccc1 feat(订单模块): 更新支付商户标签和显示逻辑
- 修改支付商户相关表单项的标签,从“微信支付商户”更改为“支付商户”,以提高表述准确性
- 在订单详情中添加支付商户的显示逻辑,根据不同的支付商户值显示相应的名称 (众妙、灵枢)
2026-03-27 11:50:22 +08:00
9 changed files with 174 additions and 13 deletions

View File

@@ -23,6 +23,17 @@
:rows="3"
></el-input>
</el-form-item>
<el-form-item label="分类" prop="type">
<el-select v-model="dataForm.type" placeholder="请选择分类" clearable>
<el-option
v-for="item in typeList"
:key="item.dictType"
:label="item.dictValue"
:value="item.dictType"
>
</el-option>
</el-select>
</el-form-item>
</el-form>
</div>
@@ -42,14 +53,19 @@ export default {
visible: false,
dialogImageUrl: "",
dialogVisible: false,
typeList: [],
dataForm: {
id: null,
title: '',
url: ''
url: '',
type: ''
},
dataRule: {
type: [
{ required: true, message: "分类不能为空", trigger: "change" }
],
url: [
{ required: true, message: "链接地址不能为空", trigger: "blur" }
{ required: true, message: "链接地址不能为空", trigger: "change" }
]
},
urlList: {
@@ -60,12 +76,31 @@ export default {
};
},
methods: {
getTypeList() {
this.$http({
url: this.$http.adornUrl("/book/sysdictdata/selectByType/psycheForumLabel"),
method: "get"
}).then(({ data }) => {
if (data && data.code === 0) {
this.typeList = data.dataList || [];
} else {
this.typeList = [];
}
});
},
init(row) {
this.getTypeList();
this.dataForm = {
id: row && row.id || null,
url: row && row.url || ''
url: row && row.url || '',
type: row && row.type != null ? String(row.type) : ''
};
this.visible = true;
this.$nextTick(() => {
if (this.$refs["dataForm"]) {
this.$refs["dataForm"].clearValidate();
}
});
},
// 表单提交
dataFormSubmit() {
@@ -101,6 +136,9 @@ export default {
});
},
handlereset() {
if (this.$refs["dataForm"]) {
this.$refs["dataForm"].clearValidate();
}
this.visible = false;
}
}

View File

@@ -5,6 +5,17 @@
:model="dataForm"
@keyup.enter.native="getDataList()"
>
<el-form-item label="分类">
<el-select v-model="query.type" placeholder="请选择分类" clearable>
<el-option
v-for="item in typeList"
:key="item.dictType"
:label="item.dictValue"
:value="item.dictType"
>
</el-option>
</el-select>
</el-form-item>
<el-form-item label="文章标题">
<el-input
v-model="query.title"
@@ -65,6 +76,14 @@
</template>
</el-table-column>
<el-table-column
prop="type"
header-align="center"
align="center"
label="分类"
:formatter="typeFormatter"
>
</el-table-column>
<el-table-column
width="200"
prop="createTime"
@@ -132,8 +151,10 @@ export default {
key: ""
},
query: {
title:""
title:"",
type: ""
},
typeList: [],
dataList: [],
delFlag: false,
pageIndex: 1,
@@ -155,9 +176,28 @@ export default {
this.pageIndex = this.$route.query.upPageIndex;
console.log(this.pageIndex);
}
this.getTypeList();
this.getDataList();
},
methods: {
getTypeList() {
this.$http({
url: this.$http.adornUrl("/book/sysdictdata/selectByType/psycheForumLabel"),
method: "get"
}).then(({ data }) => {
if (data && data.code === 0) {
this.typeList = data.dataList || [];
} else {
this.typeList = [];
}
});
},
typeFormatter(row) {
const current = this.typeList.find(
item => item.dictType === row.type || String(item.dictType) === String(row.type)
);
return current ? current.dictValue : row.type;
},
// 获取数据列表
getDataList() {
console.log("this.selectQueryApp at line 195:", this.selectQueryApp);

View File

@@ -100,6 +100,8 @@
<span>IOS内购</span>
</span>
<span v-if="orderDetails.payMerchant == 0">(众妙)</span>
<span v-if="orderDetails.payMerchant == 1">(灵枢)</span>
</li>
<li

View File

@@ -174,7 +174,7 @@
<el-radio :label="0"></el-radio>
</el-radio-group>
</el-form-item>
<el-form-item label="微信支付商户" prop="payMerchant">
<el-form-item label="支付商户" prop="payMerchant">
<el-radio-group v-model="dataForm.payMerchant">
<el-radio :label="0">众妙之门</el-radio>
<el-radio :label="1">灵枢教育科技</el-radio>
@@ -288,7 +288,7 @@ export default {
// format: '', // 开本
isFreeMail: 1, // 是否包邮
isVipPrice: 1, //是否vip
payMerchant: 0, // 微信支付商户
payMerchant: 0, // 支付商户
// pageNum: '',
// quality: '', // 内文用纸
isNew: 0,

View File

@@ -224,7 +224,7 @@
<el-radio :label="0"></el-radio>
</el-radio-group>
</el-form-item>
<el-form-item label="微信支付商户" prop="payMerchant">
<el-form-item label="支付商户" prop="payMerchant">
<el-radio-group v-model="dataForm.payMerchant">
<el-radio :label="0">众妙之门</el-radio>
<el-radio :label="1">灵枢教育科技</el-radio>
@@ -332,7 +332,7 @@ export default {
// format: '', // 开本
isFreeMail: 1, // 是否包邮
isVipPrice: 0, //是否vip
payMerchant: 0, // 微信支付商户
payMerchant: 0, // 支付商户
// pageNum: '',
// quality: '', // 内文用纸
isNew: 0,
@@ -641,7 +641,7 @@ export default {
isFreeMail: this.dataForm.isFreeMail,
isVipPrice: this.dataForm.isVipPrice,
isNew: this.dataForm.isNew,
payMerchant: this.dataForm.payMerchant, // 微信支付商户
payMerchant: this.dataForm.payMerchant, // 支付商户
// 'pageNum': this.dataForm.pageNum,
// 'quality': this.dataForm.quality, // 内文用纸
productStock: this.dataForm.productStock, // 库存

View File

@@ -33,6 +33,14 @@
size="small"
/>
</el-form-item>
<el-form-item>
<el-input
v-model="dataForm.courseTitle"
placeholder="课程名称"
clearable
size="small"
/>
</el-form-item>
<el-form-item>
<el-button
type="primary"
@@ -226,7 +234,9 @@ export default {
return {
timeType: 'year',
currentDate: new Date(),
dataForm: {},
dataForm: {
courseTitle: ''
},
dataList: [],
yearDetailDataList: [],
monthDetailDataList: [],
@@ -290,7 +300,8 @@ export default {
data: http.adornData({
date: dateStr,
page: this.page,
limit: this.limit
limit: this.limit,
courseTitle: this.dataForm.courseTitle
})
}).then(({ data }) => {
if (data && data.code === 0) {

View File

@@ -40,6 +40,7 @@
<div class="table-header">
<div class="table-title">用户统计明细{{ total }}</div>
<el-button
v-if="mode !== 'null'"
type="success"
size="small"
:loading="exportLoading"

View File

@@ -25,6 +25,16 @@
<el-radio v-model="dataForm.sex" :label=1></el-radio>
<el-radio v-model="dataForm.sex" :label=0></el-radio>
</el-form-item>
<el-form-item label="社会身份" prop="socialIdentity">
<el-select v-model="dataForm.socialIdentity" placeholder="请选择社会身份" clearable>
<el-option
v-for="item in socialIdentityList"
:key="item.dictType + '_' + item.dictValue"
:label="item.dictValue"
:value="item.dictValue"
/>
</el-select>
</el-form-item>
<el-form-item label="头像" prop="avatar">
<!-- <el-input v-model="dataForm.avatar" placeholder="头像"></el-input> -->
<el-upload :action="baseUrl + '/oss/fileoss'" list-type="picture-card" :on-preview="handlePictureCardPreview"
@@ -35,6 +45,15 @@
<img width="100%" :src="dataForm.avatar" alt="">
</el-dialog>
</el-form-item>
<el-form-item label="证件照" prop="photo">
<el-upload :action="baseUrl + '/oss/fileoss'" list-type="picture-card" :on-preview="handlePictureCardPreviewPhoto"
:file-list="photoFileList" :on-success="handlePicSuccessPhoto" :on-remove="handleRemovePhoto">
<i class="el-icon-plus"></i>
</el-upload>
<el-dialog :visible.sync="photoDialogVisible" :append-to-body="true">
<img width="100%" :src="dataForm.photo" alt="">
</el-dialog>
</el-form-item>
<el-form-item label="昵称" prop="nickname">
<el-input v-model="dataForm.nickname" placeholder="昵称"></el-input>
</el-form-item>
@@ -110,7 +129,10 @@
baseUrl: global.baseUrl,
visible: false,
dialogVisible: false,
photoDialogVisible: false,
fileList: [],
photoFileList: [],
socialIdentityList: [],
pickerOptions: {
shortcuts: [{
text: '今天',
@@ -156,6 +178,8 @@
wylqPower: 0,
prescriptAPower: 0,
prescriptBPower: 0,
socialIdentity: '',
photo: '',
},
dataRule: {
password: [{
@@ -187,12 +211,25 @@
}
},
methods: {
getSocialIdentityList() {
this.$http({
url: this.$http.adornUrl("/book/sysdictdata/selectByType/user_profile"),
method: 'get',
}).then(({ data }) => {
if (data && data.code === 0) {
this.socialIdentityList = data.dataList || [];
} else {
this.socialIdentityList = [];
}
})
},
init(id) {
this.dataForm.id = id || 0
this.visible = true
this.$nextTick(() => {
this.$refs['dataForm'].resetFields()
if (this.dataForm.id) {
this.getSocialIdentityList()
this.$http({
url: this.$http.adornUrl(`/book/user/info/${this.dataForm.id}`),
method: 'get',
@@ -206,6 +243,8 @@
this.dataForm.age = data.user.age
this.dataForm.sex = data.user.sex
this.dataForm.avatar = data.user.avatar
this.dataForm.socialIdentity = data.user.socialIdentity
this.dataForm.photo = data.user.photo
this.dataForm.nickname = data.user.nickname
this.dataForm.tel = data.user.tel
this.dataForm.password = data.user.password
@@ -231,6 +270,15 @@
attr.push(img)
this.fileList = attr
}
if (data.user.photo && data.user.photo != "") {
var photoImg = {
name: '',
url: data.user.photo
}
var photoAttr = []
photoAttr.push(photoImg)
this.photoFileList = photoAttr
}
}
})
}
@@ -271,6 +319,8 @@
'age': this.dataForm.age,
'sex': this.dataForm.sex,
'avatar': this.dataForm.avatar,
'socialIdentity': this.dataForm.socialIdentity,
'photo': this.dataForm.photo,
'nickname': this.dataForm.nickname,
'tel': this.dataForm.tel,
'pointPower': this.dataForm.pointPower,
@@ -320,6 +370,10 @@
this.dataForm.avatar = file.url;
this.dialogVisible = true;
},
handlePictureCardPreviewPhoto(file) {
this.dataForm.photo = file.url;
this.photoDialogVisible = true;
},
handlePicSuccess(res, file) {
if (res.msg == "success") {
this.dataForm.avatar = res.url;
@@ -328,15 +382,29 @@
this.$message.error("上传失败");
}
},
handlePicSuccessPhoto(res, file) {
if (res.msg == "success") {
this.dataForm.photo = res.url;
this.$message.success("上传成功");
} else {
this.$message.error("上传失败");
}
},
handleRemove(file) {
this.dataForm.avatar = '';
},
handleRemovePhoto(file) {
this.dataForm.photo = '';
this.photoFileList = [];
},
handlereset() {
// console.log('关闭了')
this.$refs['dataForm'].resetFields()
this.dataForm.password = ''
this.fileList = [],
this.visible = false
this.fileList = []
this.photoFileList = []
this.photoDialogVisible = false
this.visible = false
},
}
}

View File

@@ -154,6 +154,7 @@
<span v-else v-html="computedVipType(scope.row.userVips)"> </span>
</template>
</el-table-column>
<el-table-column prop="socialIdentity" header-align="center" align="center" label="社会身份"></el-table-column>
<el-table-column
min-width="170"
prop="tel"