ef2c9d1e1c83223c279faa8e2b1fe2df5219c7f9,modules/s3db/dc.py,DataCollectionTemplateModel,dc_question_onaccept,#Any#,575

Before Change


            else:
                field_type = "string"
            other = question_settings.get("other")
            if other:
                //@ ToDo
                pass
        elif field_type == 7:
            // "Date"
            field_type = "date"
        elif field_type == 8:

After Change


                    // Create the Dynamic Field
                    // Lookup the table_id
                    ttable = db.dc_template
                    template = db(ttable.id == question.template_id).select(ttable.table_id,
                                                                            limitby=(0, 1)
                                                                            ).first()
                    from uuid import uuid1
                    name = "f%s" % str(uuid1()).replace("-", "_")
                    field_id = current.s3db.s3_field.insert(table_id = template.table_id,
                                                            label = other,
                                                            name = name,
                                                            field_type = "text",
Italian Trulli
In pattern: SUPERPATTERN

Frequency: 3

Non-data size: 10

Instances


Project Name: sahana/eden
Commit Name: ef2c9d1e1c83223c279faa8e2b1fe2df5219c7f9
Time: 2019-08-18
Author: fran@aidiq.com
File Name: modules/s3db/dc.py
Class Name: DataCollectionTemplateModel
Method Name: dc_question_onaccept


Project Name: sahana/eden
Commit Name: 3ae77833389609a2c958c745e47086ece9efef73
Time: 2020-03-30
Author: fran@aidiq.com
File Name: modules/s3/s3gis.py
Class Name: GIS
Method Name: set_config


Project Name: sahana/eden
Commit Name: 2e268c86eee6a1753d16afe23388c9f26dd0f7ca
Time: 2020-01-27
Author: fran@aidiq.com
File Name: modules/s3db/setup.py
Class Name: S3SetupMonitorModel
Method Name: setup_monitor_task_onaccept