Commit 050ccd5f authored by Alexandre Boeglin's avatar Alexandre Boeglin

Added SortIndex fields to Catalog, and updated methods.


git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@1928 20353a03-c40f-0410-a6d1-a30d3c3de9de
parent aa35a3c2
This source diff could not be displayed because it is too large. You can view the blob instead.
...@@ -33,34 +33,35 @@ meta_type ...@@ -33,34 +33,35 @@ meta_type
getPortalType getPortalType
modified modified
review_state review_state
sales_state opportunity_state
modele_state
summary summary
getDefaultSourceReference getDefaultSourceReference
getFormeId
getGammeId
getDefaultDestinationReference getDefaultDestinationReference
getDefaultSourceTitle getDefaultSourceTitle
getDefaultDestinationTitle getDefaultDestinationTitle
getDefaultSourceSectionTitle getDefaultSourceSectionTitle
getDefaultDestinationSectionTitle getDefaultDestinationSectionTitle
getDefaultCausalityId getDefaultCausalityId
modele_state_modeliste getLocation
modele_state_gestionaire getEan13Code
forme_state
composant_state
vetement_state
transform_state
order_state
delivery_state
getSimulationState getSimulationState
causality_state causality_state
discussion_state discussion_state
invoice_state
getOrderId getOrderId
samples_delivery_check validation_state
modele_state_infos_client payment_state
modele_state_accord_technique</params> event_state
INSERT INTO catalog VALUES ( getReference
getSourceReference
getDestinationReference
getStringIndex
getIntIndex
getFloatIndex
getStringIndex2
getIntIndex2
getFloatIndex2</params>
INSERT INTO catalog VALUES (
<dtml-sqlvar uid type="int">, <dtml-sqlvar uid type="int">,
<dtml-sqlvar getPath type="string">, <dtml-sqlvar getPath type="string">,
<dtml-sqlvar getRelativeUrl type="string">, <dtml-sqlvar getRelativeUrl type="string">,
...@@ -87,31 +88,32 @@ INSERT INTO catalog VALUES ( ...@@ -87,31 +88,32 @@ INSERT INTO catalog VALUES (
<dtml-sqlvar getPortalType type="string">, <dtml-sqlvar getPortalType type="string">,
<dtml-sqlvar modified type="string">, <dtml-sqlvar modified type="string">,
<dtml-sqlvar review_state type="string">, <dtml-sqlvar review_state type="string">,
<dtml-sqlvar sales_state type="string">, <dtml-sqlvar opportunity_state type="string">,
<dtml-sqlvar modele_state type="string">,
<dtml-sqlvar getDefaultSourceReference type="string">, <dtml-sqlvar getDefaultSourceReference type="string">,
<dtml-sqlvar getFormeId type="string">,
<dtml-sqlvar getGammeId type="string">,
<dtml-sqlvar getDefaultDestinationReference type="string">, <dtml-sqlvar getDefaultDestinationReference type="string">,
<dtml-sqlvar getDefaultSourceTitle type="string">, <dtml-sqlvar getDefaultSourceTitle type="string">,
<dtml-sqlvar getDefaultDestinationTitle type="string">, <dtml-sqlvar getDefaultDestinationTitle type="string">,
<dtml-sqlvar getDefaultSourceSectionTitle type="string">, <dtml-sqlvar getDefaultSourceSectionTitle type="string">,
<dtml-sqlvar getDefaultDestinationSectionTitle type="string">, <dtml-sqlvar getDefaultDestinationSectionTitle type="string">,
<dtml-sqlvar getDefaultCausalityId type="string">, <dtml-sqlvar getDefaultCausalityId type="string">,
<dtml-sqlvar modele_state_modeliste type="string">, <dtml-sqlvar getLocation type="string">,
<dtml-sqlvar modele_state_gestionaire type="string">, <dtml-sqlvar getEan13Code type="string">,
<dtml-sqlvar forme_state type="string">, <dtml-sqlvar validation_state type="string">,
<dtml-sqlvar composant_state type="string">, <dtml-sqlvar payment_state type="string">,
<dtml-sqlvar vetement_state type="string">, <dtml-sqlvar event_state type="string">,
<dtml-sqlvar transform_state type="string">,
<dtml-sqlvar order_state type="string">,
<dtml-sqlvar delivery_state type="string">,
<dtml-sqlvar getSimulationState type="string">, <dtml-sqlvar getSimulationState type="string">,
<dtml-sqlvar causality_state type="string">, <dtml-sqlvar causality_state type="string">,
<dtml-sqlvar discussion_state type="string">, <dtml-sqlvar discussion_state type="string">,
<dtml-sqlvar invoice_state type="string">,
<dtml-sqlvar getOrderId type="string">, <dtml-sqlvar getOrderId type="string">,
<dtml-if samples_delivery_check>1<dtml-else>0</dtml-if>, <dtml-sqlvar getReference type="string">,
<dtml-sqlvar modele_state_infos_client type="string">, <dtml-sqlvar getSourceReference type="string">,
<dtml-sqlvar modele_state_accord_technique type="string">, <dtml-sqlvar getDestinationReference type="string">,
<dtml-sqlvar summary type="string"> <dtml-sqlvar summary type="string">,
); <dtml-sqlvar getStringIndex type="string">,
\ No newline at end of file <dtml-sqlvar getIntIndex type="int">,
<dtml-sqlvar getFloatIndex type="float">,
<dtml-sqlvar getStringIndex2 type="string">,
<dtml-sqlvar getIntIndex2 type="int">,
<dtml-sqlvar getFloatIndex2 type="float">
);
...@@ -62,6 +62,12 @@ CREATE TABLE `catalog` ( ...@@ -62,6 +62,12 @@ CREATE TABLE `catalog` (
`source_reference` varchar(30) default '', `source_reference` varchar(30) default '',
`destination_reference` varchar(30) default '', `destination_reference` varchar(30) default '',
`summary` text, `summary` text,
`string_index` varchar(30),
`int_index` int(11),
`float_index` real,
`string_index2` varchar(30),
`int_index2` int(11),
`float_index2` real,
PRIMARY KEY (`uid`), PRIMARY KEY (`uid`),
KEY `security_uid` (`security_uid`), KEY `security_uid` (`security_uid`),
KEY `Parent` (`parent_uid`), KEY `Parent` (`parent_uid`),
......
...@@ -8,10 +8,10 @@ class_name: ...@@ -8,10 +8,10 @@ class_name:
class_file: class_file:
</dtml-comment> </dtml-comment>
<params></params> <params></params>
# Host: # Host:
# Database: test # Database: test
# Table: 'movement' # Table: 'movement'
# #
CREATE TABLE `movement` ( CREATE TABLE `movement` (
`uid` int(11) default '0', `uid` int(11) default '0',
`delivery_uid` int(11) default '0', `delivery_uid` int(11) default '0',
...@@ -34,6 +34,7 @@ CREATE TABLE `movement` ( ...@@ -34,6 +34,7 @@ CREATE TABLE `movement` (
`is_deliverable` bool, `is_deliverable` bool,
`variation_text` VARCHAR(100), `variation_text` VARCHAR(100),
KEY `uid` (`uid`), KEY `uid` (`uid`),
KEY `delivery_uid` (`delivery_uid`),
KEY `source_uid` (`source_uid`), KEY `source_uid` (`source_uid`),
KEY `destination_uid` (`destination_uid`), KEY `destination_uid` (`destination_uid`),
KEY `resource_uid` (`resource_uid`), KEY `resource_uid` (`resource_uid`),
...@@ -42,4 +43,4 @@ CREATE TABLE `movement` ( ...@@ -42,4 +43,4 @@ CREATE TABLE `movement` (
KEY `is_orderable` (`is_orderable`), KEY `is_orderable` (`is_orderable`),
KEY `is_deliverable` (`is_deliverable`), KEY `is_deliverable` (`is_deliverable`),
KEY `variation_text` (`variation_text`) KEY `variation_text` (`variation_text`)
) TYPE=InnoDB; ) TYPE=InnoDB;
...@@ -8,17 +8,24 @@ class_name: ...@@ -8,17 +8,24 @@ class_name:
class_file: class_file:
</dtml-comment> </dtml-comment>
<params></params> <params></params>
# Host: # Host:
# Database: test # Database: test
# Table: 'stock' # Table: 'stock'
# #
CREATE TABLE `stock` ( CREATE TABLE `stock` (
`uid` int(11) NOT NULL default '0', `uid` int(11) NOT NULL default '0',
`node_uid` int(11), `node_uid` int(11),
`section_uid` int(11), `section_uid` int(11),
`quantity` real , `mirror_section_uid` int(11),
`resource_uid` int(11),
`quantity` real ,
`total_asset_price` real ,
KEY `uid` (`uid`), KEY `uid` (`uid`),
KEY `quantity` (`quantity`), KEY `quantity` (`quantity`),
KEY `section_uid` (`section_uid`), KEY `section_uid` (`section_uid`),
KEY `node_uid` (`node_uid`) KEY `mirror_section_uid` (`mirror_section_uid`),
) TYPE = InnoDB; KEY `node_uid` (`node_uid`),
KEY `resource_uid` (`resource_uid`),
KEY `resource_node_uid` (`resource_uid`, `node_uid`),
KEY `resource_section_node_uid` (`resource_uid`, `section_uid`, `node_uid`)
) TYPE = InnoDB;
...@@ -56,14 +56,20 @@ event_state ...@@ -56,14 +56,20 @@ event_state
getReference getReference
getSourceReference getSourceReference
getDestinationReference getDestinationReference
insert_catalog_line</params> insert_catalog_line
getStringIndex
getIntIndex
getFloatIndex
getStringIndex2
getIntIndex2
getFloatIndex2</params>
<dtml-if insert_catalog_line> <dtml-if insert_catalog_line>
INSERT INTO catalog(uid) VALUES (<dtml-sqlvar uid type="int">); INSERT INTO catalog(uid) VALUES (<dtml-sqlvar uid type="int">);
<dtml-var "'\0'"> <dtml-var "'\0'">
</dtml-if> </dtml-if>
UPDATE catalog SET uid=<dtml-sqlvar uid type="int">, UPDATE catalog SET uid=<dtml-sqlvar uid type="int">,
security_uid=<dtml-sqlvar security_uid type="int">, security_uid=<dtml-sqlvar security_uid type="int">,
path=<dtml-sqlvar getPath type="string">, path=<dtml-sqlvar getPath type="string">,
relative_url=<dtml-sqlvar getRelativeUrl type="string">, relative_url=<dtml-sqlvar getRelativeUrl type="string">,
...@@ -71,24 +77,24 @@ UPDATE catalog SET uid=<dtml-sqlvar uid type="int">, ...@@ -71,24 +77,24 @@ UPDATE catalog SET uid=<dtml-sqlvar uid type="int">,
CreationDate=<dtml-sqlvar CreationDate type="string">, CreationDate=<dtml-sqlvar CreationDate type="string">,
Creator=<dtml-sqlvar Creator type="string">, Creator=<dtml-sqlvar Creator type="string">,
Date=<dtml-sqlvar Date type="string">, Date=<dtml-sqlvar Date type="string">,
Description=<dtml-sqlvar getDescription type="string">, Description=<dtml-sqlvar getDescription type="string">,
PrincipiaSearchSource=<dtml-sqlvar PrincipiaSearchSource type="string">, PrincipiaSearchSource=<dtml-sqlvar PrincipiaSearchSource type="string">,
SearchableText=<dtml-sqlvar SearchableText type="string">, SearchableText=<dtml-sqlvar SearchableText type="string">,
EffectiveDate=<dtml-sqlvar EffectiveDate type="string">, EffectiveDate=<dtml-sqlvar EffectiveDate type="string">,
ExpiresDate=<dtml-sqlvar ExpiresDate type="string">, ExpiresDate=<dtml-sqlvar ExpiresDate type="string">,
ModificationDate=<dtml-sqlvar ModificationDate type="string">, ModificationDate=<dtml-sqlvar ModificationDate type="string">,
Title=<dtml-sqlvar getTitle type="string">, Title=<dtml-sqlvar getTitle type="string">,
Type=<dtml-sqlvar Type type="string">, Type=<dtml-sqlvar Type type="string">,
bobobase_modification_time=<dtml-sqlvar bobobase_modification_time type="string">, bobobase_modification_time=<dtml-sqlvar bobobase_modification_time type="string">,
created=<dtml-sqlvar created type="string">, created=<dtml-sqlvar created type="string">,
effective=<dtml-sqlvar effective type="string">, effective=<dtml-sqlvar effective type="string">,
expires=<dtml-sqlvar expires type="string">, expires=<dtml-sqlvar expires type="string">,
getIcon=<dtml-sqlvar getIcon type="string">, getIcon=<dtml-sqlvar getIcon type="string">,
id=<dtml-sqlvar id type="string">, id=<dtml-sqlvar id type="string">,
in_reply_to=<dtml-sqlvar in_reply_to type="string">, in_reply_to=<dtml-sqlvar in_reply_to type="string">,
meta_type=<dtml-sqlvar meta_type type="string">, meta_type=<dtml-sqlvar meta_type type="string">,
portal_type=<dtml-sqlvar getPortalType type="string">, portal_type=<dtml-sqlvar getPortalType type="string">,
modified=<dtml-sqlvar modified type="string">, modified=<dtml-sqlvar modified type="string">,
review_state=<dtml-sqlvar review_state type="string">, review_state=<dtml-sqlvar review_state type="string">,
opportunity_state=<dtml-sqlvar opportunity_state type="string">, opportunity_state=<dtml-sqlvar opportunity_state type="string">,
default_source_reference=<dtml-sqlvar getDefaultSourceReference type="string">, default_source_reference=<dtml-sqlvar getDefaultSourceReference type="string">,
...@@ -108,8 +114,15 @@ UPDATE catalog SET uid=<dtml-sqlvar uid type="int">, ...@@ -108,8 +114,15 @@ UPDATE catalog SET uid=<dtml-sqlvar uid type="int">,
event_state=<dtml-sqlvar event_state type="string">, event_state=<dtml-sqlvar event_state type="string">,
invoice_state=<dtml-sqlvar invoice_state type="string">, invoice_state=<dtml-sqlvar invoice_state type="string">,
order_id=<dtml-sqlvar getOrderId type="string">, order_id=<dtml-sqlvar getOrderId type="string">,
reference=<dtml-sqlvar getReference type="string">, reference=<dtml-sqlvar getReference type="string">,
source_reference=<dtml-sqlvar getSourceReference type="string">, source_reference=<dtml-sqlvar getSourceReference type="string">,
destination_reference=<dtml-sqlvar getDestinationReference type="string">, destination_reference=<dtml-sqlvar getDestinationReference type="string">,
summary=<dtml-sqlvar summary type="string"> summary=<dtml-sqlvar summary type="string">,
string_index=<dtml-sqlvar getStringIndex type="string">,
int_index=<dtml-if getIntIndex><dtml-sqlvar getIntIndex type="int"><dtml-else>NULL</dtml-if>,
float_index=<dtml-if getFloatIndex><dtml-sqlvar getFloatIndex type="float"><dtml-else>NULL</dtml-if>,
string_index2=<dtml-sqlvar getStringIndex2 type="string">,
int_index2=<dtml-if getIntIndex2><dtml-sqlvar getIntIndex2 type="int"><dtml-else>NULL</dtml-if>,
float_index2=<dtml-if getFloatIndex2><dtml-sqlvar getFloatIndex2 type="float"><dtml-else>NULL</dtml-if>
WHERE <dtml-sqltest uid op=eq type=int> ; WHERE <dtml-sqltest uid op=eq type=int> ;
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment