123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229 |
- import service from '../utils/js/request'
- const taskManage = {
- /**
- * 获取任务列表
- * @param {Object} param
- */
- getTask: function(param) {
- return service({
- url: '/task/mp/page',
- method: 'POST',
- data: param
- })
- },
- /**
- * 建议获取个人任务
- */
- getSuggest: function(data) {
- return service({
- url: "/task/mp/getSuggest",
- method: "get",
- data: data
- })
- },
- /**
- * 添加到今日任务
- * @param {Object} params
- */
- addToday: function(params) {
- return service({
- url: "/task/today/add",
- method: "post",
- data: params
- })
- },
- /**
- * 完结结个人任务
- * @param {Object} params
- */
- taskFinish: function(params) {
- return service({
- url: "/task/persontask/taskfinish",
- method: "post",
- data: params
- })
- },
- /**
- * 反完结个人任务
- * @param {Object} params
- */
- taskUnFinish: function(params) {
- return service({
- url: "/task/persontask/taskunfinish",
- method: "post",
- data: params
- })
- },
- /**
- * 更改个人任务的重要性
- * @param {Object} params
- */
- changeImportant: function(params) {
- return service({
- url: "/task/persontask/changeimportant",
- method: "post",
- data: params
- })
- },
- /**
- * 新增个人任务并添加到今日任务
- * @param {Object} params
- */
- addTodayTask: function(params) {
- return service({
- url: "/task/persontask/addtoday",
- method: "post",
- data: params
- })
- },
- /**
- * 新增个人任务
- * @param {Object} params
- */
- addTask: function(params) {
- return service({
- url: "/task/persontask/add",
- method: "post",
- data: params
- })
- },
- /**
- * 获取任务步骤
- * @param {任务id} taskId
- */
- getTaskStep: function(taskId) {
- return service({
- url: "/task/step/list",
- method: "get",
- data: {
- taskId: taskId
- }
- })
- },
- /**
- * 新增任务步骤
- * @param {任务步骤参数} params
- */
- addStep: function(params) {
- return service({
- url: "/task/step/add",
- method: "post",
- data: params
- })
- },
- /**
- * 完结任务步骤
- * @param {任务步骤参数}} params
- */
- stepFinish: function(params) {
- return service({
- url: "/task/step/finish",
- method: "post",
- data: params
- })
- },
- /**
- * 反完结任务步骤
- * @param {任务步骤参数} params
- */
- stepUnFinish: function(params) {
- return service({
- url: "/task/step/unfinish",
- method: "post",
- data: params
- })
- },
- /**
- * 删除步骤
- * @param {任务步骤参数} params
- */
- deleteStep: function(params) {
- return service({
- url: "/task/step/delete",
- method: "post",
- data: params
- })
- },
- /**
- * 更新任务
- * @param {任务参数}} params
- */
- taskEdit: function(params) {
- return service({
- url: "/task/persontask/edit",
- method: "post",
- data: params
- })
- },
- /**
- * 删除今日任务
- * @param {任务参数} params
- * @returns
- */
- deleteToday: function(params) {
- return service({
- url: "/task/today/delete",
- method: "post",
- data: params
- })
- },
- /**
- * 获取今日任务
- * @param {Object} taskId
- */
- getFile: function(taskId) {
- return service({
- url: "/task/file/list",
- method: "get",
- data: {
- "taskId": taskId
- }
- })
- },
- /**
- * 删除今日任务
- * @param {Object} id
- * @param {Object} fileId
- */
- deleteFile(id, fileId) {
- return service({
- url: "/task/file/delete",
- method: "get",
- data: {
- id: id,
- fileId: fileId
- },
- })
- },
- /**
- * 删除任务、今日任务、任务步骤、任务汇报等
- * @param {任务参数} params
- */
- deleteTask(params) {
- return service({
- url: "/task/persontask/delete",
- method: "post",
- data: params
- })
- },
- }
- export default taskManage
|