fmsystem-commits
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Fmsystem-commits] [10522] Merge 10508:10521 from trunk


From: Sigurd Nes
Subject: [Fmsystem-commits] [10522] Merge 10508:10521 from trunk
Date: Tue, 20 Nov 2012 10:24:32 +0000

Revision: 10522
          http://svn.sv.gnu.org/viewvc/?view=rev&root=fmsystem&revision=10522
Author:   sigurdne
Date:     2012-11-20 10:24:32 +0000 (Tue, 20 Nov 2012)
Log Message:
-----------
Merge 10508:10521 from trunk

Modified Paths:
--------------
    branches/Version-1_0-branch/controller/inc/class.socommon.inc.php
    branches/Version-1_0-branch/logistic/inc/class.soactivity.inc.php
    branches/Version-1_0-branch/phpgwapi/inc/class.custom_fields.inc.php
    branches/Version-1_0-branch/phpgwapi/inc/class.db_pdo.inc.php
    branches/Version-1_0-branch/phpgwapi/inc/class.js.inc.php
    branches/Version-1_0-branch/phpgwapi/inc/class.schema_proc.inc.php
    branches/Version-1_0-branch/property/inc/class.boentity.inc.php
    branches/Version-1_0-branch/property/inc/class.interlink.inc.php
    branches/Version-1_0-branch/property/inc/class.sogeneric.inc.php
    branches/Version-1_0-branch/property/inc/class.solocation.inc.php
    branches/Version-1_0-branch/property/inc/class.soproject.inc.php
    branches/Version-1_0-branch/property/inc/class.sotts.inc.php
    branches/Version-1_0-branch/property/inc/class.soworkorder.inc.php
    branches/Version-1_0-branch/property/inc/class.uicondition_survey.inc.php
    branches/Version-1_0-branch/property/inc/class.uientity.inc.php
    branches/Version-1_0-branch/property/js/portico/condition_survey_edit.js
    branches/Version-1_0-branch/property/setup/phpgw_no.lang
    branches/Version-1_0-branch/property/templates/base/attributes_form.xsl
    branches/Version-1_0-branch/property/templates/base/condition_survey.xsl
    branches/Version-1_0-branch/property/templates/base/entity.xsl
    branches/Version-1_0-branch/rental/inc/class.socommon.inc.php

Added Paths:
-----------
    
branches/Version-1_0-branch/property/inc/custom/default/BkBygg_editer_system_oversikt.js
    
branches/Version-1_0-branch/property/inc/custom/default/BkBygg_editer_system_oversikt.php

Property Changed:
----------------
    branches/Version-1_0-branch/


Property changes on: branches/Version-1_0-branch
___________________________________________________________________
Modified: svn:mergeinfo
   - 
/trunk:6439-6441,6443,6445-6447,6449-6464,6466-6468,6470-6474,6476-6477,6479-6480,6483-6488,6490-6491,6493-6494,6496-6501,6503-6504,6506,6508,6510-6511,6513,6515-6516,6518,6520-6524,6526-6528,6533-6534,6536-6541,6543-6565,6567,6569,6571-6576,6578,6580-6586,6588-6596,6598-6600,6602-6604,6606-6607,6609-6611,6613-6625,6629-6639,6641-6643,6645-6646,6648,6650-6654,6656-6659,6661-6663,6665-6666,6668-6669,6672-6673,6675,6677-6678,6680,6682-6686,6688-6717,6719,6721-6722,6724-6728,6730,6732-6734,6736-6739,6741,6743,6745-6746,6748-6756,6758-6762,6764,6766-6788,6790,6792-6798,6800-6814,6816-6819,6821-6822,6824-6826,6828-6837,6839,6841,6843-6849,6851,6853-6869,6871-6874,6876-6877,6879,6881,6883,6885-6886,6888-6893,6895-6897,6899-6901,6903,6905-6907,6909,6911-6929,6931-6936,6938-6947,6949,6951,6953,6955-6956,6958-6959,6961-6968,6970-6971,6973-6974,6976-6978,6980,6982-7017,7019-7025,7027-7035,7037-7039,7041-7045,7047-7055,7057,7059-7065,7067-7069,7071,7073,7075-7076,7078,7080-7081,7083,7085,7087,7089-7097,7099-7102,7104-7105,7107-7111,7113-7120,7122-7124,7126-7129,7131,7133-7141,7143,7145-7146,7148-7150,7152-7153,7155-7158,7160-7164,7166-7167,7169-7170,7172,7174,7176,7178,7180-7181,7183,7185,7187-7188,7190,7192-7196,7198-7199,7201-7203,7205,7207,7209-7210,7212,7214,7216-7217,7219-7222,7224-7226,7228-7229,7231,7233-7234,7236-7238,7240-7241,7243-7244,7246,7248,7250,7252-7256,7258-7259,7261-7264,7266-7273,7275-7279,7281-7332,7334-7338,7340-7348,7350,7352-7353,7355-7361,7363-7366,7368-7370,7372,7374,7376,7378,7380-7386,7388-7400,7402,7404-7433,7435-7439,7441-7446,7448-7458,7460-7469,7471-7483,7485-7487,7489-7490,7492,7494,7496-7497,7499,7501-7502,7504,7506-7507,7509-7511,7513-7517,7519-7521,7523,7525,7527-7529,7531,7533,7535-7538,7540-7542,7544-7549,7551-7552,7554-7561,7563,7565,7567-7573,7575-7578,7580-7584,7586-7591,7593-7624,7627-7636,7638-7656,7658-7718,7720-7732,7734,7736,7738-7750,7754-7759,7761-7767,7769-7780,7782,7784-7809,7811-7812,7814-7835,7837-7847,7849-7887,7889-7895,7897,7899,7901,7903-7905,7907-7921,7923-7925,7927-7933,7935,7937-7952,7954-7968,7970-7974,7976,7978-7979,7981-7982,7984-7988,7990-7992,7994-8041,8043-8066,8068-8087,8089,8091-8108,8110-8124,8126-8129,8131,8133-8150,8152-8154,8156-8162,8164-8167,8169-8170,8172-8179,8181,8183-8196,8198-8207,8209-8211,8213-8214,8216-8217,8219-8220,8222,8224-8225,8227-8247,8249,8251,8253-8282,8284-8352,8354-8368,8370-8396,8398-8430,8432,8434-8440,8442-8445,8447-8453,8455-8456,8458,8460,8462-8464,8466-8473,8475-8479,8481,8483-8501,8503-8523,8525,8527-8531,8533,8535-8536,8538-8550,8552-8554,8556-8557,8559-8579,8581-8587,8589,8591-8592,8594-8595,8597-8601,8603-8610,8612-8613,8615,8617,8619-8645,8647-8650,8652-8661,8663-8666,8668-8669,8671-8683,8685-8691,8693-8730,8732-8737,8739,8741-8767,8769,8771-8772,8774,8776-8797,8799-8812,8814-8819,8821,8823-8833,8835-8837,8839,8841,8843-8849,8852-8858,8860-8867,8869-8870,8872,8874-8877,8879,8881,8883-8888,8890,8892-8901,8903-8911,8913-8917,8920-8923,8925-8933,8935-8938,8940-8943,8945,8947-8948,8950,8952-8953,8955-8962,8964,8966,8968-8970,8972-8975,8977-8983,8985-8993,8995-9001,9003,9005,9007,9009,9011-9019,9021-9023,9025,9027-9028,9030-9044,9046-9047,9049-9050,9052-9056,9058-9059,9061,9063-9064,9066-9068,9071-9092,9094-9112,9114-9117,9119,9121-9160,9162-9166,9169-9207,9209-9211,9213-9215,9217,9219,9221-9253,9255,9257,9259-9260,9262,9264-9269,9271-9273,9275,9277-9278,9280,9282-9283,9285-9289,9291-9299,9301-9310,9312-9313,9315-9320,9322-9324,9326-9338,9340-9342,9344,9346-9348,9350-9358,9360-9362,9364-9366,9368-9374,9376-9382,9384,9386,9388-9390,9392-9396,9398-9402,9404-9410,9412,9414,9416-9417,9419-9425,9427,9429-9430,9432,9434-9463,9465-9502,9504-9506,9508-9521,9523-9526,9528,9530-9537,9539,9541-9551,9553,9555-9556,9558-9578,9580-9581,9583,9585,9587,9589,9591-9624,9626-9655,9657-9700,9702-9726,9728-9729,9731-9749,9751,9753-9754,9756-9832,9834-9836,9838-9839,9841-9846,9848-9850,9852-9858,9860-9863,9865,9867,9869-9871,9873-9893,9895,9897-9912,9914-9919,9921-9928,9930-9952,9954,9956,9958-9963,9965-9993,9995-9997,9999-10001,10003-10004,10006-10007,10009-10012,10014-10031,10033-10073,10075-10107,10109-10165,10167-10210,10222-10226,10228-10311,10313-10378,10380,10382,10384-10393,10395-10478,10480-10482,10484-10494,10496-10503,10505,10507
   + 
/trunk:6439-6441,6443,6445-6447,6449-6464,6466-6468,6470-6474,6476-6477,6479-6480,6483-6488,6490-6491,6493-6494,6496-6501,6503-6504,6506,6508,6510-6511,6513,6515-6516,6518,6520-6524,6526-6528,6533-6534,6536-6541,6543-6565,6567,6569,6571-6576,6578,6580-6586,6588-6596,6598-6600,6602-6604,6606-6607,6609-6611,6613-6625,6629-6639,6641-6643,6645-6646,6648,6650-6654,6656-6659,6661-6663,6665-6666,6668-6669,6672-6673,6675,6677-6678,6680,6682-6686,6688-6717,6719,6721-6722,6724-6728,6730,6732-6734,6736-6739,6741,6743,6745-6746,6748-6756,6758-6762,6764,6766-6788,6790,6792-6798,6800-6814,6816-6819,6821-6822,6824-6826,6828-6837,6839,6841,6843-6849,6851,6853-6869,6871-6874,6876-6877,6879,6881,6883,6885-6886,6888-6893,6895-6897,6899-6901,6903,6905-6907,6909,6911-6929,6931-6936,6938-6947,6949,6951,6953,6955-6956,6958-6959,6961-6968,6970-6971,6973-6974,6976-6978,6980,6982-7017,7019-7025,7027-7035,7037-7039,7041-7045,7047-7055,7057,7059-7065,7067-7069,7071,7073,7075-7076,7078,7080-7081,7083,7085,7087,7089-7097,7099-7102,7104-7105,7107-7111,7113-7120,7122-7124,7126-7129,7131,7133-7141,7143,7145-7146,7148-7150,7152-7153,7155-7158,7160-7164,7166-7167,7169-7170,7172,7174,7176,7178,7180-7181,7183,7185,7187-7188,7190,7192-7196,7198-7199,7201-7203,7205,7207,7209-7210,7212,7214,7216-7217,7219-7222,7224-7226,7228-7229,7231,7233-7234,7236-7238,7240-7241,7243-7244,7246,7248,7250,7252-7256,7258-7259,7261-7264,7266-7273,7275-7279,7281-7332,7334-7338,7340-7348,7350,7352-7353,7355-7361,7363-7366,7368-7370,7372,7374,7376,7378,7380-7386,7388-7400,7402,7404-7433,7435-7439,7441-7446,7448-7458,7460-7469,7471-7483,7485-7487,7489-7490,7492,7494,7496-7497,7499,7501-7502,7504,7506-7507,7509-7511,7513-7517,7519-7521,7523,7525,7527-7529,7531,7533,7535-7538,7540-7542,7544-7549,7551-7552,7554-7561,7563,7565,7567-7573,7575-7578,7580-7584,7586-7591,7593-7624,7627-7636,7638-7656,7658-7718,7720-7732,7734,7736,7738-7750,7754-7759,7761-7767,7769-7780,7782,7784-7809,7811-7812,7814-7835,7837-7847,7849-7887,7889-7895,7897,7899,7901,7903-7905,7907-7921,7923-7925,7927-7933,7935,7937-7952,7954-7968,7970-7974,7976,7978-7979,7981-7982,7984-7988,7990-7992,7994-8041,8043-8066,8068-8087,8089,8091-8108,8110-8124,8126-8129,8131,8133-8150,8152-8154,8156-8162,8164-8167,8169-8170,8172-8179,8181,8183-8196,8198-8207,8209-8211,8213-8214,8216-8217,8219-8220,8222,8224-8225,8227-8247,8249,8251,8253-8282,8284-8352,8354-8368,8370-8396,8398-8430,8432,8434-8440,8442-8445,8447-8453,8455-8456,8458,8460,8462-8464,8466-8473,8475-8479,8481,8483-8501,8503-8523,8525,8527-8531,8533,8535-8536,8538-8550,8552-8554,8556-8557,8559-8579,8581-8587,8589,8591-8592,8594-8595,8597-8601,8603-8610,8612-8613,8615,8617,8619-8645,8647-8650,8652-8661,8663-8666,8668-8669,8671-8683,8685-8691,8693-8730,8732-8737,8739,8741-8767,8769,8771-8772,8774,8776-8797,8799-8812,8814-8819,8821,8823-8833,8835-8837,8839,8841,8843-8849,8852-8858,8860-8867,8869-8870,8872,8874-8877,8879,8881,8883-8888,8890,8892-8901,8903-8911,8913-8917,8920-8923,8925-8933,8935-8938,8940-8943,8945,8947-8948,8950,8952-8953,8955-8962,8964,8966,8968-8970,8972-8975,8977-8983,8985-8993,8995-9001,9003,9005,9007,9009,9011-9019,9021-9023,9025,9027-9028,9030-9044,9046-9047,9049-9050,9052-9056,9058-9059,9061,9063-9064,9066-9068,9071-9092,9094-9112,9114-9117,9119,9121-9160,9162-9166,9169-9207,9209-9211,9213-9215,9217,9219,9221-9253,9255,9257,9259-9260,9262,9264-9269,9271-9273,9275,9277-9278,9280,9282-9283,9285-9289,9291-9299,9301-9310,9312-9313,9315-9320,9322-9324,9326-9338,9340-9342,9344,9346-9348,9350-9358,9360-9362,9364-9366,9368-9374,9376-9382,9384,9386,9388-9390,9392-9396,9398-9402,9404-9410,9412,9414,9416-9417,9419-9425,9427,9429-9430,9432,9434-9463,9465-9502,9504-9506,9508-9521,9523-9526,9528,9530-9537,9539,9541-9551,9553,9555-9556,9558-9578,9580-9581,9583,9585,9587,9589,9591-9624,9626-9655,9657-9700,9702-9726,9728-9729,9731-9749,9751,9753-9754,9756-9832,9834-9836,9838-9839,9841-9846,9848-9850,9852-9858,9860-9863,9865,9867,9869-9871,9873-9893,9895,9897-9912,9914-9919,9921-9928,9930-9952,9954,9956,9958-9963,9965-9993,9995-9997,9999-10001,10003-10004,10006-10007,10009-10012,10014-10031,10033-10073,10075-10107,10109-10165,10167-10210,10222-10226,10228-10311,10313-10378,10380,10382,10384-10393,10395-10478,10480-10482,10484-10494,10496-10503,10505,10507,10509-10521

Modified: branches/Version-1_0-branch/controller/inc/class.socommon.inc.php
===================================================================
--- branches/Version-1_0-branch/controller/inc/class.socommon.inc.php   
2012-11-20 08:10:37 UTC (rev 10521)
+++ branches/Version-1_0-branch/controller/inc/class.socommon.inc.php   
2012-11-20 10:24:32 UTC (rev 10522)
@@ -293,6 +293,8 @@
                                }
                        }
 
+                       $this->db->set_fetch_single(false);
+
                        return $results;
                }
 

Modified: branches/Version-1_0-branch/logistic/inc/class.soactivity.inc.php
===================================================================
--- branches/Version-1_0-branch/logistic/inc/class.soactivity.inc.php   
2012-11-20 08:10:37 UTC (rev 10521)
+++ branches/Version-1_0-branch/logistic/inc/class.soactivity.inc.php   
2012-11-20 10:24:32 UTC (rev 10522)
@@ -217,39 +217,10 @@
                 */
                public function get(int $start_index, int $num_of_objects, 
string $sort_field, boolean $ascending, string $search_for, string 
$search_type, array $filters, boolean $allrows)
                {
-                       $results = array();                     // Array to 
store result objects
-                       $map = array();                         // Array to 
hold number of records per target object
-                       $check_map = array();           // Array to hold the 
actual number of record read per target object
-                       $object_ids = array();          // All of the object 
ids encountered
-                       $added_object_ids = array();// All of the added objects 
ids
-
-                       // Retrieve information about the table name and the 
name and alias of id column
-                       // $break_on_limit -    flag indicating whether to 
break the loop when the number of records 
-                       //                                              for all 
the result objects are traversed
-                       $id_field_name_info = $this->get_id_field_name(true);
-                       if(is_array($id_field_name_info))
-                       {
-                               $break_on_limit = true;
-                               $id_field_name = 
$id_field_name_info['translated'];
-                       }
-                       else
-                       {
-                               $break_on_limit = false;
-                               $id_field_name = $id_field_name_info;
-                       }
-
-                       // Special case: Sort on id field. Always changed to 
the id field name.
-                       // $break_when_num_of_objects_reached - flag indicating 
to break the loop when the number of 
-                       //              results are reached and we are sure 
that the records are ordered by the id
                        if($sort_field == null || $sort_field == 'id' || 
$sort_field == '')
                        {
-                               $sort_field = $id_field_name;
-                               $break_when_num_of_objects_reached = true;
+                               $sort_field = 'id';
                        }
-                       else
-                       {
-                               $break_when_num_of_objects_reached = false;
-                       }
 
                        // Only allow positive start index
                        if($start_index < 0)
@@ -258,7 +229,7 @@
                        }
 
                        $sql = $this->get_query($sort_field, $ascending, 
$search_for, $search_type, $filters, false);
-                       $ret = $this->read_tree($sql, $filters, 
$num_of_objects, $allrows);
+                       $ret = $this->read_tree($sql, $filters, 
$num_of_objects, $start_index, $allrows);
 
                        return $ret;
                }
@@ -305,7 +276,7 @@
                 * array, never null. The array keys are the respective index 
numbers.
                 */
 
-               public function read_tree($sql, $filters, $num_of_objects = 0, 
$allrows = false)
+               public function read_tree($sql, $filters, $num_of_objects = 0, 
$start = 0, $allrows = false)
                {
                        if($filters['activity'])
                        {

Modified: branches/Version-1_0-branch/phpgwapi/inc/class.custom_fields.inc.php
===================================================================
--- branches/Version-1_0-branch/phpgwapi/inc/class.custom_fields.inc.php        
2012-11-20 08:10:37 UTC (rev 10521)
+++ branches/Version-1_0-branch/phpgwapi/inc/class.custom_fields.inc.php        
2012-11-20 10:24:32 UTC (rev 10522)
@@ -732,7 +732,8 @@
                        $OldColumnName          = $this->_db->f('column_name');
                        $OldDataType            = $this->_db->f('datatype');
                        $OldPrecision           = $this->_db->f('precision_');
-                       $OldGroup                       = (int) 
$this->_db->f('group_id');                      
+                       $OldGroup                       = (int) 
$this->_db->f('group_id');
+                       $OldNullable            = $this->_db->f('nullable');    
        
 
                        $this->_db->transaction_begin();
 
@@ -818,7 +819,9 @@
                        }
 
                        if (($OldDataType != $attrib['column_info']['type'])
-                               || ($OldPrecision != 
$attrib['column_info']['precision']) )
+                               || ($OldPrecision != 
$attrib['column_info']['precision'])
+                               || ($OldNullable != 
$attrib['column_info']['nullable'])
+                                )
                        {
                                if( !$doubled )
                                {
@@ -911,6 +914,7 @@
                                                while 
(isset($metadata[$backup_column_name]));
                                                
                                                
$this->_oProc->RenameColumn($attrib_table,$attrib['column_name'], 
$backup_column_name);
+                                               
$this->_oProc->AlterColumn($attrib_table,$backup_column_name,array('type' => 
$OldDataType, 'nullable' => true));
                                                
$this->_oProc->AddColumn($attrib_table, $attrib['column_name'], 
$attrib['column_info']);
                                        }
                                        

Modified: branches/Version-1_0-branch/phpgwapi/inc/class.db_pdo.inc.php
===================================================================
--- branches/Version-1_0-branch/phpgwapi/inc/class.db_pdo.inc.php       
2012-11-20 08:10:37 UTC (rev 10521)
+++ branches/Version-1_0-branch/phpgwapi/inc/class.db_pdo.inc.php       
2012-11-20 10:24:32 UTC (rev 10522)
@@ -350,12 +350,10 @@
                */
                public function query($sql, $line = '', $file = '', $exec = 
false, $_fetch_single = false)
                {
-//_Debug_Array($sql);
-                       $this->_get_fetchmode();
+                       self::_get_fetchmode();
+                       self::set_fetch_single($_fetch_single);
 
-                       //FIXME
-                       $fetch_single = $_fetch_single;
-                       $this->fetch_single = $_fetch_single;
+                       $fetch_single = $this->fetch_single;
 
                        if ( !$this->db )
                        {

Modified: branches/Version-1_0-branch/phpgwapi/inc/class.js.inc.php
===================================================================
--- branches/Version-1_0-branch/phpgwapi/inc/class.js.inc.php   2012-11-20 
08:10:37 UTC (rev 10521)
+++ branches/Version-1_0-branch/phpgwapi/inc/class.js.inc.php   2012-11-20 
10:24:32 UTC (rev 10522)
@@ -187,7 +187,7 @@
                                {                                       
                                        $links .= <<<HTML
                                        <script type="text/javascript" 
src="{$GLOBALS['phpgw_info']['server']['webserver_url']}/{$file}" >
-
+                                       </script>
 HTML;
                                }
                        }

Modified: branches/Version-1_0-branch/phpgwapi/inc/class.schema_proc.inc.php
===================================================================
--- branches/Version-1_0-branch/phpgwapi/inc/class.schema_proc.inc.php  
2012-11-20 08:10:37 UTC (rev 10521)
+++ branches/Version-1_0-branch/phpgwapi/inc/class.schema_proc.inc.php  
2012-11-20 10:24:32 UTC (rev 10522)
@@ -32,7 +32,7 @@
                                case 'mysql':
                                $this->m_oTranslator    = 
createObject('phpgwapi.schema_proc_mysql');
                                break;
-                               
+
                                case 'postgres':
                                $this->m_oTranslator    = 
createObject('phpgwapi.schema_proc_pgsql');
                                break;
@@ -44,13 +44,13 @@
                                case 'sapdb':
                                $this->m_oTranslator    = 
createObject('phpgwapi.schema_proc_sapdb');
                                break;
-                               
+
                                case 'mssql':
                                $this->m_oTranslator    = 
createObject('phpgwapi.schema_proc_mssql');
                                break;
 
                                default:
-                               //what now?                             
+                               //what now?
                        }
                        $this->m_oDeltaProc             = 
createObject('phpgwapi.schema_proc_array');
                        $this->m_aTables                = array();
@@ -72,7 +72,7 @@
                                $sSequenceSQL = '';
                                $sTriggerSQL = '';
                                $this->m_oTranslator->indexes_sql = array();
-                               
+
                                try
                                {
                                        $this->_GetTableSQL($sTableName, 
$aTableDef, $sTableSQL, $sSequenceSQL, $sTriggerSQL);
@@ -90,7 +90,7 @@
                                        echo $e->getMessage();
                                        return false;
                                }
-                               
+
                                $sTableSQL = "CREATE TABLE $sTableName 
(\n$sTableSQL\n)"
                                        . 
$this->m_oTranslator->m_sStatementTerminator;
                                if($sSequenceSQL != '')
@@ -102,7 +102,7 @@
                                {
                                        $sAllTableSQL .= $sTriggerSQL . "\n";
                                }
-                                       
+
                                $sAllTableSQL .= $sTableSQL . "\n\n";
 
                                // postgres and mssql
@@ -326,7 +326,7 @@
                        while(list($sFieldName, $aFieldAttr) = 
each($aTableDef['fd']))
                        {
                                $sFieldSQL = '';
-                               
+
                                try
                                {
                                        $this->_GetFieldSQL($aFieldAttr, 
$sFieldSQL);
@@ -338,7 +338,7 @@
                                        throw new Exception($_message);
                                        return False;
                                }
-                               
+
                                if($sTableSQL != '')
                                {
                                        $sTableSQL .= ",\n";
@@ -488,9 +488,10 @@
                        // Translate the type for the DBMS
                        $sBufNullable = '';
                        $sBufDefault = '';
+
                        if($sFieldSQL = 
$this->m_oTranslator->TranslateType($sType, $iPrecision, $iScale))
                        {
-                               if($bNullable == False)
+                               if($bNullable === false || $bNullable === 
'False')
                                {
                                        $sBufNullable = ' NOT NULL';
                                        //$sFieldSQL .= ' NOT NULL';
@@ -500,12 +501,12 @@
                                        $sBufNullable = ' NULL';
                                        //$sFieldSQL .= ' NULL';
                                }
-                               
+
                                if($sDefault === '0' || $sDefault === 0)
                                {
                                        $sBufDefault = ' DEFAULT 0';
                                        //$sFieldSQL .= ' DEFAULT 0';
-                               }                                               
                
+                               }
                                elseif(!is_numeric($sDefault) && $sDefault != 
'')
                                {
                                        if($DEBUG) { echo '<br>_GetFieldSQL(): 
Calling TranslateDefault for "' . $sDefault . '"'; }
@@ -519,7 +520,7 @@
                                        $sBufDefault .= " DEFAULT $sDefault";
                                        //$sFieldSQL .= " DEFAULT $sDefault";
                                }
-                               
+
                                if($this->dbms == 'oracle')
                                {
                                        $sFieldSQL .= 
"{$sBufDefault}{$sBufNullable}";
@@ -579,7 +580,7 @@
                                {
                                        $sFields .= ',';
                                }
-                               
+
                                if(is_array($sField))
                                {
                                        $sField = implode(',', $sField);
@@ -644,17 +645,17 @@
                        {
                                $sFKSQL = implode(",\n",$sFKSQLarr);
                        }
-                       
+
                        return True;
                }
-               
+
                /**
                * Create Index on tables from tables_update
                *
                * @param string|array $aFields fields hold by the index
                * @param string $sTableName table affected
                */
-               
+
                function CreateIndex($aFields, $sTableName)
                {
                        if (count($aFields) < 1 || !$sTableName)
@@ -686,12 +687,12 @@
                                }
                                ++$i;
                        }
-                       
+
                        if($this->dbms == 'mysql' && $sIXSQL)
                        {
                                $this->query($sIXSQL, __LINE__, __FILE__);
                        }
-                       
+
                        // postgres and mssql
                        if(isset($this->m_oTranslator->indexes_sql) && 
is_array($this->m_oTranslator->indexes_sql) && 
count($this->m_oTranslator->indexes_sql)>0)
                        {
@@ -701,7 +702,7 @@
                                        $IndexSQL = 
str_replace(array('__index_name__','__table_name__'), 
array($ix_name,$sTableName), $sIndexSQL);
                                        $this->query($IndexSQL, __LINE__, 
__FILE__);
                                }
-                       }                       
+                       }
                }
 
                /**

Modified: branches/Version-1_0-branch/property/inc/class.boentity.inc.php
===================================================================
--- branches/Version-1_0-branch/property/inc/class.boentity.inc.php     
2012-11-20 08:10:37 UTC (rev 10521)
+++ branches/Version-1_0-branch/property/inc/class.boentity.inc.php     
2012-11-20 10:24:32 UTC (rev 10522)
@@ -44,6 +44,7 @@
                var $part_of_town_id;
                var $location_code;
                var $results;
+               var $acl_location;
                protected $xsl_rootdir;
 
                /**
@@ -101,6 +102,9 @@
                        $this->type_app                                 = 
$this->so->get_type_app();
 
                        $this->type                                             
= isset($type)  && $type && $this->type_app[$type] ? $type : 'entity';
+
+                       $this->acl_location                             = 
".{$type}.{$entity_id}.{$cat_id}";
+
                        $this->location_code                    = 
isset($location_code)  && $location_code ? $location_code : '';
 
                        $this->soadmin_entity                   = 
CreateObject('property.soadmin_entity',$entity_id,$cat_id);
@@ -564,7 +568,7 @@
 
                                $file = PHPGW_SERVER_ROOT . 
"/{$this->type_app[$this->type]}/inc/custom/{$GLOBALS['phpgw_info']['user']['domain']}/{$entry['file_name']}";
 
-                               if ( $entry['active'] && is_file($file) )
+                               if ( $entry['active'] && !$entry['client_side'] 
&& is_file($file) )
                                {
                                        require_once $file;
                                }

Modified: branches/Version-1_0-branch/property/inc/class.interlink.inc.php
===================================================================
--- branches/Version-1_0-branch/property/inc/class.interlink.inc.php    
2012-11-20 08:10:37 UTC (rev 10521)
+++ branches/Version-1_0-branch/property/inc/class.interlink.inc.php    
2012-11-20 10:24:32 UTC (rev 10522)
@@ -77,10 +77,10 @@
                        switch( $role )
                        {
                                case 'target':
-                                       $sql = "SELECT location2_id as 
linkend_location, location2_item_id as linkend_id FROM phpgw_interlink WHERE 
location1_id = {$location_id} AND location1_item_id = {$id} ORDER by 
location2_id DESC";
+                                       $sql = "SELECT location2_id as 
linkend_location, location2_item_id as linkend_id, account_id,entry_date FROM 
phpgw_interlink WHERE location1_id = {$location_id} AND location1_item_id = 
{$id} ORDER by location2_id DESC";
                                        break;
                                default:
-                                       $sql = "SELECT location1_id as 
linkend_location, location1_item_id as linkend_id FROM phpgw_interlink WHERE 
location2_id = {$location_id} AND location2_item_id = {$id} ORDER by 
location1_id DESC";
+                                       $sql = "SELECT location1_id as 
linkend_location, location1_item_id as linkend_id, account_id,entry_date FROM 
phpgw_interlink WHERE location2_id = {$location_id} AND location2_item_id = 
{$id} ORDER by location1_id DESC";
                        }
 
                        $this->_db->query($sql,__LINE__,__FILE__);
@@ -95,7 +95,12 @@
                                        $i++;
                                }
                                $relation[$i]['linkend_location']       = 
$this->_db->f('linkend_location');
-                               $relation[$i]['data'][] = array( 'id' => 
$this->_db->f('linkend_id'));
+                               $relation[$i]['data'][] = array
+                               (
+                                       'id'                    => 
$this->_db->f('linkend_id'),
+                                       'account_id'    => 
$this->_db->f('account_id'),
+                                       'entry_date'    => 
$this->_db->f('entry_date')
+                               );
 
                                $last_type = $this->_db->f('linkend_location');
                        }
@@ -110,7 +115,9 @@
                                foreach ($entry['data'] as &$data)
                                {
                                        $data['link'] = 
$this->get_relation_link($linkend_location, $data['id']);
-                                       $data['statustext'] = 
$this->get_relation_info($linkend_location, $data['id']);
+                                       $relation_info = 
$this->get_relation_info($linkend_location, $data['id']);
+                                       $data['statustext'] = 
$relation_info['statustext'];
+                                       $data['title'] = 
$relation_info['title'];
                                }
                        }
                        return $relation;
@@ -277,44 +284,55 @@
 
                public function get_relation_info($linkend_location, $id)
                {
+                       $relation_info = array();
                        $id = (int)$id;
                        $type = $linkend_location['location'];
                        if($type == '.ticket')
                        {
-                               $this->_db->query("SELECT status FROM 
fm_tts_tickets WHERE id = {$id}",__LINE__,__FILE__);
+                               $this->_db->query("SELECT status, subject as 
title FROM fm_tts_tickets WHERE id = {$id}",__LINE__,__FILE__);
                                $this->_db->next_record();
                                $status_code = $this->_db->f('status');
+                               $relation_info['title'] = 
$this->_db->f('title');
 
                                static $status_text;
                                if(!$status_text)
                                {
                                        $status_text = 
execMethod('property.botts.get_status_text');
                                }
-                               return $status_text[$status_code];
+                               $relation_info['statustext'] = 
$status_text[$status_code];
+                               return $relation_info;
                        }
                        else if($type == '.project.workorder')
                        {
-                               $this->_db->query("SELECT 
fm_workorder_status.descr as status FROM fm_workorder {$this->_join} 
fm_workorder_status ON fm_workorder.status = fm_workorder_status.id WHERE 
fm_workorder.id = {$id}",__LINE__,__FILE__);
+                               $this->_db->query("SELECT 
fm_workorder_status.descr as status, fm_workorder.title FROM fm_workorder 
{$this->_join} fm_workorder_status ON fm_workorder.status = 
fm_workorder_status.id WHERE fm_workorder.id = {$id}",__LINE__,__FILE__);
                                $this->_db->next_record();
-                               return $this->_db->f('status');
+                               $relation_info['statustext'] = 
$this->_db->f('status');
+                               $relation_info['title'] = 
$this->_db->f('title');
+                               return $relation_info;
                        }
                        else if($type == '.project.request')
                        {
-                               $this->_db->query("SELECT 
fm_request_status.descr as status FROM fm_request {$this->_join} 
fm_request_status ON fm_request.status = fm_request_status.id WHERE 
fm_request.id = {$id}",__LINE__,__FILE__);                               
+                               $this->_db->query("SELECT fm_request.title, 
fm_request_status.descr as status FROM fm_request {$this->_join} 
fm_request_status ON fm_request.status = fm_request_status.id WHERE 
fm_request.id = {$id}",__LINE__,__FILE__);                             
                                $this->_db->next_record();
-                               return $this->_db->f('status');
+                               $relation_info['statustext'] = 
$this->_db->f('status');
+                               $relation_info['title'] = 
$this->_db->f('title');
+                               return $relation_info;
+
                        }
                        else if($type == '.project')
                        {               
-                               $this->_db->query("SELECT 
fm_project_status.descr as status FROM fm_project {$this->_join} 
fm_project_status ON fm_project.status = fm_project_status.id WHERE 
fm_project.id = {$id}",__LINE__,__FILE__);
+                               $this->_db->query("SELECT fm_project.name as 
title, fm_project_status.descr as status FROM fm_project {$this->_join} 
fm_project_status ON fm_project.status = fm_project_status.id WHERE 
fm_project.id = {$id}",__LINE__,__FILE__);
                                $this->_db->next_record();
-                               return $this->_db->f('status');
+                               $relation_info['statustext'] = 
$this->_db->f('status');
+                               $relation_info['title'] = 
$this->_db->f('title');
+                               return $relation_info;
                        }
                        else if( substr($type, 1, 6) == 'entity' )
                        {
                                $type           = explode('.',$type);
                                $entity_id      = $type[2];
                                $cat_id         = $type[3];
+                               $location_id    = 
$GLOBALS['phpgw']->locations->get_id('property', 
".entity.{$entity_id}.{$cat_id}");
                                $metadata = 
$this->_db->metadata("fm_entity_{$entity_id}_{$cat_id}");
                                if(isset($metadata['status']))
                                {
@@ -322,7 +340,6 @@
                                        
$this->_db->query($sql,__LINE__,__FILE__);
                                        $this->_db->next_record();
                                        $status_id = 
(int)$this->_db->f('status');
-                                       $location_id    = 
$GLOBALS['phpgw']->locations->get_id('property', 
".entity.{$entity_id}.{$cat_id}");
 
                                        $sql = "SELECT phpgw_cust_choice.value 
as status FROM phpgw_cust_attribute"
                                                . " {$this->_join} 
phpgw_cust_choice ON phpgw_cust_attribute.location_id = 
phpgw_cust_choice.location_id "
@@ -330,8 +347,17 @@
                                                . " AND phpgw_cust_choice.id = 
{$status_id} AND phpgw_cust_attribute.location_id = {$location_id}";
                                        
$this->_db->query($sql,__LINE__,__FILE__);
                                        $this->_db->next_record();
-                                       return $this->_db->f('status');
+                                       $relation_info['statustext'] = 
$this->_db->f('status');
                                }
+       
+                               $relation_info['title'] = 'N∕A';
+
+                               if($short_desc = 
execMethod('property.soentity.get_short_description',  array('location_id' => 
$location_id, 'id' => $id)))
+                               {
+                                       $relation_info['title'] = $short_desc;
+                               }
+
+                               return $relation_info;
                        }
                        else if( substr($type, 1, 5) == 'catch' )
                        {

Modified: branches/Version-1_0-branch/property/inc/class.sogeneric.inc.php
===================================================================
--- branches/Version-1_0-branch/property/inc/class.sogeneric.inc.php    
2012-11-20 08:10:37 UTC (rev 10521)
+++ branches/Version-1_0-branch/property/inc/class.sogeneric.inc.php    
2012-11-20 10:24:32 UTC (rev 10522)
@@ -41,7 +41,7 @@
                protected $table;
                var $appname = 'property';
 
-               function __construct()
+               function __construct($type = '', $type_id = 0)
                {
                        $this->account  = 
$GLOBALS['phpgw_info']['user']['account_id'];
                        $this->custom   = 
createObject('property.custom_fields');
@@ -49,6 +49,12 @@
                        $this->_db2             = clone($this->_db);
                        $this->_like    = & $this->_db->like;
                        $this->_join    = & $this->_db->join;
+
+                       if($type)
+                       {
+                               $this->get_location_info($type,$type_id);
+                       }
+                       
                }
 
                function read($data, $filter = array())

Modified: branches/Version-1_0-branch/property/inc/class.solocation.inc.php
===================================================================
--- branches/Version-1_0-branch/property/inc/class.solocation.inc.php   
2012-11-20 08:10:37 UTC (rev 10521)
+++ branches/Version-1_0-branch/property/inc/class.solocation.inc.php   
2012-11-20 10:24:32 UTC (rev 10522)
@@ -974,6 +974,8 @@
                                $j++;                           
                        }
 
+                       $this->db->set_fetch_single(false);
+
                        $values = $this->custom->translate_value($dataset, 
$location_id, $location_count);
                        return $values;
                }

Modified: branches/Version-1_0-branch/property/inc/class.soproject.inc.php
===================================================================
--- branches/Version-1_0-branch/property/inc/class.soproject.inc.php    
2012-11-20 08:10:37 UTC (rev 10521)
+++ branches/Version-1_0-branch/property/inc/class.soproject.inc.php    
2012-11-20 10:24:32 UTC (rev 10522)
@@ -638,6 +638,8 @@
                                        $project_list[] = array('project_id' => 
$this->db->f('id'));
                                }
 
+                               $this->db->set_fetch_single(false);
+
                                foreach($project_list as &$project)
                                {
                                        $this->db->query("{$sql} WHERE 
fm_project.id = '{$project['project_id']}' {$group_method}");

Modified: branches/Version-1_0-branch/property/inc/class.sotts.inc.php
===================================================================
--- branches/Version-1_0-branch/property/inc/class.sotts.inc.php        
2012-11-20 08:10:37 UTC (rev 10521)
+++ branches/Version-1_0-branch/property/inc/class.sotts.inc.php        
2012-11-20 10:24:32 UTC (rev 10522)
@@ -557,6 +557,8 @@
                                }
                        }
 
+                       $this->db->set_fetch_single(false);
+
                        return $tickets;
                }
 

Modified: branches/Version-1_0-branch/property/inc/class.soworkorder.inc.php
===================================================================
--- branches/Version-1_0-branch/property/inc/class.soworkorder.inc.php  
2012-11-20 08:10:37 UTC (rev 10521)
+++ branches/Version-1_0-branch/property/inc/class.soworkorder.inc.php  
2012-11-20 10:24:32 UTC (rev 10522)
@@ -721,6 +721,8 @@
                                $workorder_list[] = array('workorder_id' => 
$this->db->f('id'));
                        }
 
+                       $this->db->set_fetch_single(false);
+
                        foreach($workorder_list as &$workorder)
                        {
                                $this->db->query("{$sql} WHERE fm_workorder.id 
= '{$workorder['workorder_id']}'");

Modified: 
branches/Version-1_0-branch/property/inc/class.uicondition_survey.inc.php
===================================================================
--- branches/Version-1_0-branch/property/inc/class.uicondition_survey.inc.php   
2012-11-20 08:10:37 UTC (rev 10521)
+++ branches/Version-1_0-branch/property/inc/class.uicondition_survey.inc.php   
2012-11-20 10:24:32 UTC (rev 10522)
@@ -40,7 +40,8 @@
                        'view' => true,
                        'add' => true,
                        'edit' => true,
-                       'save' => true
+                       'save' => true,
+                       'get_vendors'   => true
                );
 
                public function __construct()
@@ -319,6 +320,19 @@
                        }
                }
 
+               public function get_vendors()
+               {
+                       $query = phpgw::get_var('query');
+
+                       $sogeneric = CreateObject('property.sogeneric', 
'vendor');
+                       $values = $sogeneric->read(array('query' => $query));
+                       foreach ($values as &$entry)
+                       {
+                               $entry['name'] = $entry['org_name'];
+                       }
+                       return array('ResultSet'=> array('Result'=>$values));
+               }
+
                private function _get_categories($selected = 0)
                {
                        $cats   = CreateObject('phpgwapi.categories', -1, 
'property', $this->acl_location);

Modified: branches/Version-1_0-branch/property/inc/class.uientity.inc.php
===================================================================
--- branches/Version-1_0-branch/property/inc/class.uientity.inc.php     
2012-11-20 08:10:37 UTC (rev 10521)
+++ branches/Version-1_0-branch/property/inc/class.uientity.inc.php     
2012-11-20 10:24:32 UTC (rev 10522)
@@ -1669,6 +1669,14 @@
 
                                                $attribute['link_history'] = 
$GLOBALS['phpgw']->link('/index.php',$link_history_data);
                                        }
+                                       
+                                       /*
+                                       * Hide dummy attributes that act as 
placeholders
+                                       */
+                                       if($attribute['datatype'] == 'R' && 
isset($attribute['choice']) && !$attribute['choice'])
+                                       {
+                                               $attribute['hide_row'] = true;
+                                       }
                                }
 
                                
phpgwapi_yui::tabview_setup('entity_edit_tabview');
@@ -1899,12 +1907,16 @@
                                );
 
                        $myColumnDefs[0] = array
-                               (
-                                       'name'          => "0",
-                                       'values'        =>      
json_encode(array(      array('key' => 
'file_name','label'=>lang('Filename'),'sortable'=>false,'resizeable'=>true),
-                                       array('key' => 
'delete_file','label'=>lang('Delete 
file'),'sortable'=>false,'resizeable'=>true,'formatter'=>'FormatterCenter')))
-                               );
+                       (
+                               'name'          => "0",
+                               'values'        =>      json_encode(array(      
array('key' => 
'file_name','label'=>lang('Filename'),'sortable'=>false,'resizeable'=>true),
+                               array('key' => 
'delete_file','label'=>lang('Delete 
file'),'sortable'=>false,'resizeable'=>true,'formatter'=>'FormatterCenter')))
+                       );
 
+
+
+//_Debug_Array($datavalues);
+//die();
 /*
                        $link_file_data['jasper']               = true;
                        $content_jasperfiles = array();
@@ -1957,35 +1969,94 @@
                                        }
                                }
 
+                               $tabs['related']        = array('label' => 
lang('related'), 'link' => '#related');
+                               $_target = array();
+                               if(isset($values['target']) && 
$values['target'])
+                               {
+                                       foreach($values['target'] as 
$_target_section)
+                                       {
+                                               foreach 
($_target_section['data'] as $_target_entry)
+                                               {
+                                                       $_target[] = array
+                                                       (
+                                                               'url'           
=> "<a href=\"{$_target_entry['link']}\" > {$_target_entry['id']}</a>",
+                                                               'type'          
=> $_target_section['descr'],
+                                                               'title'         
=> $_target_entry['title'],
+                                                               'status'        
=> $_target_entry['statustext'],
+                                                               'user'          
=> $GLOBALS['phpgw']->accounts->get($_target_entry['account_id'])->__toString(),
+                                                               'entry_date'=> 
$GLOBALS['phpgw']->common->show_date($_target_entry['entry_date'],$GLOBALS['phpgw_info']['user']['preferences']['common']['dateformat']),
+                                                       );
+                                               }
+                                       }
+                               }
+
                                $related = 
$this->bo->read_entity_to_link(array('entity_id'=>$this->entity_id,'cat_id'=>$this->cat_id,'id'=>$values['num']));
-                               $related_link = array();
 
+                               $_related = array();
                                if(isset($related['related']))
                                {
-                                       $tabs['related']        = array('label' 
=> lang('related'), 'link' => '#related');
-
                                        foreach($related as $related_key => 
$related_data)
                                        {
                                                foreach($related_data as $entry)
                                                {
-                                                       $related_link[] = array
-                                                               (
-                                                                       
'entity_link'                           => $entry['entity_link'],
-                                                                       
'lang_entity_statustext'        => $entry['descr'],
-                                                                       
'text_entity'                           => $entry['name'],
-                                                               );
+                                                       $_related[] = array
+                                                       (
+                                                               'url'           
=> "<a href=\"{$entry['entity_link']}\" > {$entry['name']}</a>",
+                                                       );
                                                }
                                        }
                                }
+                               
+                               $datavalues[1] = array
+                               (
+                                       'name'                                  
=> "1",
+                                       'values'                                
=> json_encode($_target),
+                                       'total_records'                 => 
count($_target),
+                                       'edit_action'                   => "''",
+                                       'is_paginator'                  => 1,
+                                       'footer'                                
=> 0
+                               );
+       
+                               $myColumnDefs[1] = array
+                               (
+                                       'name'          => "1",
+                                       'values'        =>      
json_encode(array(      
+                                               array('key' => 
'url','label'=>lang('id'),'sortable'=>false,'resizeable'=>true),
+                                               array('key' => 
'type','label'=>lang('type'),'sortable'=>true,'resizeable'=>true),
+                                               array('key' => 
'title','label'=>lang('title'),'sortable'=>false,'resizeable'=>true),
+                                               array('key' => 
'status','label'=>lang('status'),'sortable'=>false,'resizeable'=>true),
+                                               array('key' => 
'user','label'=>lang('user'),'sortable'=>true,'resizeable'=>true),
+                                               array('key' => 
'entry_date','label'=>lang('entry date'),'sortable'=>false,'resizeable'=>true),
+                                               )
+                                       )
+                               );
+
+                               $datavalues[2] = array
+                               (
+                                       'name'                                  
=> "2",
+                                       'values'                                
=> json_encode($_related),
+                                       'total_records'                 => 
count($_related),
+                                       'edit_action'                   => "''",
+                                       'is_paginator'                  => 1,
+                                       'footer'                                
=> 0
+                               );
+       
+                               $myColumnDefs[2] = array
+                               (
+                                       'name'          => "2",
+                                       'values'        =>      
json_encode(array(      
+                                               array('key' => 
'url','label'=>lang('where'),'sortable'=>false,'resizeable'=>true),
+                                               )
+                                       )
+                               );
                        }
 
-//_debug_array($attributes);die();
                        $data = array
                                (
                                        'property_js'                           
        => 
json_encode($GLOBALS['phpgw_info']['server']['webserver_url']."/property/js/yahoo/property2.js"),
                                        'datatable'                             
                => $datavalues,
                                        'myColumnDefs'                          
        => $myColumnDefs,       
-                                       'related_link'                          
        => $related_link,                       
+//                                     'related_link'                          
        => $related_link,                       
                                        'link_pdf'                              
                => $GLOBALS['phpgw']->link('/index.php',$pdf_data),
                                        'start_project'                         
        => $category['start_project'],
                                        'lang_start_project'                    
=> lang('start project'),
@@ -2011,8 +2082,8 @@
                                        'value_origin_type'                     
        => isset($origin)?$origin:'',
                                        'value_origin_id'                       
        => isset($origin_id)?$origin_id:'',
 
-                                       'value_target'                          
        => isset($values['target'])?$values['target']:'',
-                                       'lang_target'                           
        => lang('target'),
+                       //              'value_target'                          
        => isset($values['target'])?$values['target']:'',
+                       //              'lang_target'                           
        => lang('target'),
                                        'lang_no_cat'                           
        => lang('no category'),
                                        'lang_cat_statustext'                   
=> lang('Select the category. To do not use a category select NO CATEGORY'),
                                        'select_name'                           
        => 'cat_id',
@@ -2086,6 +2157,8 @@
                        
$GLOBALS['phpgw']->css->add_external_file('phpgwapi/js/yahoo/container/assets/skins/sam/container.css');
                        $GLOBALS['phpgw']->js->validate_file( 'yahoo', 
'entity.edit', 'property' );
 
+
+
                        $criteria = array
                                (
                                        'appname'       => 
$this->type_app[$this->type],

Copied: 
branches/Version-1_0-branch/property/inc/custom/default/BkBygg_editer_system_oversikt.js
 (from rev 10521, 
trunk/property/inc/custom/default/BkBygg_editer_system_oversikt.js)
===================================================================
--- 
branches/Version-1_0-branch/property/inc/custom/default/BkBygg_editer_system_oversikt.js
                            (rev 0)
+++ 
branches/Version-1_0-branch/property/inc/custom/default/BkBygg_editer_system_oversikt.js
    2012-11-20 10:24:32 UTC (rev 10522)
@@ -0,0 +1,126 @@
+
+$(document).ready(function(){
+       $("#id_konf_1").click(function (){
+               
+               if( $("#id_konf_1").prop('checked'))
+               {
+                       $("#id_konf_2").prop('checked',false);                  
                
+                       $("#id_konf_3").prop('checked',false);
+                       $("#id_konf_4").prop('checked',false);                  
                
+               }
+ 
+       });
+
+       $("#id_konf_2").click(function (){
+               if( $("#id_konf_2").prop('checked') ||  
$("#id_konf_3").prop('checked') || $("#id_konf_4").prop('checked'))
+               {
+                       $("#id_konf_1").prop('checked',false);                  
                
+               }
+       });
+
+       $("#id_konf_3").click(function (){
+               if( $("#id_konf_2").prop('checked') ||  
$("#id_konf_3").prop('checked') || $("#id_konf_4").prop('checked'))
+               {
+                       $("#id_konf_1").prop('checked',false);                  
                
+               }
+                               });
+       $("#id_konf_4").click(function (){
+               if( $("#id_konf_2").prop('checked') ||  
$("#id_konf_3").prop('checked') || $("#id_konf_4").prop('checked'))
+               {
+                       $("#id_konf_1").prop('checked',false);                  
                
+               }
+       });
+
+       $("#id_integritet_1").click(function (){
+               
+               if( $("#id_integritet_1").prop('checked'))
+               {
+                       $("#id_integritet_2").prop('checked',false);            
                        
+                       $("#id_integritet_3").prop('checked',false);
+                       $("#id_integritet_4").prop('checked',false);            
                        
+               }
+       });
+
+       $("#id_integritet_2").click(function (){
+               if( $("#id_integritet_2").prop('checked') ||  
$("#id_integritet_3").prop('checked') || $("#id_integritet_4").prop('checked'))
+               {
+                       $("#id_integritet_1").prop('checked',false);            
                        
+               }
+       });
+
+       $("#id_integritet_3").click(function (){
+               if( $("#id_integritet_2").prop('checked') ||  
$("#id_integritet_3").prop('checked') || $("#id_integritet_4").prop('checked'))
+               {
+                       $("#id_integritet_1").prop('checked',false);            
                        
+               }
+       });
+
+       $("#id_integritet_4").click(function (){
+               if( $("#id_integritet_2").prop('checked') ||  
$("#id_integritet_3").prop('checked') || $("#id_integritet_4").prop('checked'))
+               {
+                       $("#id_integritet_1").prop('checked',false);            
                        
+               }
+       });
+
+       $("#id_tilgjengelighet_1").click(function (){
+               
+               if( $("#id_tilgjengelighet_1").prop('checked'))
+               {
+                       $("#id_tilgjengelighet_2").prop('checked',false);       
                                
+                       $("#id_tilgjengelighet_3").prop('checked',false);
+                       $("#id_tilgjengelighet_4").prop('checked',false);       
                                
+               }
+ 
+       });
+
+       $("#id_tilgjengelighet_2").click(function (){
+               if( $("#id_tilgjengelighet_2").prop('checked') ||  
$("#id_tilgjengelighet_3").prop('checked') || 
$("#id_tilgjengelighet_4").prop('checked'))
+               {
+                       $("#id_tilgjengelighet_1").prop('checked',false);       
                                
+               }
+       });
+
+       $("#id_tilgjengelighet_3").click(function (){
+               if( $("#id_tilgjengelighet_2").prop('checked') ||  
$("#id_tilgjengelighet_3").prop('checked') || 
$("#id_tilgjengelighet_4").prop('checked'))
+               {
+                       $("#id_tilgjengelighet_1").prop('checked',false);       
                                
+               }
+       });
+
+       $("#id_tilgjengelighet_4").click(function (){
+               if( $("#id_tilgjengelighet_2").prop('checked') ||  
$("#id_tilgjengelighet_3").prop('checked') || 
$("#id_tilgjengelighet_4").prop('checked'))
+               {
+                       $("#id_tilgjengelighet_1").prop('checked',false);       
                                
+               }
+       });
+
+
+       $("#form").live("submit", function(e){
+
+               var error = false;
+               if( !$("#id_konf_1").prop('checked') && 
(!$("#id_konf_2").prop('checked') && !$("#id_konf_3").prop('checked') && 
!$("#id_konf_4").prop('checked')))
+               {
+                       error = true;
+                       alert('Du må angi kriterie for 
Konfidensialitetsvurdering');
+               }
+
+               if( !$("#id_integritet_1").prop('checked') && 
(!$("#id_integritet_2").prop('checked') && 
!$("#id_integritet_3").prop('checked') && 
!$("#id_integritet_4").prop('checked')))
+               {
+                       error = true;
+                       alert('Du må angi kriterie for Integritetsvurdering');
+               }
+
+               if( !$("#id_tilgjengelighet_1").prop('checked') && 
(!$("#id_tilgjengelighet_2").prop('checked') && 
!$("#id_tilgjengelighet_3").prop('checked') && 
!$("#id_tilgjengelighet_4").prop('checked')))
+               {
+                       error = true;
+                       alert('Du må angi kriterie for 
Tilgjengelighetsvurdering');
+               }
+
+               if(error)
+               {
+                       e.preventDefault();
+                       return;
+               }
+       });
+
+});

Copied: 
branches/Version-1_0-branch/property/inc/custom/default/BkBygg_editer_system_oversikt.php
 (from rev 10521, 
trunk/property/inc/custom/default/BkBygg_editer_system_oversikt.php)
===================================================================
--- 
branches/Version-1_0-branch/property/inc/custom/default/BkBygg_editer_system_oversikt.php
                           (rev 0)
+++ 
branches/Version-1_0-branch/property/inc/custom/default/BkBygg_editer_system_oversikt.php
   2012-11-20 10:24:32 UTC (rev 10522)
@@ -0,0 +1,119 @@
+<?php
+
+       /*
+       * This class will update classification records baed on input.
+       */
+       $systemoversikt = new ikt_systemoversikt();
+       
$systemoversikt->set_classification($values,$values_attribute,$entity_id,$cat_id,$receipt);
+
+       class ikt_systemoversikt extends property_boentity
+       {
+               protected $db;
+
+               function __construct()
+               {
+                       parent::__construct();
+                       $this->db               = & $GLOBALS['phpgw']->db;
+                       if($this->acl_location != '.entity.5.1')
+                       {
+                               throw new Exception("'ikt_systemoversikt'  is 
intended for location = '.entity.5.1'");
+                       }
+
+               }
+
+               function 
set_classification($values,$values_attribute,$entity_id,$cat_id,$receipt)
+               {
+
+                       $value_set = array();
+                       $value_set['konf_rangering']                    = 0;
+                       $value_set['integritet_rangering']              = 0;
+                       $value_set['tilgjengelighet_rangering'] = 0;
+
+                       foreach($values_attribute as $entry)
+                       {
+                               $konf_rangering =  $entry['value'];
+                               switch($entry['name'])
+                               {
+                                       case 'konf_1':
+                                               if($entry['value'] && 
$value_set['konf_rangering'] < 1)
+                                               {
+                                                       
$value_set['konf_rangering'] = 1;
+                                               }
+                                               break;
+                                       case 'konf_2':
+                                               if($entry['value'] && 
$value_set['konf_rangering'] < 2)
+                                               {
+                                                       
$value_set['konf_rangering'] = 2;
+                                               }
+                                               break;
+                                       case 'konf_3':
+                                               if($entry['value'] && 
$value_set['konf_rangering'] < 3)
+                                               {
+                                                       
$value_set['konf_rangering'] = 3;
+                                               }
+                                               break;
+                                       case 'konf_4':
+                                               if($entry['value'] && 
$value_set['konf_rangering'] < 4)
+                                               {
+                                                       
$value_set['konf_rangering'] = 4;
+                                               }
+                                               break;
+
+                                       case 'integritet_1':
+                                               if($entry['value'] && 
$value_set['integritet_rangering'] < 1)
+                                               {
+                                                       
$value_set['integritet_rangering'] = 1;
+                                               }
+                                               break;
+                                       case 'integritet_2':
+                                               if($entry['value'] && 
$value_set['integritet_rangering'] < 2)
+                                               {
+                                                       
$value_set['integritet_rangering'] = 2;
+                                               }
+                                               break;
+                                       case 'integritet_3':
+                                               if($entry['value'] && 
$value_set['integritet_rangering'] < 3)
+                                               {
+                                                       
$value_set['integritet_rangering'] = 3;
+                                               }
+                                               break;
+                                       case 'integritet_4':
+                                               if($entry['value'] && 
$value_set['integritet_rangering'] < 4)
+                                               {
+                                                       
$value_set['integritet_rangering'] = 4;
+                                               }
+                                               break;
+                                       case 'tilgjengelighet_1':
+                                               if($entry['value'] && 
$value_set['tilgjengelighet_rangering'] < 1)
+                                               {
+                                                       
$value_set['tilgjengelighet_rangering'] = 1;
+                                               }
+                                               break;
+                                       case 'tilgjengelighet_2':
+                                               if($entry['value'] && 
$value_set['tilgjengelighet_rangering'] < 2)
+                                               {
+                                                       
$value_set['tilgjengelighet_rangering'] = 2;
+                                               }
+                                               break;
+                                       case 'tilgjengelighet_3':
+                                               if($entry['value'] && 
$value_set['tilgjengelighet_rangering'] < 3)
+                                               {
+                                                       
$value_set['tilgjengelighet_rangering'] = 3;
+                                               }
+                                               break;
+                                       case 'tilgjengelighet_4':
+                                               if($entry['value'] && 
$value_set['tilgjengelighet_rangering'] < 4)
+                                               {
+                                                       
$value_set['tilgjengelighet_rangering'] = 4;
+                                               }
+                                               break;
+                               }
+                       }
+
+                       $value_set      = 
$this->db->validate_update($value_set);
+
+                       $sql = "UPDATE fm_entity_5_1 SET {$value_set} WHERE id 
=" . (int)$receipt['id'];
+
+                       $this->db->query($sql,__LINE__,__FILE__);
+               }
+       }

Modified: 
branches/Version-1_0-branch/property/js/portico/condition_survey_edit.js
===================================================================
--- branches/Version-1_0-branch/property/js/portico/condition_survey_edit.js    
2012-11-20 08:10:37 UTC (rev 10521)
+++ branches/Version-1_0-branch/property/js/portico/condition_survey_edit.js    
2012-11-20 10:24:32 UTC (rev 10522)
@@ -35,3 +35,12 @@
                 });
 
 });
+
+       YAHOO.util.Event.addListener(window, "load", function()
+       {
+               var oArgs = 
{menuaction:'property.uicondition_survey.get_vendors'};
+               var strURL = phpGWLink('index.php', oArgs, true);
+           YAHOO.portico.autocompleteHelper(strURL, 
+               'vendor_name', 'vendor_id', 'vendor_container');
+       });
+

Modified: branches/Version-1_0-branch/property/setup/phpgw_no.lang
===================================================================
--- branches/Version-1_0-branch/property/setup/phpgw_no.lang    2012-11-20 
08:10:37 UTC (rev 10521)
+++ branches/Version-1_0-branch/property/setup/phpgw_no.lang    2012-11-20 
10:24:32 UTC (rev 10522)
@@ -1650,6 +1650,7 @@
 start this entity      property        no      Start denne entiteten
 start this entity from property        no      Start denne entiteten fra 
prosjekt
 start ticket   property        no      Start melding
+started from   property        no      Startet fra
 status property        no      Status
 status changed property        no      Status er endret
 status code    property        no      Statuskode
@@ -1794,6 +1795,7 @@
 upload multiple files  property        no      Last opp flere filer
 upload files   property        no      Last opp filer
 url    property        no      URL
+used in        property        no      Brukt i
 user   property        no      Bruker
 user contact info      property        no      Bruker kontaktinfo
 user gratification     property        no      Bruker tilfredsstillelse
@@ -1884,6 +1886,7 @@
 what is the current status of this project ?   property        no      hva er 
status for dette prosjektet ?
 what is the current status of this request ?   property        no      hva er 
status for denne anmodningen ?
 what is the current status of this workorder ? property        no      hva er 
status for denne bestillingen ?
+where  property        no      Hvor
 where to deliver the key       property        no      Nøkler leveres
 where to fetch the key property        no      Nøkler hentes
 where to pick up the key       property        no      Nøkler hentes

Modified: 
branches/Version-1_0-branch/property/templates/base/attributes_form.xsl
===================================================================
--- branches/Version-1_0-branch/property/templates/base/attributes_form.xsl     
2012-11-20 08:10:37 UTC (rev 10521)
+++ branches/Version-1_0-branch/property/templates/base/attributes_form.xsl     
2012-11-20 10:24:32 UTC (rev 10522)
@@ -33,38 +33,43 @@
                </xsl:choose>
 
                <tr>
-                       <td align="left" width="19%" valign="top" 
title="{$statustext}">
-                               <xsl:choose>
-                                       <xsl:when test="helpmsg=1">
-                                               <xsl:variable name="help_url">
-                                                       <xsl:value-of 
select="help_url"/>
-                                               </xsl:variable>
-                                               <a href="javascript:var 
w=window.open('{$help_url}','','left=50,top=100,width=550,height=400,scrollbars')">
-                                                       <xsl:text>[</xsl:text>
-                                                       <xsl:value-of 
select="input_text"/>
-                                                       <xsl:text>]</xsl:text>
-                                               </a>
-                                       </xsl:when>
-                                       <xsl:otherwise>
-                                               <xsl:value-of 
select="input_text"/>
-                                       </xsl:otherwise>
-                               </xsl:choose>
-                               <xsl:choose>
-                                       <xsl:when test="datatype='pwd'">
-                                               <br/>
-                                               <xsl:text>[ </xsl:text>
+                       <xsl:choose>
+                               <xsl:when test="not(hide_row)">
+                                       <td align="left" width="19%" 
valign="top" title="{$statustext}">
                                                <xsl:choose>
-                                                       <xsl:when 
test="value!=''">
-                                                               <xsl:value-of 
select="php:function('lang', 'edit')"/>
+                                                       <xsl:when 
test="helpmsg=1">
+                                                               <xsl:variable 
name="help_url">
+                                                                       
<xsl:value-of select="help_url"/>
+                                                               </xsl:variable>
+                                                               <a 
href="javascript:var 
w=window.open('{$help_url}','','left=50,top=100,width=550,height=400,scrollbars')">
+                                                                       
<xsl:text>[</xsl:text>
+                                                                       
<xsl:value-of select="input_text"/>
+                                                                       
<xsl:text>]</xsl:text>
+                                                               </a>
                                                        </xsl:when>
                                                        <xsl:otherwise>
-                                                               <xsl:value-of 
select="php:function('lang', 'add')"/>
+                                                               <xsl:value-of 
select="input_text"/>
                                                        </xsl:otherwise>
                                                </xsl:choose>
-                                               <xsl:text> ]</xsl:text>
-                                       </xsl:when>
-                               </xsl:choose>
-                       </td>
+                                               <xsl:choose>
+                                                       <xsl:when 
test="datatype='pwd'">
+                                                               <br/>
+                                                               <xsl:text>[ 
</xsl:text>
+                                                               <xsl:choose>
+                                                                       
<xsl:when test="value!=''">
+                                                                               
<xsl:value-of select="php:function('lang', 'edit')"/>
+                                                                       
</xsl:when>
+                                                                       
<xsl:otherwise>
+                                                                               
<xsl:value-of select="php:function('lang', 'add')"/>
+                                                                       
</xsl:otherwise>
+                                                               </xsl:choose>
+                                                               <xsl:text> 
]</xsl:text>
+                                                       </xsl:when>
+                                               </xsl:choose>
+                                       </td>
+                               </xsl:when>
+                       </xsl:choose>
+
                        <td align="left">
                                <xsl:choose>
                                        <xsl:when test="name!=''">

Modified: 
branches/Version-1_0-branch/property/templates/base/condition_survey.xsl
===================================================================
--- branches/Version-1_0-branch/property/templates/base/condition_survey.xsl    
2012-11-20 08:10:37 UTC (rev 10521)
+++ branches/Version-1_0-branch/property/templates/base/condition_survey.xsl    
2012-11-20 10:24:32 UTC (rev 10522)
@@ -104,6 +104,30 @@
                                                <div class="clearDiv"></div>
                                        </div>
 
+
+                                        <div class="row">
+                                               <div class="label">
+                                                       <label 
for="vendor"><xsl:value-of select="php:function('lang', 'vendor')" /></label>
+                                               </div>
+                                               <xsl:choose>
+                                                       <xsl:when 
test="editable = 1">
+                                                           <div 
class="autocomplete">
+                                                               <input 
type="hidden" id="vendor_id" name="values[vendor_id]"  
value="{survey/vendor_id}"
+                                                                               
formvalidator:FormField="yes"
+                                                                               
formvalidator:type="TextBaseField"/>
+                                                               <input 
type="text" id="vendor_name" name="vendor_name" value="{survey/vendor_name}">
+                                                                       </input>
+                                                               <div 
id="vendor_container"/>
+                                                           </div>
+                                                       </xsl:when>
+                                                       <xsl:otherwise>
+                                                               <xsl:value-of 
select="survey/vendor_name" />
+                                                       </xsl:otherwise>
+                                               </xsl:choose>
+                                               <div class="clearDiv"></div>
+                                       </div>
+
+
 <!--
 
                                        <div class="row">

Modified: branches/Version-1_0-branch/property/templates/base/entity.xsl
===================================================================
--- branches/Version-1_0-branch/property/templates/base/entity.xsl      
2012-11-20 08:10:37 UTC (rev 10521)
+++ branches/Version-1_0-branch/property/templates/base/entity.xsl      
2012-11-20 10:24:32 UTC (rev 10522)
@@ -46,7 +46,7 @@
                        <xsl:variable name="form_action">
                                <xsl:value-of select="form_action"/>
                        </xsl:variable>
-                       <form ENCTYPE="multipart/form-data" method="post" 
name="form" action="{$form_action}">
+                       <form id="form" name="form" action="{$form_action}" 
method="post" ENCTYPE="multipart/form-data">
                                <table cellpadding="2" cellspacing="2" 
width="80%" align="center">
                                        <xsl:choose>
                                                <xsl:when test="msgbox_data != 
''">
@@ -77,7 +77,6 @@
                                        </xsl:choose>
                                </table>
                                <table cellpadding="2" cellspacing="2" 
width="80%" align="center">
-                                       <xsl:call-template name="target"/>
                                        <xsl:for-each select="origin_list">
                                                <tr>
                                                        <td class="th_text">
@@ -286,6 +285,28 @@
                                                        </div>
                                                </xsl:when>
                                        </xsl:choose>
+                                       <div id="related">
+                                               <table cellpadding="2" 
cellspacing="2" width="80%" align="center">
+                                                       <tr>
+                                                               <td 
valign='top'>
+                                                                       
<xsl:value-of select="php:function('lang', 'started from')"/>
+                                                               </td>
+                                                               <td>
+                                                                       <div 
id="datatable-container_1"/>
+                                                               </td>
+                                                       </tr>
+                                                       <tr>
+                                                               <td 
valign='top'>
+                                                                       
<xsl:value-of select="php:function('lang', 'used in')"/>
+                                                               </td>
+                                                               <td>
+                                                                       <div 
id="datatable-container_2"/>
+                                                               </td>
+                                                       </tr>
+                                               </table>
+                                       </div>
+
+                                       <!--
                                        <xsl:choose>
                                                <xsl:when test="related_link != 
''">
                                                        <div id="related">
@@ -301,6 +322,7 @@
                                                        </div>
                                                </xsl:when>
                                        </xsl:choose>
+                                       -->
                                </div>
                                <xsl:choose>
                                        <xsl:when test="mode = 'edit'">

Modified: branches/Version-1_0-branch/rental/inc/class.socommon.inc.php
===================================================================
--- branches/Version-1_0-branch/rental/inc/class.socommon.inc.php       
2012-11-20 08:10:37 UTC (rev 10521)
+++ branches/Version-1_0-branch/rental/inc/class.socommon.inc.php       
2012-11-20 10:24:32 UTC (rev 10522)
@@ -246,6 +246,9 @@
                                }
                        }
                }
+
+               $this->db->set_fetch_single(false);
+
                return $results;
        }
        




reply via email to

[Prev in Thread] Current Thread [Next in Thread]