zzw-one #5
Binary file not shown.
Before Width: | Height: | Size: 4.3 KiB After Width: | Height: | Size: 4.6 KiB |
40
yudao-admin-vue3/src/api/mall/promotion/intelligent/index.ts
Normal file
40
yudao-admin-vue3/src/api/mall/promotion/intelligent/index.ts
Normal file
@ -0,0 +1,40 @@
|
|||||||
|
import request from '@/config/axios'
|
||||||
|
|
||||||
|
export interface ArticleVO {
|
||||||
|
id: number
|
||||||
|
title: string
|
||||||
|
collectionQuantity: string
|
||||||
|
pageView: string
|
||||||
|
introduction: string
|
||||||
|
inputarr: string[]
|
||||||
|
}
|
||||||
|
|
||||||
|
// 查询文章管理列表
|
||||||
|
export const selectDynamicData = async () => {
|
||||||
|
return await request.get({ url: `/intelligentForm/selectDynamicData` })
|
||||||
|
}
|
||||||
|
|
||||||
|
// // 查询文章管理详情
|
||||||
|
// export const saveDynamicData = async (id: number) => {
|
||||||
|
// return await request.get({ url: `/promotion/article/get?id=` + id })
|
||||||
|
// }
|
||||||
|
|
||||||
|
// 新增文章管理
|
||||||
|
export const saveDynamicData = async (data: ArticleVO) => {
|
||||||
|
return await request.post({ url: `/intelligentForm/saveDynamicData`, data })
|
||||||
|
}
|
||||||
|
|
||||||
|
// 查询文章管理列表
|
||||||
|
export const collectDataList = async (query: any) => {
|
||||||
|
return await request.get({ url: `/intelligentForm/collectDataList`, query })
|
||||||
|
}
|
||||||
|
|
||||||
|
// // 修改文章管理
|
||||||
|
// export const updateArticle = async (data: ArticleVO) => {
|
||||||
|
// return await request.put({ url: `/promotion/article/update`, data })
|
||||||
|
// }
|
||||||
|
|
||||||
|
// // 删除文章管理
|
||||||
|
// export const deleteArticle = async (id: number) => {
|
||||||
|
// return await request.delete({ url: `/promotion/article/delete?id=` + id })
|
||||||
|
// }
|
280
yudao-admin-vue3/src/views/mall/promotion/intelligent/index.vue
Normal file
280
yudao-admin-vue3/src/views/mall/promotion/intelligent/index.vue
Normal file
@ -0,0 +1,280 @@
|
|||||||
|
<template>
|
||||||
|
<div class="app-container" style="display: flex;flex-wrap: wrap">
|
||||||
|
|
||||||
|
<!-- <el-col :span="8" v-for="(o, index) in 1" :key="o" :offset="index > 0 ? 2 : 0">-->
|
||||||
|
|
||||||
|
<el-card class="box-card">
|
||||||
|
<div class="container">
|
||||||
|
<el-button type="primary" plain @click="handleAdd" style="border: none;">
|
||||||
|
+ 新建表单
|
||||||
|
</el-button>
|
||||||
|
|
||||||
|
</div>
|
||||||
|
</el-card>
|
||||||
|
|
||||||
|
<el-card class="box-card" v-for="o in cardList" :key="o" >
|
||||||
|
<div slot="header" class="clearfix">
|
||||||
|
<span style="font-size: 23px;
|
||||||
|
color: #000000;
|
||||||
|
background-color:#ffffff;
|
||||||
|
border-color: #fdfdff;">{{o.title}}</span>
|
||||||
|
<el-button style="float: right; padding: 3px 0" type="text" @click="handelExtend(o.id)">推广</el-button>
|
||||||
|
</div>
|
||||||
|
<div style="display: flex;justify-content: space-between">
|
||||||
|
<!-- <div style="width: 30%">-->
|
||||||
|
<!-- <div>采购员</div>-->
|
||||||
|
<!-- <p style="font-size: 25px">1</p>-->
|
||||||
|
<!-- </div>-->
|
||||||
|
<div style="width: 30%">
|
||||||
|
<div style="font-size: 18px;
|
||||||
|
color: #999595;
|
||||||
|
background-color:#ffffff;
|
||||||
|
border-color: #fdfdff;">总浏览量</div>
|
||||||
|
<p style="font-size: 25px">{{o.pageView}}</p>
|
||||||
|
</div>
|
||||||
|
<div style="width: 30%">
|
||||||
|
<el-link style="font-size: 18px;
|
||||||
|
color: #999595;
|
||||||
|
background-color:#ffffff;
|
||||||
|
border-color: #fdfdff;"
|
||||||
|
@click="extendList(o.id)">采集数量</el-link>
|
||||||
|
<p style="font-size: 25px" @click="extendList(o.id)">{{o.collectionQuantity}}</p>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div style="display: flex;justify-content: space-between">
|
||||||
|
<div>
|
||||||
|
<span style="font-size: 16px;
|
||||||
|
color: #999595;
|
||||||
|
background-color:#ffffff;
|
||||||
|
border-color: #fdfdff;">创建人:{{o.createPeople}}</span>
|
||||||
|
</div>
|
||||||
|
<div style="font-size: 16px;
|
||||||
|
color: #999595;
|
||||||
|
background-color:#ffffff;
|
||||||
|
border-color: #fdfdff;">创建时间:{{o.createTime}}</div>
|
||||||
|
</div>
|
||||||
|
</el-card>
|
||||||
|
|
||||||
|
|
||||||
|
<!-- </el-col>-->
|
||||||
|
|
||||||
|
<!-- 添加表单对话框 -->
|
||||||
|
<el-dialog :title="title" :visible.sync="open" width="500px" append-to-body>
|
||||||
|
|
||||||
|
<div style="text-align: center">
|
||||||
|
<!-- <el-form-item label="表单标题">-->
|
||||||
|
<div><span>标题</span> <el-input style="border-bottom: 1px solid skyblue;margin-bottom: 10px" v-model="addParams.title" placeholder="请输入表单标题" />
|
||||||
|
</div>
|
||||||
|
<!-- </el-form-item>-->
|
||||||
|
<!-- <el-form-item label="字段名称">-->
|
||||||
|
<div v-for="(item,index) in inputarr" key="index" style="margin-bottom: 10px;">
|
||||||
|
<span>字段</span> <el-input style="border: 1px solid #DCDFE6;border-radius: 3px; " v-model="inputarr[index]" placeholder="请输入字段"></el-input>
|
||||||
|
</div>
|
||||||
|
<div>
|
||||||
|
<el-button @click="adinput" style="text-align: center;width: 90%;background-color: rgb(232,244,255);color:#1890ff">添加字段</el-button>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<!-- </el-form-item>-->
|
||||||
|
</div>
|
||||||
|
<br>
|
||||||
|
<div class="el-input-foot">
|
||||||
|
<el-button type="primary" @click="submitForm">确 定</el-button>
|
||||||
|
<el-button @click="cancel">取 消</el-button>
|
||||||
|
</div>
|
||||||
|
</el-dialog>
|
||||||
|
|
||||||
|
<!-- 推广链接对话框-->
|
||||||
|
<el-dialog :title="extendTitle" :visible.sync="extendOpen" width="500px" append-to-body>
|
||||||
|
<el-input v-model="extendLink" placeholder="请输入内容" :disabled="true"></el-input>
|
||||||
|
<el-button @click="copyAddress">复制</el-button>
|
||||||
|
</el-dialog>
|
||||||
|
|
||||||
|
<!-- 采集数据列表 -->
|
||||||
|
<el-dialog :title="collectTitle" :visible.sync="collectOpen" append-to-body>
|
||||||
|
<el-table border v-loading="loading" :data="collectLink" @selection-change="handleSelectionChange">
|
||||||
|
<el-table-column type="selection" width="55" align="center" />
|
||||||
|
<div >
|
||||||
|
|
||||||
|
</div>
|
||||||
|
<!-- <el-table-column label="编号" align="center" prop="id" />-->
|
||||||
|
<!-- <el-table-column label="id" align="center" prop="dynamicDataId" />-->
|
||||||
|
<!-- <el-table-column v-for="item in collectLink" :label="item.map" align="center" :prop="item" />-->
|
||||||
|
<template v-for="item in Object.keys(collectLink[0])">
|
||||||
|
<el-table-column :label="item">
|
||||||
|
<template #default="scope">
|
||||||
|
<span>{{scope.row[item]}}</span>
|
||||||
|
</template>
|
||||||
|
</el-table-column>
|
||||||
|
</template>
|
||||||
|
</el-table>
|
||||||
|
</el-dialog>
|
||||||
|
</div>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<script>
|
||||||
|
import * as ArticleCategoryApi from "@/api/mall/promotion/intelligent";
|
||||||
|
export default {
|
||||||
|
name: "Business",
|
||||||
|
dicts: ['stage_type', 'sales_stage'],
|
||||||
|
data() {
|
||||||
|
return {
|
||||||
|
id: '',
|
||||||
|
inputarr:[''],
|
||||||
|
// 遮罩层
|
||||||
|
loading: true,
|
||||||
|
// 选中数组
|
||||||
|
ids: [],
|
||||||
|
// 非单个禁用
|
||||||
|
single: true,
|
||||||
|
// 非多个禁用
|
||||||
|
multiple: true,
|
||||||
|
// 显示搜索条件
|
||||||
|
showSearch: true,
|
||||||
|
// 总条数
|
||||||
|
total: 0,
|
||||||
|
// 弹出层标题
|
||||||
|
title: "",
|
||||||
|
//推广弹出框标题
|
||||||
|
extendTitle: "",
|
||||||
|
//采集数据列表弹出标题
|
||||||
|
collectTitle: "",
|
||||||
|
// 是否显示弹出层
|
||||||
|
open: false,
|
||||||
|
// 是否显示推广弹出层
|
||||||
|
extendOpen: false,
|
||||||
|
//是否显示采集数据列表弹出层
|
||||||
|
collectOpen: false,
|
||||||
|
//推广链接数据
|
||||||
|
extendLink: '',
|
||||||
|
//采集数据列表数据
|
||||||
|
collectLink: [{}],
|
||||||
|
//下拉框客户列表
|
||||||
|
customerList: [],
|
||||||
|
//卡片列表
|
||||||
|
cardList: [],
|
||||||
|
addParams: {
|
||||||
|
title:'',
|
||||||
|
pageView:'',
|
||||||
|
collectionQuantity:'',
|
||||||
|
inputarr: []
|
||||||
|
}
|
||||||
|
};
|
||||||
|
},
|
||||||
|
created() {
|
||||||
|
this.getIntelligentList();
|
||||||
|
},
|
||||||
|
methods: {
|
||||||
|
//添加表单
|
||||||
|
adinput(){
|
||||||
|
this.inputarr.push('')
|
||||||
|
console.log(this.inputarr)
|
||||||
|
},
|
||||||
|
getIntelligentList() {
|
||||||
|
this.loading = true;
|
||||||
|
ArticleCategoryApi.selectDynamicData().then(response => {
|
||||||
|
this.cardList = response.data;
|
||||||
|
// this.total = response.total;
|
||||||
|
this.loading = false;
|
||||||
|
});
|
||||||
|
},
|
||||||
|
// 取消按钮
|
||||||
|
cancel() {
|
||||||
|
this.open = false;
|
||||||
|
},
|
||||||
|
//提交按钮
|
||||||
|
submitForm(){
|
||||||
|
this.addParams.inputarr = this.inputarr
|
||||||
|
this.addParams.pageView = '0'
|
||||||
|
this.addParams.collectionQuantity = '0'
|
||||||
|
ArticleCategoryApi.saveDynamicData(this.addParams).then(response => {
|
||||||
|
// this.cardList = response.data;
|
||||||
|
// this.total = response.total;
|
||||||
|
this.loading = false;
|
||||||
|
this.open = false;
|
||||||
|
this.getIntelligentList();
|
||||||
|
});
|
||||||
|
},
|
||||||
|
/** 新增按钮操作 */
|
||||||
|
handleAdd() {
|
||||||
|
this.inputarr = []
|
||||||
|
this.addParams = {
|
||||||
|
title:'',
|
||||||
|
inputarr: []
|
||||||
|
}
|
||||||
|
this.open = true;
|
||||||
|
this.title = "添加表单";
|
||||||
|
},
|
||||||
|
//推广按钮操作
|
||||||
|
handelExtend(id) {
|
||||||
|
this.extendLink = 'http://101.43.112.107/form/extendLink/form?id='+id
|
||||||
|
this.extendOpen = true;
|
||||||
|
this.extendTitle = "推广链接";
|
||||||
|
},
|
||||||
|
//复制按钮操作
|
||||||
|
copyAddress() {
|
||||||
|
const input = document.createElement('input');
|
||||||
|
input.value = this.extendLink;
|
||||||
|
document.body.appendChild(input);
|
||||||
|
input.select();
|
||||||
|
document.execCommand('copy');
|
||||||
|
document.body.removeChild(input);
|
||||||
|
alert('已复制到剪贴板');
|
||||||
|
},
|
||||||
|
//采集数据展示
|
||||||
|
extendList(id){
|
||||||
|
this.collectLink = null;
|
||||||
|
this.id = id
|
||||||
|
this.collectOpen = true;
|
||||||
|
this.collectTitle = "采集数据";
|
||||||
|
ArticleCategoryApi.collectDataList(this.id).then(response => {
|
||||||
|
this.collectLink = response.data
|
||||||
|
});
|
||||||
|
},
|
||||||
|
// 多选框选中数据
|
||||||
|
handleSelectionChange(selection) {
|
||||||
|
this.ids = selection.map(item => item.id)
|
||||||
|
this.single = selection.length!==1
|
||||||
|
this.multiple = !selection.length
|
||||||
|
},
|
||||||
|
},
|
||||||
|
};
|
||||||
|
</script>
|
||||||
|
<style scoped>
|
||||||
|
|
||||||
|
.clearfix:before,
|
||||||
|
.clearfix:after {
|
||||||
|
display: table;
|
||||||
|
content: "";
|
||||||
|
}
|
||||||
|
.clearfix:after {
|
||||||
|
clear: both
|
||||||
|
}
|
||||||
|
|
||||||
|
.box-card {
|
||||||
|
width:32%;
|
||||||
|
margin-bottom: 10px;
|
||||||
|
margin-right:10px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.container {
|
||||||
|
display: flex;
|
||||||
|
justify-content: center;
|
||||||
|
align-items: center;
|
||||||
|
height: 100px; /* 可根据需要调整高度 */
|
||||||
|
color: #ccc; /* 灰白色 */
|
||||||
|
}
|
||||||
|
|
||||||
|
.el-input-foot{
|
||||||
|
padding: 20px;
|
||||||
|
padding-top: 10px;
|
||||||
|
text-align: center;
|
||||||
|
box-sizing: border-box;
|
||||||
|
}
|
||||||
|
::v-deep.el-input--medium{
|
||||||
|
width: 80%;
|
||||||
|
}
|
||||||
|
::v-deep.el-input--medium .el-input__inner{
|
||||||
|
border: none;
|
||||||
|
/* border-bottom:1px solid blue; */
|
||||||
|
}
|
||||||
|
</style>
|
@ -73,6 +73,12 @@
|
|||||||
<groupId>cn.iocoder.boot</groupId>
|
<groupId>cn.iocoder.boot</groupId>
|
||||||
<artifactId>yudao-spring-boot-starter-excel</artifactId>
|
<artifactId>yudao-spring-boot-starter-excel</artifactId>
|
||||||
</dependency>
|
</dependency>
|
||||||
|
|
||||||
|
<!--MongoDB依赖-->
|
||||||
|
<dependency>
|
||||||
|
<groupId>org.springframework.boot</groupId>
|
||||||
|
<artifactId>spring-boot-starter-data-mongodb</artifactId>
|
||||||
|
</dependency>
|
||||||
</dependencies>
|
</dependencies>
|
||||||
|
|
||||||
</project>
|
</project>
|
||||||
|
@ -0,0 +1,62 @@
|
|||||||
|
package cn.iocoder.yudao.module.promotion.controller.admin.dynamic;
|
||||||
|
|
||||||
|
import cn.iocoder.yudao.framework.common.pojo.CommonResult;
|
||||||
|
import cn.iocoder.yudao.module.promotion.dal.dataobject.dynamic.DynamicData;
|
||||||
|
import cn.iocoder.yudao.module.promotion.dal.dataobject.dynamic.DynamicForm;
|
||||||
|
import cn.iocoder.yudao.module.promotion.service.dynamic.DynamicDataService;
|
||||||
|
import cn.iocoder.yudao.module.promotion.service.dynamic.DynamicFormService;
|
||||||
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
|
import org.springframework.data.mongodb.core.MongoTemplate;
|
||||||
|
import org.springframework.web.bind.annotation.*;
|
||||||
|
|
||||||
|
import javax.servlet.http.HttpServletRequest;
|
||||||
|
import java.util.ArrayList;
|
||||||
|
import java.util.List;
|
||||||
|
import java.util.Map;
|
||||||
|
import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 智能表单模块
|
||||||
|
*/
|
||||||
|
|
||||||
|
@RestController
|
||||||
|
@RequestMapping("/intelligentForm")
|
||||||
|
public class DynamicDataController {
|
||||||
|
@Autowired
|
||||||
|
private MongoTemplate mongoTemplate;
|
||||||
|
@Autowired
|
||||||
|
private DynamicDataService dynamicDataService;
|
||||||
|
@Autowired
|
||||||
|
private DynamicFormService dynamicFormService;
|
||||||
|
|
||||||
|
//保存数据
|
||||||
|
@PostMapping("/saveDynamicData")
|
||||||
|
public CommonResult<String> saveDynamicData(@RequestBody Map<String, Object> requestData, HttpServletRequest httpServletRequest) {
|
||||||
|
dynamicDataService.doSaveDynamicData(requestData,httpServletRequest);
|
||||||
|
return success("保存成功");
|
||||||
|
}
|
||||||
|
|
||||||
|
//查询全部数据
|
||||||
|
@GetMapping("/selectDynamicData")
|
||||||
|
public CommonResult<List<DynamicData>> selectDynamicData(HttpServletRequest httpServletRequest) {
|
||||||
|
return success(dynamicDataService.doSelectDynamicData(httpServletRequest));
|
||||||
|
}
|
||||||
|
//根据id查询数据
|
||||||
|
@GetMapping("/selectDynamicDataById")
|
||||||
|
public CommonResult<DynamicData> selectDynamicDataById(String id){
|
||||||
|
return success(dynamicDataService.doSelectDynamicDataById(id));
|
||||||
|
}
|
||||||
|
|
||||||
|
//采集数据
|
||||||
|
@PostMapping("/collectData")
|
||||||
|
public CommonResult<String> collectData(@RequestBody DynamicForm dynamicForm){
|
||||||
|
dynamicFormService.doCollectData(dynamicForm);
|
||||||
|
return success("保存成功");
|
||||||
|
}
|
||||||
|
//根据卡片id查询对应采集数据的列表
|
||||||
|
@GetMapping("/collectDataList")
|
||||||
|
public CommonResult<ArrayList<Object>> collectDataList(String id){
|
||||||
|
return success(dynamicFormService.doCollectDataList(id));
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
@ -0,0 +1,27 @@
|
|||||||
|
package cn.iocoder.yudao.module.promotion.dal.dataobject.dynamic;
|
||||||
|
|
||||||
|
import lombok.Data;
|
||||||
|
import org.springframework.data.annotation.Id;
|
||||||
|
import org.springframework.data.mongodb.core.mapping.Document;
|
||||||
|
|
||||||
|
import java.util.Map;
|
||||||
|
|
||||||
|
@Document(collection = "dynamicData")
|
||||||
|
@Data
|
||||||
|
public class DynamicData {
|
||||||
|
@Id
|
||||||
|
private String id;
|
||||||
|
private String title;
|
||||||
|
//总浏览量
|
||||||
|
private String pageView;
|
||||||
|
//采集数量
|
||||||
|
private String collectionQuantity;
|
||||||
|
//创建者
|
||||||
|
private String createPeople;
|
||||||
|
//创建时间
|
||||||
|
private String createTime;
|
||||||
|
//租户名称
|
||||||
|
private String tenantName;
|
||||||
|
//用户字段数据
|
||||||
|
private Map<String, Object> data;
|
||||||
|
}
|
@ -0,0 +1,16 @@
|
|||||||
|
package cn.iocoder.yudao.module.promotion.dal.dataobject.dynamic;
|
||||||
|
|
||||||
|
import lombok.Data;
|
||||||
|
import org.springframework.data.annotation.Id;
|
||||||
|
|
||||||
|
import java.util.Map;
|
||||||
|
|
||||||
|
@Data
|
||||||
|
public class DynamicForm {
|
||||||
|
@Id
|
||||||
|
private String id;
|
||||||
|
//关联后台智能表单id
|
||||||
|
private String dynamicDataId;
|
||||||
|
//采集数据
|
||||||
|
private Map<String,Object> map;
|
||||||
|
}
|
@ -0,0 +1,18 @@
|
|||||||
|
package cn.iocoder.yudao.module.promotion.dal.mysql.repository;
|
||||||
|
|
||||||
|
import cn.iocoder.yudao.module.promotion.dal.dataobject.dynamic.DynamicData;
|
||||||
|
import org.apache.ibatis.annotations.Mapper;
|
||||||
|
import org.bson.types.ObjectId;
|
||||||
|
import org.springframework.data.mongodb.repository.MongoRepository;
|
||||||
|
import org.springframework.data.mongodb.repository.Query;
|
||||||
|
import org.springframework.stereotype.Repository;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
//@Repository
|
||||||
|
@Mapper
|
||||||
|
public interface DynamicDataRepository extends MongoRepository<DynamicData,String> {
|
||||||
|
List<DynamicData> findByTenantName(String tenantName);
|
||||||
|
@Query("{'_id': {'$eq': ?0}}")
|
||||||
|
DynamicData doFindById(ObjectId id);
|
||||||
|
}
|
@ -0,0 +1,15 @@
|
|||||||
|
package cn.iocoder.yudao.module.promotion.dal.mysql.repository;
|
||||||
|
|
||||||
|
import cn.iocoder.yudao.module.promotion.dal.dataobject.dynamic.DynamicForm;
|
||||||
|
import org.apache.ibatis.annotations.Mapper;
|
||||||
|
import org.springframework.data.mongodb.repository.MongoRepository;
|
||||||
|
import org.springframework.stereotype.Repository;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
//@Repository
|
||||||
|
@Mapper
|
||||||
|
public interface DynamicFormRepository extends MongoRepository<DynamicForm,String> {
|
||||||
|
Long countAllByDynamicDataId(String dynamicDataId);
|
||||||
|
List<DynamicForm> findByDynamicDataId(String id);
|
||||||
|
}
|
@ -0,0 +1,74 @@
|
|||||||
|
package cn.iocoder.yudao.module.promotion.service.dynamic;
|
||||||
|
|
||||||
|
import cn.iocoder.yudao.module.promotion.dal.dataobject.dynamic.DynamicData;
|
||||||
|
import cn.iocoder.yudao.module.promotion.dal.mysql.repository.DynamicDataRepository;
|
||||||
|
import cn.iocoder.yudao.module.promotion.dal.mysql.repository.DynamicFormRepository;
|
||||||
|
import org.bson.types.ObjectId;
|
||||||
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
|
import org.springframework.stereotype.Service;
|
||||||
|
|
||||||
|
import javax.servlet.http.HttpServletRequest;
|
||||||
|
import java.time.LocalDate;
|
||||||
|
import java.time.format.DateTimeFormatter;
|
||||||
|
import java.util.ArrayList;
|
||||||
|
import java.util.List;
|
||||||
|
import java.util.Map;
|
||||||
|
import static cn.iocoder.yudao.framework.web.core.util.WebFrameworkUtils.getLoginUserId;
|
||||||
|
|
||||||
|
|
||||||
|
@Service
|
||||||
|
public class DynamicDataService {
|
||||||
|
@Autowired
|
||||||
|
private DynamicDataRepository dynamicDataRepository;
|
||||||
|
@Autowired
|
||||||
|
private DynamicFormRepository dynamicFormRepository;
|
||||||
|
|
||||||
|
//保存数据
|
||||||
|
public DynamicData doSaveDynamicData(Map<String, Object> requestData, HttpServletRequest httpServletRequest){
|
||||||
|
DynamicData dynamicData = new DynamicData();
|
||||||
|
//构造数据结构
|
||||||
|
String title = (String)requestData.get("title");
|
||||||
|
String pageView = (String)requestData.get("pageView");
|
||||||
|
String collectionQuantity = (String)requestData.get("collectionQuantity");
|
||||||
|
dynamicData.setTitle(title);
|
||||||
|
requestData.remove("title");
|
||||||
|
dynamicData.setPageView(pageView);
|
||||||
|
requestData.remove("pageView");
|
||||||
|
dynamicData.setCollectionQuantity(collectionQuantity);
|
||||||
|
requestData.remove("collectionQuantity");
|
||||||
|
ArrayList<String> inputarr = (ArrayList)requestData.get("inputarr");
|
||||||
|
for (String s : inputarr) {
|
||||||
|
requestData.put(s,null);
|
||||||
|
}
|
||||||
|
requestData.remove("inputarr");
|
||||||
|
dynamicData.setCreatePeople(getLoginUserId(httpServletRequest).toString());
|
||||||
|
LocalDate currentDate = LocalDate.now();
|
||||||
|
DateTimeFormatter formatter = DateTimeFormatter.ofPattern("yyyy-MM-dd");
|
||||||
|
String formattedDate = currentDate.format(formatter);
|
||||||
|
dynamicData.setCreateTime(formattedDate);
|
||||||
|
dynamicData.setData(requestData);
|
||||||
|
dynamicData.setTenantName(httpServletRequest.getHeader("Tenant"));
|
||||||
|
return dynamicDataRepository.save(dynamicData);//插入dynamicData数据
|
||||||
|
}
|
||||||
|
|
||||||
|
//查询全部数据
|
||||||
|
public List<DynamicData> doSelectDynamicData(HttpServletRequest httpServletRequest){
|
||||||
|
//查询对应租户下的卡片列表数据
|
||||||
|
List<DynamicData> dynamicData = dynamicDataRepository.findByTenantName(httpServletRequest.getHeader("Tenant"));
|
||||||
|
for (DynamicData dynamicDatum : dynamicData) {
|
||||||
|
//查询对应卡片链接采集到数据的数量
|
||||||
|
Long count = dynamicFormRepository.countAllByDynamicDataId(dynamicDatum.getId());
|
||||||
|
dynamicDatum.setCollectionQuantity(count+"");
|
||||||
|
}
|
||||||
|
return dynamicData;
|
||||||
|
}
|
||||||
|
|
||||||
|
//根据id查询数据
|
||||||
|
public DynamicData doSelectDynamicDataById(String id){
|
||||||
|
ObjectId objectId = new ObjectId(id);
|
||||||
|
DynamicData dynamicData = dynamicDataRepository.doFindById(objectId);
|
||||||
|
dynamicData.setPageView(Long.parseLong(dynamicData.getPageView())+1+"");
|
||||||
|
return dynamicDataRepository.save(dynamicData);
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
@ -0,0 +1,36 @@
|
|||||||
|
package cn.iocoder.yudao.module.promotion.service.dynamic;
|
||||||
|
|
||||||
|
import cn.iocoder.yudao.module.promotion.dal.dataobject.dynamic.DynamicForm;
|
||||||
|
import cn.iocoder.yudao.module.promotion.dal.mysql.repository.DynamicFormRepository;
|
||||||
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
|
import org.springframework.stereotype.Service;
|
||||||
|
|
||||||
|
import java.util.ArrayList;
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
@Service
|
||||||
|
public class DynamicFormService {
|
||||||
|
@Autowired
|
||||||
|
private DynamicFormRepository dynamicFormRepository;
|
||||||
|
|
||||||
|
//查询对应卡片采集数据的数量
|
||||||
|
public Long findDynamicFormToCount(String id){
|
||||||
|
return dynamicFormRepository.countAllByDynamicDataId(id);
|
||||||
|
}
|
||||||
|
|
||||||
|
//采集数据
|
||||||
|
public void doCollectData(DynamicForm dynamicForm){
|
||||||
|
dynamicFormRepository.save(dynamicForm);
|
||||||
|
}
|
||||||
|
|
||||||
|
//根据卡片id查询对应采集数据的列表
|
||||||
|
public ArrayList<Object> doCollectDataList(String id){
|
||||||
|
List<DynamicForm> dynamicForms = dynamicFormRepository.findByDynamicDataId(id);
|
||||||
|
ArrayList<Object> list = new ArrayList<>();
|
||||||
|
for (DynamicForm dynamicForm : dynamicForms) {
|
||||||
|
list.add(dynamicForm.getMap());
|
||||||
|
}
|
||||||
|
return list;
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
@ -14,12 +14,15 @@ import io.swagger.v3.oas.annotations.Operation;
|
|||||||
import io.swagger.v3.oas.annotations.tags.Tag;
|
import io.swagger.v3.oas.annotations.tags.Tag;
|
||||||
import org.springframework.validation.annotation.Validated;
|
import org.springframework.validation.annotation.Validated;
|
||||||
import org.springframework.web.bind.annotation.GetMapping;
|
import org.springframework.web.bind.annotation.GetMapping;
|
||||||
|
import org.springframework.web.bind.annotation.PostMapping;
|
||||||
import org.springframework.web.bind.annotation.RequestMapping;
|
import org.springframework.web.bind.annotation.RequestMapping;
|
||||||
import org.springframework.web.bind.annotation.RestController;
|
import org.springframework.web.bind.annotation.RestController;
|
||||||
|
|
||||||
import javax.annotation.Resource;
|
import javax.annotation.Resource;
|
||||||
|
import javax.annotation.security.PermitAll;
|
||||||
import java.util.Comparator;
|
import java.util.Comparator;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
|
import java.util.Map;
|
||||||
|
|
||||||
import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success;
|
import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success;
|
||||||
|
|
||||||
@ -40,11 +43,18 @@ public class AppDeliverExpressController {
|
|||||||
return success(DeliveryExpressConvert.INSTANCE.convertList03(list));
|
return success(DeliveryExpressConvert.INSTANCE.convertList03(list));
|
||||||
}
|
}
|
||||||
|
|
||||||
@GetMapping("/realTimeExpressDeliveryQuery")
|
@PostMapping("/realTimeExpressDeliveryQuery")
|
||||||
@Operation(summary = "实时物流查询")
|
@Operation(summary = "实时物流查询")
|
||||||
public CommonResult<String> realTimeExpressDeliveryQuery(){
|
public CommonResult<String> realTimeExpressDeliveryQuery(){
|
||||||
String deliveryQuery = deliveryExpressService.deliveryQuery();
|
String deliveryQuery = deliveryExpressService.deliveryQuery();
|
||||||
return success(deliveryQuery);
|
return success(deliveryQuery);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@PostMapping("/electronicFaceSheet")
|
||||||
|
@Operation(summary = "电子面单下单")
|
||||||
|
public CommonResult<String> electronicFaceSheetOrder(){
|
||||||
|
String sheetOrder = deliveryExpressService.doElectronicFaceSheetOrder();
|
||||||
|
return success(sheetOrder);
|
||||||
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
@ -0,0 +1,12 @@
|
|||||||
|
package cn.iocoder.yudao.module.trade.controller.app.delivery.vo.express;
|
||||||
|
|
||||||
|
import lombok.Data;
|
||||||
|
|
||||||
|
@Data
|
||||||
|
public class ElectronicFaceSheet {
|
||||||
|
private String method;//业务类型(默认:order)
|
||||||
|
private String key;//授权码,请到快递100页面申请企业版接口获取
|
||||||
|
private String sign;//32位大写,签名,用于验证身份,按MD5 (param +t+key+ secret)的顺序进行MD5加密,不需要加上“+”号,secret在企业管理后台获取
|
||||||
|
private String t;//时间戳如:1576123932000
|
||||||
|
private ElectronicFaceSheetParam param;// 由其他字段拼接
|
||||||
|
}
|
@ -0,0 +1,30 @@
|
|||||||
|
package cn.iocoder.yudao.module.trade.controller.app.delivery.vo.express;
|
||||||
|
|
||||||
|
import lombok.Data;
|
||||||
|
|
||||||
|
@Data
|
||||||
|
public class ElectronicFaceSheetParam {
|
||||||
|
private String printType;//打印类型,NON:只下单不打印(默认); IMAGE:生成图片短链;HTML:生成html短链; CLOUD:使用快递100云打印机打印,使用CLOUD时siid必填
|
||||||
|
private String partnerId;// 电子面单客户账户或月结账号,需贵司向当地快递公司网点申请(参考电子面单申请指南); 是否必填该属性,请查看参数字典
|
||||||
|
private String partnerKey;//电子面单密码,需贵司向当地快递公司网点申请; 是否必填该属性,请查看参数字典
|
||||||
|
private String partnerSecret;//电子面单密钥,需贵司向当地快递公司网点申请; 是否必填该属性,请查看参数字典
|
||||||
|
private String partnerName;// 电子面单客户账户名称,需贵司向当地快递公司网点申请; 是否必填该属性,请查看参数字典
|
||||||
|
private String net;//收件网点名称,由快递公司当地网点分配, 若使用淘宝授权填入(taobao),使用菜鸟授权填入(cainiao), 使用京东授权填入(jdalpha),使用拼多多授权填入(pinduoduoWx),使用抖音授权填入(douyin),使用快手授权填入(kuaishou),使用唯品会授权填入(weipinhui),使用视频号授权填入(wechatChannels),使用小红书授权填入(xiaohongshu)。 是否必填该属性,请查看参数字典 (若通过第三方授权方式获取单号partnerId,partnerKey参数为必填,参数值可通过第三方授权接口获取)
|
||||||
|
private String code;//电子面单承载编号,需贵司向当地快递公司网点申请; 是否必填该属性,请查看参数字典
|
||||||
|
private String checkMan;//电子面单承载快递员名,需贵司向当地快递公司网点申请; 是否必填该属性,请查看参数字典
|
||||||
|
private String tbNet;// 在使用菜鸟/淘宝/拼多多授权电子面单时,若月结账号下存在多个网点,则tbNet="网点名称,网点编号" ,注意此处为英文逗号
|
||||||
|
private String kuaidicom;//快递公司的编码,一律用小写字母,请查看参数字典
|
||||||
|
private RecManVo recMan;//收件人信息
|
||||||
|
private SendManVo sendMan;//寄件人信息
|
||||||
|
private String cargo;//物品名称,例:文件
|
||||||
|
private Integer count;//包裹总数量。该属性与子单有关,如果需要子单(指同一个订单打印出多张电子面单,即同一个订单返回多个面单号),needChild = 1、count 需要大于1,如count = 2 则一个主单 一个子单,count = 3则一个主单 二个子单;返回的子单号码见返回结果的childNum字段
|
||||||
|
private Double weight;//物品总重量KG,例:1.5,单位kg。极兔速递必填,其他快递公司非必填
|
||||||
|
private String payType;//支付方式: SHIPPER:寄方付(默认) CONSIGNEE:到付 MONTHLY:月结 THIRDPARTY:第三方支付 (详细请查看参数字典 )
|
||||||
|
private String expType;//产品类型: 如标准快递(默认) 顺丰标快(陆运) EMS经济 (详细请请查看参数字典 )
|
||||||
|
private String remark;//备注
|
||||||
|
private String siid;//打印设备,通过打印机输出的设备码进行获取,printType为CLOUD时必填
|
||||||
|
private String direction;//打印方向, 0:正方向(默认); 1:反方向;只有printType为CLOUD时该参数生效
|
||||||
|
private String tempId;//主单模板,通过管理后台的快递公司模板V2信息获取
|
||||||
|
private String childTempId;//子单模板,部分快递公司需指定。通过管理后台的快递公司模板V2信息获取
|
||||||
|
private String backTempId;//回单模板,部分快递公司需指定。通过管理后台的快递公司模板V2信息获取
|
||||||
|
}
|
@ -0,0 +1,12 @@
|
|||||||
|
package cn.iocoder.yudao.module.trade.controller.app.delivery.vo.express;
|
||||||
|
|
||||||
|
import lombok.Data;
|
||||||
|
|
||||||
|
@Data
|
||||||
|
public class RecManVo {
|
||||||
|
private String name;
|
||||||
|
private String mobile;
|
||||||
|
private String tel;
|
||||||
|
private String printAddr;
|
||||||
|
private String company;
|
||||||
|
}
|
@ -0,0 +1,12 @@
|
|||||||
|
package cn.iocoder.yudao.module.trade.controller.app.delivery.vo.express;
|
||||||
|
|
||||||
|
import lombok.Data;
|
||||||
|
|
||||||
|
@Data
|
||||||
|
public class SendManVo {
|
||||||
|
private String name;
|
||||||
|
private String mobile;
|
||||||
|
private String tel;
|
||||||
|
private String printAddr;
|
||||||
|
private String company;
|
||||||
|
}
|
@ -82,4 +82,6 @@ public interface DeliveryExpressService {
|
|||||||
|
|
||||||
String deliveryQuery();
|
String deliveryQuery();
|
||||||
|
|
||||||
|
String doElectronicFaceSheetOrder();
|
||||||
|
|
||||||
}
|
}
|
||||||
|
@ -9,6 +9,8 @@ import cn.iocoder.yudao.module.trade.controller.admin.delivery.vo.express.Delive
|
|||||||
import cn.iocoder.yudao.module.trade.controller.admin.delivery.vo.express.DeliveryExpressExportReqVO;
|
import cn.iocoder.yudao.module.trade.controller.admin.delivery.vo.express.DeliveryExpressExportReqVO;
|
||||||
import cn.iocoder.yudao.module.trade.controller.admin.delivery.vo.express.DeliveryExpressPageReqVO;
|
import cn.iocoder.yudao.module.trade.controller.admin.delivery.vo.express.DeliveryExpressPageReqVO;
|
||||||
import cn.iocoder.yudao.module.trade.controller.admin.delivery.vo.express.DeliveryExpressUpdateReqVO;
|
import cn.iocoder.yudao.module.trade.controller.admin.delivery.vo.express.DeliveryExpressUpdateReqVO;
|
||||||
|
import cn.iocoder.yudao.module.trade.controller.app.delivery.vo.express.ElectronicFaceSheet;
|
||||||
|
import cn.iocoder.yudao.module.trade.controller.app.delivery.vo.express.ElectronicFaceSheetParam;
|
||||||
import cn.iocoder.yudao.module.trade.convert.delivery.DeliveryExpressConvert;
|
import cn.iocoder.yudao.module.trade.convert.delivery.DeliveryExpressConvert;
|
||||||
import cn.iocoder.yudao.module.trade.dal.dataobject.delivery.DeliveryExpressDO;
|
import cn.iocoder.yudao.module.trade.dal.dataobject.delivery.DeliveryExpressDO;
|
||||||
import cn.iocoder.yudao.module.trade.dal.mysql.delivery.DeliveryExpressMapper;
|
import cn.iocoder.yudao.module.trade.dal.mysql.delivery.DeliveryExpressMapper;
|
||||||
@ -170,4 +172,23 @@ public class DeliveryExpressServiceImpl implements DeliveryExpressService {
|
|||||||
return postSec.body();
|
return postSec.body();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public String doElectronicFaceSheetOrder() {
|
||||||
|
//快递100 电子面单下单api接口地址
|
||||||
|
String url = "https://api.kuaidi100.com/label/order";
|
||||||
|
ElectronicFaceSheet faceSheet = new ElectronicFaceSheet();
|
||||||
|
faceSheet.setKey("");
|
||||||
|
faceSheet.setMethod("order");
|
||||||
|
faceSheet.setSign("");
|
||||||
|
ElectronicFaceSheetParam sheetParam = new ElectronicFaceSheetParam();
|
||||||
|
sheetParam.setPrintType("NON");
|
||||||
|
sheetParam.setPartnerId("");
|
||||||
|
faceSheet.setParam(sheetParam);
|
||||||
|
HttpResponse postSec = HttpUtil.createPost(url)
|
||||||
|
.header("Content-Type","application/x-www-form-urlencoded")
|
||||||
|
.body(faceSheet.toString())
|
||||||
|
.execute();
|
||||||
|
return postSec.body();
|
||||||
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
@ -0,0 +1,26 @@
|
|||||||
|
package cn.iocoder.yudao.module.trade.doTest;
|
||||||
|
|
||||||
|
import cn.hutool.http.HttpResponse;
|
||||||
|
import cn.hutool.http.HttpUtil;
|
||||||
|
import cn.iocoder.yudao.module.trade.dal.dataobject.delivery.DeliveryExpressDO;
|
||||||
|
import lombok.extern.slf4j.Slf4j;
|
||||||
|
import org.junit.jupiter.api.Test;
|
||||||
|
|
||||||
|
@Slf4j
|
||||||
|
public class DoKDTest {
|
||||||
|
|
||||||
|
@Test
|
||||||
|
public void test(){
|
||||||
|
String url = "http://127.0.0.1:6127/admin-api/trade/delivery/express-template/doTest";
|
||||||
|
DeliveryExpressDO expressDO = new DeliveryExpressDO();
|
||||||
|
expressDO.setCode("134435");
|
||||||
|
expressDO.setLogo("scsdc");
|
||||||
|
expressDO.setName("jjjj");
|
||||||
|
HttpResponse postSec = HttpUtil.createPost(url)
|
||||||
|
.header("Content-Type","application/x-www-form-urlencoded")
|
||||||
|
.header("tenant-id","1")
|
||||||
|
.body(expressDO.toString())
|
||||||
|
.execute();
|
||||||
|
System.out.println(postSec.body());
|
||||||
|
}
|
||||||
|
}
|
@ -6,6 +6,7 @@ import cn.iocoder.yudao.module.pay.dal.dataobject.app.PayAppDO;
|
|||||||
import cn.iocoder.yudao.module.pay.dal.dataobject.channel.PayChannelDO;
|
import cn.iocoder.yudao.module.pay.dal.dataobject.channel.PayChannelDO;
|
||||||
import cn.iocoder.yudao.module.pay.enums.order.PayOrderStatusEnum;
|
import cn.iocoder.yudao.module.pay.enums.order.PayOrderStatusEnum;
|
||||||
import com.baomidou.mybatisplus.annotation.KeySequence;
|
import com.baomidou.mybatisplus.annotation.KeySequence;
|
||||||
|
import com.baomidou.mybatisplus.annotation.TableId;
|
||||||
import com.baomidou.mybatisplus.annotation.TableName;
|
import com.baomidou.mybatisplus.annotation.TableName;
|
||||||
import lombok.*;
|
import lombok.*;
|
||||||
|
|
||||||
@ -29,6 +30,7 @@ public class PayOrderDO extends BaseDO {
|
|||||||
/**
|
/**
|
||||||
* 订单编号,数据库自增
|
* 订单编号,数据库自增
|
||||||
*/
|
*/
|
||||||
|
@TableId
|
||||||
private Long id;
|
private Long id;
|
||||||
/**
|
/**
|
||||||
* 应用编号
|
* 应用编号
|
||||||
|
@ -47,7 +47,7 @@ public class PayWalletRechargeServiceImpl implements PayWalletRechargeService {
|
|||||||
/**
|
/**
|
||||||
* TODO 芋艿:放到 payconfig
|
* TODO 芋艿:放到 payconfig
|
||||||
*/
|
*/
|
||||||
private static final Long WALLET_PAY_APP_ID = 8L;
|
private static final Long WALLET_PAY_APP_ID = 1L;
|
||||||
|
|
||||||
private static final String WALLET_RECHARGE_ORDER_SUBJECT = "钱包余额充值";
|
private static final String WALLET_RECHARGE_ORDER_SUBJECT = "钱包余额充值";
|
||||||
|
|
||||||
@ -84,7 +84,7 @@ public class PayWalletRechargeServiceImpl implements PayWalletRechargeService {
|
|||||||
// 2.1 创建支付单
|
// 2.1 创建支付单
|
||||||
Long payOrderId = payOrderService.createOrder(new PayOrderCreateReqDTO()
|
Long payOrderId = payOrderService.createOrder(new PayOrderCreateReqDTO()
|
||||||
.setAppId(WALLET_PAY_APP_ID).setUserIp(userIp)
|
.setAppId(WALLET_PAY_APP_ID).setUserIp(userIp)
|
||||||
.setMerchantOrderId(recharge.getId().toString()) // 业务的订单编号
|
.setMerchantOrderId(""+recharge.getId()) // 业务的订单编号
|
||||||
.setSubject(WALLET_RECHARGE_ORDER_SUBJECT).setBody("")
|
.setSubject(WALLET_RECHARGE_ORDER_SUBJECT).setBody("")
|
||||||
.setPrice(recharge.getPayPrice())
|
.setPrice(recharge.getPayPrice())
|
||||||
.setExpireTime(addTime(Duration.ofHours(2L)))); // TODO @芋艿:支付超时时间
|
.setExpireTime(addTime(Duration.ofHours(2L)))); // TODO @芋艿:支付超时时间
|
||||||
|
@ -82,7 +82,7 @@ public class WarningJob implements JobHandler {
|
|||||||
OperateWarningDO spaceWarningDO = new OperateWarningDO();
|
OperateWarningDO spaceWarningDO = new OperateWarningDO();
|
||||||
spaceWarningDO.setAlarmPolicy("磁盘告警策略");
|
spaceWarningDO.setAlarmPolicy("磁盘告警策略");
|
||||||
spaceWarningDO.setMonitoringObject("磁盘");
|
spaceWarningDO.setMonitoringObject("磁盘");
|
||||||
spaceWarningDO.setTriggeringCondition("当磁盘占用率达到"+Double.parseDouble(configCountProcessCPUDo.getLabel())*100+"%");
|
spaceWarningDO.setTriggeringCondition("当磁盘占用率达到"+Double.parseDouble(configCountDo.getLabel())*100+"%");
|
||||||
operateWarningMapper.insert(spaceWarningDO);
|
operateWarningMapper.insert(spaceWarningDO);
|
||||||
}
|
}
|
||||||
} catch (Exception e) {
|
} catch (Exception e) {
|
||||||
|
@ -47,7 +47,7 @@ spring:
|
|||||||
datasource:
|
datasource:
|
||||||
master:
|
master:
|
||||||
name: ruoyi-vue-pro
|
name: ruoyi-vue-pro
|
||||||
url: jdbc:mysql://120.46.37.243:3306/${spring.datasource.dynamic.datasource.master.name}?useSSL=false&serverTimezone=Asia/Shanghai&allowPublicKeyRetrieval=true&nullCatalogMeansCurrent=true # MySQL Connector/J 8.X 连接的示例
|
url: jdbc:mysql://1.14.205.126:3306/${spring.datasource.dynamic.datasource.master.name}?useSSL=false&serverTimezone=Asia/Shanghai&allowPublicKeyRetrieval=true&nullCatalogMeansCurrent=true # MySQL Connector/J 8.X 连接的示例
|
||||||
# url: jdbc:mysql://127.0.0.1:3306/${spring.datasource.dynamic.datasource.master.name}?useSSL=false&serverTimezone=Asia/Shanghai&allowPublicKeyRetrieval=true&nullCatalogMeansCurrent=true # MySQL Connector/J 8.X 连接的示例
|
# url: jdbc:mysql://127.0.0.1:3306/${spring.datasource.dynamic.datasource.master.name}?useSSL=false&serverTimezone=Asia/Shanghai&allowPublicKeyRetrieval=true&nullCatalogMeansCurrent=true # MySQL Connector/J 8.X 连接的示例
|
||||||
# url: jdbc:mysql://127.0.0.1:3306/ruoyi-vue-pro?useSSL=true&allowPublicKeyRetrieval=true&useUnicode=true&characterEncoding=UTF-8&serverTimezone=Asia/Shanghai # MySQL Connector/J 5.X 连接的示例
|
# url: jdbc:mysql://127.0.0.1:3306/ruoyi-vue-pro?useSSL=true&allowPublicKeyRetrieval=true&useUnicode=true&characterEncoding=UTF-8&serverTimezone=Asia/Shanghai # MySQL Connector/J 5.X 连接的示例
|
||||||
# url: jdbc:postgresql://127.0.0.1:5432/ruoyi-vue-pro # PostgreSQL 连接的示例
|
# url: jdbc:postgresql://127.0.0.1:5432/ruoyi-vue-pro # PostgreSQL 连接的示例
|
||||||
@ -73,7 +73,8 @@ spring:
|
|||||||
|
|
||||||
# Redis 配置。Redisson 默认的配置足够使用,一般不需要进行调优
|
# Redis 配置。Redisson 默认的配置足够使用,一般不需要进行调优
|
||||||
redis:
|
redis:
|
||||||
host: 120.46.37.243 # 地址
|
host: 1.14.205.126 # 地址
|
||||||
|
# host: 120.46.37.243 # 地址
|
||||||
# host: 124.70.1.134 # 地址
|
# host: 124.70.1.134 # 地址
|
||||||
# host: 127.0.0.1 # 地址
|
# host: 127.0.0.1 # 地址
|
||||||
port: 6379 # 端口
|
port: 6379 # 端口
|
||||||
@ -256,3 +257,12 @@ justauth:
|
|||||||
prefix: 'social_auth_state:' # 缓存前缀,目前只对 Redis 缓存生效,默认 JUSTAUTH::STATE::
|
prefix: 'social_auth_state:' # 缓存前缀,目前只对 Redis 缓存生效,默认 JUSTAUTH::STATE::
|
||||||
timeout: 24h # 超时时长,目前只对 Redis 缓存生效,默认 3 分钟
|
timeout: 24h # 超时时长,目前只对 Redis 缓存生效,默认 3 分钟
|
||||||
|
|
||||||
|
spring:
|
||||||
|
data:
|
||||||
|
mongodb:
|
||||||
|
uri: mongodb://root:123456@120.46.37.243:27017/admin?authMechanism=SCRAM-SHA-256
|
||||||
|
# uri: mongodb://root:123456@101.43.112.107:27017/admin?authMechanism=SCRAM-SHA-256
|
||||||
|
database: zy-crm
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user