| 12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758 |
- const _Http = getApp().globalData.http;
- Component({
- properties: {
- list: Array
- },
- data: {
- viewIndex: null
- },
- options: {
- addGlobalClass: true
- },
- methods: {
- selectClient(e) {
- const {
- item
- } = e.currentTarget.dataset,
- pages = getCurrentPages(),
- page = pages[pages.length - 1];
- this.setData({
- taskname: item.taskname,
- content: {
- sa_projectid: page.data.detail.sa_projectid,
- "sa_projtaskmagid": item.sa_projtaskmagid,
- "sa_projstagemagid": item.sa_projstagemagid,
- }
- })
- if (item.partiestype.length != 0) {
- wx.navigateTo({
- url: '/packageA/select/setclient/select?params=' + JSON.stringify({
- "id": 20221129152204,
- content: {
- model: "#Task",
- nocache: true,
- sa_projectid: page.data.detail.sa_projectid,
- "sa_projtaskmagid": item.sa_projtaskmagid,
- pageNumber: 1,
- pageTotal: 1,
- pageSize: 20,
- total: null,
- where: {
- condition: "",
- }
- },
- }),
- });
- } else {
- this.handleAdd([]);
- }
- },
- handleAdd(ids) {
- let content = this.data.content;
- content.sa_project_partiesids = ids
- wx.redirectTo({
- url: '/packageA/project/modules/task/add?content=' + JSON.stringify(content) + '&taskname=' + this.data.taskname,
- })
- }
- }
- })
|