mirror of
https://git.imnavajas.es/jjimenez/safekat.git
synced 2025-07-25 22:52:08 +00:00
ordenes trabajo
This commit is contained in:
@ -33,6 +33,14 @@ class OrdenTrabajoTable extends Migration
|
||||
"comment" => "Usuario que ha actualizado la orden de trabajo",
|
||||
|
||||
],
|
||||
"fecha_entrega_warning" => [
|
||||
"type" => "BOOLEAN",
|
||||
"default" => false
|
||||
],
|
||||
"fecha_entrega_warning_revised" => [
|
||||
"type" => "BOOLEAN",
|
||||
"default" => false
|
||||
],
|
||||
"total_tirada" => [
|
||||
"type" => "DOUBLE",
|
||||
"null" => true
|
||||
@ -56,11 +64,60 @@ class OrdenTrabajoTable extends Migration
|
||||
|
||||
"estado" => [
|
||||
"type" => "ENUM",
|
||||
"constraint" => ["I","F","P","E"],
|
||||
"constraint" => ["I", "F", "E","PM"],
|
||||
"default" => "I",
|
||||
"comment" => "I => INICIADO, F => FINALIZADO, P => PROGRESO , E => ERROR"
|
||||
"comment" => "I => INICIADO, F => FINALIZADO, P => PENDIENTE , PM=> PENDIENTE_MATERIAL , E => ERROR"
|
||||
],
|
||||
/**============================================
|
||||
* PREIMPRESION
|
||||
*=============================================**/
|
||||
"revisar_formato" => [
|
||||
"type" => "BOOLEAN",
|
||||
"default" => false,
|
||||
"comment" => "Realizar revision del formato"
|
||||
],
|
||||
"revisar_lomo" => [
|
||||
"type" => "BOOLEAN",
|
||||
"default" => false,
|
||||
"comment" => "Realizar revision del lomo"
|
||||
],
|
||||
"revisar_solapa" => [
|
||||
"type" => "BOOLEAN",
|
||||
"default" => false,
|
||||
"comment" => "Realizar revision de la solapa"
|
||||
|
||||
],
|
||||
"revisar_isbn" => [
|
||||
"type" => "BOOLEAN",
|
||||
"default" => false,
|
||||
"comment" => "Realizar revision del ISBN"
|
||||
|
||||
],
|
||||
"revisar_codigo_barras" => [
|
||||
"type" => "BOOLEAN",
|
||||
"default" => false,
|
||||
"comment" => "Realizar revision del codigo de barras"
|
||||
|
||||
],
|
||||
"realizar_imposicion" => [
|
||||
"type" => "BOOLEAN",
|
||||
"default" => false,
|
||||
"comment" => "Realizar revision imposicion"
|
||||
|
||||
],
|
||||
"enviar_impresion" => [
|
||||
"type" => "BOOLEAN",
|
||||
"default" => false,
|
||||
"comment" => "Realizar revision impresion"
|
||||
|
||||
],
|
||||
"portada_path" => [
|
||||
"type" => "TEXT",
|
||||
"default" => null,
|
||||
"null" => true,
|
||||
"comment" => "Path al archivo de portada"
|
||||
|
||||
],
|
||||
"comentarios" => [
|
||||
"type" => "TEXT",
|
||||
"null" => true,
|
||||
@ -90,9 +147,9 @@ class OrdenTrabajoTable extends Migration
|
||||
],
|
||||
]);
|
||||
$this->forge->addPrimaryKey("id");
|
||||
$this->forge->addForeignKey("pedido_id","pedidos","id");
|
||||
$this->forge->addForeignKey("user_created_id","users","id");
|
||||
$this->forge->addForeignKey("user_updated_id","users","id");
|
||||
$this->forge->addForeignKey("pedido_id", "pedidos", "id");
|
||||
$this->forge->addForeignKey("user_created_id", "users", "id");
|
||||
$this->forge->addForeignKey("user_updated_id", "users", "id");
|
||||
|
||||
$this->forge->createTable("ordenes_trabajo", true);
|
||||
}
|
||||
|
||||
@ -99,6 +99,11 @@ class OrdenTrabajoTareasTable extends Migration
|
||||
"default" => 0.00,
|
||||
"null" => true,
|
||||
"comment" => "Tiempo ejecución real de la tarea",
|
||||
],
|
||||
"comment" => [
|
||||
"type" => "TEXT",
|
||||
"null" => true,
|
||||
"comment" => "Comentario sobre la tarea",
|
||||
]
|
||||
];
|
||||
public function up()
|
||||
@ -129,7 +134,6 @@ class OrdenTrabajoTareasTable extends Migration
|
||||
$this->forge->addForeignKey("presupuesto_manipulado_id","presupuesto_manipulados","id");
|
||||
$this->forge->addForeignKey("presupuesto_preimpresion_id","presupuesto_preimpresiones","id");
|
||||
$this->forge->addForeignKey("presupuesto_extra_id","presupuesto_serviciosExtra","id");
|
||||
|
||||
$this->forge->addForeignKey("imposicion_id","lg_imposiciones","id");
|
||||
$this->forge->addForeignKey("maquina_id","lg_maquinas","id");
|
||||
$this->forge->createTable("orden_trabajo_tareas");
|
||||
|
||||
@ -13,26 +13,23 @@ class OrdenTrabajoDatesTable extends Migration
|
||||
"unsigned" => true,
|
||||
],
|
||||
"fecha_entrada_at" => [
|
||||
"type" => "DATETIME",
|
||||
"type" => "DATE",
|
||||
"null" => true,
|
||||
],
|
||||
"fecha_entrega_at" => [
|
||||
"type" => "DATETIME",
|
||||
"type" => "DATE",
|
||||
"null" => true,
|
||||
],
|
||||
"fecha_entrega_change_at" => [
|
||||
"type" => "DATETIME",
|
||||
"type" => "DATE",
|
||||
"null" => true,
|
||||
],
|
||||
|
||||
"fecha_entrega_real_at" => [
|
||||
"type" => "DATETIME",
|
||||
"type" => "DATE",
|
||||
"null" => true,
|
||||
],
|
||||
"fecha_entrega_real_warning" => [
|
||||
"type" => "BOOLEAN",
|
||||
"default" => false,
|
||||
],
|
||||
|
||||
"fecha_impresion_at" => [
|
||||
"type" => "DATE",
|
||||
"null" => true,
|
||||
@ -45,105 +42,97 @@ class OrdenTrabajoDatesTable extends Migration
|
||||
"type" => "DATE",
|
||||
"null" => true,
|
||||
],
|
||||
"fecha_entrega_warning" => [
|
||||
"type" => "BOOLEAN",
|
||||
"default" => false
|
||||
],
|
||||
"fecha_entrega_warning_revised" => [
|
||||
"type" => "BOOLEAN",
|
||||
"default" => false
|
||||
],
|
||||
|
||||
|
||||
"pendiente_ferro_at" => [
|
||||
"type" => "DATETIME",
|
||||
"type" => "DATE",
|
||||
"null" => true,
|
||||
],
|
||||
"ferro_en_cliente_at" => [
|
||||
"type" => "DATETIME",
|
||||
"type" => "DATE",
|
||||
"null" => true,
|
||||
],
|
||||
"ferro_ok_at" => [
|
||||
"type" => "DATETIME",
|
||||
"type" => "DATE",
|
||||
"null" => true,
|
||||
],
|
||||
"interior_bn_at" => [
|
||||
"type" => "DATETIME",
|
||||
"type" => "DATE",
|
||||
"null" => true,
|
||||
],
|
||||
"interior_color_at" => [
|
||||
"type" => "DATETIME",
|
||||
"type" => "DATE",
|
||||
"null" => true,
|
||||
],
|
||||
"preparacion_interiores_at" => [
|
||||
"type" => "DATETIME",
|
||||
"type" => "DATE",
|
||||
"null" => true,
|
||||
],
|
||||
"cubierta_at" => [
|
||||
"type" => "DATETIME",
|
||||
"type" => "DATE",
|
||||
"null" => true,
|
||||
],
|
||||
"plastificado_at" => [
|
||||
"type" => "DATETIME",
|
||||
"type" => "DATE",
|
||||
"null" => true,
|
||||
],
|
||||
"encuadernacion_at" => [
|
||||
"type" => "DATETIME",
|
||||
"type" => "DATE",
|
||||
"null" => true,
|
||||
],
|
||||
"corte_at" => [
|
||||
"type" => "DATETIME",
|
||||
"type" => "DATE",
|
||||
"null" => true,
|
||||
],
|
||||
"embalaje_at" => [
|
||||
"type" => "DATETIME",
|
||||
"type" => "DATE",
|
||||
"null" => true,
|
||||
],
|
||||
"envio_at" => [
|
||||
"type" => "DATETIME",
|
||||
"type" => "DATE",
|
||||
"null" => true,
|
||||
],
|
||||
"entrada_manipulado_at" => [
|
||||
"type" => "DATETIME",
|
||||
"type" => "DATE",
|
||||
"null" => true,
|
||||
],
|
||||
|
||||
|
||||
"ferro_disponible_hecho_at" => [
|
||||
"type" => "DATETIME",
|
||||
"type" => "DATE",
|
||||
"null" => true,
|
||||
],
|
||||
|
||||
"ferro_disponible_ok_at" => [
|
||||
"type" => "DATETIME",
|
||||
"type" => "DATE",
|
||||
"null" => true,
|
||||
],
|
||||
|
||||
"ferro_entregado_at" => [
|
||||
"type" => "DATETIME",
|
||||
"type" => "DATE",
|
||||
"null" => true,
|
||||
],
|
||||
"pre_formato_at" => [
|
||||
"type" => "DATETIME",
|
||||
"type" => "DATE",
|
||||
"null" => true,
|
||||
],
|
||||
|
||||
"pre_lomo_at" => [
|
||||
"type" => "DATETIME",
|
||||
"type" => "DATE",
|
||||
"null" => true,
|
||||
],
|
||||
|
||||
"pre_solapa_at" => [
|
||||
"type" => "DATETIME",
|
||||
"type" => "DATE",
|
||||
"null" => true,
|
||||
],
|
||||
|
||||
"pre_codbarras_at" => [
|
||||
"type" => "DATETIME",
|
||||
"type" => "DATE",
|
||||
"null" => true,
|
||||
],
|
||||
|
||||
"pre_imposicion_at" => [
|
||||
"type" => "DATETIME",
|
||||
"type" => "DATE",
|
||||
"null" => true,
|
||||
],
|
||||
];
|
||||
|
||||
@ -9,21 +9,28 @@ class OrdenTrabajoUsers extends Migration
|
||||
{
|
||||
protected array $COLUMNS = [
|
||||
|
||||
"orden_trabajo_id" => [
|
||||
"type" => "INT",
|
||||
"unsigned" => true,
|
||||
],
|
||||
|
||||
"user_created_id" => [
|
||||
"type" => "INT",
|
||||
"unsigned" => true,
|
||||
"constraint" => 10,
|
||||
"null" => true,
|
||||
],
|
||||
"user_update_id" => [
|
||||
"type" => "INT",
|
||||
"unsigned" => true,
|
||||
"constraint" => 10,
|
||||
"null" => true,
|
||||
],
|
||||
"inaplazable_revised_change_user_id" => [
|
||||
"type" => "INT",
|
||||
"unsigned" => true,
|
||||
"constraint" => 10,
|
||||
"null" => true,
|
||||
],
|
||||
|
||||
|
||||
@ -31,33 +38,39 @@ class OrdenTrabajoUsers extends Migration
|
||||
"type" => "INT",
|
||||
"unsigned" => true,
|
||||
"constraint" => 10,
|
||||
"null" => true,
|
||||
],
|
||||
|
||||
"ferro_disponible_ok_user_id" => [
|
||||
"type" => "INT",
|
||||
"unsigned" => true,
|
||||
"constraint" => 10,
|
||||
"null" => true,
|
||||
],
|
||||
"ferro_entregado_user_id" => [
|
||||
"type" => "INT",
|
||||
"unsigned" => true,
|
||||
"constraint" => 10,
|
||||
"null" => true,
|
||||
],
|
||||
|
||||
"pendiente_ferro_user_id" => [
|
||||
"type" => "INT",
|
||||
"unsigned" => true,
|
||||
"constraint" => 10,
|
||||
"null" => true,
|
||||
],
|
||||
"ferro_en_cliente_user_id" => [
|
||||
"type" => "INT",
|
||||
"unsigned" => true,
|
||||
"constraint" => 10,
|
||||
"null" => true,
|
||||
],
|
||||
"ferro_ok_user_id" => [
|
||||
"type" => "INT",
|
||||
"unsigned" => true,
|
||||
"constraint" => 10,
|
||||
"null" => true,
|
||||
],
|
||||
|
||||
|
||||
@ -66,51 +79,61 @@ class OrdenTrabajoUsers extends Migration
|
||||
"type" => "INT",
|
||||
"unsigned" => true,
|
||||
"constraint" => 10,
|
||||
"null" => true,
|
||||
],
|
||||
"interior_color_user_id" => [
|
||||
"type" => "INT",
|
||||
"unsigned" => true,
|
||||
"constraint" => 10,
|
||||
"null" => true,
|
||||
],
|
||||
"preparacion_interior_user_id" => [
|
||||
"type" => "INT",
|
||||
"unsigned" => true,
|
||||
"constraint" => 10,
|
||||
"null" => true,
|
||||
],
|
||||
"cubierda_user_id" => [
|
||||
"cubierta_user_id" => [
|
||||
"type" => "INT",
|
||||
"unsigned" => true,
|
||||
"constraint" => 10,
|
||||
"null" => true,
|
||||
],
|
||||
"plastificado_user_id" => [
|
||||
"type" => "INT",
|
||||
"unsigned" => true,
|
||||
"constraint" => 10,
|
||||
"null" => true,
|
||||
],
|
||||
"encuadernacion_user_id" => [
|
||||
"type" => "INT",
|
||||
"unsigned" => true,
|
||||
"constraint" => 10,
|
||||
"null" => true,
|
||||
],
|
||||
"corte_user_id" => [
|
||||
"type" => "INT",
|
||||
"unsigned" => true,
|
||||
"constraint" => 10,
|
||||
"null" => true,
|
||||
],
|
||||
"embalaje_user_id" => [
|
||||
"type" => "INT",
|
||||
"unsigned" => true,
|
||||
"constraint" => 10,
|
||||
"null" => true,
|
||||
],
|
||||
"envio_user_id" => [
|
||||
"type" => "INT",
|
||||
"unsigned" => true,
|
||||
"constraint" => 10,
|
||||
"null" => true,
|
||||
],
|
||||
"entrada_manipulado_user_id" => [
|
||||
"type" => "INT",
|
||||
"unsigned" => true,
|
||||
"constraint" => 10,
|
||||
"null" => true,
|
||||
],
|
||||
|
||||
|
||||
@ -118,6 +141,7 @@ class OrdenTrabajoUsers extends Migration
|
||||
"type" => "INT",
|
||||
"unsigned" => true,
|
||||
"constraint" => 10,
|
||||
"null" => true,
|
||||
],
|
||||
|
||||
|
||||
@ -125,12 +149,14 @@ class OrdenTrabajoUsers extends Migration
|
||||
"type" => "INT",
|
||||
"unsigned" => true,
|
||||
"constraint" => 10,
|
||||
"null" => true,
|
||||
],
|
||||
|
||||
"pre_solapa_user_id" => [
|
||||
"type" => "INT",
|
||||
"unsigned" => true,
|
||||
"constraint" => 10,
|
||||
"null" => true,
|
||||
],
|
||||
|
||||
|
||||
@ -138,22 +164,26 @@ class OrdenTrabajoUsers extends Migration
|
||||
"type" => "INT",
|
||||
"unsigned" => true,
|
||||
"constraint" => 10,
|
||||
"null" => true,
|
||||
],
|
||||
|
||||
"pre_imposicion_user_id" => [
|
||||
"type" => "INT",
|
||||
"unsigned" => true,
|
||||
"constraint" => 10,
|
||||
"null" => true,
|
||||
],
|
||||
"pre_imprimir_user_id" => [
|
||||
"type" => "INT",
|
||||
"unsigned" => true,
|
||||
"constraint" => 10,
|
||||
"null" => true,
|
||||
],
|
||||
"pre_imprimir_user_id" => [
|
||||
"type" => "INT",
|
||||
"unsigned" => true,
|
||||
"constraint" => 10,
|
||||
"null" => true,
|
||||
],
|
||||
];
|
||||
public function up()
|
||||
@ -180,7 +210,10 @@ class OrdenTrabajoUsers extends Migration
|
||||
foreach ($this->COLUMNS as $key => $value) {
|
||||
$this->forge->addForeignKey([$key],"users",["id"]);
|
||||
}
|
||||
$this->forge->addPrimaryKey("orden_trabajo_id");
|
||||
// $this->forge->addForeignKey(["ordenes_trabajo_id"],"ordenes_trabajo",["id"]);
|
||||
$this->forge->createTable("orden_trabajo_users", true);
|
||||
|
||||
}
|
||||
|
||||
public function down()
|
||||
|
||||
Reference in New Issue
Block a user