123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566 |
- <?php
- namespace app\models;
- use Yii;
- /**
- * This is the model class for table "ConceptosObra".
- *
- * @property string $id
- * @property string $idObra
- * @property string $idConceptoObra
- * @property string|null $cantidad
- * @property string|null $descripcion
- * @property string $fechaCompra
- *
- */
- class Pago extends ModeloBase
- {
- /**
- * {@inheritdoc}
- */
- public static function tableName()
- {
- return 'Pago';
- }
- /**
- * {@inheritdoc}
- */
- public function rules()
- {
- return [
- [['id','idObra','idConceptoObra'], 'required'],
- [['creado', 'modificado', 'eliminado','fechaPago'], 'safe'],
- [['cantidad'], 'integer'],
- [['cantidad'], 'default', 'value' => null],
- [['id', 'idObra','idConceptoObra'], 'string', 'max' => 36],
- [[ 'descripcion'], 'string', 'max' => 100],
- [['idObra'], 'exist', 'skipOnError' => true, 'targetClass' => Obra::class, 'targetAttribute' => ['idObra' => 'id']],
- [['idConceptoObra'], 'exist', 'skipOnError' => true, 'targetClass' => ConceptosObra::class, 'targetAttribute' => ['idConceptoObra' => 'id']],
- ];
- }
- /**
- * {@inheritdoc}
- */
- public function attributeLabels()
- {
- return [
- 'id' => 'ID',
- 'idObra' => 'ID de la Obra',
- 'idConceptoObra' => 'ID del Concepto Obra',
- 'cantidad' => 'Cantidad',
- 'descripcion' => 'Descripcion',
- 'fechaPago' => 'Fecha de Pago',
- 'creado' => 'Creado',
- 'modificado' => 'Modificado',
- 'eliminado' => 'Eliminado',
- ];
- }
- }
|