xlb-main-login
Version:
``` yarn install ```
206 lines (186 loc) • 4.58 kB
JavaScript
import { wechat_url, wei_url } from './config'
import { axios } from '@/utils/request'
const baseUrl = '/demo-wechat-work/v1/wechat/work/'
const baseActivity = '/wecom-inner'
//欢迎语列表
export function getgreetlist(params, type) {
return axios({
url: wechat_url + '/v1/wechat/work/source/' + type,
method: 'get',
params,
})
}
export function packetinfo(params, type) {
return axios({
url: wechat_url + '/v1/wechat/work/source/' + type,
method: 'get',
params,
})
}
//企业红包列表
export function getRedpacklist(params) {
return axios({
url: wei_url + baseUrl + 'redPacketTool/',
method: 'get',
params,
})
}
//商品列表
export function getCommoditylist(params) {
return axios({
url: wei_url + '/demo-distribution/v1/shop/event/all',
method: 'get',
params,
})
}
//商品列表详情
export function getDetails(id) {
return axios({
url: wei_url + `/demo-distribution/v1/shop/event/all/${id}`,
method: 'get',
})
}
//雷达列表
export function radarlist(params) {
return axios({
url: wei_url + '/demo-wechat-work/v1/wechat/work/radar/',
method: 'get',
params,
})
}
//表单列表
export function getFormlist(params, type) {
return axios({
url: wechat_url + '/v1/wechat/work/form/',
method: 'get',
params,
})
}
//删除语列表
export function delgreetlist(type, id) {
return axios({
url: wechat_url + '/v1/wechat/work/source/' + type + '/' + id,
method: 'delete',
})
}
//新增欢迎语列表
export function addgreet(data, type) {
return axios({
headers: { 'Content-Type': 'application/json;charset=UTF-8' },
url: wechat_url + '/v1/wechat/work/source/' + type,
method: 'post',
data,
})
}
//编辑欢迎语列表
export function uploadgreet(data, type) {
return axios({
headers: { 'Content-Type': 'application/json;charset=UTF-8' },
url: wechat_url + '/v1/wechat/work/source/' + type,
method: 'put',
data,
})
}
//查询欢迎语列表
export function greetdetail(type, id) {
return axios({
url: wechat_url + '/v1/wechat/work/source/' + type + '/' + id,
method: 'get',
})
}
//查询部门列表树形图
export function getdepart() {
return axios({
url: wechat_url + '/v1/wechat/work/depart',
method: 'get',
})
}
//查询员工列表
export function getmember() {
return axios({
url: wechat_url + '/v1/wechat/work/staff',
method: 'get',
})
}
//查询单个数据二维码
export function getmemberqr(type, id) {
return axios({
url: wechat_url + '/v1/wechat/work/source/' + type + '/' + id + '/img',
method: 'get',
})
}
//下载渠道码
export function downsDitch(type, id) {
return axios({
url: wechat_url + '/v1/wechat/work/source/' + type + '/' + id + '/img',
method: 'get',
})
}
/*企业微信渠道码*/
/*企业微信标签进群*/
export function gettaglist(params) {
return axios({
url: wechat_url + '/v1/wechat/work/tag-build-group',
method: 'get',
params,
})
}
//删除标签进群
export function deltaglist(id) {
return axios({
url: wechat_url + '/v1/wechat/work/tag-build-group/' + id,
method: 'delete',
})
}
//标签进群详情
export function grouptagdetail(id) {
return axios({
url: wechat_url + '/v1/wechat/work/tag-build-group/' + id,
method: 'get',
})
}
//查找人数
export function grouptagchange(params) {
return axios({
url: wechat_url + '/v1/wechat/work/tag-build-group/objUserCount',
method: 'get',
params,
})
}
//新增标签进群
export function grouptagadd(data) {
return axios({
headers: { 'Content-Type': 'application/json;charset=UTF-8' },
url: wechat_url + '/v1/wechat/work/tag-build-group',
method: 'post',
data,
})
}
//编辑标签进群
export function grouptagedit(data) {
return axios({
url: wechat_url + '/v1/wechat/work/tag-build-group',
method: 'put',
data,
})
}
//发送标签进群消息
export function sendgrouptag(id) {
return axios({
url: wechat_url + '/v1/wechat/work/tag-build-group/sendMessage/' + id,
method: 'post',
})
}
/*企业微信标签进群*/
//欢迎语列表
export function getLeave(type = 3) {
const params = {
current: 1,
size: 1,
}
return axios({
url: wechat_url + '/v1/wechat/work/source/' + type,
method: 'get',
params,
})
}