Commit 3cf63544fce320323d9959e2434988fc629b4829
1 parent
4aba9b59
a
Showing
15 changed files
with
142 additions
and
24 deletions
antis-ncc-admin/.env.production
antis-ncc-admin/src/utils/define.js
| ... | ... | @@ -2,7 +2,8 @@ |
| 2 | 2 | // JAVA Boot版本对应后端接口地址 |
| 3 | 3 | // JAVA Cloud对应网关地址 |
| 4 | 4 | // const APIURl = 'http://localhost:8061' |
| 5 | -const APIURl = 'http://8.130.38.56:8066' | |
| 5 | +// const APIURl = 'http://8.130.38.56:8066' | |
| 6 | +const APIURl = 'https://www.xiaoxiangsuanshu.com' | |
| 6 | 7 | |
| 7 | 8 | module.exports = { |
| 8 | 9 | APIURl: APIURl, | ... | ... |
antis-ncc-admin/src/views/tbMemCode/index.vue
| ... | ... | @@ -51,7 +51,7 @@ |
| 51 | 51 | <el-table-column label="状态" prop="type" align="left"> |
| 52 | 52 | <template slot-scope="scope">{{ scope.row.type | dynamicText(typeOptions) }}</template> |
| 53 | 53 | </el-table-column> |
| 54 | - <el-table-column prop="expire" label="到期时间截至" align="left" /> | |
| 54 | + <el-table-column prop="expire" label="到期时间截至" align="left" :formatter="ncc.tableDateFormat"/> | |
| 55 | 55 | <el-table-column prop="creatorTime" label="创建时间" align="left" :formatter="ncc.tableDateFormat" /> |
| 56 | 56 | <el-table-column prop="lastModifyTime" label="修改时间" align="left" :formatter="ncc.tableDateFormat" /> |
| 57 | 57 | <el-table-column label="操作" fixed="right" width="100"> | ... | ... |
antis-ncc-net-core/ClassLibrary1/打卡记录/Dto/TbPunchListOutput.cs
| 1 | -using NCC.System.Entitys.Permission; | |
| 1 | +using Aspose.Words.Lists; | |
| 2 | +using NCC.Common.Model; | |
| 3 | +using NCC.System.Entitys.Permission; | |
| 4 | +using Newtonsoft.Json; | |
| 2 | 5 | using System; |
| 6 | +using System.Collections.Generic; | |
| 3 | 7 | |
| 4 | 8 | namespace NCC.Education.Entitys.Dto.TbPunch |
| 5 | 9 | { |
| ... | ... | @@ -27,6 +31,20 @@ namespace NCC.Education.Entitys.Dto.TbPunch |
| 27 | 31 | /// </summary> |
| 28 | 32 | public DateTime? exerciseDate { get; set; } |
| 29 | 33 | |
| 34 | + public string imgList { get; set; } | |
| 35 | + | |
| 36 | + public List<FileControlsModel> ImgList { get | |
| 37 | + { | |
| 38 | + try | |
| 39 | + { | |
| 40 | + return JsonConvert.DeserializeObject<List<FileControlsModel>>(imgList); | |
| 41 | + }catch(Exception ex) | |
| 42 | + { | |
| 43 | + return new List<FileControlsModel>(); | |
| 44 | + } | |
| 45 | + } } | |
| 46 | + | |
| 47 | + | |
| 30 | 48 | /// <summary> |
| 31 | 49 | /// 编号 |
| 32 | 50 | /// </summary> | ... | ... |
antis-ncc-net-core/ClassLibrary1/打卡记录/Dto/TbPunchListQueryInput.cs
antis-ncc-net-core/ClassLibrary1/打卡资讯/Dto/TbPunchInfoListOutput.cs
| 1 | -using System; | |
| 1 | +using NCC.Common.Model; | |
| 2 | +using Newtonsoft.Json; | |
| 3 | +using System; | |
| 4 | +using System.Collections.Generic; | |
| 2 | 5 | |
| 3 | 6 | namespace NCC.Education.Entitys.Dto.TbPunchInfo |
| 4 | 7 | { |
| ... | ... | @@ -26,6 +29,29 @@ namespace NCC.Education.Entitys.Dto.TbPunchInfo |
| 26 | 29 | /// 修改时间 |
| 27 | 30 | /// </summary> |
| 28 | 31 | public DateTime? lastModifyTime { get; set; } |
| 32 | + /// <summary> | |
| 33 | + /// 富文本 | |
| 34 | + /// </summary> | |
| 35 | + public string editors { get; set; } | |
| 36 | + /// <summary> | |
| 37 | + /// 图片 | |
| 38 | + /// </summary> | |
| 39 | + public string img { get; set; } | |
| 40 | + | |
| 41 | + public List<FileControlsModel> Img | |
| 42 | + { | |
| 43 | + get | |
| 44 | + { | |
| 45 | + try | |
| 46 | + { | |
| 47 | + return JsonConvert.DeserializeObject<List<FileControlsModel>>(img); | |
| 48 | + } | |
| 49 | + catch (Exception ex) | |
| 50 | + { | |
| 51 | + return new List<FileControlsModel>(); | |
| 52 | + } | |
| 53 | + } | |
| 54 | + } | |
| 29 | 55 | |
| 30 | 56 | /// <summary> |
| 31 | 57 | /// 阅读量 | ... | ... |
antis-ncc-net-core/ClassLibrary1/测评信息/Dto/TbEvaluationListOutput.cs
| 1 | -using System; | |
| 1 | +using NCC.Common.Model; | |
| 2 | +using Newtonsoft.Json; | |
| 3 | +using SqlSugar; | |
| 4 | +using System; | |
| 5 | +using System.Collections.Generic; | |
| 2 | 6 | |
| 3 | 7 | namespace NCC.Education.Entitys.Dto.TbEvaluation |
| 4 | 8 | { |
| ... | ... | @@ -16,7 +20,31 @@ namespace NCC.Education.Entitys.Dto.TbEvaluation |
| 16 | 20 | /// 标题 |
| 17 | 21 | /// </summary> |
| 18 | 22 | public string title { get; set; } |
| 19 | - | |
| 23 | + /// <summary> | |
| 24 | + /// 图文信息 | |
| 25 | + /// </summary> | |
| 26 | + public string editors { get; set; } | |
| 27 | + /// <summary> | |
| 28 | + /// 图片 | |
| 29 | + /// </summary> | |
| 30 | + public string img { get; set; } | |
| 31 | + | |
| 32 | + public List<FileControlsModel> Img | |
| 33 | + { | |
| 34 | + get | |
| 35 | + { | |
| 36 | + try | |
| 37 | + { | |
| 38 | + return JsonConvert.DeserializeObject<List<FileControlsModel>>(img); | |
| 39 | + } | |
| 40 | + catch (Exception ex) | |
| 41 | + { | |
| 42 | + return new List<FileControlsModel>(); | |
| 43 | + } | |
| 44 | + } | |
| 45 | + } | |
| 46 | + | |
| 47 | + | |
| 20 | 48 | /// <summary> |
| 21 | 49 | /// 创建时间 |
| 22 | 50 | /// </summary> | ... | ... |
antis-ncc-net-core/ClassLibrary1/首页信息/Dto/TbHomeInfoListOutput.cs
| 1 | -using System; | |
| 1 | +using NCC.Common.Model; | |
| 2 | +using Newtonsoft.Json; | |
| 3 | +using System; | |
| 4 | +using System.Collections.Generic; | |
| 2 | 5 | |
| 3 | 6 | namespace NCC.Education.Entitys.Dto.TbHomeInfo |
| 4 | 7 | { |
| ... | ... | @@ -21,7 +24,22 @@ namespace NCC.Education.Entitys.Dto.TbHomeInfo |
| 21 | 24 | /// 备注 |
| 22 | 25 | /// </summary> |
| 23 | 26 | public string remark { get; set; } |
| 24 | - | |
| 27 | + /// <summary> | |
| 28 | + /// 图片 | |
| 29 | + /// </summary> | |
| 30 | + public string img { get; set; } | |
| 31 | + | |
| 32 | + public List<FileControlsModel> Img { get | |
| 33 | + { | |
| 34 | + try | |
| 35 | + { | |
| 36 | + return JsonConvert.DeserializeObject<List<FileControlsModel>>(img); | |
| 37 | + }catch(Exception ex) | |
| 38 | + { | |
| 39 | + return new List<FileControlsModel>(); | |
| 40 | + } | |
| 41 | + } } | |
| 42 | + | |
| 25 | 43 | /// <summary> |
| 26 | 44 | /// 创建时间 |
| 27 | 45 | /// </summary> | ... | ... |
antis-ncc-net-core/NCC.Education/打卡记录/TbPunchService.cs
| ... | ... | @@ -117,7 +117,7 @@ namespace NCC.Education.TbPunch |
| 117 | 117 | /// </summary> |
| 118 | 118 | /// <param name="input">参数</param> |
| 119 | 119 | /// <returns></returns> |
| 120 | - [HttpPost("TbPunchCrInput")] | |
| 120 | + [HttpPost("StartPunch")] | |
| 121 | 121 | public async Task<dynamic> StartPunch([FromBody] TbPunchCrInput input) |
| 122 | 122 | { |
| 123 | 123 | var dbLink = await _dbLinkService.GetInfo("218239598550058245"); |
| ... | ... | @@ -157,7 +157,7 @@ namespace NCC.Education.TbPunch |
| 157 | 157 | return new OutPutInfo() |
| 158 | 158 | { |
| 159 | 159 | SingleNum = model.Num.ToInt(), |
| 160 | - BothNum = bothModel.Num.ToInt(), | |
| 160 | + BothNum =bothModel!=null?bothModel.Num.ToInt():0, | |
| 161 | 161 | Days = sum |
| 162 | 162 | }; |
| 163 | 163 | } |
| ... | ... | @@ -175,7 +175,7 @@ namespace NCC.Education.TbPunch |
| 175 | 175 | private void AddInterateNumBoth(TbBothSettingEntity model, TbPunchEntity entity) |
| 176 | 176 | { |
| 177 | 177 | //增加用户积分 |
| 178 | - var result = _db.Updateable<UserEntity>(it => new UserEntity { IntegralNum = it.IntegralNum.ToInt() + model.Num }).Where(o => o.Id == entity.UserId).ExecuteCommand(); | |
| 178 | + var result = _db.Updateable<UserEntity>(it => new UserEntity { IntegralNum =SqlFunc.ToInt32(it.IntegralNum) + model.Num }).Where(o => o.Id == entity.UserId).ExecuteCommand(); | |
| 179 | 179 | //增加积分日志 |
| 180 | 180 | var logResult = _db.Insertable(new TbMoneysLogEntity() |
| 181 | 181 | { |
| ... | ... | @@ -192,7 +192,7 @@ namespace NCC.Education.TbPunch |
| 192 | 192 | private void AddInterateNumSinge(TbSingleSettingEntity model, TbPunchEntity entity) |
| 193 | 193 | { |
| 194 | 194 | //增加用户积分 |
| 195 | - var result = _db.Updateable<UserEntity>(it => new UserEntity { IntegralNum = it.IntegralNum.ToInt() + model.Num }).Where(o => o.Id == entity.UserId).ExecuteCommand(); | |
| 195 | + var result = _db.Updateable<UserEntity>(it => new UserEntity { IntegralNum =SqlFunc.ToInt32(it.IntegralNum)+ model.Num }).Where(o => o.Id == entity.UserId).ExecuteCommand(); | |
| 196 | 196 | //增加积分日志 |
| 197 | 197 | var logResult = _db.Insertable(new TbMoneysLogEntity() |
| 198 | 198 | { |
| ... | ... | @@ -283,10 +283,15 @@ namespace NCC.Education.TbPunch |
| 283 | 283 | List<string> queryExerciseDate = input.exerciseDate != null ? input.exerciseDate.Split(',').ToObeject<List<string>>() : null; |
| 284 | 284 | DateTime? startExerciseDate = queryExerciseDate != null ? Ext.GetDateTime(queryExerciseDate.First()) : null; |
| 285 | 285 | DateTime? endExerciseDate = queryExerciseDate != null ? Ext.GetDateTime(queryExerciseDate.Last()) : null; |
| 286 | + List<string> creatorTimeDate = input.creatorTime != null ? input.creatorTime.Split(',').ToObeject<List<string>>() : null; | |
| 287 | + DateTime? startcreatorTimeDate = creatorTimeDate != null ? Ext.GetDateTime(creatorTimeDate.First()) : null; | |
| 288 | + DateTime? endcreatorTimeDate = creatorTimeDate != null ? Ext.GetDateTime(creatorTimeDate.Last()) : null; | |
| 286 | 289 | var data = await _db.Queryable<TbPunchEntity>() |
| 287 | 290 | .WhereIF(!string.IsNullOrEmpty(input.userId), p => p.UserId.Equals(input.userId)) |
| 288 | 291 | .WhereIF(queryExerciseDate != null, p => p.ExerciseDate >= new DateTime(startExerciseDate.ToDate().Year, startExerciseDate.ToDate().Month, startExerciseDate.ToDate().Day, 0, 0, 0)) |
| 289 | 292 | .WhereIF(queryExerciseDate != null, p => p.ExerciseDate <= new DateTime(endExerciseDate.ToDate().Year, endExerciseDate.ToDate().Month, endExerciseDate.ToDate().Day, 23, 59, 59)) |
| 293 | + .WhereIF(creatorTimeDate != null, p => p.CreatorTime >= new DateTime(startcreatorTimeDate.ToDate().Year, startcreatorTimeDate.ToDate().Month, startcreatorTimeDate.ToDate().Day, 0, 0, 0)) | |
| 294 | + .WhereIF(creatorTimeDate != null, p => p.CreatorTime <= new DateTime(endcreatorTimeDate.ToDate().Year, endcreatorTimeDate.ToDate().Month, endcreatorTimeDate.ToDate().Day, 23, 59, 59)) | |
| 290 | 295 | .WhereIF(!string.IsNullOrEmpty(input.code), p => p.Code.Contains(input.code)) |
| 291 | 296 | .WhereIF(!string.IsNullOrEmpty(input.type), p => p.Type.Equals(input.type)) |
| 292 | 297 | .Select(it=> new TbPunchListOutput |
| ... | ... | @@ -299,6 +304,7 @@ namespace NCC.Education.TbPunch |
| 299 | 304 | creatorTime=it.CreatorTime, |
| 300 | 305 | lastModifyTime=it.LastModifyTime, |
| 301 | 306 | type=it.Type, |
| 307 | + imgList=it.ImgList, | |
| 302 | 308 | }).MergeTable().Mapper(p => { |
| 303 | 309 | p.user = _db.Queryable<UserEntity>().Where(o => o.Id == p.userId).First(); |
| 304 | 310 | }).OrderBy(sidx+" "+input.sort).ToPagedListAsync(input.currentPage, input.pageSize); | ... | ... |
antis-ncc-net-core/NCC.Education/打卡资讯/TbPunchInfoService.cs
antis-ncc-net-core/NCC.Education/测评信息/TbEvaluationService.cs
| ... | ... | @@ -105,6 +105,8 @@ namespace NCC.Education.TbEvaluation |
| 105 | 105 | title=it.Title, |
| 106 | 106 | creatorTime=it.CreatorTime, |
| 107 | 107 | lastModifyTime=it.LastModifyTime, |
| 108 | + editors = it.Editors, | |
| 109 | + img =it.Img, | |
| 108 | 110 | }).MergeTable().OrderBy(sidx+" "+input.sort).ToPagedListAsync(input.currentPage, input.pageSize); |
| 109 | 111 | return PageResult<TbEvaluationListOutput>.SqlSugarPageResult(data); |
| 110 | 112 | } | ... | ... |
antis-ncc-net-core/NCC.Education/首页信息/TbHomeInfoService.cs
| ... | ... | @@ -106,6 +106,7 @@ namespace NCC.Education.TbHomeInfo |
| 106 | 106 | remark=it.Remark, |
| 107 | 107 | creatorTime=it.CreatorTime, |
| 108 | 108 | lastModifyTime=it.LastModifyTime, |
| 109 | + img=it.Img, | |
| 109 | 110 | }).MergeTable().OrderBy(sidx+" "+input.sort).ToPagedListAsync(input.currentPage, input.pageSize); |
| 110 | 111 | return PageResult<TbHomeInfoListOutput>.SqlSugarPageResult(data); |
| 111 | 112 | } | ... | ... |
antis-ncc-net-core/src/Application/NCC.API/appsettings.json
| ... | ... | @@ -99,15 +99,15 @@ |
| 99 | 99 | "WEPAY_APP_URL": "", |
| 100 | 100 | "WEPAY_APP_KEY": "", |
| 101 | 101 | //公众号平台配置 |
| 102 | - "WEPAY_WEB_APPID": "wx2ad028e8f5a3e6c0", | |
| 102 | + "WEPAY_WEB_APPID": "wx5b2942cc4a832ca4", | |
| 103 | 103 | "WEPAY_WEB_MCH_ID": "1635119465", //商户号 |
| 104 | 104 | "WEPAY_WEB_NOTIFY_URL": "http://localhost:8061/api/Hairdressing/tbuserorder/WePayNotifyUserOrder", //微信支付回调地址 |
| 105 | 105 | "WEPAY_WEB_URL": "https://uu365.t1j2.com/", |
| 106 | 106 | "WEPAY_WEB_KEY": "QvzO0StUx5hpvYsNY0sRMSldYmtGY2bE", //微信商户秘钥 |
| 107 | 107 | |
| 108 | 108 | //小程序 |
| 109 | - "APPLETE_APPSECRET": "ca62af33bb382ac9688907db01740b15", | |
| 110 | - "APPLETE_APPID": "wx2ad028e8f5a3e6c0" | |
| 109 | + "APPLETE_APPSECRET": "f065790516f790f0ae935524d3fed203", | |
| 110 | + "APPLETE_APPID": "wx5b2942cc4a832ca4" | |
| 111 | 111 | |
| 112 | 112 | }, |
| 113 | 113 | /* 支付宝支付配置 */ |
| ... | ... | @@ -164,8 +164,8 @@ |
| 164 | 164 | "NCC_App": { |
| 165 | 165 | "CodeAreasName": "Education", |
| 166 | 166 | //系统文件路径(末尾必须带斜杆) |
| 167 | - //"SystemPath": "C:\\web\\NCC\\uu-resources\\", | |
| 168 | - "SystemPath": "C:\\inetpub\\wwwroot\\教育小程序\\UploadFile\\", | |
| 167 | + "SystemPath": "C:\\web\\NCC\\uu-resources\\", | |
| 168 | + //"SystemPath": "C:\\inetpub\\wwwroot\\教育小程序\\UploadFile\\", | |
| 169 | 169 | //微信公众号允许上传文件类型 |
| 170 | 170 | "MPUploadFileType": "bmp,png,jpeg,jpg,gif,mp3,wma,wav,amr,mp4", |
| 171 | 171 | //微信允许上传文件类型 | ... | ... |
antis-ncc-net-core/src/Modularity/OAuth/NCC.OAuth/Service/OAuthService.cs
| ... | ... | @@ -169,8 +169,8 @@ namespace NCC.OAuth.Service |
| 169 | 169 | if (user.DeleteMark == 1) |
| 170 | 170 | throw NCCException.Oh(ErrorCode.D1017); |
| 171 | 171 | // app权限验证 |
| 172 | - if (NetUtil.isMobileBrowser && user.IsAdministrator == 0 && !ExistRoleByApp(user.RoleId)) | |
| 173 | - throw NCCException.Oh(ErrorCode.D1022); | |
| 172 | + //if (NetUtil.isMobileBrowser && user.IsAdministrator == 0 && !ExistRoleByApp(user.RoleId)) | |
| 173 | + // throw NCCException.Oh(ErrorCode.D1022); | |
| 174 | 174 | |
| 175 | 175 | //登录成功时 判断单点登录信息 |
| 176 | 176 | |
| ... | ... | @@ -259,7 +259,8 @@ namespace NCC.OAuth.Service |
| 259 | 259 | return new LoginOutput() |
| 260 | 260 | { |
| 261 | 261 | theme = user.Theme == null ? "classic" : user.Theme, |
| 262 | - token = "Bearer " + accessToken | |
| 262 | + token = "Bearer " + accessToken, | |
| 263 | + user=user | |
| 263 | 264 | }; |
| 264 | 265 | } |
| 265 | 266 | ... | ... |
antis-ncc-net-core/src/Modularity/System/NCC.System/Service/Permission/UsersService.cs
| ... | ... | @@ -31,6 +31,7 @@ using System.Threading.Tasks; |
| 31 | 31 | using UAParser; |
| 32 | 32 | using NCC.Common.Model; |
| 33 | 33 | using Yitter.IdGenerator; |
| 34 | +using NPOI.OpenXmlFormats; | |
| 34 | 35 | |
| 35 | 36 | namespace NCC.System.Service.Permission |
| 36 | 37 | { |
| ... | ... | @@ -120,6 +121,14 @@ namespace NCC.System.Service.Permission |
| 120 | 121 | /// 入学年份 |
| 121 | 122 | /// </summary> |
| 122 | 123 | public string year { get; set; } |
| 124 | + /// <summary> | |
| 125 | + /// 头像 | |
| 126 | + /// </summary> | |
| 127 | + public string headIcon { get; set; } | |
| 128 | + /// <summary> | |
| 129 | + /// 是否首次登录 1--非首次登录 2--首次登录 | |
| 130 | + /// </summary> | |
| 131 | + public string status { get; set; } | |
| 123 | 132 | #endregion |
| 124 | 133 | } |
| 125 | 134 | /// <summary> |
| ... | ... | @@ -130,6 +139,7 @@ namespace NCC.System.Service.Permission |
| 130 | 139 | [HttpPost("GetUserInfoByUserId")] |
| 131 | 140 | public async Task<dynamic> GetUserInfoByUserId(string UserId) |
| 132 | 141 | { |
| 142 | + var user = _userRepository.Context.Queryable<UserEntity>().Where(o => o.Id == UserId).First(); | |
| 133 | 143 | var model = _userRepository.Context.Queryable<UserEntity>().Where(o => o.Id == UserId).Select(it => new UserInfoCustom |
| 134 | 144 | { |
| 135 | 145 | id = it.Id, |
| ... | ... | @@ -142,7 +152,9 @@ namespace NCC.System.Service.Permission |
| 142 | 152 | postalAddress = it.PostalAddress, |
| 143 | 153 | realName = it.RealName, |
| 144 | 154 | type = it.Type, |
| 145 | - year = it.Year.ToString() | |
| 155 | + year = it.Year.ToString(), | |
| 156 | + headIcon = it.HeadIcon, | |
| 157 | + status = user.Type == "1" ? "2" : "1" | |
| 146 | 158 | }).First(); |
| 147 | 159 | return model; |
| 148 | 160 | } | ... | ... |