Changeset 743 for trunk/phpbms
- Timestamp:
- 01/09/10 17:58:06 (2 years ago)
- Files:
-
- 1 modified
-
trunk/phpbms/install/generateuuids.php (modified) (7 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/phpbms/install/generateuuids.php
r727 r743 115 115 $this->createUUIDs("tbld:c595dbe7-6c77-1e02-5e81-c2e215736e9c"); //aritems 116 116 $this->createUUIDs("tbld:43678406-be25-909b-c715-7e2afc7db601"); //receipts 117 $this->createUUIDs("tbld:157b7707-5503-4161-4dcf-6811f8b0322f"); //client email projects118 117 119 118 $this->aritemList = $this->generateUUIDList("aritems"); … … 122 121 $this->addressList = $this->generateUUIDList("addresses"); 123 122 $this->productcatList = $this->generateUUIDList("productcategories"); 123 $this->productList = $this->generateUUIDList("products"); 124 124 $this->clientList = $this->generateUUIDList("clients"); 125 125 $this->statusList = $this->generateUUIDList("invoicestatuses"); … … 170 170 171 171 $this->updateFields("files", array("roleid"=>$this->roleList)); 172 $this->updateFields("attachments", array("fileid"=>$this->fileList ));172 $this->updateFields("attachments", array("fileid"=>$this->fileList, "tabledefid"=>$this->tabledefList)); 173 173 $this->updateFields("menu", array("parentid"=>$menuList, "roleid"=>$this->roleList)); 174 174 $this->updateFields("smartsearches", array("tabledefid"=>$this->tabledefList, "moduleid"=>$this->moduleList)); 175 175 $this->updateFields("tabs", array("roleid"=>$this->roleList)); 176 $this->updateFields("notes", array("assignedtoid"=>$this->userList, "assignedbyid"=>$this->userList, "attachedtabledefid" , "parentid"=>$notesList));176 $this->updateFields("notes", array("assignedtoid"=>$this->userList, "assignedbyid"=>$this->userList, "attachedtabledefid"=>$this->tabledefList, "parentid"=>$notesList)); 177 177 $this->updateFields("log", array("userid"=>$this->userList)); 178 178 … … 213 213 $this->updateFields("aritems", array("clientid"=>$this->clientList)); 214 214 $this->updateFields("prerequisites", array("parentid"=>$this->productList, "childid"=>$this->productList)); 215 $this->updateFields("clientemailprojects", array("userid"=>$this->userList));216 215 217 216 //we would have to run this if their were addresses associated with other records … … 321 320 322 321 foreach($fields as $key=>$value) 323 if(strpos($therecord[$key],":") === false) 324 $updateClause .= ", `".$key."` = '".$value[$therecord[$key]]."'"; 322 if(strpos($therecord[$key],":") === false && ((int) $therecord[$key])) 323 if(isset($value[$therecord[$key]]) && $therecord[$key] != 0) 324 $updateClause .= ", `".$key."` = '".$value[$therecord[$key]]."'"; 325 else 326 $updateClause .= ", `".$key."` = ''"; 325 327 326 328 if($updateClause){ … … 509 511 * 510 512 FROM 511 `set ings`513 `settings` 512 514 WHERE 513 515 `name` = 'default_payment' … … 616 618 `id` = ".$therecord["id"]; 617 619 620 $this->db->query($updatestatement); 621 618 622 }//endwhile 619 623