예제 #1
0
	public function edit() {
		global $wgOut, $wgTitle, $wgUser;

		if ( !parent::edit() ) {
			return false;
		}
		$this->outputEditHeader();

		$spelling = $wgTitle->getText();

		$wgOut->addHTML(
			getExpressionsEditor( $spelling, $this->viewInformation )->edit(
				$this->getIdStack(),
				getExpressionsRecordSet( $spelling, $this->viewInformation )
			)
		);

		$this->outputEditFooter();
	}
	public function edit() {
		global
			$wgOut, $wgTitle;

		if ( !parent::edit() ) return false;

		$definedMeaningId = $this->getDefinedMeaningIdFromTitle( $wgTitle->getText() );

		$this->outputEditHeader();
		$dmModel = new DefinedMeaningModel( $definedMeaningId, $this->viewInformation );
		
		if ( is_null( $dmModel->getRecord() ) ) {
			$wgOut->addHTML( wfMsgSc( "db_consistency__not_found" ) . " ID:$definedMeaningId" );
			return;
		}
		
		$wgOut->addHTML(
			getDefinedMeaningEditor( $this->viewInformation )->edit(
				$this->getIdStack( $dmModel->getId() ),
				$dmModel->getRecord()
			)
		);
		$this->outputEditFooter();
	}