[Vtigercrm-developers] Calendar - Show Projects

Vladimir Karažija vladimir at kosacrta.hr
Fri Mar 11 22:49:52 GMT 2016


Hi,

I searched vtigercrm-developer list and found solution from Alan Bell.

Thnx Alan ;)

in modules/Calendar/actions/Feed.php in the pullProjects function at line
337 there is:

        $params = array_merge($params,$userAndGroupIds);

which then gets used in this query  . . .

                $query = "SELECT projectname, startdate, targetenddate,
crmid FROM vtiger_project";
                $query.= " INNER JOIN vtiger_crmentity ON
vtiger_project.projectid = vtiger_crmentity.crmid";
                $query.= " WHERE vtiger_crmentity.deleted=0 AND smownerid
IN (". generateQuestionMarks($userAndGroupIds) .") AND ";
                $query.= " ((startdate >= ? AND targetenddate < ?) OR (
targetenddate >= ?))";
                $queryResult = $db->pquery($query, $params);

however, the questionmarks for the users and groups come before the date
parameters, so it doesn't work and projects don't display on the calendar,
changing line 337 to put the users and groups first fixes it:

        $params = array_merge($userAndGroupIds,$params);

regards, Vladimir


Vladimir Karažija
Kosa crta d.o.o.
Jagnedje 1
10090 Zagreb
OIB: 57724075047

t. +385 1 777 33 85
m. +385 91 122 0511
www.kosacrta.hr

On Fri, Mar 11, 2016 at 11:38 PM, Vladimir Karažija <vladimir at kosacrta.hr>
wrote:

> Hi,
>
> I am testing Projects module and cannot make vtiger 6.4 to show Projects
> Activity Types in Calendar.
>
> I am able to see Project Tasks in All-Day view that are related to Project
> but cannot see Projects in Calendar.
>
> I have added Start Date & End Date as instructed on
> http://www.boruapps.com/vtiger-tip-modules-on-the-vtiger-calendar/ but
> still there is no Projects Activity Type shown in Calendar.
>
> Anyone with same experience?
>
> regards, Vladimir
>
>
> Vladimir Karažija
> Kosa crta d.o.o.
> Jagnedje 1
> 10090 Zagreb
> OIB: 57724075047
>
> t. +385 1 777 33 85
> m. +385 91 122 0511
> www.kosacrta.hr
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.vtigercrm.com/pipermail/vtigercrm-developers/attachments/20160311/835d5f28/attachment-0001.html>


More information about the vtigercrm-developers mailing list