修改接口

master
username 10 months ago
parent 2292604da0
commit ca5cb4629a

@ -135,6 +135,9 @@ public class DfBizClueController extends BaseController {
} else if ("2".equals(dfBizClue.getClassify())) {
queryWrapper.in(DfBizClue::getDataType, "1");
}
if (Validator.isNotEmpty(dfBizClue.getBusinessLinks())) {
queryWrapper.eq(DfBizClue::getBusinessLinks, dfBizClue.getBusinessLinks());
}
List<DfBizClue> list = dfBizClueService.list(queryWrapper);
List<DfBizClue> uniqueList = list.stream()
.collect(Collectors.toMap(

@ -182,7 +182,7 @@ public class DfOrderController extends BaseController {
dfOrder.setCreateTimeVo(date);
SecurityUtils.getTenantId();
dfOrder.setTenantId(SecurityUtils.getTenantId());
dfOrder.setCreateBy(SecurityUtils.getUserId());
// dfOrder.setCreateBy(SecurityUtils.getUserId());
dfOrder.setCreateDept(SecurityUtils.getDeptId());
return toAjax(dfOrderMapper.insertOrder(dfOrder));
}

@ -1,8 +1,12 @@
package com.bs.df.controller;
import java.util.List;
import java.util.Map;
import javax.servlet.http.HttpServletResponse;
import com.bs.common.annotation.Anonymous;
import com.bs.common.core.domain.model.LoginBody;
import com.bs.web.utils.WeiXinUtil;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import org.springframework.security.access.prepost.PreAuthorize;
@ -39,7 +43,6 @@ import javax.annotation.Resource;
public class DfUserBrokerController extends BaseController {
@Resource
private IDfUserBrokerService dfUserBrokerService;
/**
*
*/
@ -118,6 +121,7 @@ public class DfUserBrokerController extends BaseController {
return toAjax(dfUserBrokerService.removeBatchByIds(ids));
}
/**
*
*/

@ -382,10 +382,10 @@ public class SysLoginController
*/
@PostMapping("/getConfig")
@Anonymous
public Map<String, String> getConfig(LoginBody loginBody)
public AjaxResult getConfig(@RequestBody LoginBody loginBody)
{
Map<String, String> config = weiXinUtil.getConfig(loginBody.getUrl());
return config;
return AjaxResult.success(config);
}
}

@ -237,7 +237,7 @@ public class SysUserController extends BaseController {
@Anonymous
public AjaxResult getUser(@PathVariable(value = "userId", required = false) Long userId) {
SysUser sysUser = userService.selectUserById(userId);
List<CmAttach> attachVo = cmAttachService.list(new LambdaQueryWrapper<CmAttach>().eq(CmAttach::getFileId, userId));
List<CmAttach> attachVo = cmAttachService.list(new LambdaQueryWrapper<CmAttach>().eq(CmAttach::getFileId, "userId" + userId));
sysUser.setFiles(attachVo);
return success(sysUser);
}

@ -45,19 +45,19 @@ public class SignUtil {
String timestamp = create_timestamp();
String string1;
String signature = "";
//注意这里参数名必须全部小写,且必须有序
string1 = "jsapi_ticket=" + jsapi_ticket +
"&noncestr=" + nonce_str +
"&timestamp=" + timestamp +
"&url=" + url;
System.out.println(string1);
try
{
MessageDigest crypt = MessageDigest.getInstance("SHA-1");
crypt.reset();
crypt.update(string1.getBytes("UTF-8"));
signature = byteToHex(crypt.digest());
System.out.println("signature" + signature);
}
catch (NoSuchAlgorithmException e)
{
@ -67,7 +67,6 @@ public class SignUtil {
{
e.printStackTrace();
}
ret.put("nonceStr", nonce_str);
ret.put("timestamp", timestamp);
ret.put("signature", signature);

@ -42,17 +42,17 @@ public class WeiXinUtil {
private static SimpleDateFormat format = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss");
// 微信小程序appid
//@Value("${wxConfig.appid}")
private static String appid="wx9e514cd1390086a8" ;
private static String appid="wx750df5fec24d61c1" ;
// 微信小程序appsecret
//@Value("${wxConfig.appsecret}")
private static String appsecret="e1e7395c8162f9d97487dae670faee5f";
private static String appsecret="fda079d4713bc3bdd5810ebb54dc7507";
// 微信公众号appid
//@Value("${wxConfig.gzhappid}")
private static String gzhappid="wx328dafbfac1bb1b6";
private static String gzhappid="wxe8539d3b62c9a06c";
// 微信公众号appsecret
//@Value("${wxConfig.gzhappsecret}")
private static String gzhappsecret="Dfjf3333";
private static String gzhappsecret="84f607283501d0177ca7595f709c20ca";
// 微信开放号appid
private static String openAppid = "";
@ -224,6 +224,7 @@ public class WeiXinUtil {
try {
String titcket = getTitcket();
sign = SignUtil.sign(titcket, url);
sign.put("titcket", titcket);
} catch (Exception e) {
e.printStackTrace();
}
@ -543,7 +544,9 @@ public class WeiXinUtil {
// 获取Access_token
public synchronized String getAccess_token(String appid, String appsecret) {
System.out.println("appid:" + appid + ".appsecret:" + appsecret);
String access_token = getSysConfig("access_token");
System.out.println(access_token);
if (StringUtils.isNotEmpty(access_token)){
JSONObject jo = JSONObject.parseObject(access_token);
jo.getString("expirettime");
@ -1024,7 +1027,8 @@ public class WeiXinUtil {
public String getTitcket() throws Exception {
String accessToken = getAccess_token(appid, appsecret);
String accessToken = getAccess_token(gzhappid, gzhappsecret);
System.out.println(accessToken);
String url = "https://api.weixin.qq.com/cgi-bin/ticket/getticket?access_token=" + accessToken + "&type=jsapi";
String returnValue = httpGet(url,null);

@ -103,6 +103,7 @@
plain
size="mini"
@click="shelves"
:disabled="multiple"
v-hasPermi="['article:article:shelves']"
>上架
</el-button>
@ -113,6 +114,7 @@
plain
size="mini"
@click="offShelves"
:disabled="multiple"
v-hasPermi="['article:article:offShelves']"
>下架
</el-button>
@ -268,7 +270,7 @@
<script>
import {pageListArticle, getArticle, delArticle, addArticle, updateArticle,changeStatusByArticle} from "@/api/article/article";
import {changeStatus} from "@/api/product/info";
import {addMoment, updateMoment} from "@/api/moment/moment";
import {addMoment, changeStatusByMoment, updateMoment} from "@/api/moment/moment";
export default {
name: "Article",
@ -346,10 +348,17 @@ export default {
ids: ids,
status: "0"
}
changeStatusByArticle(param).then(response => {
this.$modal.confirm('是否确认下架数据?').then(function () {
return changeStatusByArticle(param)
}).then(() => {
this.getList();
this.$modal.msgSuccess("修改成功");
this.$modal.msgSuccess("下架成功");
}).catch(() => {
});
// changeStatusByArticle(param).then(response => {
// this.getList();
// this.$modal.msgSuccess("");
// });
},
shelves(){
const ids = this.ids;

@ -112,26 +112,26 @@
<el-table-column label="业务链接" align="center" prop="businessLinks" sortable='custom'/>
<el-table-column label="头像链接" align="center" prop="avatarLink" sortable='custom' />
<el-table-column label="手机号" align="center" prop="phone" sortable='custom' />
<el-table-column label="操作" align="center" class-name="small-padding fixed-width">
<template slot-scope="scope">
<el-button
size="mini"
type="text"
icon="el-icon-edit"
@click="handleUpdate(scope.row)"
v-hasPermi="['biz:clue:edit']"
>修改
</el-button>
<el-button
size="mini"
type="text"
icon="el-icon-delete"
@click="handleDelete(scope.row)"
v-hasPermi="['biz:clue:remove']"
>删除
</el-button>
</template>
</el-table-column>
<!-- <el-table-column label="操作" align="center" class-name="small-padding fixed-width">-->
<!-- <template slot-scope="scope">-->
<!-- <el-button-->
<!-- size="mini"-->
<!-- type="text"-->
<!-- icon="el-icon-edit"-->
<!-- @click="handleUpdate(scope.row)"-->
<!-- v-hasPermi="['biz:clue:edit']"-->
<!-- >修改-->
<!-- </el-button>-->
<!-- <el-button-->
<!-- size="mini"-->
<!-- type="text"-->
<!-- icon="el-icon-delete"-->
<!-- @click="handleDelete(scope.row)"-->
<!-- v-hasPermi="['biz:clue:remove']"-->
<!-- >删除-->
<!-- </el-button>-->
<!-- </template>-->
<!-- </el-table-column>-->
</el-table>
<pagination

@ -76,6 +76,7 @@
plain
size="mini"
@click="shelves"
:disabled="multiple"
v-hasPermi="['moment:moment:shelves']"
>上架
</el-button>
@ -86,6 +87,7 @@
plain
size="mini"
@click="offShelves"
:disabled="multiple"
v-hasPermi="['moment:moment:offShelves']"
>下架
</el-button>
@ -292,9 +294,12 @@ export default {
ids: ids,
status: "0"
}
changeStatusByMoment(param).then(response => {
this.$modal.confirm('是否确认下架数据?').then(function () {
return changeStatusByMoment(param)
}).then(() => {
this.getList();
this.$modal.msgSuccess("修改成功");
this.$modal.msgSuccess("下架成功");
}).catch(() => {
});
},
shelves(){

@ -100,6 +100,7 @@
plain
size="mini"
@click="shelves"
:disabled="multiple"
v-hasPermi="['poster:poster:shelves']"
>上架
</el-button>
@ -110,6 +111,7 @@
plain
size="mini"
@click="offShelves"
:disabled="multiple"
v-hasPermi="['poster:poster:offShelves']"
>下架
</el-button>
@ -250,6 +252,7 @@ import {pageListPoster, getPoster, delPoster, addPoster, updatePoster, changeSta
import {changeStatus, listInfo} from "@/api/product/info";
import {uploadFiles, getAttachList} from "@/api/common/file";
import {getToken} from "@/utils/auth";
import {changeStatusByArticle} from "@/api/article/article";
export default {
name: "Poster",
@ -336,10 +339,17 @@ export default {
ids: ids,
status: "0"
}
changeStatusByPoster(param).then(response => {
this.$modal.confirm('是否确认下架数据?').then(function () {
return changeStatusByPoster(param)
}).then(() => {
this.getList();
this.$modal.msgSuccess("修改成功");
this.$modal.msgSuccess("下架成功");
}).catch(() => {
});
// changeStatusByPoster(param).then(response => {
// this.getList();
// this.$modal.msgSuccess("");
// });
},
shelves() {
const ids = this.ids;

@ -167,6 +167,7 @@
plain
size="mini"
@click="shelves"
:disabled="multiple"
v-hasPermi="['product:info:shelves']"
>上架
</el-button>
@ -177,6 +178,7 @@
plain
size="mini"
@click="offShelves"
:disabled="multiple"
v-hasPermi="['product:info:offShelves']"
>下架
</el-button>
@ -427,6 +429,7 @@
<script>
import {pageListInfo, getInfo, delInfo, addInfo, updateInfo, changeStatus, getBrokerNum} from "@/api/product/info";
import {listArea} from "@/api/system/area";
import {changeStatusByPoster} from "@/api/poster/poster";
// import Treeselect from "@riophae/vue-treeselect";
export default {
@ -541,10 +544,17 @@ export default {
ids: ids,
status: "0"
}
changeStatus(param).then(response => {
this.$modal.confirm('是否确认下架数据?').then(function () {
return changeStatus(param)
}).then(() => {
this.getList();
this.$modal.msgSuccess("修改成功");
this.$modal.msgSuccess("下架成功");
}).catch(() => {
});
// changeStatus(param).then(response => {
// this.getList();
// this.$modal.msgSuccess("");
// });
},
shelves(){
const ids = this.ids;

Loading…
Cancel
Save