摘要: 参考 常见的缓存更新策略共有3种: Cache Aside(旁路缓存)策略; Read/Write Through(读穿 / 写穿)策略; Write Back(写回)策略; Cache Aside(旁路缓存)策略 Cache Aside(旁路缓存)策略是最常用的,应用程序直接与「数据库、缓存」交互 阅读全文
posted @ 2024-03-27 11:27 Kelvin's 阅读(31) 评论(0) 推荐(0) 编辑
摘要: Dto Dto设置参考 [ExcelImporter(IsLabelingError = true)] public class MyDto { [ImporterHeader(Name = "序号")] [ExporterHeader(DisplayName = "序号")] public int 阅读全文
posted @ 2024-01-16 17:20 Kelvin's 阅读(77) 评论(0) 推荐(0) 编辑
摘要: 添加Nuget包Azure.Data.Tables 在appsettings.json中配置连接字符串 在Module中获取连接字符串,并注册服务 private void ConfigurationTableStorage(ServiceConfigurationContext context) 阅读全文
posted @ 2023-12-26 10:03 Kelvin's 阅读(11) 评论(0) 推荐(0) 编辑
摘要: # 复制 yy # 粘贴 p # 删除当前行,并添加到寄存器中 dd # 向上移动/向下移动(同键盘上下方向键) k/j # 搜索 # 按下 :/搜索内容 # 查看下一个匹配,按下n(小写n) # 跳转到上一个匹配,按下N(大写N) # 关闭高亮 # 命令模式下,输入 nohlsearch/set 阅读全文
posted @ 2023-12-15 10:56 Kelvin's 阅读(9) 评论(0) 推荐(0) 编辑
摘要: var jsonData = JSON.parse(responseBody); pm.environment.set("captcha", jsonData.Data.Captcha); pm.environment.set("uuid", jsonData.Data.Uuid); let img 阅读全文
posted @ 2023-11-15 11:57 Kelvin's 阅读(221) 评论(0) 推荐(0) 编辑
摘要: 发布命令 发布时,进入到Host文件夹路径下 dotnet publish -c XXX 发布完成会生成一个XXX文件夹,里面\net6.0\publish就是发布的程序了 运行命令 运行时,进入到publish文件夹,并在此处打开终端 设置运行端口为8888,使用配置文件appSettings.X 阅读全文
posted @ 2023-11-13 10:35 Kelvin's 阅读(870) 评论(0) 推荐(0) 编辑
摘要: 这里如果直接使用new Date()的话,在传输数据时,会变成ISO时间,所以需要对当前时间进行格式化 如果格式化成YYYY-MM-DD HH:mm:ss无法将时间传递给后端 阅读全文
posted @ 2023-11-01 14:10 Kelvin's 阅读(573) 评论(0) 推荐(0) 编辑
摘要: 参考 Reference 引用某个程序集 PackageReference 引用某个 NuGet 包 ProjectReference 引用某个项目 Compile 常规的 C# 编译 None 没啥特别的编译选项,就为了执行一些通用的操作(或者是只是为了在 Visual Studio 列表中能够有 阅读全文
posted @ 2023-10-18 14:25 Kelvin's 阅读(62) 评论(0) 推荐(0) 编辑
摘要: Service public interface ITestFileService : IApplicationService { public Task<string> getDownloadUrl(); } public class TestFileService : XXXManagement 阅读全文
posted @ 2023-10-18 08:56 Kelvin's 阅读(212) 评论(1) 推荐(0) 编辑
摘要: 仅当局部变量在相同语句中进行声明和初始化时,才能使用 var;变量不能初始化为 null,也不能初始化为方法组或匿名函数。 参考 阅读全文
posted @ 2023-10-11 13:22 Kelvin's 阅读(102) 评论(0) 推荐(0) 编辑
摘要: 定义一个自定义的配置文件 在调试配置中设置启动环境 这里的值填入刚刚设置的配置文件appsetings.{配置文件名字}.json 的配置文件名字 启动即可 系统启动时,首先会检查{配置文件名字}是否存在,存在的话使用appsettings.{配置文件名字}.json,不存在则使用appsettin 阅读全文
posted @ 2023-10-10 16:46 Kelvin's 阅读(161) 评论(0) 推荐(0) 编辑
摘要: 参考 列名 public class Blog { [Column("blog_id")] public int BlogId { get; set; } public string Url { get; set; } } 列数据类型 public class Blog { public int B 阅读全文
posted @ 2023-10-10 14:35 Kelvin's 阅读(37) 评论(0) 推荐(0) 编辑
摘要: Decimal报错: No store type was specified for the decimal property 'GridElectricityPurchase' on entity type 'ChargeDischarge'. This will cause values to 阅读全文
posted @ 2023-10-10 12:02 Kelvin's 阅读(164) 评论(0) 推荐(0) 编辑
摘要: 参考 .gitignore只能忽略那些原来没有被track的文件,如果某些文件已经被纳入了版本管理中,则修改.gitignore是无效的。 git rm -r --cached . git add . git commit -m "update .gitignore" 再推送 git rm -r - 阅读全文
posted @ 2023-10-10 10:38 Kelvin's 阅读(7) 评论(0) 推荐(0) 编辑
摘要: internal权限修饰符 示例1: 此示例包含两个文件,即 Assembly1.cs 和 Assembly1_a.cs。 第一个文件包含内部基类 BaseClass。 在第二个文件中,尝试实例化 BaseClass 会产生错误。 // Assembly1.cs // Compile with: / 阅读全文
posted @ 2023-09-26 10:23 Kelvin's 阅读(9) 评论(0) 推荐(0) 编辑
摘要: 前端控制: 给普通角色配置签收的权限 后端权限控制: /** * 验证用户是否具备某权限 * * @param permission 权限字符串 * @return 用户是否具备某权限 */ public boolean hasPermi(String permission) /** * 验证用户是 阅读全文
posted @ 2022-11-16 11:30 Kelvin's 阅读(2253) 评论(0) 推荐(0) 编辑
摘要: 不传参 computed: { // 仅读取 aDouble: function () { return this.a * 2 }, // 读取和设置 aPlus: { get: function () { return this.a + 1 }, set: function (v) { this. 阅读全文
posted @ 2022-08-22 18:22 Kelvin's 阅读(19) 评论(0) 推荐(0) 编辑
摘要: 启动和停止 进入nginx目录,打开cmd 启动命令 start nginx 停止命令 nginx.exe -s stop 若出现pid不存在无法关闭服务情况,这样才能彻底关闭 taskkill /f /t /im nginx.exe 重新加载配置文件命令 .\nginx.exe -s reload 阅读全文
posted @ 2022-08-22 10:55 Kelvin's 阅读(31) 评论(0) 推荐(0) 编辑
摘要: 参考 单例设计模式 在我们的系统中,有一些对象其实我们只需要一个,比如说:线程池、缓存、对话框、注册表、日志对象、充当打印机、显卡等设备驱动程序的对象。事实上,这一类对象只能有一个实例,如果制造出多个实例就可能会导致一些问题的产生,比如:程序的行为异常、资源使用过量、或者不一致性的结果。 使用单例模 阅读全文
posted @ 2022-08-12 20:29 Kelvin's 阅读(14) 评论(0) 推荐(0) 编辑
摘要: 参考 父组件 <div class="formRight"> <div class="formRightLuckysheet"> <preview :id="businessId" :tableTemplateId1="tableTemplateId" ref="luckysheetPreview" 阅读全文
posted @ 2022-07-22 10:16 Kelvin's 阅读(144) 评论(0) 推荐(0) 编辑
摘要: 阅读全文
posted @ 2022-07-05 10:39 Kelvin's 阅读(28) 评论(0) 推荐(0) 编辑
摘要: vscode 无法使用到conda中pip安装的包 原因:使用的是默认的conda的python环境,如果默认conda环境没有这个包,自然无法找到 解决: 找到设置,将code-runner.excutorMap中的python改成下面的: 不要设置默认的python解释器 "python": " 阅读全文
posted @ 2022-03-26 20:35 Kelvin's 阅读(950) 评论(0) 推荐(0) 编辑
摘要: int cv::createTrackbar( const String & trackbarname,//trackerBar名称 const String & winname,//绘制TrackerBar的窗口 int * value,//需要动态改变的值 int count,//最大值 Tra 阅读全文
posted @ 2022-03-19 20:08 Kelvin's 阅读(144) 评论(0) 推荐(0) 编辑
摘要: ![image](https://img2022.cnblogs.com/blog/2012645/202203/2012645-20220317203401543-1629742774.png) 阅读全文
posted @ 2022-03-17 20:34 Kelvin's 阅读(17) 评论(0) 推荐(0) 编辑
摘要: 1、打开属性管理器(视图-其他窗口-属性管理器) 2、添加新项目属性表 3、设置属性保存位置 4、保存后双击进行属性设置 5、保存 6、全部保存 7、新项目导入属性表 8、确保项目可用,可以所有的都导入 阅读全文
posted @ 2021-11-22 21:04 Kelvin's 阅读(832) 评论(0) 推荐(0) 编辑
摘要: 项目git架构 项目git流程 阅读全文
posted @ 2021-07-22 18:00 Kelvin's 阅读(25) 评论(0) 推荐(0) 编辑
摘要: const target = { a: 1, b: 2 }; const source = { b: 4, c: 5 }; const returnedTarget = Object.assign(target, source); console.log(target); // expected o 阅读全文
posted @ 2021-06-15 13:43 Kelvin's 阅读(65) 评论(0) 推荐(0) 编辑
摘要: 在SpringBoot中启动Netty 方式1 设置一个ApplicationListener @Component public class NettyBooter implements ApplicationListener<ContextRefreshedEvent>{ @Override p 阅读全文
posted @ 2021-05-22 20:43 Kelvin's 阅读(4488) 评论(0) 推荐(0) 编辑
摘要: SpringUtil报空处理 SpringUtil工具类 package com.kelvin.nettydemo; import org.springframework.beans.BeansException; import org.springframework.context.Applica 阅读全文
posted @ 2021-05-22 19:55 Kelvin's 阅读(363) 评论(0) 推荐(0) 编辑
摘要: mybatis-plus配置 添加依赖 <dependency> <groupId>com.baomidou</groupId> <artifactId>mybatis-plus-boot-starter</artifactId> <version>3.4.0</version> </depende 阅读全文
posted @ 2021-03-08 10:44 Kelvin's 阅读(829) 评论(0) 推荐(0) 编辑
摘要: 创建springboot项目 项目结构如下: Maven 打包项目成jar包 添加Docker插件 设置服务器docker可被远程连接 vim /usr/lib/systemd/system/docker.service # 在ExecStart=/usr/bin/dockerd 后面加上-H tc 阅读全文
posted @ 2021-02-25 21:15 Kelvin's 阅读(140) 评论(0) 推荐(0) 编辑
摘要: 源码: myComponentPage.wxml: <myComponent question="{{quesiton.quesContent}}" quid="{{quesiton.quesOrder}}" question="{{quesiton.quesContent}}" quesOptio 阅读全文
posted @ 2021-02-03 12:51 Kelvin's 阅读(578) 评论(0) 推荐(0) 编辑
摘要: 官方案例: <!-- audio.wxml --> <audio poster="{{poster}}" name="{{name}}" author="{{author}}" src="{{src}}" id="myAudio" controls loop></audio> <button typ 阅读全文
posted @ 2021-02-03 11:34 Kelvin's 阅读(877) 评论(0) 推荐(0) 编辑
摘要: 配置centos7基本环境 更换镜像源 参考:https://developer.aliyun.com/mirror/中的CentOS镜像 安装wget #使用户成为sudoer su vi /etc/sudoers sudo yum install -y wget 备份镜像源 mv /etc/yu 阅读全文
posted @ 2021-01-28 12:05 Kelvin's 阅读(1270) 评论(0) 推荐(0) 编辑
摘要: 1. 初始化 npm init 一直默认回车就OK,然后会产生一个package.json的文件 2. 安装vant 官网安装方法: npm i @vant/weapp -S --production 3. 修改app.json文件 将 app.json 中的 "style": "v2" 去除 4. 阅读全文
posted @ 2021-01-19 11:53 Kelvin's 阅读(603) 评论(0) 推荐(0) 编辑
摘要: 使用Promise封装request请求 Promise 对象是由关键字 new 及其构造函数来创建的。该构造函数会把一个叫做“处理器函数”(executor function)的函数作为它的参数。这个“处理器函数”接受两个函数——resolve 和 reject ——作为其参数。当异步任务顺利完成 阅读全文
posted @ 2020-12-18 14:19 Kelvin's 阅读(1507) 评论(0) 推荐(0) 编辑
摘要: 参考解构赋值文档 解构赋值语法是一种 Javascript 表达式。通过解构赋值, 可以将属性/值从对象/数组中取出,赋值给其他变量。 let a, b, rest; [a, b] = [10, 20]; console.log(a); // expected output: 10 console. 阅读全文
posted @ 2020-12-18 09:56 Kelvin's 阅读(445) 评论(0) 推荐(0) 编辑
摘要: 微信小程序wxml 在微信小程序中有一个简易的双向绑定 简易双向绑定 但是这个双向绑定只能绑定简单的值,无法绑定复杂对象的属性值 用法: <input model:value="{{value}}" /> 错误用法: <input model:value="{{ a.b }}" /> 设置一个监听器 阅读全文
posted @ 2020-12-17 20:16 Kelvin's 阅读(524) 评论(0) 推荐(0) 编辑
摘要: 官方文档 小程序登陆 登陆时序图: 微信小程序前端: <button type="primary" plain open-type="getUserInfo" bindgetuserinfo="handleGetUserInfo"> 登录 </button> handleGetUserInfo(e) 阅读全文
posted @ 2020-12-14 16:46 Kelvin's 阅读(160) 评论(0) 推荐(0) 编辑
摘要: 下载 vue 这里可能会出现的一个问题是,无法获取到文件名,需要springboot在响应头上将content-disposition暴露出来 let fileName = decodeURI(res.headers['content-disposition']);// 设置文件名 即: respo 阅读全文
posted @ 2020-11-27 18:47 Kelvin's 阅读(2363) 评论(2) 推荐(0) 编辑
点击右上角即可分享
微信分享提示